Skip to main content
POST https://xquik.com/api/v1/x/accounts/{id}/reauth
Free. This endpoint does not consume credits.
Re-authenticate X accounts at dashboard.xquik.com/account. This route serves only a signed-in dashboard session. That way, X passwords never pass through an API key. API keys and OAuth tokens get 403 session_required.
Use this when an account session expires or X requires re-verification.
Omit totp_secret to reuse the saved key. Send a replacement only if X changed or rejected the saved key. Re-authentication does not guarantee the same public IP. Xquik does not support custom, dedicated, or user-supplied proxies.
Send totp_secret only when the saved key no longer works.
cURL

Path parameters

Headers

Body

2FA re-authentication

Xquik reuses the saved TOTP secret by default. Send totp_secret only when replacing that key. Never send a 6-digit code, backup code, passkey, or security key prompt. If you never saved the secret key, reset the authenticator app setup before re-authenticating. Do the same if X rejects the current one.

Saved key still works

Omit totp_secret. Xquik reuses the encrypted key saved during connection.

Key is missing

X shows the text secret only during Authentication App setup. Turn Authentication App off, then on again. Copy the new key, then finish setup on X.

Key was rejected

Treat the old TOTP secret as stale. Reset Authentication App setup on X and save the new long key. Finish 2FA confirmation, then re-authenticate.
  1. Open X Settings and Privacy > Security and Account Access > Security.
  2. Open Two-Step Verification > Authentication App.
  3. Turn Authentication App off, then turn it on again.
  4. X shows a QR code. Then choose Can’t scan the QR code? to reveal the text secret.
  5. Copy the long secret key. Then store it in a password manager before leaving the setup screen.
  6. Add that key to your authenticator app if you are setting it up fresh.
  7. Finish enabling 2FA on X by entering the current 6-digit code. The code comes from your authenticator app.
  8. Send the new long key in totp_secret when you call Xquik.
Finish the X-side 2FA confirmation after copying the secret key. If you abandon setup before confirmation, re-authentication cannot use that key.
See 2FA secret key setup for the full connection checklist.

Response

200 OK

400 Invalid input

{ "error": "invalid_input", "message": "Missing required password field" } Missing password field or invalid format. { "error": "invalid_id", "message": "Invalid account ID format" } The provided account ID is not a valid format.

401 Unauthenticated

{ "error": "unauthenticated", "message": "Missing or invalid API key" } Missing or invalid API key.

404 Not found

No account exists with this ID, or it belongs to a different Xquik account.

429 Login cooldown

{ "error": "login_cooldown", "message": "Login is temporarily paused", "reason": "automated", "retryAfterMs": 3600000 } A prior login attempt triggered a cooldown (for example, X flagged the session). Wait for retryAfterMs before retrying. The response includes a Retry-After header in seconds.

429 Rate limited

{ "error": "rate_limit_exceeded", "message": "Too many requests. Try again later.", "retryAfter": 60 } Wait for the Retry-After value before starting another re-authentication request.

422 Login failed

X rejected the submitted password or TOTP secret. Retry with the current password and the saved Authenticator App secret key. Use the key, not a 6-digit code. { "error": "passkey_required", "message": "X asked this account to sign in with a passkey. Delete the passkey in X's security settings, keep Authentication app 2FA, then try again." } X showed this account a passkey sign-in, which Xquik can’t complete. Open X Settings and Privacy > Security and Account Access > Security > Passkey. Delete the passkey but keep Authenticator App 2FA on, then re-authenticate.

503 Service unavailable

{ "error": "service_unavailable", "message": "Service temporarily unavailable. Try again." } The X re-authentication service is temporarily unavailable. Retry after a short delay.
Related.

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." }
  • 403 { "error": "session_required", "message": "API keys & OAuth tokens cannot use this route. Sign in at dashboard.xquik.com/account instead." }
  • 404 { "error": "account_not_found", "message": "X account not found." }
  • 422 { "error": "login_failed", "message": "Login failed. Check credentials and try again." }
  • 429 { "error": "login_cooldown", "message": "Login is temporarily paused. Try again when the countdown ends." }
  • 503 { "error": "service_unavailable", "message": "Service temporarily unavailable. Try again later." }