X accounts
X account email verification API & login challenges
Submit an email verification code for an active X account login challenge. Start a fresh connect or reauthentication when the challenge expires. Free to call.
- 201
- 202
- 400
- 401
- 404
- 409
- 410
- 422
- 429
- 503
POST
X account email verification API & login challenges
Free. This endpoint does not consume credits.
202 Email Code Required. Submit the one-time code from the account email inbox before expiresAt.
Continue the pending login
Use the returned challenge ID
Keep the
id from the 202 response and submit the inbox code to that challenge. The challenge belongs to the same pending login attempt.Enter the account email code
Use the one-time code X sent to the account email inbox. Xquik strips spaces before submission.
123 456 and 123456 work the same way.Handle another code prompt
If X asks for a new email code, this endpoint returns
202 again. Keep the same flow open and submit the next inbox code before expiresAt.Start over when stale
410 means the code expired. 409 means the challenge already completed, failed, or expired, or a newer challenge replaced it. Start Connect X Account again for a new account, or use Re-authenticate X Account for an existing account.202 prompt if X asks again. After the 201 response, it refreshes the account list.
Headers
string
required
Your API key. Session cookie authentication is also supported. Generate a key from the dashboard.
string
required
Must be
application/json.Path parameters
string
required
Challenge ID returned by Connect X Account.
Body
string
required
Email verification code for the pending connection. The API accepts codes from 4 to 64 characters. Xquik strips spaces before submission.
Response
201 Created
string
Unique account ID.
string
Connected X username.
string
X user ID.
string
Account connection status (for example
"active").string
Derived login and cookie health. One of
healthy, locked, needsReauth, recovering, suspended, temporaryIssue. See Account health for meanings.string
ISO 8601 time when Xquik connected the account.
202 Email code required
string
Always
x_account_connection_challenge.string
Challenge ID to submit with the next email verification code.
string
Always
requires_email_code.string
ISO 8601 expiration time for the challenge.
string
Human-readable next step.
string
X username being connected.
400 Invalid input
email_code, invalid JSON, or a code outside the accepted length.
401 Unauthenticated
404 Not found
409 Conflict
410 Expired
422 Login failed
429 Rate limit exceeded
Retry-After header before retrying.
503 Service unavailable
Related. Connect X Account starts the challenge, and List X Accounts verifies the account after connection.