Worlds API (Draft WIP) - lolmaxz/vrc-ts GitHub Wiki
The World API allows you to manage worlds in VRChat—create, update, delete, and search for worlds.
-
searchAllWorlds
- Search and list any worlds by query filters. -
createWorld
- Create a new world. -
listActiveWorlds
- Search and list currently active worlds. -
listFavoritedWorlds
- Search and list favorited worlds. -
listRecentWorlds
- Search and list recently visited worlds. -
getWorldById
- Get information about a specific world. -
updateWorld
- Update information about a specific world. -
deleteWorld
- Delete a world. -
getWorldMetadata
- Get a world's metadata (deprecated). -
getWorldPublishStatus
- Get a world's publish status. -
publishWorld
- Publish a world. -
unpublishWorld
- Unpublish a world. -
getWorldInstance
- Get information about a world instance.
Search and list any worlds by query filters.
Search and list any worlds by applying various query filters.
searchAllWorlds(options: {
featured?: boolean;
sort?: string;
n?: number;
offset?: number;
order?: 'ascending' | 'descending';
search?: string;
tag?: string;
notag?: string;
releaseStatus?: 'public' | 'private' | 'hidden' | 'all';
maxUnityVersion?: string;
minUnityVersion?: string;
platform?: string;
user?: 'me';
userId?: string;
developer?: 'none' | 'internal';
fuzzy?: boolean;
includeInstances?: boolean;
}): Promise<LimitedWorld[]>
-
options
(object):-
featured
(boolean, optional):
Filter by featured worlds. Default isfalse
. -
sort
(string, optional):
Sorting option. Default is'popularity'
. -
n
(number, optional):
Number of results to return (1-100). Default is10
. -
offset
(number, optional):
Offset from the first result. Must be 0 or greater. -
order
('ascending'
|'descending'
, optional):
Order of the results. Default is'descending'
. -
search
(string, optional):
Search query string. -
tag
(string, optional):
Tag to include. -
notag
(string, optional):
Tag to exclude. -
releaseStatus
('public'
|'private'
|'hidden'
|'all'
, optional):
Release status to filter by. -
maxUnityVersion
(string, optional):
Maximum Unity version. -
minUnityVersion
(string, optional):
Minimum Unity version. -
platform
(string, optional):
Platform to filter by. -
user
('me'
, optional):
User filter. Only'me'
is allowed for non-admin users. -
userId
(string, optional):
User ID to filter by. -
developer
('none'
|'internal'
, optional):
Developer type to filter by. -
fuzzy
(boolean, optional):
Enable fuzzy search. Default isfalse
. -
includeInstances
(boolean, optional):
Include instance information. Default isfalse
.
-
-
Promise<LimitedWorld[]>
: A promise that resolves to an array of limited world objects.
// Example: Search for public worlds with the tag 'game'
const worlds = await vrchatApi.worldsApi.searchAllWorlds({
tag: 'game',
releaseStatus: 'public',
n: 20,
});
console.log(worlds);
Create a new world.
Create a new world. Requires valid asset URLs and image URLs.
createWorld(options: {
assetUrl: string;
assetVersion?: number;
authorId?: string;
authorName?: string;
capacity?: number;
description?: string;
id?: string;
imageUrl: string;
name: string;
platform?: string;
releaseStatus?: 'public' | 'private' | 'hidden' | 'all';
tags?: string[];
unityPackageUrl?: string;
unityVersion?: string;
}): Promise<World>
-
options
(object):-
assetUrl
(string, required):
The asset URL of the world. -
imageUrl
(string, required):
The image URL of the world. -
name
(string, required):
Name of the world. -
Other optional fields:
-
assetVersion
(number, optional) -
authorId
(string, optional) -
authorName
(string, optional) -
capacity
(number, optional) -
description
(string, optional) -
id
(string, optional) -
platform
(string, optional) -
releaseStatus
('public'
|'private'
|'hidden'
|'all'
, optional) -
tags
(string[], optional) -
unityPackageUrl
(string, optional) -
unityVersion
(string, optional)
-
-
-
Promise<World>
: A promise that resolves to the created world object.
// Example: Create a new world
const newWorld = await vrchatApi.worldsApi.createWorld({
assetUrl: 'https://example.com/asset.vrcw',
imageUrl: 'https://example.com/image.png',
name: 'My New World',
description: 'A wonderful new world to explore.',
capacity: 16,
tags: ['exploration', 'fun'],
releaseStatus: 'private',
});
console.log(newWorld);
Search and list currently active worlds.
Search and list currently active worlds by applying various query filters.
listActiveWorlds(options?: {
n?: number;
offset?: number;
sort?: string;
order?: 'ascending' | 'descending';
search?: string;
tag?: string;
notag?: string;
releaseStatus?: 'public' | 'private' | 'hidden' | 'all';
maxUnityVersion?: string;
minUnityVersion?: string;
platform?: string;
}): Promise<LimitedWorld[]>
-
options
(object, optional):-
n
(number, optional):
Number of results to return (1-100). Default is10
. -
Other optional fields:
Same as insearchAllWorlds
, excludingfeatured
,user
,userId
,developer
,fuzzy
, andincludeInstances
.
-
-
Promise<LimitedWorld[]>
: A promise that resolves to an array of limited world objects.
// Example: List active worlds sorted by popularity
const activeWorlds = await vrchatApi.worldsApi.listActiveWorlds({
sort: 'popularity',
n: 20,
});
console.log(activeWorlds);
Search and list favorited worlds.
Search and list favorited worlds by applying various query filters.
listFavoritedWorlds(options?: {
userId?: string;
n?: number;
offset?: number;
sort?: string;
order?: 'ascending' | 'descending';
search?: string;
tag?: string;
notag?: string;
releaseStatus?: 'public' | 'private' | 'hidden' | 'all';
maxUnityVersion?: string;
minUnityVersion?: string;
platform?: string;
}): Promise<LimitedWorld[]>
-
options
(object, optional):-
userId
(string, optional):
User ID to filter by. Admin only. -
Other optional fields:
Same as inlistActiveWorlds
.
-
-
Promise<LimitedWorld[]>
: A promise that resolves to an array of favorited world objects.
// Example: List your favorited worlds
const favoritedWorlds = await vrchatApi.worldsApi.listFavoritedWorlds();
console.log(favoritedWorlds);
Search and list recently visited worlds.
Search and list recently visited worlds by applying various query filters.
listRecentWorlds(options?: {
userId?: string;
n?: number;
offset?: number;
sort?: string;
order?: 'ascending' | 'descending';
search?: string;
tag?: string;
notag?: string;
releaseStatus?: 'public' | 'private' | 'hidden' | 'all';
maxUnityVersion?: string;
minUnityVersion?: string;
platform?: string;
}): Promise<LimitedWorld[]>
-
options
(object, optional):-
userId
(string, optional):
User ID to filter by. Admin only. -
Other optional fields:
Same as inlistActiveWorlds
.
-
-
Promise<LimitedWorld[]>
: A promise that resolves to an array of recently visited world objects.
// Example: List your recently visited worlds
const recentWorlds = await vrchatApi.worldsApi.listRecentWorlds();
console.log(recentWorlds);
Get information about a specific world.
Retrieve detailed information about a specific world by its ID.
getWorldById(options: { worldId: string }): Promise<World>
-
options
(object):-
worldId
(string, required):
The ID of the world to retrieve.
-
-
Promise<World>
: A promise that resolves to the world object.
// Example: Get information about a specific world
const worldId = 'wrld_12345678-1234-1234-1234-1234567890ab';
const worldInfo = await vrchatApi.worldsApi.getWorldById({ worldId });
console.log(worldInfo);
Update information about a specific world.
Update information about a specific world. You can update fields like name, description, tags, image URL, release status, etc.
updateWorld(options: {
worldId: string;
assetUrl?: string;
assetVersion?: string;
authorId?: string;
authorName?: string;
capacity?: number;
description?: string;
imageUrl?: string;
name?: string;
platform?: string;
releaseStatus?: 'public' | 'private' | 'hidden' | 'all';
tags?: string[];
unityPackageUrl?: string;
unityVersion?: string;
}): Promise<World>
-
options
(object):-
worldId
(string, required):
The ID of the world to update. -
Other optional fields:
Any of the fields you want to update (same as increateWorld
).
-
-
Promise<World>
: A promise that resolves to the updated world object.
// Example: Update the description of a world
const updatedWorld = await vrchatApi.worldsApi.updateWorld({
worldId: 'wrld_12345678-1234-1234-1234-1234567890ab',
description: 'An updated description for the world.',
});
console.log(updatedWorld);
Delete a world.
Delete a world. Note that a world is never fully "deleted"; only its releaseStatus
is set to 'hidden'
and the linked files are deleted. The worldId
is permanently reserved.
deleteWorld(options: { worldId: string }): Promise<Response>
-
options
(object):-
worldId
(string, required):
The ID of the world to delete.
-
-
Promise<Response>
: A promise that resolves to a response object indicating the result.
// Example: Delete a world
const response = await vrchatApi.worldsApi.deleteWorld({
worldId: 'wrld_12345678-1234-1234-1234-1234567890ab',
});
console.log(response);
Get a world's metadata (deprecated).
Retrieve a world's custom metadata. This endpoint is deprecated and may be removed in the future.
getWorldMetadata(options: { worldId: string }): Promise<WorldMetadata>
-
options
(object):-
worldId
(string, required):
The ID of the world to get metadata for.
-
-
Promise<WorldMetadata>
: A promise that resolves to the world's metadata object.
// Example: Get metadata for a world
const metadata = await vrchatApi.worldsApi.getWorldMetadata({
worldId: 'wrld_12345678-1234-1234-1234-1234567890ab',
});
console.log(metadata);
Note: This endpoint is deprecated and may not return useful data.
Get a world's publish status.
Check whether a world can be published.
getWorldPublishStatus(options: { worldId: string }): Promise<{ canPublish: boolean }>
-
options
(object):-
worldId
(string, required):
The ID of the world to check.
-
-
Promise<{ canPublish: boolean }>
: A promise that resolves to an object indicating if the world can be published.
// Example: Check if a world can be published
const publishStatus = await vrchatApi.worldsApi.getWorldPublishStatus({
worldId: 'wrld_12345678-1234-1234-1234-1234567890ab',
});
console.log(publishStatus); // { canPublish: true }
Publish a world.
Publish a world. You can only publish one world per week.
publishWorld(options: { worldId: string }): Promise<Response>
-
options
(object):-
worldId
(string, required):
The ID of the world to publish.
-
-
Promise<Response>
: A promise that resolves to a response object indicating the result.
// Example: Publish a world
const response = await vrchatApi.worldsApi.publishWorld({
worldId: 'wrld_12345678-1234-1234-1234-1234567890ab',
});
console.log(response);
Unpublish a world.
Unpublish a world.
unpublishWorld(options: { worldId: string }): Promise<Response>
-
options
(object):-
worldId
(string, required):
The ID of the world to unpublish.
-
-
Promise<Response>
: A promise that resolves to a response object indicating the result.
// Example: Unpublish a world
const response = await vrchatApi.worldsApi.unpublishWorld({
worldId: 'wrld_12345678-1234-1234-1234-1234567890ab',
});
console.log(response);
Get information about a world instance.
Retrieve information about a specific instance of a world.
getWorldInstance(options: {
worldId: string;
instanceId?: string;
}): Promise<Instance>
-
options
(object):-
worldId
(string, required):
The ID of the world. -
instanceId
(string, optional):
The ID of the instance to retrieve. If omitted, retrieves information about all instances.
-
-
Promise<Instance>
: A promise that resolves to an instance object.
// Example: Get information about a specific instance of a world
const instanceInfo = await vrchatApi.worldsApi.getWorldInstance({
worldId: 'wrld_12345678-1234-1234-1234-1234567890ab',
instanceId: 'instance_1',
});
console.log(instanceInfo);
// Example: Get information about all instances of a world
const allInstances = await vrchatApi.worldsApi.getWorldInstance({
worldId: 'wrld_12345678-1234-1234-1234-1234567890ab',
});
console.log(allInstances);
Note: Some methods may require the user to be authenticated. Ensure you have successfully logged in before using these methods.
Please replace placeholder IDs like 'wrld_12345678-1234-1234-1234-1234567890ab'
with actual IDs as needed.
-
Deprecated Methods: The
getWorldMetadata
endpoint is deprecated and may be removed in future updates. - Publish Limits: You can only publish one world per week. Attempting to publish more frequently may result in an error.
-
Deletion: Deleting a world does not fully remove it; it sets the
releaseStatus
to'hidden'
and deletes linked files. TheworldId
remains reserved.