Skip to content

Error codes ​

Every JSON error response has the same shape:

json
{
  "error": "Job not found",
  "code": "NOT_FOUND",
  "requestId": "req-42"
}
FieldAlways presentMeaning
errorYesA human-readable message. Safe to show to users. Do not parse it.
codeYesA stable, machine-readable code. Branch on this.
requestIdYesThe server's ID for this request. Quote it when you report a problem; it matches the server log.
detailsSometimesMore context for some 4xx errors, such as the validation message.

Messages can change between releases. Codes do not, so write client logic against code.

Codes from the HTTP status ​

When a route does not set its own code, the server derives one from the status:

HTTP statuscode
400BAD_REQUEST
401AUTH_REQUIRED
403FORBIDDEN
404NOT_FOUND
409CONFLICT
413PAYLOAD_TOO_LARGE
415UNSUPPORTED_MEDIA_TYPE
422UNPROCESSABLE_ENTITY
429RATE_LIMITED
500INTERNAL_ERROR
501NOT_IMPLEMENTED
503SERVICE_UNAVAILABLE
507INSUFFICIENT_STORAGE

Any other 4xx falls back to BAD_REQUEST, and any other 5xx to INTERNAL_ERROR.

A route can set a more specific code, and then the response carries that code instead. For example, a tool that cannot run because its AI bundle is missing returns a feature-specific code. Those codes are described with the feature that raises them.

Authentication and access ​

codeStatusWhat to do
AUTH_REQUIRED401Send Authorization: Bearer <token> with a session token or an API key (si_...).
FORBIDDEN403The credential is valid but lacks the permission. Ask an admin for the permission.
MUST_CHANGE_PASSWORD403The account must change its password before it can call other endpoints. Call POST /api/auth/change-password with the session token, then retry.
USER_DISABLED403The account is disabled. An admin has to re-enable it.
LOGIN_THROTTLED429Too many failed sign-in attempts. Wait before trying again.
VALIDATION_ERROR400The request body or parameters failed validation. details names the problem.

The first-run admin account is admin with the password admin unless DEFAULT_USERNAME or DEFAULT_PASSWORD changed it. Unless SKIP_MUST_CHANGE_PASSWORD is set, that account gets MUST_CHANGE_PASSWORD on every call until the password changes.

Jobs ​

A job that fails reports its reason on the job itself, not in the HTTP error. Read error.code and error.message from GET /api/v1/jobs/{jobId}. See Progress Tracking.

A failed job keeps error.code only when the failure is an input error or a server fault. Other failures carry the message alone.

codeMeaningWhat to do
CANCELEDThe job was canceled by a user. It is not an HTTP status. Progress events carry phase: failed with this code.Treat it as a user cancel. Do not retry it automatically.
INPUT_MISSINGThe input was removed before the job ran.Upload the file again.
ENGINE_UNAVAILABLEA required engine could not start on the server.Retry after an administrator repairs the install.
JOB_STALLEDNot returned to clients; it labels the server's error report. The worker lost the job's lock more times than the queue allows, usually because the server restarted or ran short of memory or CPU. The job fails with a message saying it was interrupted.Retry. If it keeps happening, give the server more memory or lower CONCURRENT_JOBS.

Authentication and MFA ​

