Skip to main content
GET
Fetch Mutual Spaces
Returns a paginated list of spaces that both the authenticated user and another user are active members of — i.e. their spaces in common. Requires an authenticated user.

Path Parameters

string
required
The other user’s Sublay ID. Mutual spaces are computed between this user and the authenticated user.

Query Parameters

string
The authenticated user to act as. Only accepted with a service or master key — a user token always acts as itself and may not name a different user. Ignored (the token’s user is used) for end-user requests.
number
Page number. Defaults to 1.
number
Results per page. Max 100. Defaults to 20.
string
Optional comma-separated includes. Pass "files" to include avatar and banner file objects on each space.

Response

Space[]
The spaces both users are active members of. Computed fields such as membersCount and isMember are populated from the authenticated user’s perspective.
object
Standard pagination metadata (page, pageSize, totalPages, totalItems, hasMore).
See also: useFetchMutualSpaces