Skip to main content
Get Space Conversation
Returns the chat conversation associated with a space. If no conversation exists yet, one is created automatically. Requires authentication. The caller must be an active member of the space: a request still awaiting approval, a rejected request and a ban are all refused.

Path Parameters

string
required
UUID of the space.

Query Parameters

string
Service key only, and required with one: the user this request acts as. Must be an active member of the space. A user token always acts as its own user and must not send it (400 chat/acting-user-not-allowed).

Response

Returns a Conversation object with two additional fields:
object | null
The caller’s ConversationMember record for this conversation. Created or re-activated on first call.
number
Number of currently active members in the conversation.
Each space has at most one associated conversation. This endpoint is idempotent — calling it multiple times returns the same conversation.

Error Responses

A user token sent actingUserId, even naming its own user. Only a service key names the user it acts as; a user token always acts as its own user.
Returned when a service key names an actingUserId that isn’t a user in this project.
The request sent userId. On this route the user a service key acts as is actingUserId.With a service key:
With a user token, or with no credentials:
A service key sent no actingUserId.
Returned when spaceId isn’t a valid UUID. Checked before sign-in, permissions and the endpoint’s other checks.
Also returned when the caller’s request to join was rejected.
See also: useFetchSpaceConversation hook