Skip to content
SignWithDocs
Esc
  • Developer docs homeDocs
  • ChangelogDocs
  • OverviewREST API · Get started
  • Quick startREST API · Get started
  • Text tagsREST API · Get started
  • AuthenticationREST API · Get started
  • Making requestsREST API · Get started
  • ErrorsREST API · Get started

API error codes and what they mean

The SignWith API uses conventional HTTP status codes, and every error response has the same small envelope with a stable code your program can branch on.

Updated

The error envelope

Every 4xx and 5xx response looks like this:

JSON
{
  "error": {
    "code": "invalid_signer",
    "message": "Signer 2 needs an email or phone"
  }
}
  • code is stable. Branch on it in your code.
  • message is for people. It may change, so don't parse it; show it or log it.

All error codes

HTTPCodeMeaning
400invalid_jsonThe request body is not valid JSON.
401unauthenticatedThe API key is missing, malformed or revoked, or its account has been archived.
401api_key_expiredThe API key has passed its expiry date. Create a new one.
402insufficient_creditsYour account doesn't have enough credits to send this document. See Buying credits.
403read_only_api_keyA read-only key was used for a write request.
403insufficient_scopeMCP only: the AI app was connected with View only access and tried to change something.
403not_availableMCP only: the tool isn't offered to this app (credit purchase tools in ChatGPT).
403forbiddenThe key's user doesn't have access to this resource.
404not_foundThe resource doesn't exist or belongs to another account, or no endpoint matches the method and path.
409idempotency_key_in_useAnother request with the same Idempotency-Key is still running.
422idempotency_key_reusedThe Idempotency-Key was already used with a different request body.
422missing_parameterA required parameter is missing.
422invalid_parameterA parameter has an unsupported value (e.g. status, signing_order, expires_at not an ISO 8601 time in the future, prefill/metadata not an object, invalid signer email on update).
422invalid_requestThe request is well-formed but can't be processed (e.g. invalid prefill value).
422missing_documentsA template was created without any documents.
422too_many_documentsMore than 10 documents were sent for one template.
422document_too_largeA document is larger than 25 MB.
422invalid_documentA document is empty, could not be downloaded, or is not valid base64 / PDF.
422invalid_file_typeA document is not a PDF or an image.
422invalid_fieldA template field in fields is invalid (unknown type, missing options or areas, page or coordinates out of range, too many roles).
422template_has_no_fieldsThe template has no fields to fill in or sign yet. Add fields with PATCH /templates/{id} or in the editor.
422template_archivedThe template is archived and can't be sent. Duplicate it or pick another one.
422pdf_encryptedThe PDF is password protected and no password was sent.
422missing_signersA signature request has no usable signers.
422invalid_signersigners isn't a list of objects, a signer has no email or phone or an invalid email, has an unknown role, a role is given twice, or there are more signers than roles.
422already_completedThe signature request is already fully signed.
422not_openThe signature request was canceled, declined or has expired, so it can't be reminded and its signers can't be changed.
422nothing_to_remindNo signer is currently waiting to sign.
422signer_finishedThe signer has already signed or declined.
422invalid_discount_codeThe discount code is invalid, used up, expired or not valid for this credit pack.
422already_purchasedThe user already has the lifetime deal.
422billing_details_requiredThe user must add a billing country in SignWith before buying credits.
429rate_limitedToo many requests (or more than 20 feedback messages in an hour). Wait for Retry-After seconds when present.
429remind_too_soonSigners of this request were reminded less than an hour ago, or (resend: true) this signer was emailed less than 10 minutes ago.
500internal_errorSomething went wrong on SignWith's side. Retry (with the same Idempotency-Key for POSTs); contact support if it persists.
502payment_provider_errorThe payment provider couldn't start the checkout. Try again later.

Handling errors in practice

  • 402 insufficient_credits is the one most integrations should handle in the product: tell the user, or buy credits from the API and retry. See credits and billing.
  • 422 codes mean the request itself needs fixing. The message names the parameter, signer or field, for example Signer 2 has role "Buyer", but the template's roles are: Tenant, Landlord.
  • 429, 409 and 5xx are temporary. Retry them safely with the same Idempotency-Key.
  • 401 and 403 are about the key. See authentication.

Each endpoint in the API reference lists the statuses it can return.

Start building

The API and MCP server come with every account. 3 free documents a month, then pay per document.