POST https://xquik.com/api/v1/x/accounts/{id}/reauth
Free. This endpoint does not consume credits.
Use this when an account session expires or X requires re-verification.
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.
Replace the saved TOTP secret
Replace the saved TOTP secret
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. Sendtotp_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.
- Open X Settings and Privacy > Security and Account Access > Security.
- Open Two-Step Verification > Authentication App.
- Turn Authentication App off, then turn it on again.
- X shows a QR code. Then choose Can’t scan the QR code? to reveal the text secret.
- Copy the long secret key. Then store it in a password manager before leaving the setup screen.
- Add that key to your authenticator app if you are setting it up fresh.
- Finish enabling 2FA on X by entering the current 6-digit code. The code comes from your authenticator app.
- Send the new long key in
totp_secretwhen you call Xquik.
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.202 Sign-in continues
A key’s sign-in past 75 seconds answerspending with a Location status URL. Wait for Retry-After, then call Get X Account Connection Status. X may also ask for an email code, which answers requires_email_code. Send it to Submit Email Code.404 Not found
No account exists with this ID, or it belongs to a different Xquik account.409 Another X account
{ "error": "x_account_mismatch", "message": "This sign-in belongs to a different X account. Connect it as a new account instead." }
The stored login stays as it was.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": "Connection safety limit reached. Try again later.", "retryAfter": 900 }
You sent too many failed logins in 15 minutes. The limit counts this caller or this X account. Wait the Retry-After seconds, then try once. Each account a caller connects raises its limit. See the rate limits guide for details.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.
- Get X Account to check account status.
- Connect X Account if you need to add a new account instead.
Response examples
202 example
- 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": "api_key_paused", "message": "This API key is paused. Resume it at dashboard.xquik.com/api-keys to use it again." } - 404
{ "error": "account_not_found", "message": "X account not found." } - 409
{ "error": "x_account_mismatch", "message": "This sign-in belongs to a different X account. Connect it as a new account instead." } - 422
{ "error": "login_failed", "message": "Login failed. Check credentials and try again." } - 429
{ "error": "rate_limit_exceeded", "message": "Too many requests. Retry later." } - 503
{ "error": "service_unavailable", "message": "Service temporarily unavailable. Try again later." }