vrchat_create_instance
Create a new VRChat world instance with configurable access, region, and invite settings to customize multiplayer experiences.
Instructions
Create a new instance of a world.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| canRequestInvite | No | ||
| closedAt | No | ||
| groupAccessType | No | ||
| hardClose | No | ||
| inviteOnly | No | ||
| ownerId | No | ||
| queueEnabled | No | ||
| region | No | us | |
| roleIds | No | ||
| type | Yes | ||
| worldId | Yes |
Implementation Reference
- src/tools/instances.ts:54-83 (handler)The core handler function for the vrchat_create_instance tool. It authenticates the VRChat client, maps parameters to the API call, invokes instancesApi.createInstance, and returns the JSON-stringified instance data or an error message.async (params) => { try { await vrchatClient.auth() const instance = await vrchatClient.instancesApi.createInstance({ worldId: params.worldId, type: params.type, region: params.region, ownerId: params.ownerId, roleIds: params.roleIds, groupAccessType: params.groupAccessType, queueEnabled: params.queueEnabled, closedAt: params.closedAt, canRequestInvite: params.canRequestInvite, hardClose: params.hardClose, inviteOnly: params.inviteOnly, }) return { content: [{ type: 'text', text: JSON.stringify(instance.data, null, 2) }] } } catch (error) { return { content: [{ type: 'text', text: 'Failed to create instance: ' + error }] } }
- src/tools/instances.ts:42-53 (schema)Zod input schema defining all parameters for creating a VRChat instance, including worldId, type, region, and various optional instance configuration options.worldId: z.string(), type: z.enum(['public', 'hidden', 'friends', 'private', 'group']), region: z.enum(['us', 'use', 'eu', 'jp', 'unknown']).default('us'), ownerId: z.string().nullable().optional(), roleIds: z.array(z.string()).optional(), groupAccessType: z.enum(['members', 'plus', 'public']).optional(), queueEnabled: z.boolean().optional(), closedAt: z.string().optional(), // date-time format canRequestInvite: z.boolean().optional(), hardClose: z.boolean().optional(), inviteOnly: z.boolean().optional(), },
- src/tools/instances.ts:36-41 (registration)Local registration of the tool within the createInstancesTools function using server.tool(name, description, schema, handler).server.tool( // Name 'vrchat_create_instance', // Description 'Create a new instance of a world.', {
- src/main.ts:33-33 (registration)Top-level invocation of createInstancesTools in the main server setup, which registers the vrchat_create_instance tool (and get_instance) on the MCP server.createInstancesTools(server, vrchatClient)