projqoDevelopers

Guide

Errors

Every status and error code, what causes it and how to fix it.

Every error has the same shape (see conventions): a code for your program, a message for people, the status, the request_id, and for a wrong value, details with one entry per field.

The codes

These are every code the API answers. A code never changes for the same cause; a new code is added to this list and to the OpenAPI file together.

StatusCodeCauseFix
400invalidA value is wrong or missing, or a parameter is unknown. Every problem is in details.Correct the values named in details and send the call again.
400field_requiredA field the task's screen or workflow step requires is empty.Send each field named in details.
401invalid_tokenNo token was sent, or it is wrong, expired or revoked, or its person is no longer a member (or is now a guest).Send a live token as Authorization: Bearer <token>. Make a new one in Personal settings > API tokens.
402not_in_planThe feature isn't in the organisation's plan.An owner can change the plan in Billing; the message names the plan that has it.
403insufficient_scopeThe token doesn't have the scope this call needs (named in WWW-Authenticate).Make a token with that scope.
403refusedThe token's person can see the thing but may not do this; the message says why.Ask whoever the message names for the permission, or use a token of someone who has it.
403api_offThe organisation's admins have switched the API off.Ask an organisation admin to switch it on in Organisation settings > API.
403read_onlyThe organisation is read-only (over the Free plan's people, or a payment is overdue).Reading still works. An owner can fix the plan in Billing.
403suspendedprojqo has suspended the organisation.Contact the organisation's owner.
404not_foundNothing is at this address, or the token's person can't see it: the answer is the same.Check the address and the ids, and that the token's person can open the thing in the app.
405method_not_allowedThe address exists but not with this method (updates use PATCH; there is no PUT).Use a method the address lists in the reference.
409conflictThe thing changed since it was read, or the change clashes with its state.Read it again and send the change once more.
409archivedThe item (or its project) is archived, so it can't be changed.Restore it first, or leave it.
409transition_not_allowedThe transition isn't open from the task's status now, or one of its conditions or checks isn't met; the message gives the workflow's reason.List the open transitions with GET /tasks/{task}/transitions and pick one of them.
409limit_reachedA limit was reached (of the plan, or of how many of something one person may have).The message names the limit; remove something or change the plan.
413too_largeThe body or a file is larger than allowed.Send less, or a smaller file.
415unsupported_media_typeThe body isn't JSON.Send JSON with Content-Type: application/json.
422idempotency_key_reusedThe same Idempotency-Key was sent within 24 hours with a different body.Use a new key for a new request; repeat a request with its own key and the same body.
429rate_limitedToo many calls in this minute, for the token or for the whole organisation.Wait the seconds in Retry-After. The RateLimit headers on every answer show what is left.
500internalSomething went wrong on projqo's side (never your mistake).Try again; if it keeps happening, contact support and quote the request_id.

Each entry in details names the field, says what is wrong in message, and has one of these codes: required, invalid_value, too_long, too_short, too_big, too_small, unknown_parameter, invalid_cursor.

Workflow and field rules

projqo's own rules refuse a change through the API exactly as they refuse it in the app, with the app's message:

  • a transition that isn't open from the task's status, or whose condition or validator isn't met, is 409 transition_not_allowed: list the open transitions with GET /tasks/{task}/transitions and pick one;
  • a field the task's screen or the transition's screen requires is 400 field_required, with the field's key in details;
  • a value a field doesn't take (an option that isn't the field's, a number out of range, a text too long) is 400 invalid, one entry in details per field, by its key (summary, cf_effort_score);
  • an archived task, project, release or page is 409 archived;
  • a plan's limit (Free's ten people, a guest on Free, the organisation's storage) is 409 limit_reached;
  • any other clash with the item's state (a project's or space's key already taken, a closed sprint, a page published since you read it, the organisation's last owner) is 409 conflict, and the message says which.

Hidden and missing look the same

projqo never tells a caller that something exists when the person can't open it. An item in a project the person has no role in answers 404 not_found, byte for byte the same as an item that was never there.

Retrying

StatusRetry?
400, 401, 402, 403, 404, 405, 409, 413, 415, 422No: change the request first.
429Yes, after Retry-After seconds.
500 and other 5xxYes, a few times, waiting longer each time. For a create, send the same Idempotency-Key so the retry can't make a second item.