GEThttps://api.veriko.mx/v1/validations/{id}/image

Get the receipt image

Visibility
public
Auth
API key
Permission
validations.records.read
How-to guide →

Returns the receipt kept for an OCR validation, with private caching:

  • Image: delivered with inline disposition.
  • PDF: always delivered as an attachment (attachment) and with Content-Security-Policy: sandbox, so a browser does not open it within the same origin.

If the validation has no image available, it responds with an HTTP status 404 (with image_not_available in the body).

If the validation was created with retain_image=false, it responds with an HTTP status 410 (with image_not_retained in the body); if it was purged, with an HTTP status 410 (with validation_purged in the body). A 410 is not resolved by retrying: the file does not exist.

Parameters
ParameterInTypeRequiredDescription
id*pathstring (uuid)required

Validation UUID.

Request
curl -X GET 'https://api.veriko.mx/v1/validations/{id}/image' \
  -H 'Authorization: Bearer veriko_••••'

Python example — coming soon.

JavaScript example — coming soon.

PHP example — coming soon.

Response status codesGET /v1/validations/{id}/image
StatusClassDescriptionBody
2002xx
Receipt. Content-Type is image/png, image/jpeg, image/webp, or application/pdf; other content is returned as application/octet-stream.
Body without schema
4014xx
Authentication is required or the provided credentials are invalid.
ErrorResponse
4034xx
Insufficient permissions. Also email_verification_required: the account's email cannot receive mail and, until it is fixed or verified, only reading the profile, fixing the email, and logging out are allowed.
ErrorResponse
4044xx
Validation not found (not_found) or no image is available (image_not_available).
ErrorResponse
4104xx
The image does not exist by the client's decision: the validation was created with retain_image=false (image_not_retained) or was purged (validation_purged).
ErrorResponse
4224xx
Invalid UUID in path (invalid_uuid).
ErrorResponse
4294xx
Rate limit exceeded (rate_limit_exceeded: wait a few seconds).
RetryAfterError
Response headers200
HeaderTypeDescription
Cache-Controlstring
Privately cacheable for 1 hour.
Content-Dispositionstring
inline for an image and attachment for a PDF, with a filename derived from the validation identifier and the format extension.
Content-Security-Policystring
Only with a PDF. sandbox blocks scripts and treats the document as a different origin if a viewer opens it.
Cross-Origin-Resource-Policystring
Restricts use of the resource to the same origin.
X-Content-Type-Optionsstring
Prevents the browser from inferring a different content type.
Errors from GET /v1/validations/{id}/image
StatusCodeExample
401unauthorized

This request requires authentication.

Envelope
meta.request_id
c4d5e6f7a8b99b8a7f6e5d4c
403permission_denied

You do not have permission to access this resource.

Envelope
meta.request_id
d5e6f7a8b9c00c9b8a7f6e5d
404not_found

We could not find what you requested.

Envelope
meta.request_id
bd8fd99b15bf
422validation_error

Some data needs fixing.

Envelope
meta.request_id
f4ae25da5af5
429rate_limit_exceeded

You exceeded the request limit.

Envelope
meta.request_id
f7a8b9c0d1e22e1d0c9b8a7f
Response headers
  • Retry-After: integer — Seconds to wait before retrying. Matches the endpoint's rate-limit window (typically 60s for list endpoints, 1-5s for in-flight idempotent operations).
  • X-RateLimit-Limit: integer — Configured request cap for this bucket. It is emitted on every 429 and, on the authenticated API, also on successful responses, where it is the per-key cap of the account plan.
  • X-RateLimit-Remaining: integer — Requests remaining in the current window. Always 0 at the moment of the 429; on a successful response of the authenticated API it is what is left of the per-key cap.
  • X-RateLimit-Reset: integer — Absolute Unix epoch (seconds) when the window resets. Emitted on every 429, alongside Retry-After, and on successful responses of the authenticated API.