Skip to content
VectorMojo

Docs

Errors

An error has an HTTP status and a body with a code and a message. Read the code; the message is for people and may change.

The shape

{
  "error": {
    "code": "invalid_request",
    "message": "prompt: Too big: expected string to have <=8000 characters"
  }
}

A few errors come from the web server before VectorMojo reads the request: a body that is not valid JSON (400), a body over 8 MB (413), a path that does not exist (404), and an unexpected fault (500). Those bodies hold statusCode and message instead of error.code. Check the HTTP status first.

HTTP errors

StatusCodeWhen
400invalid_requestA field is missing, has the wrong type or is out of range. The message names each field.
400unknown_modelThe model name is not one on sale. See GET /v1/models.
400invalid_imageThe image is not a PNG, JPEG or WebP, or does not match its media_type.
400invalid_svgEdit: the SVG you sent is unsafe beyond repair, has no size between 16 and 4,000, or does not render. Export: the version could not be exported.
400target_not_foundEdit: no element with that id in the version you edit.
400too_many_versionsEdit: the design already holds 100 versions.
400export_too_largeExport: the PNG or WebP would pass 40 million pixels or 16,383 pixels on a side.
401unauthorizedNo key, a wrong key or a revoked key.
402insufficient_creditsYour balance is lower than the job's price. No job is made. Extra fields: required, available.
403forbiddenAPI key routes called with an API key. Manage keys in the studio.
404not_foundNo such job, design, version, file or brand in your account.
409api_key_limitThe account already holds the most API keys it can.
409brand_limitThe account already holds 50 brands.
413(none)The request body is larger than 8 MB.
429rate_limitedToo many requests in this minute. Has a Retry-After header and a retry_after field. See Rate limits.
429too_many_failed_jobsMany of your recent jobs failed. Wait a while, or change the request. No Retry-After header.
429account_pausedThe account sent several requests that VectorMojo does not answer (see identity_question below) within 24 hours. It is paused for 24 hours. Extra field: retry_at.
502checkout_failedBuying credits: the payment page could not be opened. Try again in a moment.
503billing_not_configuredBuying credits is not available yet.

402: not enough credits

HTTP/1.1 402 Payment Required

{
  "error": {
    "code": "insufficient_credits",
    "message": "Not enough credits: this job needs 20, the balance is 4.",
    "required": 20,
    "available": 4
  }
}

429: too many requests

HTTP/1.1 429 Too Many Requests
Retry-After: 23

{
  "error": {
    "code": "rate_limited",
    "message": "Too many requests. Try again in 23 s.",
    "retry_after": 23
  }
}

too_many_failed_jobs is also a 429. Jobs that fail are free for you, so an account whose jobs keep failing is paused for a while: by default, more than 12 failed jobs in the past hour. It has no Retry-After header. Wait, or change what you send.

When a job fails

A job that was accepted (202) can still fail later. GET /v1/jobs/:id then answers 200 with "status": "failed" and an error. A failed job is never charged: its credits come back, and its credits field reads 0.

job.error.codeWhen
design_failed_checksVectorMojo could not make a design that passes its own checks, even after one repair.
model_refusedVectorMojo could not make this design or edit.
identity_questionThe request asks what is behind VectorMojo, or tries to change how VectorMojo works. VectorMojo does not answer that. Nothing is drawn and nothing is charged.
generation_failedSomething went wrong while making the design.
edit_failedSomething went wrong while editing the design.
design_not_foundEdit: the design was gone when the job ran.
queue_unavailableVectorMojo could not queue the job. Try again in a moment.
queue_timeoutThe job waited in the queue for too long (about 7 minutes).
timed_outThe job ran for too long (about 12 minutes) and was stopped.

Designs are AI-generated. Outputs can contain factual mistakes, so review every design before you use it.