Skip to content
Docs
qmpass.ai Become a design partner
Start

Errors and limits

Error responses and their codes, rate limits, and retrying safely.

Errors come back as JSON with an HTTP status. There are two shapes.

Token and access refusals (403):

{
"error": "PROJECT_API_TOKEN_SCOPE_DENIED",
"message": "Project API token lacks the project:write scope for this request",
"status": 403
}

Everything else (400, 404, 409, 422):

{
"message": "Evaluation PEV-0042 is still open on this gate: finish or abandon it in Qmpass, then run the pipeline again.",
"errorType": "CI_GATE_RUN_IN_PROGRESS",
"code": 409
}

Read error or errorType in code; message is for people and can change. Some errors add a details object.

Status When What to do
401 The token is unknown, revoked or expired; the project is turned off; or the plan lost API access. Check the token in API tokens, or create a new one.
403 PROJECT_API_TOKEN_SCOPE_DENIED A Read only token sent a write. Use a Read & write token.
403 PROJECT_API_TOKEN_PROJECT_MISMATCH The path names another project. Use the token’s own project id, or current.
403 PROJECT_API_TOKEN_PATH_DENIED The route isn’t open to tokens. Use a public route; see the API reference.
403 PROJECT_API_TOKEN_CAPABILITY_DENIED The step needs more than a project Member can do. It’s a Quality Owner’s step: do it in Jira.
400 The request body is invalid. Fix the fields named in message.
404 The release, gate, evaluation or milestone isn’t in this project. Check the id.
409 The request conflicts with the current state, for example CI_GATE_RUN_IN_PROGRESS when an evaluation is already open on the gate. Finish or end the other one, then try again.
422 The request is valid but can’t be done, for example CI_NOTHING_TO_AUTOMATE. Read message.
429 Too many requests. Wait and retry; see below.

Each token can make 10 requests a second, with bursts of up to 20. Over the limit, the API answers 429 with X-RateLimit-* headers. Give each pipeline its own token so one busy job doesn’t slow another.

  • Retry 429 and 5xx answers, and network errors, with exponential backoff: wait about 1 second, then 2, 4 and so on, with some jitter.
  • Don’t retry other 4xx answers unchanged: the same request gets the same answer.
  • Poll politely. A gate evaluation from CI usually needs a check every 15 seconds or so, and release readiness rarely changes faster than that.