Room

This endpoint updates specific properties of a room. Corresponds to liveblocks.updateRoom.

It’s not necessary to provide the entire room’s information. Setting a property to null means to delete this property. For example, if you want to remove access to a specific user without losing other users: { "usersAccesses": { "john": null } } defaultAccesses, metadata, usersAccesses, groupsAccesses can be updated.

  • defaultAccesses is the default room permission list, for example [], ["*:read"], ["*:write"], or a more granular permission list.
  • metadata could be key/value as string or string[]. metadata supports maximum 50 entries. Key length has a limit of 40 characters maximum. Value length has a limit of 256 characters maximum. metadata is optional field.
  • usersAccesses contains user-specific permission lists. It can contain 1000 ids maximum. Id length has a limit of 256 characters. usersAccesses is optional field.
  • groupsAccesses contains group-specific permission lists and is optional.
post/rooms/{roomId}

Request

  • Base URL: https://api.liveblocks.io/v2
  • URL: https://api.liveblocks.io/v2/rooms/{roomId}
  • Auth: none declared

Path parameters

roomIdstring required

ID of the room

Example:my-room-id

Request body

defaultAccessesRoomPermissionItem[]
usersAccessesobject

A map of user identifiers to permissions list. Setting the value as null will clear all users’ accesses. Setting one user identifier as null will clear this user’s accesses.

groupsAccessesobject

A map of group identifiers to permissions list. Setting the value as null will clear all groups’ accesses. Setting one group identifier as null will clear this group’s accesses.

metadataobject

Example request

{
  "defaultAccesses": [
    "*:write"
  ],
  "usersAccesses": {
    "alice": [
      "*:write"
    ]
  },
  "groupsAccesses": {
    "marketing": [
      "*:write"
    ]
  },
  "metadata": {
    "color": "blue"
  }
}

Response

Success. Returns the updated room.

idstring required
type'room' required
organizationIdstring required

The organization ID associated with this room.

lastConnectionAtstring date-time
createdAtstring date-time required
defaultAccessesRoomPermissionItem[] required
usersAccessesRoomAccesses required
groupsAccessesRoomAccesses required
metadataRoomMetadata required

Example response

{
  "type": "room",
  "id": "my-room-id",
  "lastConnectionAt": "2022-08-04T21:07:09.380Z",
  "createdAt": "2022-07-13T14:32:50.697Z",
  "organizationId": "org_123456789",
  "metadata": {
    "color": "blue",
    "type": "whiteboard"
  },
  "defaultAccesses": [
    "*:write"
  ],
  "groupsAccesses": {
    "marketing": [
      "*:write"
    ]
  },
  "usersAccesses": {
    "alice": [
      "*:write"
    ]
  }
}

