Browse the docs Open Close
API Reference
every object, every endpoint
The complete reference, generated from the live API spec. Download it whole as Markdown, OpenAPI or Postman.
Objects
Template
A reusable design with addressable layers.
| Field | Type | Description |
|---|---|---|
uuid |
string | Stable public identifier. |
title |
string | Human-readable name. |
width |
integer | Canvas width in pixels. |
height |
integer | Canvas height in pixels. |
layers |
Layer[] | Addressable layers and their modifications. |
created_at |
datetime | ISO-8601 creation timestamp. |
Layer
A single addressable element inside a template.
| Field | Type | Description |
|---|---|---|
layer |
string | Layer key used when overriding content. |
type |
string | One of image, text, empty, qr_code. |
available_modifications |
object | Override keys this layer accepts (image_url, text, background_color, qr_content). |
Screenshot
A rendered capture of a web page.
| Field | Type | Description |
|---|---|---|
id |
string | Screenshot UUID. |
url |
string | Captured page URL. |
image_url |
string | URL of the rendered image. |
width |
integer | Viewport width in pixels. |
height |
integer | Viewport height in pixels. |
created_at |
datetime | ISO-8601 creation timestamp. |
Snap
A render job produced from a template or collection.
| Field | Type | Description |
|---|---|---|
id |
string | Snap UUID. |
media_url |
string|null | URL of the finished asset, null until completed. |
type |
string | image or pdf. |
status |
string | pending, processing, completed, failed or canceled. |
is_async |
boolean | Whether the snap was queued. |
webhook_url |
string|null | Callback URL for async completion. |
completed_at |
datetime|null | When rendering finished. |
last_error |
string|null | Failure reason, when status is failed. |
variants |
array|null | Per-layer content overrides applied. |
template_id |
string|null | Source template UUID. |
template_title |
string|null | Source template name. |
created_at |
datetime | ISO-8601 creation timestamp. |
Endpoints
Authentication
/v1/auth
Verify the current token
Returns the account the token belongs to. Use it to confirm a token is valid and to read the signed-in identity.
Example request
curl
curl https://snapsbrew.com/api/v1/auth \
-H 'Authorization: Bearer <your-token>' \
-H 'Accept: application/json'
Example responses
{
"data": {
"email": "[email protected]",
"name": "Ada Lovelace"
}
}
{
"message": "Unauthenticated."
}
{
"message": "Invalid ability provided."
}
Usage
/v1/usage
Get current usage
Returns purchased, used and remaining requests for the active billing period.
The response carries an `X-Request-Uuid` header you can quote in support tickets.
Example request
curl
curl https://snapsbrew.com/api/v1/usage \
-H 'Authorization: Bearer <your-token>' \
-H 'Accept: application/json'
Example responses
{
"period_start_date": "2026-05-01T00:00:00Z",
"period_end_date": "2026-05-31T23:59:59Z",
"period_purchased_requests": 1000,
"period_used_requests": 240,
"period_available_requests": 760
}
{
"message": "Unauthenticated."
}
Templates
/v1/templates
List templates
Returns a cursor-paginated list of your templates.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
cursor |
query | string | No | Cursor token from a previous response's meta.next_cursor. |
Example request
curl
curl https://snapsbrew.com/api/v1/templates \
-H 'Authorization: Bearer <your-token>'
Example responses
{
"data": [
{
"uuid": "141e8454-8aa1-420a-bd0b-18a85ba949a2",
"title": "Template 1",
"width": 1200,
"height": 630,
"layers": [
{
"layer": "review_title",
"type": "text",
"available_modifications": {
"text": "The worst Time-Travel movie ever made"
}
}
],
"created_at": "2026-05-01T12:00:00Z"
}
],
"meta": {
"previous_cursor": null,
"next_cursor": "eyJpZCI6MTB9"
}
}
/v1/templates/{templateUuid}
Get a template
Returns a single template and its parsed layers.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
templateUuid |
path | string | Yes | UUID of the template. |
Example request
curl
curl https://snapsbrew.com/api/v1/templates/<uuid> \
-H 'Authorization: Bearer <your-token>'
Example responses
{
"uuid": "141e8454-8aa1-420a-bd0b-18a85ba949a2",
"title": "Template 1",
"width": 1200,
"height": 630,
"layers": [
{
"layer": "review_poster",
"type": "image",
"available_modifications": {
"image_url": "https://snapsbrew.com/crazy-doc-brown-jailed"
}
},
{
"layer": "review_title",
"type": "text",
"available_modifications": {
"text": "The worst Time-Travel movie ever made"
}
}
],
"created_at": "2026-05-01T12:00:00Z"
}
{
"message": "Not found."
}
/v1/templates
Create a template
Creates a template and generates its preview image. Requires the create-template policy.
Request body
Content-Type: application/json
| Field | Type | Required | Validation | Description |
|---|---|---|---|---|
title |
string | No | no server validation |
Template name. |
width |
integer | No | no server validation |
Canvas width in pixels. |
height |
integer | No | no server validation |
Canvas height in pixels. |
layers |
array | No | no server validation |
Layer definitions; stored JSON-encoded. |
This endpoint does not validate input. Send well-formed values — bad data is persisted as-is.
Example request
curl
curl -X POST https://snapsbrew.com/api/v1/templates \
-H 'Authorization: Bearer <your-token>' \
-H 'Content-Type: application/json' \
-d '{"title":"Launch card","width":1200,"height":630,"layers":[]}'
Example responses
{
"data": {
"uuid": "...",
"title": "New template"
},
"message": "Template created successfully"
}
/v1/templates/{templateId}
Update a template
Updates a template and regenerates its preview image. The path segment is the numeric template ID, not the UUID.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
templateId |
path | integer | Yes | Numeric template ID, scoped to your company. |
Request body
Content-Type: application/json
| Field | Type | Required | Validation | Description |
|---|---|---|---|---|
title |
string | No | no server validation |
Template name. |
width |
integer | No | no server validation |
Canvas width in pixels. |
height |
integer | No | no server validation |
Canvas height in pixels. |
layers |
array | No | no server validation |
Layer definitions; stored JSON-encoded. |
Example request
curl
curl -X PATCH https://snapsbrew.com/api/v1/templates/42 \
-H 'Authorization: Bearer <your-token>' \
-H 'Content-Type: application/json' \
-d '{"title":"Updated title"}'
Example responses
{
"message": "template updated sucessfully"
}
{
"message": "Not found."
}
/v1/templates/{templateId}
Delete a template
Deletes a template. The path segment is the numeric template ID. Requires the delete-template policy.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
templateId |
path | integer | Yes | Numeric template ID, scoped to your company. |
Example request
curl
curl -X DELETE https://snapsbrew.com/api/v1/templates/42 \
-H 'Authorization: Bearer <your-token>'
Example responses
{
"message": "template deleted sucessfully"
}
{
"message": "Not found."
}
Media
/v1/media
List media
Returns your uploaded images, 12 per page, newest first.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
page |
query | integer | No | Page number for the standard paginator. |
Example request
curl
curl https://snapsbrew.com/api/v1/media \
-H 'Authorization: Bearer <your-token>'
Example responses
{
"data": [
{
"id": 12,
"file_name": "logo.png",
"src": "https://snapsbrew.com/storage/12/conversions/logo-image.jpg"
}
],
"links": {
"first": "...",
"last": "...",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"per_page": 12,
"total": 1
}
}
/v1/media
Upload media
Uploads an image into your media library. Send as multipart/form-data.
Request body
Content-Type: multipart/form-data
| Field | Type | Required | Validation | Description |
|---|---|---|---|---|
file |
file | Yes | required, file, image |
The image to upload. |
Example request
curl
curl -X POST https://snapsbrew.com/api/v1/media \
-H 'Authorization: Bearer <your-token>' \
-F '[email protected]'
Example responses
{
"id": 12,
"file_name": "logo.png",
"src": "https://snapsbrew.com/storage/12/conversions/logo-image.jpg"
}
{
"message": "The file must be an image."
}
Screenshots
/v1/screenshots
List screenshots
Returns a cursor-paginated list of your screenshots.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
cursor |
query | string | No | Cursor token from meta.next_cursor. |
Example request
curl
curl https://snapsbrew.com/api/v1/screenshots \
-H 'Authorization: Bearer <your-token>'
Example responses
{
"data": [
{
"uuid": "a1b2c3",
"url": "https://example.com",
"image_url": "https://snapsbrew.com/storage/screenshots/a1b2c3.png",
"width": 1330,
"height": 780,
"created_at": "2026-05-01T12:00:00Z"
}
],
"meta": {
"previous_cursor": null,
"next_cursor": null
}
}
/v1/screenshots/{screenshotUuid}
Get a screenshot
Returns a single screenshot.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
screenshotUuid |
path | string | Yes | UUID of the screenshot. |
Example request
curl
curl https://snapsbrew.com/api/v1/screenshots/<uuid> \
-H 'Authorization: Bearer <your-token>'
Example responses
{
"data": {
"id": "a1b2c3",
"url": "https://example.com",
"image_url": "https://snapsbrew.com/storage/screenshots/a1b2c3.png",
"width": 1330,
"height": 780,
"created_at": "2026-05-01T12:00:00Z"
}
}
{
"message": "Not found."
}
/v1/screenshots
Create a screenshot
Captures a web page. Defaults to a 1330x780 viewport when width/height are omitted.
Credits — Requires available credits (canCreateSnap); returns 417 when exhausted.
Request body
Content-Type: application/json
| Field | Type | Required | Validation | Description |
|---|---|---|---|---|
url |
string | No | url |
Page to capture. Validated as a URL when present. |
width |
integer | No | integer |
Viewport width. Defaults to 1330. |
height |
integer | No | integer |
Viewport height. Defaults to 780. |
Example request
curl
curl -X POST https://snapsbrew.com/api/v1/screenshots \
-H 'Authorization: Bearer <your-token>' \
-H 'Content-Type: application/json' \
-d '{"url":"https://example.com","width":1330,"height":780}'
Example responses
{
"data": {
"id": "a1b2c3",
"url": "https://example.com",
"image_url": "https://snapsbrew.com/storage/screenshots/a1b2c3.png",
"width": 1330,
"height": 780,
"created_at": "2026-05-01T12:00:00Z"
}
}
{
"message": "Unauthenticated."
}
{
"message": "You have reached your snap quota."
}
Snaps
/v1/snaps
Create a snap
Renders a snap from a single template (`template_id`) or every template in a collection (`collection_id`). Provide exactly one of the two.
Synchronous (default): the response carries the finished `media_url` and returns 201.
Asynchronous (`async: true`): the snap is queued, the response returns 202 immediately, and the result is delivered to `webhook_url` on completion.
Credits — Synchronous: 1 credit per rendered template. Asynchronous: 0 credits at accept time (HTTP 202); the credit is charged when the queued snap reaches completed.
Request body
Content-Type: application/json
| Field | Type | Required | Validation | Description |
|---|---|---|---|---|
template_id |
string | No | required_without:collection_id, prohibits:collection_id, exists templates.uuid scoped to company |
UUID of a single template to render. |
collection_id |
string | No | required_without:template_id, prohibits:template_id, exists template_collections.uuid scoped to company |
UUID of a collection; one snap is rendered per template. |
type |
string | No | nullable, in:image,pdf |
Output format. Defaults to image. |
async |
boolean | No | sometimes, boolean |
Queue the render and return 202. |
webhook_url |
string | No | url, required_if:async,true |
Callback URL invoked when an async snap completes. |
variants |
array | No | no server validation |
Per-layer content overrides applied to the render. |
Every response carries an `X-Request-Uuid` header. Quote it in support tickets.
A collection request returns an array of snap objects, one per template.
Example request
curl
curl -X POST https://snapsbrew.com/api/v1/snaps \
-H 'Authorization: Bearer <your-token>' \
-H 'Content-Type: application/json' \
-d '{"template_id":"<uuid>","type":"image","variants":[{"layer":"review_title","text":"Hello world"}]}'
async curl
curl -X POST https://snapsbrew.com/api/v1/snaps \
-H 'Authorization: Bearer <your-token>' \
-H 'Content-Type: application/json' \
-d '{"template_id":"<uuid>","async":true,"webhook_url":"https://example.com/hooks/snap"}'
Example responses
{
"id": "9f1c2d3e",
"media_url": "https://snapsbrew.com/storage/snaps/9f1c2d3e.png",
"type": "image",
"status": "completed",
"is_async": false,
"webhook_url": null,
"completed_at": "2026-05-01T12:00:03Z",
"last_error": null,
"variants": [],
"template_id": "141e8454-8aa1-420a-bd0b-18a85ba949a2",
"template_title": "Launch card",
"created_at": "2026-05-01T12:00:00Z"
}
{
"id": "9f1c2d3e",
"media_url": null,
"type": "image",
"status": "pending",
"is_async": true,
"webhook_url": "https://example.com/hooks/snap",
"completed_at": null,
"last_error": null,
"variants": [],
"template_id": "141e8454-8aa1-420a-bd0b-18a85ba949a2",
"template_title": "Launch card",
"created_at": "2026-05-01T12:00:00Z"
}
{
"message": "Not found."
}
{
"message": "You have reached your snap quota."
}
{
"message": "The template id field is required when collection id is not present."
}
Tags
Embedded Forms
/v1/embedded-forms/{formUuid}
Submit an embedded form
Renders a snap from a configured form. Template forms return one snap; collection forms return an array of snaps.
Layer keys: template forms use the plain layer key (`headline`); collection forms use `{templateUuid}__{layerKey}`. Only layers the form was configured with are accepted; the rest are dropped silently.
Credits — The form owner is charged: 1 credit for a template form, or 1 per template for a collection form.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
formUuid |
path | string | Yes | UUID of the form. |
signature |
query | string | Yes | Laravel URL signature. The whole URL must be signed. |
Request body
Content-Type: multipart/form-data
| Field | Type | Required | Validation | Description |
|---|---|---|---|---|
layers |
object | No | keys matched against the form configuration |
Layer overrides. Value keys by layer type: image -> image_url (file), text -> text, empty -> background_color, qr_code -> qr_content. |
Collection forms return a bare array of snap objects, not a `data`-wrapped object.
This route has no rate limiting.
Example request
curl
curl -X POST 'https://snapsbrew.com/api/v1/embedded-forms/<formUuid>?signature=<sig>' \
-F 'layers[headline]=Summer sale' \
-F 'layers[logo][email protected]'
Example responses
{
"data": {
"id": "9f1c2d3e",
"media_url": "https://snapsbrew.com/storage/snaps/9f1c2d3e.png",
"type": "image",
"status": "completed",
"is_async": false,
"webhook_url": null,
"completed_at": "2026-05-01T12:00:03Z",
"last_error": null,
"variants": [],
"template_id": "141e8454",
"template_title": "Launch card",
"created_at": "2026-05-01T12:00:00Z"
}
}
{
"message": "Not found."
}
{
"message": "The form does not include any templates."
}