{
    "info": {
        "name": "Snapsbrew API Suite",
        "description": "Generate images, PDFs and screenshots from reusable templates. The Snapsbrew API turns design templates into a render pipeline you can call from any stack.",
        "_postman_id": "e9004e39-d826-8409-d889-bd2672cf4949",
        "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json"
    },
    "item": [
        {
            "name": "Authentication",
            "description": "Authenticated endpoints use a Sanctum personal access token. Send it as a bearer token in the Authorization header. Tokens must carry the `api_requests` ability. Authorization: Bearer <your-token> Accept: application/json",
            "item": [
                {
                    "name": "Verify the current token",
                    "request": {
                        "method": "GET",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/auth",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "auth"
                            ]
                        },
                        "description": "Returns the account the token belongs to, with the company it belongs to. Use it to confirm a token is valid and to read the signed-in identity. `company` is null when the account belongs to no company.\n\nGates: logApiRequest."
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                }
            ]
        },
        {
            "name": "Usage",
            "description": "Read the credit balance for the current billing period. Purely informational \u2014 it does not consume credits.",
            "item": [
                {
                    "name": "Get current usage",
                    "request": {
                        "method": "GET",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/usage",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "usage"
                            ]
                        },
                        "description": "Returns purchased, used and remaining requests for the active billing period.\n\nGates: logApiRequest.\n\nNote: The response carries an `X-Request-Uuid` header you can quote in support tickets."
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                }
            ]
        },
        {
            "name": "Guides",
            "description": "Guides are static reference catalogs. They tell you which layer properties exist, which overrides a layer accepts, how to compose a template that looks good, and what the v2 editor document contains. They also tell you what a platform does to an image after you upload it, and what a given kind of image has to achieve. The content never changes between accounts, so you can cache a response and reuse it. These endpoints read no template and no company data, and they cost no credits. They also stay outside your usage record, so a guide call never appears in `GET /v1/usage`.",
            "item": [
                {
                    "name": "Get the design guide",
                    "request": {
                        "method": "GET",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/guides/design",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "guides",
                                "design"
                            ]
                        },
                        "description": "Returns design guidance for building a template: canvas presets, the back-to-front layer order, typography and color rules, composition recipes, anti-patterns, and a preflight checklist. Read it before you write a `layers` array.\n\nNote: The catalog is the same for every account. Cache the response and refresh it on a new API version.\n\nNote: A guide call costs no credits and does not appear in `GET /v1/usage`."
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                },
                {
                    "name": "Get the layer schema",
                    "request": {
                        "method": "GET",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/guides/layers",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "guides",
                                "layers"
                            ]
                        },
                        "description": "Returns the design-time layer vocabulary: the layer object shape, every property name, the value shape of each property, and a worked example. Use it to build the `layers` array a template write accepts.\n\nNote: The catalog is the same for every account. Cache the response and refresh it on a new API version.\n\nNote: A guide call costs no credits and does not appear in `GET /v1/usage`."
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                },
                {
                    "name": "List variant properties",
                    "request": {
                        "method": "GET",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/guides/variant-properties",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "guides",
                                "variant-properties"
                            ]
                        },
                        "description": "Returns every property you can apply to a layer in `variants`, with its value type, the layer types it applies to, and an example. Pair it with the `available_modifications` of a template layer.\n\nNote: The catalog is the same for every account. Cache the response and refresh it on a new API version.\n\nNote: A guide call costs no credits and does not appear in `GET /v1/usage`."
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                },
                {
                    "name": "Get the editor document contract",
                    "request": {
                        "method": "GET",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/guides/editor-document",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "guides",
                                "editor-document"
                            ]
                        },
                        "description": "Returns the versioned v2 editor-document contract: the resource it describes, property constraints, persistence rules, conflict recovery, and a safe workflow. Read it before you change an editor document.\n\nNote: The catalog is the same for every account. Cache the response and refresh it on a new API version.\n\nNote: A guide call costs no credits and does not appear in `GET /v1/usage`."
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                },
                {
                    "name": "List platform guides",
                    "request": {
                        "method": "GET",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/guides/platforms",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "guides",
                                "platforms"
                            ]
                        },
                        "description": "Returns one line per platform: the size preset to start from, its dimensions and why that preset is the default. Read it to choose a platform, then read that platform for the full rules. The response also carries `specs_reviewed`, the month the published specs were last checked.\n\nNote: The catalog is the same for every account. Cache the response and refresh it on a new API version.\n\nNote: A guide call costs no credits and does not appear in `GET /v1/usage`."
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                },
                {
                    "name": "Get one platform guide",
                    "request": {
                        "method": "GET",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/guides/platforms/{platform}",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "guides",
                                "platforms",
                                "{platform}"
                            ]
                        },
                        "description": "Returns everything one platform does to an image: how it crops the frame, the directional UI safe zones where it paints its own controls, the accepted formats and size limits, the export width and color profile, its size presets, and its rules and anti-patterns.\n\nNote: The catalog is the same for every account. Cache the response and refresh it on a new API version.\n\nNote: A guide call costs no credits and does not appear in `GET /v1/usage`.\n\nNote: An alias is accepted. `/v1/guides/platforms/insta` returns the same guide as `/v1/guides/platforms/instagram`."
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                },
                {
                    "name": "List image purpose guides",
                    "request": {
                        "method": "GET",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/guides/purposes",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "guides",
                                "purposes"
                            ]
                        },
                        "description": "Returns one line per purpose: what that kind of image is, when to use it and the size presets that fit it. Read it to choose a purpose, then read that purpose for the full rules.\n\nNote: The catalog is the same for every account. Cache the response and refresh it on a new API version.\n\nNote: A guide call costs no credits and does not appear in `GET /v1/usage`."
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                },
                {
                    "name": "Get one image purpose guide",
                    "request": {
                        "method": "GET",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/guides/purposes/{purpose}",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "guides",
                                "purposes",
                                "{purpose}"
                            ]
                        },
                        "description": "Returns the job one kind of image has to do: the size presets that fit it, the rules and failure modes specific to it, a layer recipe in the Snapsbrew vocabulary, an anti-pattern list and a preflight checklist. The `link_preview` purpose also returns the og: and twitter: meta tags to put in the page head.\n\nNote: The catalog is the same for every account. Cache the response and refresh it on a new API version.\n\nNote: A guide call costs no credits and does not appear in `GET /v1/usage`.\n\nNote: An alias is accepted. `/v1/guides/purposes/og` returns the same guide as `/v1/guides/purposes/link_preview`."
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                }
            ]
        },
        {
            "name": "Templates",
            "description": "Templates are reusable designs with addressable layers. List and read them, or manage them programmatically. All template endpoints are scoped to your company.",
            "item": [
                {
                    "name": "List templates",
                    "request": {
                        "method": "GET",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/templates",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "templates"
                            ],
                            "query": [
                                {
                                    "key": "cursor",
                                    "value": "",
                                    "description": "Cursor token from a previous response's meta.next_cursor.",
                                    "disabled": true
                                }
                            ]
                        },
                        "description": "Returns a cursor-paginated list of your templates.\n\nGates: logApiRequest."
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                },
                {
                    "name": "List canvas size presets",
                    "request": {
                        "method": "GET",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/templates/sizes",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "templates",
                                "sizes"
                            ]
                        },
                        "description": "Returns every canvas size preset a template write accepts as `size` \u2014 Instagram, Facebook, X, LinkedIn, Threads, Pinterest, TikTok, YouTube, Snapchat, WhatsApp, web and email, display ads, and print. Each preset gives its dimensions, aspect ratio, and the safe margin to keep content away from the edges.\n\nGates: logApiRequest."
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                },
                {
                    "name": "Get a template",
                    "request": {
                        "method": "GET",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/templates/{templateUuid}",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "templates",
                                "{templateUuid}"
                            ]
                        },
                        "description": "Returns a single template, its parsed layers and its publish state. The layers are the draft, so read `has_unpublished_edits` to know whether the draft is what renders.\n\nGates: logApiRequest.\n\nNote: BREAKING CHANGE. The template fields moved under a `data` key. Read `data.uuid`, not `uuid`. Every success body of this API is `{\"data\": ...}`, a list adds `meta` and a write adds `message`.\n\nNote: `size` is the canvas size preset the template is stored under, the same value POST /v1/templates returns. It reads `custom` when the dimensions match no preset. GET /v1/templates/sizes lists every preset.\n\nNote: `published_version` is the version number snaps and previews render. It is null until you publish the template.\n\nNote: `has_unpublished_edits` is true when the draft is not the same as the published version. A layer edit, a resize and an editor-document edit all set it. Call POST /v1/templates/{templateUuid}/publish to make the draft render."
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                },
                {
                    "name": "Create a template",
                    "request": {
                        "method": "POST",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            },
                            {
                                "key": "Content-Type",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/templates",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "templates"
                            ]
                        },
                        "description": "Creates a template and generates its preview image. Requires the create-template policy.\n\nGates: policy:create,Template.\n\nNote: Send a `size` preset or an explicit `width`/`height`. A template saved with dimensions that match a preset is stored under that preset.\n\nNote: A body with no `size` and no `width`/`height` answers 422. A create has no stored canvas to fall back on.\n\nNote: The response holds the six fields above and nothing more. Read GET /v1/templates/{templateUuid} for the parsed layers and the publish state.",
                        "body": {
                            "mode": "raw",
                            "raw": "{\n    \"title\": \"<title>\",\n    \"size\": \"<size>\",\n    \"width\": 0,\n    \"height\": 0,\n    \"layers\": []\n}",
                            "options": {
                                "raw": {
                                    "language": "json"
                                }
                            }
                        }
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                },
                {
                    "name": "Update a template",
                    "request": {
                        "method": "PATCH",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            },
                            {
                                "key": "Content-Type",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/templates/{templateIdentifier}",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "templates",
                                "{templateIdentifier}"
                            ]
                        },
                        "description": "Updates a template and regenerates its preview image. The path segment accepts the template UUID or the numeric template ID. GET /v1/templates returns the UUID.\n\nNote: `data` holds the same six fields POST /v1/templates returns. It is a new key, so a client that reads `message` still works.\n\nNote: Read `data.size`, `data.width` and `data.height` after the write. A body that sends `size` sets the dimensions, and a body that sends the dimensions sets `size`.",
                        "body": {
                            "mode": "raw",
                            "raw": "{\n    \"title\": \"<title>\",\n    \"size\": \"<size>\",\n    \"width\": 0,\n    \"height\": 0,\n    \"layers\": []\n}",
                            "options": {
                                "raw": {
                                    "language": "json"
                                }
                            }
                        }
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                },
                {
                    "name": "Publish a template",
                    "request": {
                        "method": "POST",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/templates/{templateUuid}/publish",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "templates",
                                "{templateUuid}",
                                "publish"
                            ]
                        },
                        "description": "Publishes the current draft of a template as a new immutable version and returns that version number. Snaps and previews render the published version, so an edit takes effect only after this call. The call is safe to repeat: a draft with no new edits returns the version which is already live and creates no second version.\n\nGates: policy:update,Template.\n\nNote: BREAKING CHANGE. The response fields moved under a `data` key. Read `data.published_version`, not `published_version`.\n\nNote: `data.id` is deprecated. It repeats the value of `data.uuid`, which is the name every other template field uses. Read `data.uuid`. `data.id` stays until a major version removes it."
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                },
                {
                    "name": "Delete a template",
                    "request": {
                        "method": "DELETE",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/templates/{templateIdentifier}",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "templates",
                                "{templateIdentifier}"
                            ]
                        },
                        "description": "Deletes a template. The path segment accepts the template UUID or the numeric template ID. GET /v1/templates returns the UUID. Requires the delete-template policy.\n\nGates: policy:delete,Template.\n\nNote: This body carries no `data` key. Every other success body of this API holds one, and a delete is the exemption: the template is gone, so there is no resource to return."
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                }
            ]
        },
        {
            "name": "Editor documents",
            "description": "An editor document is the v2 draft of a template: its layers, its groups and every design-time property the editor shows. A template renders from that draft, so a change here changes what the next render draws. Every write is a compare-and-swap. Read the document, keep the `revision` it returns, and send that revision back. If the stored revision moved, the write returns `409` with the current revision and the current document. Rebuild the change on top of them and send the write again. Never resend the same body with the returned revision. `PATCH` applies a closed list of operations and changes only the properties you name. `PUT` replaces the whole document and drops every property you leave out. `GET /v1/guides/editor-document` carries the constraints both accept.",
            "item": [
                {
                    "name": "Get the editor document",
                    "request": {
                        "method": "GET",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/templates/{templateUuid}/document",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "templates",
                                "{templateUuid}",
                                "document"
                            ]
                        },
                        "description": "Returns the stored v2 editor document and its revision. A template with no draft returns a null document and revision 0. Read this before every write.\n\nGates: throttle:editor-document.\n\nNote: The read gate and the write gate name the same people. Every account in your company that can write the document can also read it."
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                },
                {
                    "name": "Apply editor operations",
                    "request": {
                        "method": "PATCH",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            },
                            {
                                "key": "Content-Type",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/templates/{templateUuid}/document",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "templates",
                                "{templateUuid}",
                                "document"
                            ]
                        },
                        "description": "Applies a closed list of layer operations and saves the result under the next revision. `set_layer_property` takes `layer_key`, `property` and `value`. `set_layer_type` takes `layer_key` and `type`. Every operation in one call applies together, or none of them applies.\n\nGates: throttle:editor-document.\n\nNote: A rejected operation returns a stable `code`, for example `editor_operation_layer_not_found` or `editor_operation_invalid_value`. Correct the operation and call again.\n\nNote: A malformed body returns the standard validation shape instead, with a message under `errors.revision` or `errors.operations`.\n\nNote: The route allows 30 calls a minute for one token and 180 a minute for one company.",
                        "body": {
                            "mode": "raw",
                            "raw": "{\n    \"revision\": 0,\n    \"operations\": []\n}",
                            "options": {
                                "raw": {
                                    "language": "json"
                                }
                            }
                        }
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                },
                {
                    "name": "Replace the editor document",
                    "request": {
                        "method": "PUT",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            },
                            {
                                "key": "Content-Type",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/templates/{templateUuid}/document",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "templates",
                                "{templateUuid}",
                                "document"
                            ]
                        },
                        "description": "Replaces the whole v2 editor document and saves it under the next revision. Send the document you read, with your change applied to it. Any layer or property you leave out is gone. Prefer `PATCH` unless you rebuild the document.\n\nGates: throttle:editor-document.\n\nNote: The document is bounded: 262144 bytes, 1000 nodes, depth 12, and 16384 characters for one string. A document over a limit returns `editor_document_too_large` or `editor_document_budget_exceeded` under `errors.document`.\n\nNote: The route allows 30 calls a minute for one token and 180 a minute for one company.",
                        "body": {
                            "mode": "raw",
                            "raw": "{\n    \"revision\": 0,\n    \"document\": {}\n}",
                            "options": {
                                "raw": {
                                    "language": "json"
                                }
                            }
                        }
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                },
                {
                    "name": "Inspect the editor document",
                    "request": {
                        "method": "GET",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/templates/{templateUuid}/document/preflight",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "templates",
                                "{templateUuid}",
                                "document",
                                "preflight"
                            ]
                        },
                        "description": "Reads the stored document and returns the known draft problems it carries, each with a code, a JSON pointer and a message. An empty `issues` list means the known checks pass. It does not guarantee that the render looks right.\n\nGates: throttle:editor-document.\n\nNote: Run it after the last write and before you publish the template."
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                }
            ]
        },
        {
            "name": "Media",
            "description": "Upload and list images stored in your account media library. Use these as image-layer sources in snaps.",
            "item": [
                {
                    "name": "List media",
                    "request": {
                        "method": "GET",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/media",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "media"
                            ],
                            "query": [
                                {
                                    "key": "page",
                                    "value": "",
                                    "description": "Page number for the standard paginator.",
                                    "disabled": true
                                }
                            ]
                        },
                        "description": "Returns your uploaded images, 12 per page, newest first."
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                },
                {
                    "name": "Upload media",
                    "request": {
                        "method": "POST",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            },
                            {
                                "key": "Content-Type",
                                "value": "multipart/form-data",
                                "disabled": true
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/media",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "media"
                            ]
                        },
                        "description": "Uploads an image into your media library. Send as multipart/form-data.",
                        "body": {
                            "mode": "formdata",
                            "formdata": [
                                {
                                    "key": "file",
                                    "type": "file",
                                    "value": "",
                                    "description": "The image to upload."
                                }
                            ]
                        }
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                }
            ]
        },
        {
            "name": "Screenshots",
            "description": "Render a web page to an image. Creating screenshots requires an active subscription or trial.",
            "item": [
                {
                    "name": "List screenshots",
                    "request": {
                        "method": "GET",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/screenshots",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "screenshots"
                            ],
                            "query": [
                                {
                                    "key": "cursor",
                                    "value": "",
                                    "description": "Cursor token from meta.next_cursor.",
                                    "disabled": true
                                }
                            ]
                        },
                        "description": "Returns a cursor-paginated list of your screenshots.\n\nGates: logApiRequest."
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                },
                {
                    "name": "Get a screenshot",
                    "request": {
                        "method": "GET",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/screenshots/{screenshotUuid}",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "screenshots",
                                "{screenshotUuid}"
                            ]
                        },
                        "description": "Returns a single screenshot.\n\nGates: logApiRequest."
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                },
                {
                    "name": "Create a screenshot",
                    "request": {
                        "method": "POST",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            },
                            {
                                "key": "Content-Type",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/screenshots",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "screenshots"
                            ]
                        },
                        "description": "Captures a web page. Defaults to a 1330x780 viewport when width/height are omitted.\n\nGates: logApiRequest, hasActiveSubscription.\n\nCredits: Requires available credits (canCreateSnap); returns 417 when exhausted.",
                        "body": {
                            "mode": "raw",
                            "raw": "{\n    \"url\": \"<url>\",\n    \"width\": 0,\n    \"height\": 0\n}",
                            "options": {
                                "raw": {
                                    "language": "json"
                                }
                            }
                        }
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                }
            ]
        },
        {
            "name": "Snaps",
            "description": "A snap renders a template (or every template in a collection) into a finished image or PDF, with your content substituted into each layer. Render synchronously for an instant result, or asynchronously with a webhook for bulk work. Creating snaps requires an active subscription or trial.",
            "item": [
                {
                    "name": "Create a snap",
                    "request": {
                        "method": "POST",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            },
                            {
                                "key": "Content-Type",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/snaps",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "snaps"
                            ]
                        },
                        "description": "Renders a snap from a single template (`template_id`) or every template in a collection (`collection_id`). Provide exactly one of the two.\n\nSynchronous (default): the response carries the finished `media_url` and returns 201.\n\nAsynchronous (`async: true`): the snap is queued, the response returns 202 immediately, and the result is delivered to `webhook_url` on completion.\n\nThe API always renders the template's **published** version. Unpublished draft edits are not visible to the API until the template is published.\n\nGates: logApiRequest, hasActiveSubscription.\n\nCredits: Synchronous: 1 credit per rendered template. Asynchronous: 0 credits at accept time (HTTP 202); the credit is charged when the queued snap reaches completed. A repeated `idempotency_key` returns the first snap and charges 0 credits.\n\nNote: Every response carries an `X-Request-Uuid` header. Quote it in support tickets.\n\nNote: A collection request returns an array of snap objects, one per template.\n\nNote: A response to a repeated `idempotency_key` carries an `X-Idempotent-Replay: true` header and charges 0 credits.\n\nNote: `webhook_url` must be a public address. A host that resolves to a private, loopback, link-local or reserved range is rejected with 422.\n\nNote: An `idempotency_key` is honored for 24 hours. After that window a retry is a new request and charges a new credit.",
                        "body": {
                            "mode": "raw",
                            "raw": "{\n    \"template_id\": \"<template_id>\",\n    \"collection_id\": \"<collection_id>\",\n    \"type\": \"<type>\",\n    \"format\": \"<format>\",\n    \"transparent\": false,\n    \"async\": false,\n    \"webhook_url\": \"<webhook_url>\",\n    \"variants\": [],\n    \"idempotency_key\": \"<idempotency_key>\"\n}",
                            "options": {
                                "raw": {
                                    "language": "json"
                                }
                            }
                        }
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([201, 202]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                }
            ]
        },
        {
            "name": "Snap batches",
            "description": "A batch renders up to 100 snaps from ONE template, with a different set of variants per item. The call is always asynchronous: it returns 202 with a batch id, and the items render in the background. Poll the batch to read progress and to collect the image URLs, and cancel it to stop the items that have not started. One webhook is posted when the batch finishes. Creating a batch requires an active subscription or trial. Reading and canceling one do not.",
            "item": [
                {
                    "name": "Create a batch of snaps",
                    "request": {
                        "method": "POST",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            },
                            {
                                "key": "Content-Type",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/snaps/batches",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "snaps",
                                "batches"
                            ]
                        },
                        "description": "Renders up to 100 snaps from one template. Every item carries its own `variants` and an optional `identifier` you use to recognize it in the result.\n\nThe response is always 202. Nothing is charged at accept time. Each item costs 1 credit when it renders.\n\n`type`, `format` and `transparent` apply to every item in the batch. An item that needs a different format belongs in a different batch.\n\nThe API always renders the template's **published** version.\n\nGates: logApiRequest, hasActiveSubscription.\n\nCredits: 0 credits at accept time (HTTP 202). Each item is charged 1 credit when it reaches completed. An item that fails costs nothing. A repeated `idempotency_key` returns the first batch and starts no second one.\n\nNote: The whole batch is checked against the credit balance before any item is created. A batch of 100 against 40 credits creates nothing, not 40 items.\n\nNote: The balance check is not a reservation. Two batches accepted a second apart read the same balance, so a caller can queue more items than the balance covers. Each item is still charged only when it renders.\n\nNote: Over 100 items returns 422 on `errors.items` and creates nothing. The request is never truncated in silence.\n\nNote: Exactly one webhook is posted, when the batch finishes. There is no per-item webhook on this endpoint.\n\nNote: `webhook_url` must be a public address. A host that resolves to a private, loopback, link-local or reserved range is rejected with 422.\n\nNote: A response to a repeated `idempotency_key` carries an `X-Idempotent-Replay: true` header.\n\nNote: Every response carries an `X-Request-Uuid` header. Quote it in support tickets.\n\nNote: A batch holds one of five statuses. `pending` and `processing` mean it is still running. The three terminal statuses are `completed`, `failed` and `canceled`, and a batch never leaves one. `completed` means the batch ran to the end and at least one item rendered, so read the `failed` count as well as the status. `failed` means zero items rendered. At every terminal status `completed + failed + canceled` equals `total_rows`.",
                        "body": {
                            "mode": "raw",
                            "raw": "{\n    \"template_id\": \"<template_id>\",\n    \"items\": [],\n    \"title\": \"<title>\",\n    \"webhook_url\": \"<webhook_url>\",\n    \"type\": \"<type>\",\n    \"format\": \"<format>\",\n    \"transparent\": false,\n    \"idempotency_key\": \"<idempotency_key>\"\n}",
                            "options": {
                                "raw": {
                                    "language": "json"
                                }
                            }
                        }
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([202]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                },
                {
                    "name": "Read a batch",
                    "request": {
                        "method": "GET",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/snaps/batches/{batchUuid}",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "snaps",
                                "batches",
                                "{batchUuid}"
                            ]
                        },
                        "description": "Returns the counts, the running credit total, and every item with its status and image URL. Poll this about every 5 seconds and stop when `status` is `completed`, `failed` or `canceled`.\n\nThis endpoint does not require an active subscription, so a customer whose plan lapsed can still collect work they already paid for.\n\nGates: logApiRequest.\n\nNote: A batch holds one of five statuses. `pending` and `processing` mean it is still running. The three terminal statuses are `completed`, `failed` and `canceled`, and a batch never leaves one. `completed` means the batch ran to the end and at least one item rendered, so read the `failed` count as well as the status. `failed` means zero items rendered. At every terminal status `completed + failed + canceled` equals `total_rows`.\n\nNote: `credits_charged` is read from the billing ledger, not counted from `completed`. It rises between polls.\n\nNote: `media_url` is set only on an item with status `completed`.\n\nNote: `last_error` on a failed item carries the render error as the renderer reported it. Treat it as a message for a person, never as a stable code to branch on.\n\nNote: A batch id that belongs to another account returns 404, the same as an id that does not exist."
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                },
                {
                    "name": "Cancel a batch",
                    "request": {
                        "method": "POST",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/snaps/batches/{batchUuid}/cancel",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "snaps",
                                "batches",
                                "{batchUuid}",
                                "cancel"
                            ]
                        },
                        "description": "Stops a batch that is still running.\n\nAn item that already rendered keeps its image and stays billed. An item that had not started is marked `canceled` and costs nothing. An item that is rendering at that moment can still finish and can still be charged.\n\nThis cannot be undone. A canceled batch cannot be resumed. Start a new batch for the items you still want.\n\nLike the read endpoint, this does not require an active subscription: stopping work only lowers the bill.\n\nGates: logApiRequest.\n\nCredits: Nothing is charged by this call. Items that already rendered keep the credit they cost. Items that never started cost nothing.\n\nNote: Canceling twice is safe. A batch that already holds a terminal status is returned unchanged.\n\nNote: One webhook is posted, carrying `event: snap-import.canceled`.\n\nNote: An item that is rendering when the cancel lands can still complete and can still be charged. The counts in the response are the truth at that moment.\n\nNote: A batch id that belongs to another account returns 404, the same as an id that does not exist."
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                }
            ]
        },
        {
            "name": "Preview",
            "description": "Preview renders a template (optionally with variants) into a WATERMARKED, self-contained HTML document without creating a snap and without charging a credit. The response is the rendered HTML \u2014 nothing is rasterized and nothing is persisted. Use it to iterate, then call POST /v1/snaps to produce the final, un-watermarked, billed snap image with the same variants. Available to trial users (no active subscription required). Rate-limited separately from the rest of the API.",
            "item": [
                {
                    "name": "Preview a template",
                    "request": {
                        "method": "GET",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/templates/{templateUuid}/preview",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "templates",
                                "{templateUuid}",
                                "preview"
                            ],
                            "query": [
                                {
                                    "key": "variants",
                                    "value": "",
                                    "description": "Per-layer overrides, e.g. variants[0][layer]=headline&variants[0][text]=Hello. Each item targets a layer key with one of text, image_url (public URL), background_color, qr_content, barcode_content, or hidden.",
                                    "disabled": true
                                }
                            ]
                        },
                        "description": "Renders a free, watermarked preview of a template using its default layer content, or with `variants` applied. Returns a self-contained HTML document (text/html).\n\nGates: throttle:preview.\n\nNote: The preview is watermarked HTML, not a usable final asset.\n\nNote: No credit is charged and no snap is stored."
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                },
                {
                    "name": "Preview a snap",
                    "request": {
                        "method": "GET",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/snaps/preview",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "snaps",
                                "preview"
                            ],
                            "query": [
                                {
                                    "key": "template_id",
                                    "value": "",
                                    "description": "UUID of the template to render.",
                                    "disabled": false
                                },
                                {
                                    "key": "variants",
                                    "value": "",
                                    "description": "Per-layer overrides, e.g. variants[0][layer]=headline&variants[0][text]=Hello. Each item targets a layer key with one of text, image_url (public URL), background_color, qr_content, barcode_content, or hidden.",
                                    "disabled": true
                                }
                            ]
                        },
                        "description": "Renders a free, watermarked preview of the snap you intend to create \u2014 a template (`template_id`) plus `variants`. Returns a self-contained HTML document (text/html). Pass the same template_id and variants to POST /v1/snaps to create the final billed snap.\n\nGates: throttle:preview.\n\nNote: The preview is watermarked HTML, not a usable final asset.\n\nNote: No credit is charged and no snap is stored."
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                }
            ]
        },
        {
            "name": "Tags",
            "description": "Tags organise templates. Create them, search them, and attach them to templates. All tags are scoped to your company.",
            "item": [
                {
                    "name": "List tags",
                    "request": {
                        "method": "GET",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/tags",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "tags"
                            ],
                            "query": [
                                {
                                    "key": "search",
                                    "value": "",
                                    "description": "Case-insensitive substring match on tag name.",
                                    "disabled": true
                                }
                            ]
                        },
                        "description": "Returns up to 15 tags, ordered by name, optionally filtered by a search term.\n\nGates: logApiRequest."
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                },
                {
                    "name": "Create a tag",
                    "request": {
                        "method": "POST",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            },
                            {
                                "key": "Content-Type",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/tags",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "tags"
                            ]
                        },
                        "description": "Creates a tag. The slug is generated from the name; collisions get a numeric suffix.\n\nGates: logApiRequest.",
                        "body": {
                            "mode": "raw",
                            "raw": "{\n    \"name\": \"<name>\"\n}",
                            "options": {
                                "raw": {
                                    "language": "json"
                                }
                            }
                        }
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([201]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                },
                {
                    "name": "Sync template tags",
                    "request": {
                        "method": "POST",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            },
                            {
                                "key": "Content-Type",
                                "value": "application/json"
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/templates/{templateUuid}/tags",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "templates",
                                "{templateUuid}",
                                "tags"
                            ]
                        },
                        "description": "Replaces all tags on a template with the supplied set. Send an empty array to clear every tag.\n\nGates: logApiRequest.",
                        "body": {
                            "mode": "raw",
                            "raw": "{\n    \"tag_ids\": []\n}",
                            "options": {
                                "raw": {
                                    "language": "json"
                                }
                            }
                        }
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([200]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                }
            ]
        },
        {
            "name": "Embedded Forms",
            "description": "Embedded forms render snaps from a signed URL \u2014 no API token. The URL must be a Laravel signed URL; an invalid signature returns 404. The form owner is charged for the render.",
            "item": [
                {
                    "name": "Submit an embedded form",
                    "request": {
                        "method": "POST",
                        "header": [
                            {
                                "key": "Accept",
                                "value": "application/json"
                            },
                            {
                                "key": "Content-Type",
                                "value": "multipart/form-data",
                                "disabled": true
                            }
                        ],
                        "url": {
                            "raw": "{{base_url}}/v1/embedded-forms/{formUuid}",
                            "host": [
                                "{{base_url}}"
                            ],
                            "path": [
                                "v1",
                                "embedded-forms",
                                "{formUuid}"
                            ],
                            "query": [
                                {
                                    "key": "signature",
                                    "value": "",
                                    "description": "Laravel URL signature. The whole URL must be signed.",
                                    "disabled": false
                                }
                            ]
                        },
                        "description": "Renders a snap from a configured form. Template forms return one snap; collection forms return an array of snaps.\n\nLayer 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.\n\nGates: embeddedFormMiddleware, valid signature required.\n\nCredits: The form owner is charged: 1 credit for a template form, or 1 per template for a collection form.\n\nNote: Collection forms return a bare array of snap objects, not a `data`-wrapped object.\n\nNote: This route has no rate limiting.",
                        "body": {
                            "mode": "formdata",
                            "formdata": [
                                {
                                    "key": "layers",
                                    "type": "text",
                                    "value": "",
                                    "description": "Layer overrides. Value keys by layer type: image -> image_url (file), text -> text, empty -> background_color, qr_code -> qr_content, barcode -> barcode_content."
                                }
                            ]
                        }
                    },
                    "event": [
                        {
                            "listen": "test",
                            "script": {
                                "type": "text/javascript",
                                "exec": [
                                    "pm.test('Successful response', function () {",
                                    "  pm.expect([201]).to.include(pm.response.code);",
                                    "});"
                                ]
                            }
                        }
                    ],
                    "response": []
                }
            ]
        }
    ],
    "auth": {
        "type": "bearer",
        "bearer": [
            {
                "key": "token",
                "value": "{{token}}",
                "type": "string"
            }
        ]
    },
    "variable": [
        {
            "key": "base_url",
            "value": "https://snapsbrew.com/api",
            "type": "string"
        },
        {
            "key": "token",
            "value": "YOUR_API_TOKEN",
            "type": "string"
        }
    ]
}