codeStatusMeaningWhat to do
MFA_ENROLLMENT_REQUIRED403The MFA policy requires enrollment, and this instance cannot enroll the user (no enterprise license). Licensed instances return 200 with requiresMfaEnrollment: true and walk the user through enrollment instead.Do not retry. An administrator has to change the policy or use the offline recovery CLI.
MFA_POLICY_UNAVAILABLE503The server could not read the MFA policy during sign-in.Retry the sign-in shortly.
INVALID_CODE401The TOTP or recovery code is wrong.Ask the user for a fresh code and retry. Repeated failures end in MFA_ATTEMPTS_EXHAUSTED.
MFA_ATTEMPTS_EXHAUSTED401Too many wrong codes. The challenge is discarded.Start the sign-in again to get a new challenge.
MFA_EXPIRED401The MFA or enrollment challenge expired or does not match.Start the sign-in again.
MFA_NOT_CONFIGURED401The account has no TOTP secret, so a code cannot be checked.Enroll MFA before signing in with a code.
MFA_ALREADY_ENABLED409MFA is already active on the account.Do not enroll again.
NO_PENDING_ENROLLMENT400An enrollment confirmation arrived with no pending enrollment.Call the enroll endpoint first.
MFA_NOT_ENABLED400The action needs MFA to be on, and it is off for this user.Skip the action, or enable MFA first.
MFA_DECRYPTION_FAILED500The stored TOTP secret cannot be decrypted.Operator action. This usually means the encryption key changed. Check DATA_ENCRYPTION_KEY and DATA_ENCRYPTION_KEY_PREVIOUS.
DECRYPTION_FAILED500A stored value (a setting, a webhook auth header, or a TOTP secret) cannot be decrypted.Operator action, as above. Do not retry.
IDLE_TIMEOUT401The session expired after a period of inactivity.Sign in again.
INVALID_PASSWORD401The current password is wrong on a password change.Ask the user for the current password.
PASSWORD_CHANGED409The password changed in another session, or an administrator reset it, while this request was running.Sign in again.
OIDC_NO_PASSWORD400A password change or reset was requested for an account created through SSO.Direct the user to the identity provider.

OIDC ​

OIDC failures during sign-in do not return a JSON body. The login route redirects to the login page with a generic reason, and the audit log records the code. The logout route still ends the local session when the identity provider cannot be reached.

codeStatusMeaningWhat to do
OIDC_ISSUER_SCHEME_MISMATCHNone (redirect)The issuer URL is http, but EXTERNAL_URL is https, so the client refuses discovery.Administrator: serve the issuer over https, or run the instance over http.
OIDC_DISCOVERY_TIMEOUTNone (redirect)Discovery of the issuer timed out.Check that the server can reach the issuer, then retry.
OIDC_DISCOVERY_FAILEDNone (redirect)Discovery failed for another reason.Check the issuer URL and the server's outbound access.
OIDC_END_SESSION_INVALIDNone (logout continues)The identity provider's end_session_endpoint is not a valid URL. The local session is still cleared.Administrator: fix the provider's metadata.
OIDC_END_SESSION_SCHEMENone (logout continues)The end_session_endpoint uses a scheme the server does not allow. The local session is still cleared.Administrator: fix the provider's metadata.

SAML ​

SAML failures do not set a code. A failed assertion redirects to the login page with saml_auth_failed, and the SAML_LOGIN_FAILED audit event records the reason.

SCIM ​

SCIM routes answer with the RFC 7644 error envelope (schemas, detail, status, and sometimes scimType). They do not set code. Branch on the HTTP status.

Teams, roles, and users ​

Duplicate team or role names return the generic CONFLICT, and a missing team or role returns NOT_FOUND.

codeStatusMeaningWhat to do
ESCALATION_DENIED403The caller's role does not allow the change. The target sits above the caller's authority, the role is built in, or the request grants permissions the caller does not hold.Do not retry. Ask a user with more authority.
UNKNOWN_ROLE400The role ID does not match an existing role.Fix the role ID. List the roles to find it.
UNKNOWN_TEAM400The team ID does not match an existing team.Fix the team ID.
SELF_DEMOTE400An admin tried to remove their own admin role.Have another admin make the change.
SELF_DELETE400An admin tried to delete their own account.Have another admin delete it.
LAST_ADMIN400 on user routes, 409 on GDPR purge routesThe change would leave no admin, or purge a team that holds every admin.Make another user an admin first.
USER_LIMIT_REACHED403The instance is at its MAX_USERS limit.Remove a user, or raise MAX_USERS.

Features and AI bundles ​

Tools, batch runs, and pipelines that need an optional AI bundle use these codes.