Changes

    • warning

      added the new comments:private:none enum value to the / response property for the response status

    • warning

      added the new comments:private:none enum value to the // response property for the response status

    • warning

      added the new comments:private:none enum value to the // response property for the response status

    • warning

      added the new comments:private:read enum value to the / response property for the response status

    • warning

      added the new comments:private:read enum value to the // response property for the response status

    • warning

      added the new comments:private:read enum value to the // response property for the response status

    • warning

      added the new comments:private:write enum value to the / response property for the response status

    • warning

      added the new comments:private:write enum value to the // response property for the response status

    • warning

      added the new comments:private:write enum value to the // response property for the response status

    • warning

      added the new comments:public:none enum value to the / response property for the response status

    • warning

      added the new comments:public:none enum value to the // response property for the response status

    • warning

      added the new comments:public:none enum value to the // response property for the response status

    • warning

      added the new comments:public:read enum value to the / response property for the response status

    • warning

      added the new comments:public:read enum value to the // response property for the response status

    • warning

      added the new comments:public:read enum value to the // response property for the response status

    • warning

      added the new comments:public:write enum value to the / response property for the response status

    • warning

      added the new comments:public:write enum value to the // response property for the response status

    • warning

      added the new comments:public:write enum value to the // response property for the response status

    • info

      added the new comments:private:none enum value to the request property /////

    • info

      added the new comments:private:none enum value to the request property ///

    • info

      added the new comments:private:none enum value to the request property ///

    • info

      added the new comments:private:read enum value to the request property /////

    • info

      added the new comments:private:read enum value to the request property ///

    • info

      added the new comments:private:read enum value to the request property ///

    • info

      added the new comments:private:write enum value to the request property /////

    • info

      added the new comments:private:write enum value to the request property ///

    • info

      added the new comments:private:write enum value to the request property ///

    • info

      added the new comments:public:none enum value to the request property /////

    • info

      added the new comments:public:none enum value to the request property ///

    • info

      added the new comments:public:none enum value to the request property ///

    • info

      added the new comments:public:read enum value to the request property /////

    • info

      added the new comments:public:read enum value to the request property ///

    • info

      added the new comments:public:read enum value to the request property ///

    • info

      added the new comments:public:write enum value to the request property /////

    • info

      added the new comments:public:write enum value to the request property ///

    • info

      added the new comments:public:write enum value to the request property ///

    • warning

      added the new *:read enum value to the / response property for the response status

    • warning

      added the new *:read enum value to the // response property for the response status

    • warning

      added the new *:read enum value to the // response property for the response status

    • warning

      added the new *:write enum value to the / response property for the response status

    • warning

      added the new *:write enum value to the // response property for the response status

    • warning

      added the new *:write enum value to the // response property for the response status

    • warning

      added the new comments:none enum value to the / response property for the response status

    • warning

      added the new comments:none enum value to the // response property for the response status

    • warning

      added the new comments:none enum value to the // response property for the response status

    • warning

      added the new comments:read enum value to the / response property for the response status

    • warning

      added the new comments:read enum value to the // response property for the response status

    • warning

      added the new comments:read enum value to the // response property for the response status

    • warning

      added the new feeds:none enum value to the / response property for the response status

    • warning

      added the new feeds:none enum value to the // response property for the response status

    • warning

      added the new feeds:none enum value to the // response property for the response status

    • warning

      added the new feeds:read enum value to the / response property for the response status

    • warning

      added the new feeds:read enum value to the // response property for the response status

    • warning

      added the new feeds:read enum value to the // response property for the response status

    • warning

      added the new feeds:write enum value to the / response property for the response status

    • warning

      added the new feeds:write enum value to the // response property for the response status

    • warning

      added the new feeds:write enum value to the // response property for the response status

    • warning

      added the new storage:none enum value to the / response property for the response status

    • warning

      added the new storage:none enum value to the // response property for the response status

    • warning

      added the new storage:none enum value to the // response property for the response status

    • warning

      added the new storage:read enum value to the / response property for the response status

    • warning

      added the new storage:read enum value to the // response property for the response status

    • warning

      added the new storage:read enum value to the // response property for the response status

    • warning

      added the new storage:write enum value to the / response property for the response status

    • warning

      added the new storage:write enum value to the // response property for the response status

    • warning

      added the new storage:write enum value to the // response property for the response status

    • info

      added the new *:read enum value to the request property /////

    • info

      added the new *:read enum value to the request property ///

    • info

      added the new *:read enum value to the request property ///

    • info

      added the new *:write enum value to the request property /////

    • info

      added the new *:write enum value to the request property ///

    • info

      added the new *:write enum value to the request property ///

    • info

      added the new comments:none enum value to the request property /////

    • info

      added the new comments:none enum value to the request property ///

    • info

      added the new comments:none enum value to the request property ///

    • info

      added the new comments:read enum value to the request property /////

    • info

      added the new comments:read enum value to the request property ///

    • info

      added the new comments:read enum value to the request property ///

    • info

      added the new feeds:none enum value to the request property /////

    • info

      added the new feeds:none enum value to the request property ///

    • info

      added the new feeds:none enum value to the request property ///

    • info

      added the new feeds:read enum value to the request property /////

    • info

      added the new feeds:read enum value to the request property ///

    • info

      added the new feeds:read enum value to the request property ///

    • info

      added the new feeds:write enum value to the request property /////

    • info

      added the new feeds:write enum value to the request property ///

    • info

      added the new feeds:write enum value to the request property ///

    • info

      added the new storage:none enum value to the request property /////

    • info

      added the new storage:none enum value to the request property ///

    • info

      added the new storage:none enum value to the request property ///

    • info

      added the new storage:read enum value to the request property /////

    • info

      added the new storage:read enum value to the request property ///

    • info

      added the new storage:read enum value to the request property ///

    • info

      added the new storage:write enum value to the request property /////

    • info

      added the new storage:write enum value to the request property ///

    • info

      added the new storage:write enum value to the request property ///