Docs

Sleep configuration

Swap zones with bed partner

Swaps the given user with the other user on the same device (each must occupy exactly one zone, device must have exactly 2 users).

POST
/v1/sleep-configuration/swap

Pass your own user id to swap yourself with your bed partner.

Request parameters

Headers
Authorization string required

Your API key as a bearer token: Bearer os_…. Make one on the API keys page; see Authentication.

Body application/json
  • user_id string (uuid) required

    User id whose zone will be swapped with their bed partner (your own id or a shared user from list_devices)

Response parameters

200 OK application/json
  • success boolean required

Errors

Every error answers { "error": { "code", "message" } }.

StatusCodeMeaning
400invalidInvalid input.
401unauthorizedMissing or unsupported API key.
403forbiddenNot allowed on this device or user.
429rate_limitedRate limit exceeded.
503unavailableNot available for this account.
Also an MCP tool: swap_zones