Reference
Error codes
The codes Controxity explains in words, on a problem's page, its card on Today and its alert.
An error's code is a short word for why it failed: never its message. The SDKs find one by themselves (see codeOf), or your code sets it. Forms Controxity knows:
http-<status>: a call to another service answered with that status (http-429).<service>-<status>: the same, naming the service (play-403,stripe-402,google-signin-400). Known names:play,google,google-signin,stripe,apple,firebase,apns,twilio,sendgrid,smtp,s3,github,gitlab,openai,anthropic.timeout, and network errnos as they are (ECONNREFUSED).- Database codes (Postgres SQLSTATE, like
23505).
A code it doesn't know is shown as it is, never guessed.
Every code it explains#
| Code | What it means | What to do |
|---|---|---|
google-signin-400 | Google turned down the server's sign-in: the key file is wrong or damaged, or the server's clock is off. | Check the service account key file the server uses, and that the server's clock is right. |
google-signin-401 | Google doesn't know the service account: the key was deleted or the account disabled. | Make a new key for the service account in Google Cloud, or turn the account back on. |
play-401 | Google Play didn't accept the server's sign-in for this call. | Check that the service account key is the one invited in the Play Console. |
play-403 | Google Play knows the service account, but it lacks permission in the Play Console, or the permission isn't active yet (that can take up to 24 hours). | In the Play Console, Users and permissions: give the service account access to the app, then wait if it was just given. |
timeout | The other side took too long to answer, and the call was given up. | Retry later; if it keeps happening, look at that service's speed or the server's network. |
ECONNREFUSED | Nothing answered at that address: the service isn't running there, or the port is wrong. | Check that the service is up, and the address and port the server uses. |
ENOTFOUND | The name couldn't be found (DNS): a wrong host name, or no network. | Check the host name in the server's settings. |
EAI_AGAIN | Looking the name up failed for now (DNS). | Usually passes; check the server's network if it lasts. |
ECONNRESET | The other side closed the connection in the middle. | Usually passes: retry. If it keeps happening, look at that side's logs or limits. |
ETIMEDOUT | The connection timed out before the other side answered. | Check the network between the server and that service. |
EPIPE | The connection was closed while still sending. | Usually passes: retry. |
CERT_HAS_EXPIRED | The other side's HTTPS certificate has expired. | Tell whoever runs that service; their certificate needs renewing. |
UNABLE_TO_VERIFY_LEAF_SIGNATURE | The other side's HTTPS certificate couldn't be checked. | Check that service's certificate chain. |
23505 | The database refused a duplicate: something with the same unique value is there already. | Treat it as existing, or check for it before adding. |
23503 | The database refused a link to something that doesn't exist (a foreign key). | Make sure what it points to exists first, or is not deleted meanwhile. |
23502 | The database refused an empty value where one is required. | Send a value for that column. |
22001 | A value was too long for its database column. | Shorten it, or widen the column. |
22008 | A date or time value was out of range or badly formed for the database. | Check the date the code builds before saving it. |
22P02 | A value had the wrong form for its database column (text where a number or id was expected). | Check what the code passes for that column. |
40001 | Two changes clashed in the database and one was undone (serialization failure). | Retry the transaction. |
40P01 | Two changes waited on each other in the database (deadlock) and one was undone. | Retry; take locks in the same order everywhere. |
53300 | The database has too many connections. | Use a connection pool, or raise the database's limit. |
57014 | The database stopped a query that ran too long. | Make the query faster, or raise its time limit. |
42P01 | The database has no such table: a migration hasn't run. | Run the migrations where it happened. |
42703 | The database has no such column: a migration hasn't run, or a name is wrong. | Run the migrations, or check the column's name. |
http-400 | The service found the request wrong: a missing or bad field, or a format it doesn't take. | Compare the request with the service's documentation for that call. |
http-401 | The service didn't accept the credentials: the key or token is wrong, expired or revoked. | Check the key or token the server uses for the service, and make a new one if it was revoked. |
http-402 | The service wants payment: the account's plan or card. | Look at the the service account's billing. |
http-403 | The service knows who is asking, but that account lacks permission for this. Grants to a new service account can take up to 24 hours to work. | Give the account the permission in the service's console, or wait if it was just given. |
http-404 | The service has no such thing: a wrong address, id or name, or it was deleted. | Check the address or id the server asks the service for. |
http-408 | The service gave up waiting for the request. | Try again; if it keeps happening, the request is too slow or too big. |
http-409 | The service refused because of a conflict: it changed in between, or it exists already. | Read it again from the service and retry, or treat it as done. |
http-410 | The service says it's gone for good. | Stop asking for it. |
http-413 | The service found the request too big. | Send less at a time. |
http-422 | The service understood the request but won't take its values. | Check the values the server sends the service. |
http-429 | The service is limiting how often it's asked (rate limited). | Ask less often, or wait and retry with a growing pause. |
http-500 | The service failed on its side. | Usually passes: retry later. Check the service's status page if it lasts. |
http-502 | The service, or a gateway in front of it, couldn't answer. | Usually passes: retry later. Check the service's status page if it lasts. |
http-503 | The service is down or overloaded for now. | Retry later; check the service's status page. |
http-504 | The service, or a gateway in front of it, ran out of time. | Retry later; if it keeps happening, the request is too slow. |
Controxity 1.132.0These pages are in the repository: docs/site