codeStatusMeaningWhat to do
FEATURE_NOT_INSTALLED501, or 400 from Smart Crop's face modeThe tool, or one step of a pipeline or batch, needs a bundle that is not installed. The body includes feature (the bundle ID) and featureName.Install the bundle in Settings, then retry.
FEATURE_CPU_UNSUPPORTED409An install or offline import was refused because the bundle's x86-64 libraries need AVX and this server's CPU doesn't have it. Nothing was downloaded or installed. The body includes feature (the bundle ID) and reason (cpu-no-avx). GET /api/v1/features reports the same bundle with compatibility: "incompatible" and compatibilityReason: "cpu-no-avx".Run SnapOtter on a CPU with AVX, or on arm64. Other bundles still install.
FEATURE_INCOMPATIBLE501, or 400 when Fast OCR gets a language it can't readThe installed feature cannot do the requested quality or language.Change the setting, or install a bundle that supports it.
ENGINE_UNAVAILABLE503A required engine could not start, or an OCR runtime was removed after the request was validated.Retry after an administrator repairs or reinstalls the feature.
BROWSER_NOT_AVAILABLE503Chromium is not installed, so HTML to image cannot run.Ask an administrator to install the browser.
BROWSER_CRASHED503The screenshot browser crashed while rendering.Retry the request.

Tools ​

codeStatusMeaningWhat to do
INPUT_MISSING410The uploaded input was removed before the job ran.Upload the file again and submit the job.
ANALYSIS_EXPIRED410The passport photo analysis expired before generation.Analyze the photo again, then generate.
BACKGROUND_REMOVAL_EXPIRED410The background removal result expired before the follow-up step.Remove the background again.
NOT_ANIMATED400Remove GIF Background received a still image.Use Remove Background for still images.
TOO_MANY_FRAMES400The animation has more frames than the server allows (GIF_BG_MAX_FRAMES).Send a shorter animation, or ask an administrator to raise the limit.
TOO_MANY_PIXELS400The animation's canvas times its frame count is over the server's limit: 268,402,689 pixels (16383 x 16383) for Remove GIF Background, or the GIF workload cap for other animated tools.Send fewer frames or a smaller animation.
IMAGE_TOO_LARGE400The image has more pixels than the decoder accepts.Send a smaller image.
RESULT_TOO_LARGE400The settings would produce an image larger than the encoder or pixel limit allows.Use a smaller image or settings that make a smaller result.
DOCUMENT_UNREADABLE400LibreOffice or pandoc couldn't open the document. It may be damaged, password-protected, or not the format its extension says.Check the file opens in an office app, then send it again.
PDF_DAMAGED400The PDF engine found broken document structure.Run the file through Repair PDF, then retry.
PDF_PASSWORD_PROTECTED400The PDF is encrypted and this tool can't open it.Unlock it with Unlock PDF first.
NO_AUDIO_TRACK400The file has no audio stream for an audio tool to use.Send a file that has audio.
MEDIA_UNDECODABLE400ffmpeg couldn't read the audio or video: it found no packets, no codec parameters, no moov atom, or data it can't parse.Check the file plays in a media player, or re-export it, then retry.
PAGE_OUT_OF_RANGE400The page range names a page the PDF doesn't have.Check the page count and send a range inside it.
INVALID_PAGE_RANGE400The page range isn't valid syntax.Use page numbers like 1-3,5.
CANNOT_REMOVE_ALL_PAGES400Remove Pages was asked to remove every page.Keep at least one page.
NESTING_TOO_DEEP400The JSON or XML is nested more than 100 levels deep.Flatten the document, then convert it.
IMAGE_UNDECODABLE400The image can't be decoded, or its dimensions can't be read. The file may be damaged or use an encoding the decoder doesn't support.Re-export the image from another app, or convert it to PNG or JPEG first.
INVALID_SETTINGS400A setting is out of range or doesn't fit this file: a crop outside the image, a resize of zero, a GIF frame the animation doesn't have, a passport spec that doesn't exist. The error text names the setting.Fix the setting named in error, then retry.
CHART_DATA_INVALID400Chart Maker couldn't read chart data from the file: the CSV or JSON doesn't parse, has no numeric column, has more than 100 rows, or has a negative value. The error text says which.Send CSV or JSON with up to 100 rows, each a label and a number of zero or more.
NO_FACE_DETECTED400Passport Photo found no face in the image.Send a clear, front-facing photo with good lighting.
TARGET_SIZE_UNREACHABLE400Compression, or a passport photo's size limit, can't get the file under the requested size, even after scaling it down.Ask for a larger target size, or crop the image first.
TOO_MANY_PAGES400OCR was asked for more pages than it processes in one job.Select fewer pages with the page range.
METADATA_DAMAGED400Edit Metadata found the image's existing EXIF data damaged, so it can't rewrite it safely.Strip the metadata with Remove Image Metadata first, then edit.
REMOTE_RESOURCES_DISABLED400HTML or Markdown to PDF found a reference to an image, stylesheet, or font on the network, which the server doesn't fetch.Embed the resource in the file (for example as a data: URI), then retry.

