Skip to main content
GET https://xquik.com/api/v1/x/spaces/{id}
1 credit per call · All plans from $0.00012/creditDirect MPP at USD 0.00015 per call
Get Space returns one public X Space as X shows it. It can be live, scheduled, or ended. The endpoint is GET /api/v1/x/spaces/{id}.
The Node.js and Python snippets build 1 row per Space. Each call costs 1 credit. A refused request costs nothing.

Read a Space’s state, audience, and stage

Use GET /x/spaces/{id} when you hold a Space ID or a Space URL. Find Space IDs with Search Spaces.
  • state tells a scheduled Space from a live or ended one.
  • isAvailableForReplay says whether X offers a recording. Get it with Get Space replay once the Space is over.
  • totalLiveListeners counts the accounts that listened live. totalReplayWatched counts the accounts that played the recording.
  • participantCount is the audience now, while the Space is live.
  • admins, speakers, and listeners name the accounts. X (Twitter) lists them on the stage and in the audience.
  • sharings lists the posts the hosts and speakers shared in the Space. It says who shared each and when.
  • tweet is the post that announces the Space, with its text, counts, and author.
X names a Space’s hosts, speakers, and listeners without follower counts. So their rows carry none. Pass a username to Get User for the full profile. A field X leaves empty is left out. A Space X (Twitter) limits to subscribers or a community answers 404. A Space is a live audio room. For a live video at x.com/i/broadcasts, use Get broadcast.

Path parameters

Query parameters

Headers

Response

200 OK

400 Invalid Space ID

{ "error": "invalid_space_id", "message": "Send a Space ID or URL, such as x.com/i/spaces/1OGwblLjnQMKB." } The path is not a Space ID or a Space URL. The request costs nothing.

401 Unauthenticated

Missing or invalid API key. Check the x-api-key header value.

402 Payment required

Account keys get account options. Guest keys get guest top-up only. Anonymous calls receive a direct MPP WWW-Authenticate: Payment challenge plus a guest wallet creation action. No checkout starts automatically. Confirm any payment action.

404 Space not found

X (Twitter) has no such Space, or limits it to subscribers or a community. The request costs nothing.

502 X API unavailable

The read service returned an error. Retry after a short delay.

503 Service busy

X failed to return the Space, or Xquik is busy. Retry after a short delay. The request costs nothing.

429 Rate limit exceeded

You exceeded your tier rate limit. Wait for the Retry-After header before retrying.

424 Dependency failed

The normalized v1 response contract can return 424 when the read service is unavailable.

Twitter Spaces API questions

URL-encode the Space link and pass it as id. You can also pass the Space ID from the link. x.com/i/spaces/1OGwblLjnQMKB holds the ID 1OGwblLjnQMKB.

How many people listened to a Space?

Read totalLiveListeners for the live audience and totalReplayWatched for the recording. While a Space is live, participantCount is the audience now.

Who hosted or spoke in a Space?

admins holds the hosts and co-hosts. speakers holds the accounts X (Twitter) lists as speakers.

Which posts were shared in a Space?

Read sharings. Each sharing has the post as tweet and the time as sharedAt. It also has the account that shared the post as sharedBy.

Why does a Space return 404?

X no longer has the Space, or limits it to subscribers or a community.

Does this replace X’s official API?

No. This page documents Xquik, an independent third-party service. It does not document X’s official API.
Next steps. Get Space replay for an ended Space’s recording. Search Spaces to find more Spaces. Get User for a host’s full profile. Get broadcast for a live video.

Response examples

  • 400 { "error": "invalid_input", "message": "Invalid input. Check the request body." }
  • 401 { "error": "unauthenticated", "message": "Authentication required. Provide a valid API key or bearer token." }
  • 402 { "error": "insufficient_credits", "message": "Insufficient credits. Top up or subscribe to continue." }
  • 403 { "error": "api_key_paused", "message": "This API key is paused. Resume it at dashboard.xquik.com/api-keys to use it again." }
  • 404 { "error": "not_found", "message": "Resource not found." }
  • 424 { "error": "x_api_unavailable", "message": "X data source temporarily unavailable. Try again later." }
  • 429 { "error": "rate_limit_exceeded", "message": "Too many requests. Try again later.", "retryAfter": 60 }
  • 502 { "error": "x_api_unavailable", "message": "X data source temporarily unavailable. Try again later." }
  • 503 { "error": "x_api_unavailable", "message": "Xquik is busy right now. Retry shortly." }