AUTH_ERROR — Generic authentication failure
Summary
Section titled “Summary”The key looked syntactically valid but our auth layer couldn’t resolve it to an organization. This is the catch-all for auth failures that aren’t a missing key, a revoked key, or an expired key.
HTTP status
Section titled “HTTP status”401 Unauthorized. Standard envelope.
Example response
Section titled “Example response”{ "success": false, "error": { "code": "AUTH_ERROR", "message": "Authentication failed. The key could not be resolved.", "request_id": "req_01HXJZK4ABCDEF", "doc_url": "https://docs.surveycoder.io/errors/auth-error" }}Why this happens
Section titled “Why this happens”- The key was deleted (not just revoked) in the dashboard.
- A backing data store had a transient blip during key lookup.
- The key was issued for a different environment (e.g. a sandbox key used against production).
- The auth cache hasn’t caught up with a very recent key rotation (usually under 30s).
How to fix it
Section titled “How to fix it”- Check the key at surveycoder.io/api-keys. If it’s gone, generate a new one.
- Confirm prefix:
scp_live_forapi.surveycoder.io,scp_test_for test mode. - Wait 30 seconds and retry once — transient auth-cache issues self-heal quickly.
- If it persists, email support@surveycoder.io with the
request_id.
Related
Section titled “Related”UNAUTHORIZED— header missing entirelyKEY_REVOKED— explicitly revokedNO_ORG— orphaned key with no org binding