Files ​

codeStatusMeaningWhat to do
STORAGE_QUOTA_EXCEEDED413Saving to Files would exceed the user's storage quota.Delete files, or ask an administrator for more space.
INVALID_STORED_NAME400The server rejected a stored file name.Upload the file again.

Pipelines and batch ​

Pipeline and batch requests return the feature codes above for each step that needs a bundle. A job ID that is already in use returns CONFLICT with status 409. Send a new job ID.

Settings ​

codeStatusMeaningWhat to do
UNKNOWN_SETTING400The key is not a known setting.Check the key name.
READONLY_SETTING400The setting cannot be changed through the API.Change it through the environment or the admin UI.
DEPENDENCY_VALIDATION_FAILED400The new value conflicts with other settings. The body names the setting in setting and lists the problems in validationErrors.Fix the listed settings, then retry.
SETTING_DECRYPTION_FAILED500A stored setting cannot be decrypted.Operator action, as for DECRYPTION_FAILED.

For VALIDATION_ERROR on a setting, details holds the schema issues.

Enterprise ​

codeStatusMeaningWhat to do
FEATURE_NOT_LICENSED403The setting or policy needs an enterprise license, such as SSO enforcement or the MFA policy.Use a licensed instance, or leave the setting off.
IP_NOT_ALLOWED403The request's IP address is not in the allowlist.Connect from an allowed network.
INVALID_CIDR400An allowlist entry is not a valid CIDR. The message lists the bad entries.Fix the entries and save again.
SELF_LOCKOUT400Saving the allowlist would block the caller's current IP.Add your current IP to the list first.

GDPR purge routes return a plain CONFLICT with status 409 when a user or team is under legal hold.

Codes that clients do not receive ​

These codes exist in the server source for logs, telemetry, or Fastify's own errors. A client does not get them in a response body or job row, so do not write client logic against them.

codeWhere it goes
ALERT_DECRYPTION_FAILEDReported to error tracking by the alert evaluator. An alert webhook's auth header cannot be decrypted.
SIEM_DECRYPTION_FAILEDReported to error tracking by SIEM forwarding. The SIEM auth header cannot be decrypted.
WEBHOOK_DECRYPTION_FAILEDReported to error tracking. The request that hit the same failure answers with DECRYPTION_FAILED.
STAGED_DISCARD_FAILEDReported to error tracking when a staged upload cannot be removed.
USERNAME_RACE_EXHAUSTEDRaised when SSO auto-create loses the username race on every retry. The login page shows an error instead.
ERR_OUT_OF_RANGEThrown by the object storage reader for an invalid byte range.
ETIMEDOUTSet on the timeout error for a GDPR export. The export fails, and it can be requested again.
FST_REQ_FILE_TOO_LARGEFastify's code for an upload over the limit. Clients get a 413 with PAYLOAD_TOO_LARGE, or the route's own 413 message.
TARGET_SIZE_EXCEEDEDThrown when a target-size compression misses its target. The error has no status or code, so clients get a generic failure.
OCR_CACHE_PERMISSIONSReported to error tracking as an operational fault when the AI data volume leaves the OCR runtime cache world-writable. The install job fails with a message that names the storage problem.
OCR_RUNTIME_UNREACHABLEReported to error tracking as an operational fault when the server never reached huggingface.co to download the OCR runtime. The install job fails with a message about network access, HTTPS_PROXY, and offline import.