XRCLOUD API (1.0)

Download OpenAPI specification:Download

Authentication

All API calls in this document require an ApiKey.

  • ApiKey can be issued from My page in the upper right corner of the page after logging in to XRCLOUD page.

Project

A Project in XRCLOUD can be a developer's project, a platform, or a third-party application. It is the unit that manages Scenes and Rooms, and multiple Scenes and Rooms belong to a specific Project.

  • webhookUrl can be set when creating a project or modifying information on the XRCLOUD page.

get project

header Parameters
X-XRCLOUD-API-KEY
required
string

The header must contain the following X-XRCLOUD-API-KEY: ${ApiKey}.

Responses

Response samples

Content type
application/json
{}

Scene

This is the space required to create a Room, which is a webpage-based 3D virtual space.

You can access 'sceneCreationUrl' among the fields obtained by calling get-creation-url api to access the editor (Spoke) and create a Scene through the Publish Scene button on the top right. You can also access 'sceneModificationUrl' among the fields obtained by calling get-scene api to modify it.

  • The optId value is a callback value to confirm the creation and modification of the Scene in XRCLOUD. Using a variation of it may result in an error.

get scenes

query Parameters
projectId
required
uuid

The unique ID of the project.

name
string

(search) Search for Object(s) with that name.

creator
string

(search) Search for Object(s) with that creator.

take
number

(pagination) number of rows to get.

skip
number

(pagination) number of rows to skip.

header Parameters
X-XRCLOUD-API-KEY
required
string

The header must contain the following X-XRCLOUD-API-KEY: ${ApiKey}.

Responses

Response samples

Content type
application/json
{}

get creation url

query Parameters
projectId
required
uuid

The unique ID of the project.

creator
string

Allows you to specify the creator of the Scene. This is used to distinguish 'My Assets' within the authoring space, and if called to create without including this parameter, the scene will be created identically to the one created by 'Admin'.

callback
string
Example: callback=https://api.xrcloud.app/rooms

This is called when a specific behavior is required immediately after a Scene is created, including when a Room is created directly from that Scene. The call on the XRCloud side looks like this.

{ method: 'POST', headers: { 'Content-Type': 'application/json' }, body: JSON.stringify({ sceneId }) }

header Parameters
X-XRCLOUD-API-KEY
required
string

The header must contain the following X-XRCLOUD-API-KEY: ${ApiKey}.

Responses

Response samples

get scene

header Parameters
X-XRCLOUD-API-KEY
required
string

The header must contain the following X-XRCLOUD-API-KEY: ${ApiKey}.

Responses

Response samples

Content type
application/json
{}

remove scene

header Parameters
X-XRCLOUD-API-KEY
required
string

The header must contain the following X-XRCLOUD-API-KEY: ${ApiKey}.

Responses

Response samples

Content type
application/json
{
  • "statusCode": 400,
  • "method": "Method",
  • "url": "/example/endpoint",
  • "body": {
    },
  • "message": "Detailed error messages"
}

Room

A Room is a space organized by Scenes created through the Editor (Spoke).

Each Room has a private room URL, which changes with each request for information, and a public room URL, which has a fixed address. These URLs are also separated into a host URL, which grants permissions to the host of the room, and a guest URL, which grants permissions to guests.

The 'returnUrl' is the web address to return to when leaving the room, which can be set in the Rooms tab of XRCloud.

create room

header Parameters
X-XRCLOUD-API-KEY
required
string

The header must contain the following X-XRCLOUD-API-KEY: ${ApiKey}.

Request Body schema: application/json
required
projectId
required
uuid

The unique ID of the project.

sceneId
required
uuid

The unique ID of the scene.

name
required
string

The name of the room.

returnUrl
required
string

The URL to return to when leaving the Room.

size
number

Maximum number of people who can enter a room.

Responses

Request samples

Content type
application/json
{
  • "projectId": "f24ee5ba-8f1f-4f7a-86ed-738f95ea1f8b",
  • "sceneId": "1234e5ba-5678-4f7a-86ed-abcd95ea1efg",
  • "name": "example room name",
  • "returnUrl": "https://www.google.com/",
  • "size": 10
}

Response samples

Content type
application/json
{}

get rooms

That API must be called with either a projectId or a sceneId.

query Parameters
projectId
uuid

The unique ID of the project.

sceneId
uuid

The unique ID of the scene.

name
string

(search) Search for Object(s) with that name.

userId
string

The user of the project (app). Used to differentiate between users accessing room.

avatarUrl
string
Example: avatarUrl=https://storage.com/bucket/avatar-file.glb

The path to the avatar file to use in Room.

linkPayload
string
Example: linkPayload=belivvr:eyJhbGciOiJIUzI1,test:NiIsInR5cCI6IkpXVCJ9,xrcloud:testValue

Values to pass to the 'inline viewer', an element in the Scene. Each key maps to the name of the 'inline viewer' and is separated by a comma (,), and the key and value are separated by a colon (:).

take
number

(pagination) number of rows to get.

skip
number

(pagination) number of rows to skip.

header Parameters
X-XRCLOUD-API-KEY
required
string

The header must contain the following X-XRCLOUD-API-KEY: ${ApiKey}.

Responses

Response samples

Content type
application/json
{}

get room

query Parameters
userId
string

The user of the project (app). Used to differentiate between users accessing room.

avatarUrl
string
Example: avatarUrl=https://storage.com/bucket/avatar-file.glb

The path to the avatar file to use in Room.

linkPayload
string
Example: linkPayload=belivvr:eyJhbGciOiJIUzI1,test:NiIsInR5cCI6IkpXVCJ9,xrcloud:testValue

Values to pass to the 'inline viewer', an element in the Scene. Each key maps to the name of the 'inline viewer' and is separated by a comma (,), and the key and value are separated by a colon (:).

header Parameters
X-XRCLOUD-API-KEY
required
string

The header must contain the following X-XRCLOUD-API-KEY: ${ApiKey}.

Responses

Response samples

Content type
application/json
{}

update room

header Parameters
X-XRCLOUD-API-KEY
required
string

The header must contain the following X-XRCLOUD-API-KEY: ${ApiKey}.

Request Body schema: application/json
required
name
string

The name of the room.

size
number

Maximum number of people who can enter a room.

returnUrl
string

The URL to return to when leaving the Room.

Responses

Request samples

Content type
application/json
{}

Response samples

Content type
application/json
{}

remove room

header Parameters
X-XRCLOUD-API-KEY
required
string

The header must contain the following X-XRCLOUD-API-KEY: ${ApiKey}.

Responses

Response samples

Content type
application/json
{
  • "statusCode": 400,
  • "method": "Method",
  • "url": "/example/endpoint",
  • "body": {
    },
  • "message": "Detailed error messages"
}

get room logs

header Parameters
X-XRCLOUD-API-KEY
required
string

The header must contain the following X-XRCLOUD-API-KEY: ${ApiKey}.

Responses

Response samples

Content type
application/json
{
  • "id": "77",
  • "infraUserId": "user@domain.com",
  • "roomId": "1234e5ba-5678-4f7a-86ed-abcd95ea1efg",
  • "sessionId": "4f7edfb6-b8a1-4f58-96ee-1deb4da98740",
  • "joinedAt": "2023-12-12T09:27:41.600Z",
  • "exitedAt": "2023-12-12T09:30:41.600Z"
}