Public docs

Error Reference

All error codes, their causes, and how to handle them.

Phase 1 shell: this docs surface is wired to the existing backend and repo documentation, and will be expanded as the private dashboard comes online.

HTTP status codes

400 — Bad Request

The request body is missing required fields or contains invalid values.

Common causes:

  • Missing raw_text on translate
  • Invalid severity value (must be high, medium, or low)
  • Invalid status value (must be active or resolved)
  • Business signup without business_name

401 — Unauthorized

The X-API-Key header is missing or the key is not recognized.

403 — Forbidden

You are attempting to use a feature that requires a higher plan (e.g., AI mode with a free key).

404 — Not Found

The requested resource (alert, partner row, team member, app) does not exist.

422 — Unprocessable Entity

FastAPI validation error — the request body has the wrong types or structure.

429 — Too Many Requests

Your key has exceeded its rate limit. The response body includes a retry hint.

500 — Internal Server Error

Something went wrong server-side. Check your request body and try again. If it persists, contact support.

---

Error response shape

All errors return a JSON body:

json
{ "detail": "Human-readable error message" }

---

Handling errors in code

javascript
const res = await fetch("https://api.opsentry.ai/v1/translate", {
method: "POST",
headers: {
"Content-Type": "application/json",
"X-API-Key": apiKey
},
body: JSON.stringify(payload)
});
 
if (!res.ok) {
const err = await res.json();
console.error(res.status, err.detail);
// Handle 401, 403, 429 specifically
return;
}
 
const data = await res.json();