{
    "openapi": "3.1.0",
    "info": {
        "title": "Lokasign API",
        "version": "1.3.0",
        "description": "# Lokasign API\n\nLokasign is an e-signature platform. Through this API a client application sends documents for\nsignature, follows their progress through signed webhooks, and fetches the executed, sealed\nPDFs \u2014 without any of its users needing a Lokasign account. Signers receive an emailed\ninvitation or sign inside the client's own page; the client only ever talks to this API.\n\nThis document is the complete contract: every endpoint with its request and response schemas,\nexamples and error codes (under *paths*), every outgoing event (under *webhooks*), the error\ncatalogue (`ErrorCode`), and this guide. It is generated from the code that serves the API, so\nit cannot lag behind it. The same document is served as JSON at `/docs/api.json` and indexed\nfor language models at `/llms.txt`.\n\n**New here?** Three guides in Indonesian walk through an integration end to end:\n`/docs/quickstart` (from sign-up to a first executed agreement, including webhooks and\narchiving), `/docs/signing` (email, embedded in a web page, embedded in a mobile app), and\n`/docs/templates` (turning a Word contract into a template, with two tested samples). For an AI\nassistant, attach `/docs/LOKASIGN.md` to the chat; `/llms-full.txt` carries every guide in one\nfile.\n\n**For AI agents**: the same operations are available as MCP tools at `POST /mcp` (Streamable\nHTTP), one tool per `operationId`, authenticated with the same API key\n(`Authorization: Bearer \u2026`). Each tool carries this document's description and input schema, and\ncalling it runs the documented route \u2014 so everything below applies unchanged. The whole tool\ncatalogue is served in one `tools/list`; still follow `nextCursor` when it appears, so your\nclient keeps working if the catalogue ever outgrows a page. Client setup is at `/docs/mcp`.\n\n**Base URL**: `https://<host>/api/v1`. The current version is v1; breaking changes will ship\nunder a new prefix and this version will keep working for the announced period.\n\n## 1. Who calls this API\n\nTwo layers matter to a caller:\n\n- A **tenant** is an organisation with a Lokasign dashboard \u2014 the people who author templates,\n  configure integrations and see every request in their account.\n- An **application** is one client system of that tenant (for example your backend). Each\n  application has its own API keys, its own webhook endpoint and secret, its own allowed\n  origins for embedded signing, and its own `external_ref` namespace. Everything the API\n  returns is confined to the application the key belongs to; another application's data does\n  not exist as far as your key is concerned.\n\nSigners deliberately have no accounts. They are identified by the email the invitation goes to\nand, when you ask for it, by a one-time code sent to that address.\n\n## 2. Authentication\n\nEvery request carries an API key:\n\n```\nAuthorization: Bearer esk_live_\u2026\n```\n\nor, for clients that keep `Authorization` for something else (Claude's custom connectors reserve\nit for OAuth), the same key as `X-Api-Key: esk_live_\u2026`. The bearer token wins when both are sent.\n\nKeys are issued per application from the dashboard at **/api-settings**, each either **live**\n(`esk_live_\u2026`) or **test** (`esk_test_\u2026` \u2014 see *Test mode* below). The secret is shown once at\ncreation; only its prefix (16 characters; 12 for keys issued before modes existed) stays visible\nafterwards, for identification.\nKeys can be revoked and rotated there at any time, and a revoked key is indistinguishable from a\nwrong one (`401 unauthorized`). A key whose application has been deactivated by the platform\noperator answers `403 application_inactive`.\n\nThere is no per-key permission scope yet: a key can do everything its application can.\n\n**Isolation.** A `gid` that belongs to another application answers `404 not_found`, never 403 \u2014\nthe API does not disclose that a resource exists elsewhere. The same holds between modes: a live\nkey does not see test data, and a test key does not see live data.\n\n### Test mode\n\nA test key calls the same API \u2014 endpoints, payloads, validation, statuses and webhooks are\nidentical, so an integration built against one needs nothing changed but the key. What differs\nis that nothing it creates reaches the world:\n\n| | Live key | Test key |\n|---|---|---|\n| Requests and documents | live data | test data (`\"test\": true`), invisible to live keys and kept out of the dashboard's Documents list unless its test filter is on |\n| `external_ref` | unique among live requests | unique among test requests \u2014 production's own references can be rehearsed |\n| Email (invitations, one-time codes, reminders, notices, executed copies) | delivered | **never sent**; kept 30 days in the test outbox, read with `GET /test-mail` (codes and links extracted) |\n| Executed documents | sealed with the platform certificate | a **SPECIMEN** watermark on every page, **no platform seal**; still downloadable, and `sealed_hash` still describes the served file |\n| Webhooks | delivered with `\"test\": false` | delivered with `\"test\": true` |\n| Signing | by the signer | by the signer through the outbox link, or simulated with `POST /signature-requests/{gid}/signers/{signerGid}/simulate` |\n\nUse a test key for development, CI, and **any AI agent** you connect over MCP: it can explore and\nrehearse freely without inviting a real person or producing a binding document. Test keys exist in\nproduction too, so an integration can be checked there before its first real request.\n`GET /test-mail` and `\u2026/simulate` answer `403 test_mode_only` to a live key.\n\n## 3. Conventions\n\n### Identifiers and time\n\n- Every public identifier is a `gid`: a UUIDv7 string. Internal numeric ids never appear.\n- Every timestamp is ISO-8601 with a UTC offset (`2026-09-17T09:00:12+07:00`), in responses and\n  in webhooks alike. Dates you send (`created_from`, merge values declared as dates) may be\n  ISO-8601 or `YYYY-MM-DD`.\n\n### Envelope and pagination\n\nA single resource is wrapped in `data`:\n\n```json\n{ \"data\": { \"gid\": \"0199\u2026\", \"status\": \"draft\", \"\u2026\": \"\u2026\" } }\n```\n\nA list is wrapped in `data` with `links` and `meta` alongside \u2014 offset pagination, 25 rows per\npage unless `per_page` (1\u2013100) says otherwise, `page` to move:\n\n```json\n{ \"data\": [ \u2026 ], \"links\": { \"next\": \"\u2026?page=2\", \"\u2026\": \"\u2026\" }, \"meta\": { \"current_page\": 1, \"per_page\": 25, \"total\": 143, \"\u2026\": \"\u2026\" } }\n```\n\n### Request headers\n\n| Header | Applies to | Behaviour |\n|---|---|---|\n| `Authorization` | everything | `Bearer <api_key>`. Required, unless the key is sent as `X-Api-Key`. |\n| `X-Api-Key` | everything | The API key itself, without `Bearer`. Read only when there is no bearer token. |\n| `Content-Type` | every POST | `application/json`, except `POST /documents` which also accepts `multipart/form-data`. |\n| `Idempotency-Key` | POST endpoints that create something (`/signature-requests`, `/documents`, `/document-uploads`, `/signing-sessions`) | Optional but strongly recommended. Any unique string (a UUID). The first response is stored for 24 hours; the same key with the same body returns it verbatim with `Idempotent-Replay: true`, without doing the work again. The same key with a different body answers `409 idempotency_key_reused`. Uploaded files are compared by content hash. |\n| `Accept-Language` | everything | `id` (default) or `en`. Affects only `error.message` and, where relevant, the language of emails the call triggers. `error.code` and event names are never translated. |\n\n### Response headers\n\n| Header | Meaning |\n|---|---|\n| `X-Request-Id` | UUIDv7 minted for every request, successful or not; the same value appears in `error.request_id`. Quote it when contacting support. |\n| `Idempotent-Replay` | `true` when the response is a stored replay rather than fresh work. |\n| `Retry-After` | With `429`: seconds to wait. |\n\n### Rate limit\n\n120 requests per minute per API key. Beyond that the API answers `429 rate_limited` with\n`Retry-After`. Manual reminders have their own, separate limit (one per signer per 24 hours).\n`GET /application` reports the limits in force, so read them from there rather than hard-coding\nthe numbers.\n\n### Errors\n\nEvery error, whatever the status, has one shape:\n\n```json\n{\n  \"error\": {\n    \"code\": \"validation_failed\",\n    \"message\": \"Nilai wajib belum diisi untuk tag: signer1.party_tax_id.\",\n    \"field\": \"documents.0.merge_fields\",\n    \"request_id\": \"0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d\"\n  }\n}\n```\n\n- `code` is stable and untranslated \u2014 branch on it. The full list, with what to do about each,\n  is the `ErrorCode` schema; each operation lists the codes it can answer.\n- `message` is for whoever reads your logs and follows `Accept-Language`. Its wording may\n  change without notice.\n- `field` names the first invalid input as a dotted path when the error is about one\n  (`documents.0.template_code`, `signers.1.email`); null otherwise. Only the first failure is\n  reported \u2014 fix it and resend.\n- Unknown failures collapse to `500 server_error` without internal details; retry with backoff.\n\n## 4. Concepts\n\n### Signature request lifecycle\n\n```\n                 send / send_when_ready          first signature          last signature + seal\n   draft  \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u25ba  sent  \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u25ba  partially_signed  \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u25ba  completed\n     \u2502                                    \u2502                              \u2502\n     \u2502 void                               \u2502 void \u00b7 decline \u00b7 expiry      \u2502 void \u00b7 decline \u00b7 expiry\n     \u25bc                                    \u25bc                              \u25bc\n   voided                          declined / expired / voided    declined / expired / voided\n```\n\n- **draft** \u2014 created, nobody invited. Template documents may still be rendering\n  (`documents_pending` > 0). Reviewable through `GET /signature-requests/{gid}/documents`.\n- **sent** \u2014 invitations dispatched; nobody has signed. In a *sequential* request only the\n  first signer has been invited; the next one is invited when the previous one signs.\n- **partially_signed** \u2014 some signed, not all.\n- **completed** \u2014 everyone signed. The executed documents are composed, hashed, sealed with the\n  platform's PAdES signature and timestamp, and then \u2014 only then \u2014 the\n  `signature_request.completed` webhook fires and `GET /signature-requests/{gid}/document`\n  answers. Terminal.\n- **declined** \u2014 one signer refused; that ends the whole request. Terminal.\n- **expired** \u2014 the deadline (`expires_in_days` at creation, 1\u201390 days, or your organisation's\n  default when sent) passed. Checked hourly. Terminal.\n- **voided** \u2014 withdrawn by you or from the dashboard. Terminal.\n\nTerminal states never change again. The server is the only source of truth for the status: a\nbrowser landing on `redirect_url` says nothing.\n\n### external_ref\n\nYour own identifier for a request \u2014 a contract id, an order number. It is unique per\napplication, echoed at the top level of every webhook, and searchable through\n`GET /signature-requests?external_ref=`. A reference is *reserved* while its request is live or\ncompleted and *released* when the request is voided, declined or expired, so the corrected\nsecond attempt can carry the same reference. Sending a reserved reference answers\n`422 external_ref_taken`: look the existing request up instead of creating a twin.\n\n`Idempotency-Key` and `external_ref` solve different problems. The header protects one HTTP\ncall against network retries for 24 hours; the reference protects your business process\nagainst a job that runs twice, days apart.\n\n### Signers\n\nEach signer has a `name`, an `email`, a position (`order_index`), an optional human-readable\n`role_label`, an optional machine `role_key` (required when a template declares roles), a\n`delivery`, and a `verification_method`.\n\n`delivery` decides who brings the signer to the signing page:\n\n- `email` (default) \u2014 the platform emails the invitation and the reminders;\n- `embedded` \u2014 your application does, through `POST /signing-sessions`. No invitation or\n  reminder is emailed, because an emailed link would stop working the moment the embedded\n  session opens. One-time codes and the executed copy are still emailed.\n\n`verification_method` decides what the signer must prove before the document opens:\n\n- `none` \u2014 possession of the emailed link is enough;\n- `otp` \u2014 a one-time code is emailed and must be entered before the document opens;\n- `email_link` \u2014 the signer re-confirms through a second emailed link.\n\nPer signer you get `status` (`pending`, `viewed`, `signed`, `declined`, `expired`) and, for\nsequential requests, `waiting_turn`: true while an earlier signer has not finished, i.e. this\nsigner has not been asked yet. A signer who has not acted can still be corrected \u2014 see\n`PATCH /signature-requests/{gid}/signers/{signerGid}` \u2014 but their `role_key`, `delivery` and\n`verification_method` are fixed once the request is created. Signers see the request `title`, your `message`, and the\ndocuments; every signature is recorded together with the signer's consent, IP address and the\ndocument hash they saw.\n\n### Documents\n\nA request carries one or more PDFs, in signing order. Each `documents[]` entry supplies its\ndocument in exactly one of three ways:\n\n| Entry | When to use it |\n|---|---|\n| `{ \"document_url\": \"https://\u2026\" }` | You already have the PDF at a public HTTPS URL. The platform fetches and stores it now (\u2264 25 MB, not password-protected, private addresses refused). |\n| `{ \"document_gid\": \"0199\u2026\" }` | You uploaded the PDF earlier through `POST /documents` and want to reuse it. |\n| `{ \"template_code\": \"\u2026\", \"merge_fields\": {\u2026}, \"merge_rows\": {\u2026} }` | You want the platform to render the document from one of your templates. The only way to send *data* instead of a file. |\n\nEvery PDF is inspected on intake \u2014 not a PDF, encrypted, too large, or carrying active content\nthat cannot be removed \u2192 `422` with a `document_*` code. Uploaded documents are reusable across\nrequests; documents rendered from templates are stored too and appear in `GET /documents`.\n\n**No public URL and no multipart?** `POST /document-uploads` returns an `upload_url` that takes\none PDF for your application within 15 minutes, with no API key \u2014 the URL is the credential.\nOpen it in a browser for a page to pick the file, or send the bytes:\n`PUT <upload_url>` with `Content-Type: application/pdf` (or `POST` a multipart `file`). Then\n`GET /document-uploads/{gid}` reports `completed` with the stored `document`, whose `gid` is a\n`document_gid` like any other. A refused file leaves the link open; a used, expired or closed\nlink answers `upload_link_used`, `upload_link_expired` or `upload_link_invalid`. This is the\npath for an AI agent acting for someone who has the file. Set `uploaded_by: \"agent\"` when the\nagent will send the file itself, `person` (the default) when a person will open the link.\n\n### Templates\n\nA template is a reusable agreement authored in the dashboard: either an uploaded PDF on which\nfields were placed, or an editable document \u2014 written in the editor or imported from `.docx` \u2014\nwhose text carries **tags**. A template declares:\n\n- **roles** \u2014 the parties that sign it (`party`, `operator`, \u2026). Each `documents[]` entry\n  backed by a template needs a signer with a matching `role_key` for every role, or the request\n  is refused.\n- **merge tags** \u2014 the placeholders in the text, addressed by name in `merge_fields`\n  (`signer1.party_name`, `agreement.number`). A tag may be *required*, may carry a stored\n  *default* (boilerplate that lives in the template, not in your code \u2014 a value you send always\n  wins), and may declare a *format* the value must satisfy (a date, a number that is spelled\n  out, \u2026). A required tag with neither a value nor a default is refused *before* anything is\n  queued.\n- **collections** \u2014 repeating table rows (a song list, a class attendance sheet, a schedule of\n  assets). You send them in each `documents[]` entry's `merge_rows`, keyed by collection name, one\n  row per entry; the template's row is cloned per entry and removed when the array is empty. The\n  collection name is the tag prefix the template author chose (`sessions` for\n  `{{data|name:sessions.DATE}}`) \u2014 nothing is reserved, and `GET /templates/{code}` lists each one\n  with its columns. A column may declare a *format* like any tag, and an unreadable row value is\n  refused before anything is queued; a column left out prints an empty cell.\n- **field placement** \u2014 where each role signs. The template places its own fields, so\n  `fields[]` must not point at a template-backed document.\n- **editions** \u2014 a template may exist in more than one language; the request's `locale` picks\n  the edition, falling back to Indonesian.\n\nTemplates are scoped to your application and identified by `code`. Rendering happens on a\nqueue: a template-backed request is created as `draft` with `documents_pending` greater than\nzero, its `documents` fill in as rendering finishes, and `send_when_ready: true` sends it the\nmoment the last one is done.\n\nFour endpoints make this workable without opening the dashboard:\n\n| Call | What it answers |\n|---|---|\n| `GET /templates` | Which templates exist, which are active, and what roles each needs. |\n| `GET /templates/{code}` | The full contract: documents, roles, every merge tag with `required`, `default_value` and `formats`, the collections and their columns, the prefill keys, and whether the template passes its activation checks. |\n| `POST /templates/{code}/check` | A dry run of your `merge_fields`, `merge_rows` and signer role keys. Nothing is created; every finding is reported at once as lists, so one round of fixes is enough \u2014 including row values a column's format cannot read (`unreadable_row_values`) and collection or column keys the template does not print (`unknown_collections`, `unknown_columns`). |\n| `POST /templates/{code}/activate` \u00b7 `/deactivate` | The switch that makes an authored template usable, or takes it out of use. Activation is gated on the same checks the dashboard's review screen shows and refuses with `409 template_not_activatable` while any of them blocks. |\n\nOnly an *active* template can be used in a request. Activation is a review step, meant to be\ncalled once a person has read the template \u2014 not from an unattended pipeline. Deactivating\nnever deletes anything, and requests already created from a template are unaffected.\n\n### Fields\n\nFor documents you supply as a file (`document_url` / `document_gid`), `fields[]` says what is\ndrawn where. Each field names a document (`document_index`), usually a signer\n(`signer_index`), and a `type`:\n\n- **signature group** \u2014 `signature`, `initials`: the signer draws, types or uploads; submitted\n  with consent.\n- **auto-filled** \u2014 `date_signed`, `full_name`, `email_address`, `company`, `title`: filled by\n  the platform from the signer's record at signing.\n- **form inputs** \u2014 `textbox`, `checkbox`, `dropdown`, `radio_group` (the last two read\n  `options`).\n- **placement** \u2014 `materai`: reserves the area an e-Meterai will be affixed to. Belongs to the\n  document, not to a signer; never required.\n\nA field is positioned either by coordinates \u2014 `page_number` plus `x`, `y`, `width`, `height`\nas fractions of the page (0\u20131, origin top-left) \u2014 or by an `anchor`, resolved when the request is\ncreated against the first occurrence of `anchor.text` (pages in order). The box is centred\nhorizontally on that text. Without `offset_y` it is centred in the gap under the text, at the\ntype's usual height or less, so a signature block such as\n\n```\nPihak Pertama,          \u2190 anchor.text\n   [ signature ]        \u2190 the box lands here\nJohn Smith\n```\n\nneeds nothing but the line above the signature. With `offset_y` the box's top sits that many\npoints below the top of the text instead; `offset_x` shifts it sideways. Text that does not occur\nrefuses the request with `422 anchor_not_found` \u2014 scanned PDFs have no text layer, so place\ntheir fields by coordinates. Every signer needs at least one signature-group field somewhere,\nor `/send` is refused.\n\n### Webhooks\n\nConfigure one endpoint per application \u2014 from the dashboard at **/api-settings**, or over the\nAPI with `PUT /webhook`, which is what lets a deployment stand its own integration up:\n\n| Call | What it does |\n|---|---|\n| `GET /webhook` | Where events go now, what is subscribed, and every event name you may subscribe to. |\n| `PUT /webhook` | Sets the URL, the complete event list and whether delivery is on. The call that *creates* the endpoint returns its signing secret \u2014 the only time it is readable. `url: null` stops delivery without forgetting the endpoint. |\n| `POST /webhook/rotate-secret` | A new signing secret, returned once. It breaks your receiver until you deploy the new value; there is no overlap. |\n| `POST /webhook/ping` | A `webhook.ping` delivery down the real path \u2014 same job, same signature, same retries \u2014 to prove your receiver verifies and answers. It ignores `subscribed_events` and names no signature request. |\n| `GET /webhook-deliveries` | What was sent, with the exact body and what your server answered. Filter `status=failed` after an outage. |\n| `POST /webhook-deliveries/{delivery_id}/retry` | One more attempt under the same `X-Delivery-Id`, so your deduplication treats it as the retry it is. |\n\nThe platform POSTs a JSON body for each subscribed event; the events and their payloads are\ndocumented under *webhooks* in this document. Rules that keep a receiver correct:\n\n1. **Verify the signature.** `X-Signature: t=<unix>,v1=<hex>`; recompute\n   `HMAC-SHA256(secret, \"{t}.{raw body}\")` over the raw bytes \u2014 not a re-serialised parse \u2014\n   compare in constant time, and reject when `t` is more than 5 minutes from now.\n2. **Acknowledge fast.** Any 2xx within 10 seconds; queue the real work.\n3. **Deduplicate.** `X-Delivery-Id` is identical across retries of one event; process each id\n   once and acknowledge repeats.\n4. **Order by `occurred_at`**, not by arrival: deliveries can arrive out of order.\n5. **Correlate on `external_ref`** (top level) or `signature_request_gid`.\n\nFailed attempts are retried after 1 minute, 5 minutes, 30 minutes, 2 hours and 12 hours, then\nmarked failed; a failed delivery can be replayed from the dashboard or with\n`POST /webhook-deliveries/{delivery_id}/retry`. The `signature_request.completed` payload\ndeliberately carries no download URL \u2014 mint one with your API key when you receive it.\n\n### Executed documents\n\nWhen the last signer signs, the platform composes each document with a certificate of\ncompletion, hashes it (`final_hash`, lowercase hex SHA-256), and applies its own PAdES seal\nwith a trusted timestamp, so the PDF verifies on its own in any reader. Only sealed documents\nare distributed: `GET /signature-requests/{gid}/document` answers with 72-hour signed links,\none per document, and can be called again whenever a fresh link is needed. Store the file and\nits hash; never the URL.\n\nTwo digests come back, taken either side of the seal, and only one of them describes the file\nyou receive:\n\n| | What it is | Use it for |\n|---|---|---|\n| `sealed_hash` | SHA-256 of the sealed PDF the link serves | checking the download you just made |\n| `final_hash` | SHA-256 of the composed document, before the seal | the audit record, and Verify Document for a file held from that side |\n\nThe seal is written into the PDF after `final_hash` is taken, so the two never agree \u2014 check a\ndownload against `sealed_hash`.\n\n### Embedded signing\n\nInstead of the emailed link, a signer can sign inside your own web page or mobile app:\n\n1. Your backend calls `POST /signing-sessions` for one signer of a `sent` request.\n   - **Web page:** name the `embedder_origin` of the page that will frame it (it must be on your\n     key's `allowed_origins`); the browser refuses to frame the URL anywhere else.\n   - **Mobile app:** omit `embedder_origin` (the page then refuses every frame) and pass a\n     `return_url` in your app's own scheme, such as `myapp://signing-done`.\n2. Your front end opens the returned `signing_url` in the iframe or the WebView. It is valid for\n   5 minutes and for one opening.\n3. When the signer finishes, the page reports\n   `{ \"source\": \"lokasign\", \"type\": \"esign:completed\" | \"esign:declined\", \"requestId\": \"\u2026\", \"exchangeCode\": \"\u2026\" }`:\n   to the framing page by `postMessage` (addressed to `embedder_origin`), or \u2014 top-level in a\n   WebView \u2014 to any bridge the app installed (`LokasignBridge`, `webkit.messageHandlers.lokasign`,\n   `ReactNativeWebView`, a `flutter_inappwebview` handler named `lokasign`). With a `return_url`\n   it then navigates there, adding `lokasign_event`, `request_id` and `exchange_code` to the\n   query string, which the app intercepts to close the WebView.\n4. Your backend redeems the exchange code through `POST /signing-sessions/exchange` (single use,\n   5 minutes) and gets the verified outcome. Act on that response or on webhooks \u2014 never on the\n   message or the navigation alone, which a browser could forge.\n\nOpening an embedded session rotates the signer's emailed link, so create the signers you bring\nto the page yourself with `delivery: \"embedded\"`: they then receive no invitation and no\nreminder.\n\n**A signer talking to an AI agent.** The agent creates that signer with `delivery: \"embedded\"`\nand a session **without** `embedder_origin`, and the person opens `signing_url` in their own\nbrowser \u2014 through the agent's interactive box where the client shows one (see `/docs/mcp`), or\nas a link. The URL still works once and for 5 minutes, so it is minted right before it is shown.\nTo ask such a signer for a one-time code first, give them `verification_method: \"otp\"` (or set\nit as your organisation's signing default). In a sequential request nobody emails an embedded signer when their turn comes \u2014\nthe `signer.signed` webhook of the signer before them is your cue.\n\n## 5. Recipes\n\n### A. Send an agreement rendered from a template\n\nStart with `GET /application` to confirm the key and read the limits, then `GET /templates` to\nfind the code and `GET /templates/{code}` to learn what it expects. Build the payload,\n`POST /templates/{code}/check` it until `ready` is true, and only then:\n\n```\nPOST /signature-requests            Idempotency-Key: <uuid>\n{\n  \"title\": \"Perjanjian Kerjasama \u2014 PT Musik Nusantara\",\n  \"external_ref\": \"company:0198f1a2-\u2026\",\n  \"sequential\": true,\n  \"send_when_ready\": true,\n  \"documents\": [{\n    \"template_code\": \"MEMBER_LABEL\",\n    \"merge_fields\": { \"signer1.party_name\": \"PT Musik Nusantara\", \"signer1.deed_date\": \"2019-03-14\" },\n    \"merge_rows\": { \"songs\": [ { \"NO\": \"1\", \"TITLE\": \"Senja di Jakarta\", \"ISWC\": \"T-123.456.789-0\" } ] }\n  }],\n  \"signers\": [\n    { \"name\": \"Rina Kartika\", \"email\": \"rina@musik-nusantara.example\", \"role_key\": \"party\", \"order_index\": 1, \"verification_method\": \"otp\" },\n    { \"name\": \"Legal Operator\", \"email\": \"legal@operator.example\", \"role_key\": \"operator\", \"order_index\": 2 }\n  ]\n}\n```\n\n\u2192 `201` with `status: \"draft\"`, `documents_pending: 1`. Rendering finishes on the queue; the\nrequest is sent automatically; you receive `signature_request.sent`, then `signer.signed` per\nparty, then `signature_request.completed`.\n\nTo review before sending, omit `send_when_ready`, poll `GET /signature-requests/{gid}` until\n`documents_pending` is 0, read the PDFs through `GET /signature-requests/{gid}/documents`, and\nthen call `POST /signature-requests/{gid}/send`.\n\n### B. Send a PDF you already have and place the signatures yourself\n\n```\nPOST /documents                     multipart: file=<agreement.pdf>      \u2192 { \"data\": { \"gid\": \"D\" } }\nPOST /signature-requests\n{\n  \"title\": \"NDA \u2014 Studio Sinar\",\n  \"documents\": [ { \"document_gid\": \"D\" } ],\n  \"signers\": [ { \"name\": \"Budi\", \"email\": \"budi@example.com\" } ],\n  \"fields\": [\n    { \"document_index\": 0, \"signer_index\": 0, \"type\": \"signature\", \"page_number\": 3, \"x\": 0.12, \"y\": 0.72, \"width\": 0.25, \"height\": 0.08 },\n    { \"document_index\": 0, \"signer_index\": 0, \"type\": \"signature\", \"anchor\": { \"text\": \"Pihak Pertama,\" } },\n    { \"document_index\": 0, \"signer_index\": 0, \"type\": \"date_signed\", \"anchor\": { \"text\": \"Tanggal:\", \"offset_x\": 60, \"offset_y\": 0 } }\n  ]\n}\nPOST /signature-requests/{gid}/send\n```\n\nOr skip the upload and pass `{ \"document_url\": \"https://\u2026/agreement.pdf\" }` directly \u2014 or, when\nthe file is with a person or an agent and not on a server, take it through an upload link:\n\n```\nPOST /document-uploads   { \"uploaded_by\": \"person\" }       \u2192 { \"data\": { \"gid\": \"U\", \"upload_url\": \"https://\u2026/upload/\u2026\" } }\n(the person opens upload_url, or:  PUT upload_url  Content-Type: application/pdf  <bytes>)\nGET  /document-uploads/U                                    \u2192 { \"data\": { \"status\": \"completed\", \"document\": { \"gid\": \"D\" } } }\n```\n\n### C. Let a signer sign inside your own page or app\n\nCreate the signer with `\"delivery\": \"embedded\"`, then see *Embedded signing* above:\n`POST /signing-sessions` \u2192 open `signing_url` in an iframe or WebView \u2192 receive the message or\nthe `return_url` navigation \u2192 `POST /signing-sessions/exchange`. `/docs/signing` has complete\nweb and Flutter examples.\n\n### D. Receive the outcome and archive the executed documents\n\nOn `signature_request.completed` (verified, deduplicated): call\n`GET /signature-requests/{gid}/document`, download each `download_url`, check the file's\nSHA-256 against `sealed_hash` \u2014 not `final_hash`, which is the digest of the same document\nbefore the seal \u2014 and store the file. Optionally fetch\n`GET /signature-requests/{gid}/audit-trail` and keep it beside the document as evidence.\n\n### E. Nudge, withdraw, recover\n\n- Signer silent: `POST /signature-requests/{gid}/remind` (once per signer per 24 hours).\n- **Wrong address**: `PATCH /signature-requests/{gid}/signers/{signerGid}` with the corrected\n  `email`. The link already in the wrong inbox stops working, a fresh invitation goes to the new\n  address, and everybody else's signatures are untouched. Only for a signer who has not acted \u2014\n  and nothing is sent to a sequential signer whose turn has not come, which `invitation_resent`\n  tells you.\n- Wrong data or wrong document: `POST /signature-requests/{gid}/void`, then create a corrected\n  request \u2014 the same `external_ref` is free again.\n- Declined or expired: create a new request; the reason is in `signers[].declined_reason` and in\n  the `signature_request.declined` webhook.\n- Lost track: `GET /signature-requests?external_ref=<yours>`.\n\n## 6. Changes\n\n- **1.3.0** \u2014 Upload links: `POST /document-uploads` and `GET /document-uploads/{gid}` take one\n  PDF through a short-lived `upload_url` (no API key, `PUT` raw bytes or `POST` multipart), for\n  callers with no public URL and no multipart \u2014 AI agents above all; new codes\n  `upload_link_invalid`, `upload_link_expired`, `upload_link_used`. The API key may also be sent\n  as `X-Api-Key`. `fields[].anchor` is now resolved when the request is created (first\n  occurrence; without `offset_y` the box is centred in the gap under the text) and an absent text\n  refuses the request with `422 anchor_not_found` \u2014 before this, an anchored field was stored with\n  no position and drawn nowhere. Over MCP, `uploadDocument` no longer offers `file`, and\n  `createDocumentUpload`, `createSigningSession` and `getFinalDocuments` render an interactive box\n  in clients that support MCP Apps.\n\n- **1.2.0** \u2014 Test mode: keys are issued as `esk_live_\u2026` or `esk_test_\u2026`; a test key's requests\n  and documents are test data (`\"test\": true`, a separate `external_ref` namespace), send no\n  email (`GET /test-mail` reads the outbox), produce SPECIMEN documents without the platform seal,\n  and can be signed with `POST /signature-requests/{gid}/signers/{signerGid}/simulate`. Every\n  webhook carries `test`; `GET /application` reports `api_key.mode`. The MCP server offers the\n  integration guides as resources and two prompts (`integrate-lokasign`,\n  `diagnose-lokasign-error`).\n- **1.1.0** \u2014 `signers[].delivery` (`email` | `embedded`): embedded signers receive no invitation\n  or reminder, reminding one answers `409 signer_embedded`, and correcting one re-sends nothing.\n  Signing sessions for mobile apps: `embedder_origin` is optional (a session without one refuses\n  every frame), a new `return_url` hands control back to the app with the exchange code, and the\n  page reports to native WebView bridges when it is not framed (`403 return_url_not_allowed`\n  guards the URL). Guides at `/docs/quickstart`, `/docs/signing` and `/docs/templates`, with two\n  tested sample templates; `/docs/LOKASIGN.md` and `/llms-full.txt` for AI assistants.\n- **1.0.0** \u2014 First published contract, generated from the code, and the MCP server that mirrors\n  it at `/mcp`. It adds `GET /application`,\n  the five template endpoints, `documents[].prefill` for template PDFs, webhook configuration\n  and delivery inspection, and `PATCH \u2026/signers/{gid}` for correcting a mistyped address. Compared with the earlier\n  hand-written design notes: responses are wrapped in `data`; signing-session identifiers are\n  `signature_request_gid`, `signer_gid` and `gid` (formerly `*_id`/`id`); an `external_ref` is\n  released when its request is voided, declined or expired; a duplicate `external_ref` always\n  answers `external_ref_taken`; and there is no inbound `X-Signature` on write endpoints \u2014 the\n  API key over TLS is the authentication.\n"
    },
    "servers": [
        {
            "url": "https://lokasign.net/api/v1"
        }
    ],
    "tags": [
        {
            "name": "Application",
            "description": "Your application as the API sees it: the identity behind the key, the key itself, the webhook endpoint it delivers to, and the limits in force. Call it first to confirm credentials and configuration."
        },
        {
            "name": "Signature Requests",
            "description": "A signature request is the unit of work: one or more documents, one or more signers, and the lifecycle that takes it from `draft` to `completed`. Create one, send it, watch it through webhooks or `GET /signature-requests/{gid}`, then fetch the executed documents."
        },
        {
            "name": "Templates",
            "description": "The agreements your application can render: what each one expects (roles, merge tags, repeating collections, prefill keys), a dry run of your data against it, and the switch that makes an authored template usable. Templates are authored in the dashboard; the API discovers and activates them."
        },
        {
            "name": "Documents",
            "description": "PDFs stored under your application, independently of any request. Upload once, then reference the `gid` from as many signature requests as you like \u2014 or skip this and hand `POST /signature-requests` a `document_url` or a `template_code` directly. Documents rendered from templates appear here too."
        },
        {
            "name": "Signing Sessions",
            "description": "Embedded signing: let a signer sign inside your own web page (iframe) or mobile app (WebView) instead of following an emailed link. Your backend mints a session for one signer, your frontend opens the returned URL, and your backend redeems the exchange code the signing page hands back to learn the outcome. Status still comes from the API or webhooks, never from the browser."
        },
        {
            "name": "Webhooks",
            "description": "Where your application's events are delivered, and the record of what was sent. Configure the endpoint, choose the events, rotate the signing secret, send a test delivery, and inspect or retry past ones. The events themselves are documented under *webhooks*."
        },
        {
            "name": "Test Mode",
            "description": "Only for test-mode keys (`esk_test_\u2026`). With a test key the whole API works as usual, but every request and document is test data kept apart from live data, nothing is emailed, and executed documents carry a SPECIMEN watermark and no platform seal. These two endpoints complete the rehearsal: read the email a request would have sent (one-time codes and signing links included), and sign or decline on a signer's behalf so your webhook handling and archiving can run end to end."
        },
        {
            "name": "Webhooks",
            "description": "Events the platform POSTs to the endpoint configured for your application at `/api-settings`. Signed, retried, and deduplicable \u2014 see the *Webhooks* section of the introduction."
        }
    ],
    "security": [
        {
            "apiKey": []
        }
    ],
    "paths": {
        "/application": {
            "get": {
                "operationId": "getApplication",
                "description": "Returns the application the API key belongs to, the key's own identity (prefix, primary\nflag, allowed embedder origins), the webhook endpoint configured for the application and\nthe events it subscribes to, and the limits that apply. Nothing secret is included. Use\nit to verify a credential before doing work, and to read limits instead of hard-coding\nthem.",
                "summary": "Get the calling application",
                "tags": [
                    "Application"
                ],
                "responses": {
                    "200": {
                        "description": "The application, its key, its webhook configuration and its limits.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "$ref": "#/components/schemas/ApplicationResource"
                                        }
                                    },
                                    "required": [
                                        "data"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/signature-requests": {
            "get": {
                "operationId": "listSignatureRequests",
                "description": "Returns the application's requests, newest first, 25 per page unless `per_page` says\notherwise. Filter by `status`, by your own `external_ref`, or by creation date. Each row\ncarries its documents, signers and CC recipients, so a list is enough to render a status\nboard without one call per request. Prefer webhooks for change detection and use this\nendpoint to reconcile or to look a request up by `external_ref`.",
                "summary": "List signature requests",
                "tags": [
                    "Signature Requests"
                ],
                "parameters": [
                    {
                        "name": "status",
                        "in": "query",
                        "description": "Only requests in this lifecycle status.\n| |\n|---|\n| `draft` <br/> Being composed in the wizard. No signer has been invited yet. |\n| `sent` <br/> Invitations dispatched, nobody has signed. |\n| `partially_signed` <br/> At least one but not all signers have signed. |\n| `completed` <br/> Every signer signed; final documents sealed and downloadable (R50). |\n| `declined` <br/> A signer refused. Terminal \u2014 a new request is needed to try again. |\n| `expired` <br/> Passed `expires_at` before completion (R39). Terminal. |\n| `voided` <br/> Withdrawn by the sender before completion. Terminal. |",
                        "schema": {
                            "anyOf": [
                                {
                                    "$ref": "#/components/schemas/SignatureRequestStatusEnum"
                                },
                                {
                                    "type": "null"
                                }
                            ]
                        }
                    },
                    {
                        "name": "external_ref",
                        "in": "query",
                        "description": "Only the request carrying exactly this `external_ref` \u2014 the way to find a request by your own identifier.",
                        "schema": {
                            "type": [
                                "string",
                                "null"
                            ],
                            "maxLength": 191
                        }
                    },
                    {
                        "name": "created_from",
                        "in": "query",
                        "description": "Only requests created at or after this instant (ISO-8601 or `YYYY-MM-DD`).",
                        "schema": {
                            "type": [
                                "string",
                                "null"
                            ],
                            "format": "date-time"
                        }
                    },
                    {
                        "name": "created_to",
                        "in": "query",
                        "description": "Only requests created at or before this instant (ISO-8601 or `YYYY-MM-DD`).",
                        "schema": {
                            "type": [
                                "string",
                                "null"
                            ],
                            "format": "date-time"
                        }
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "description": "Rows per page, 1\u2013100. Default 25. Use `page` to move through the pages.",
                        "schema": {
                            "type": [
                                "integer",
                                "null"
                            ],
                            "minimum": 1,
                            "maximum": 100
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "One page of requests, newest first, each with its documents, signers and CC recipients.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "allOf": [
                                                    {
                                                        "$ref": "#/components/schemas/SignatureRequestResource"
                                                    },
                                                    {
                                                        "type": "object",
                                                        "required": [
                                                            "documents",
                                                            "signers",
                                                            "cc_recipients"
                                                        ]
                                                    }
                                                ]
                                            },
                                            "description": "The rows of this page."
                                        },
                                        "links": {
                                            "type": "object",
                                            "properties": {
                                                "first": {
                                                    "type": [
                                                        "string",
                                                        "null"
                                                    ],
                                                    "description": "URL of the first page."
                                                },
                                                "last": {
                                                    "type": [
                                                        "string",
                                                        "null"
                                                    ],
                                                    "description": "URL of the last page."
                                                },
                                                "prev": {
                                                    "type": [
                                                        "string",
                                                        "null"
                                                    ],
                                                    "description": "URL of the previous page. Null on the first page."
                                                },
                                                "next": {
                                                    "type": [
                                                        "string",
                                                        "null"
                                                    ],
                                                    "description": "URL of the next page. Null on the last page."
                                                }
                                            },
                                            "required": [
                                                "first",
                                                "last",
                                                "prev",
                                                "next"
                                            ],
                                            "description": "Absolute URLs of neighbouring pages, ready to request as they are."
                                        },
                                        "meta": {
                                            "type": "object",
                                            "properties": {
                                                "current_page": {
                                                    "type": "integer",
                                                    "minimum": 1,
                                                    "description": "Number of this page, starting at 1."
                                                },
                                                "from": {
                                                    "type": [
                                                        "integer",
                                                        "null"
                                                    ],
                                                    "minimum": 1,
                                                    "description": "Position of the first row on this page within the whole result set (1-based). Null when the page is empty."
                                                },
                                                "last_page": {
                                                    "type": "integer",
                                                    "minimum": 1,
                                                    "description": "Number of the last page."
                                                },
                                                "links": {
                                                    "type": "array",
                                                    "description": "Generated paginator links.",
                                                    "items": {
                                                        "type": "object",
                                                        "properties": {
                                                            "url": {
                                                                "type": [
                                                                    "string",
                                                                    "null"
                                                                ],
                                                                "description": "URL of that page. Null for the disabled previous/next entry at either end."
                                                            },
                                                            "label": {
                                                                "type": "string",
                                                                "description": "Text of the link: a page number, or the localised previous/next label."
                                                            },
                                                            "active": {
                                                                "type": "boolean",
                                                                "description": "True for the entry of the current page."
                                                            }
                                                        },
                                                        "required": [
                                                            "url",
                                                            "label",
                                                            "active"
                                                        ]
                                                    }
                                                },
                                                "path": {
                                                    "type": [
                                                        "string",
                                                        "null"
                                                    ],
                                                    "description": "Base path for paginator generated URLs."
                                                },
                                                "per_page": {
                                                    "type": "integer",
                                                    "description": "Number of items shown per page.",
                                                    "minimum": 0
                                                },
                                                "to": {
                                                    "type": [
                                                        "integer",
                                                        "null"
                                                    ],
                                                    "description": "Number of the last item in the slice.",
                                                    "minimum": 1
                                                },
                                                "total": {
                                                    "type": "integer",
                                                    "description": "Total number of items being paginated.",
                                                    "minimum": 0
                                                }
                                            },
                                            "required": [
                                                "current_page",
                                                "from",
                                                "last_page",
                                                "links",
                                                "path",
                                                "per_page",
                                                "to",
                                                "total"
                                            ],
                                            "description": "Where this page sits in the whole result set."
                                        }
                                    },
                                    "required": [
                                        "data",
                                        "links",
                                        "meta"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "**422** \u2014 `error.code` is one of:\n\n- `validation_failed` \u2014 The payload or query string is invalid. `field` names the first thing to fix and `message` says why. Correct the request; retrying it unchanged will fail again.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "validation_failed": {
                                        "summary": "validation_failed",
                                        "value": {
                                            "error": {
                                                "code": "validation_failed",
                                                "message": "Permintaan tidak dapat diproses.",
                                                "field": "title",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            },
            "post": {
                "operationId": "createSignatureRequest",
                "description": "Creates a request with its documents and signers. Nothing is emailed yet: the request is\nborn `draft`, and invitations leave only on `POST /signature-requests/{gid}/send` \u2014 or on\ntheir own when `send_when_ready` is true and every document has finished rendering.\n\nEach `documents[]` entry supplies its document in exactly one of three ways: a public\nHTTPS `document_url` the platform fetches now, a `document_gid` stored earlier through\n`POST /documents`, or a `template_code` with `merge_fields` (and `merge_rows` for repeating\ntables) that the platform renders on a queue. Template-backed requests therefore answer\nwith `documents: []` and `documents_pending` greater than zero; the template's existence,\nits required tags and its roles are still checked synchronously, so a payload that could\nnot render is refused with 422 here rather than failing later in the queue.\n\n`external_ref` is your own identifier, unique per application and echoed in every\nwebhook \u2014 use your contract or order id. Send an `Idempotency-Key` header so a retried\ncall returns the original response instead of creating a second request.\n\nNext: subscribe to webhooks, or poll `GET /signature-requests/{gid}` no more than once a\nminute; review the rendered documents with `GET /signature-requests/{gid}/documents`\nbefore sending, if you did not ask for `send_when_ready`.",
                "summary": "Create a signature request as a draft",
                "tags": [
                    "Signature Requests"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/StoreSignatureRequestRequest"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new request, still a draft. `documents_pending` is greater than zero while template documents render.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "allOf": [
                                                {
                                                    "$ref": "#/components/schemas/SignatureRequestResource"
                                                },
                                                {
                                                    "type": "object",
                                                    "required": [
                                                        "documents",
                                                        "signers",
                                                        "cc_recipients"
                                                    ]
                                                }
                                            ]
                                        }
                                    },
                                    "required": [
                                        "data"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "409": {
                        "description": "**409** \u2014 `error.code` is one of:\n\n- `idempotency_key_reused` \u2014 This `Idempotency-Key` was already used within the last 24 hours with a different body. Use a new key for new work; reuse a key only to retry the identical request.\n- `application_without_sender` \u2014 Your application's organisation has no owner account to act as the sender of record, so no request can be created yet. Ask the organisation owner to complete their Lokasign account.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "idempotency_key_reused": {
                                        "summary": "idempotency_key_reused",
                                        "value": {
                                            "error": {
                                                "code": "idempotency_key_reused",
                                                "message": "Idempotency-Key ini sudah dipakai dengan isi permintaan yang berbeda.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "application_without_sender": {
                                        "summary": "application_without_sender",
                                        "value": {
                                            "error": {
                                                "code": "application_without_sender",
                                                "message": "Aplikasi klien ini belum punya pemilik organisasi sebagai pengirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "**422** \u2014 `error.code` is one of:\n\n- `validation_failed` \u2014 The payload or query string is invalid. `field` names the first thing to fix and `message` says why. Correct the request; retrying it unchanged will fail again.\n- `external_ref_taken` \u2014 Another live or completed request of your application already carries this `external_ref`. Look it up with `GET /signature-requests?external_ref=` instead of creating a duplicate. A reference is freed when its request is voided, declined or expired.\n- `document_not_found` \u2014 A `documents[].document_gid` does not name a document of your application. Upload it first with `POST /documents`, or check the `gid`.\n- `document_fetch_failed` \u2014 The `document_url` could not be downloaded (connection error, non-2xx answer, or too many redirects). Check that the URL is public and serves the file directly.\n- `document_url_scheme` \u2014 `document_url` must use `https`.\n- `document_url_blocked` \u2014 `document_url` resolves to a private or reserved network address, which the platform refuses to fetch. Host the file on a public address.\n- `anchor_not_found` \u2014 A field's `anchor.text` does not occur anywhere in its document, so the box has nowhere to go. `field` names the entry (`fields.N.anchor.text`). Check the exact wording, punctuation included, or place the field with `page_number`, `x` and `y`.\n- `document_too_large` \u2014 The file exceeds the 25 MB limit. Reduce it (for example by downsampling images) and try again.\n- `document_not_pdf` \u2014 The bytes are not a PDF, whatever the file extension or `Content-Type` said. Export the document as PDF and upload that.\n- `document_encrypted` \u2014 The PDF is password-protected and cannot be processed. Remove the protection and upload again.\n- `document_not_sanitisable` \u2014 The PDF contains active content (scripts or attachments) that could not be stripped. Re-export it as a plain PDF and upload again.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "validation_failed": {
                                        "summary": "validation_failed",
                                        "value": {
                                            "error": {
                                                "code": "validation_failed",
                                                "message": "Permintaan tidak dapat diproses.",
                                                "field": "title",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "external_ref_taken": {
                                        "summary": "external_ref_taken",
                                        "value": {
                                            "error": {
                                                "code": "external_ref_taken",
                                                "message": "external_ref sudah dipakai signature request lain.",
                                                "field": "external_ref",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "document_not_found": {
                                        "summary": "document_not_found",
                                        "value": {
                                            "error": {
                                                "code": "document_not_found",
                                                "message": "Dokumen dengan gid tersebut tidak ditemukan pada aplikasi ini.",
                                                "field": "documents.0.document_gid",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "document_fetch_failed": {
                                        "summary": "document_fetch_failed",
                                        "value": {
                                            "error": {
                                                "code": "document_fetch_failed",
                                                "message": "Dokumen pada document_url tidak dapat diunduh.",
                                                "field": "document_url",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "document_url_scheme": {
                                        "summary": "document_url_scheme",
                                        "value": {
                                            "error": {
                                                "code": "document_url_scheme",
                                                "message": "document_url harus memakai skema https.",
                                                "field": "document_url",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "document_url_blocked": {
                                        "summary": "document_url_blocked",
                                        "value": {
                                            "error": {
                                                "code": "document_url_blocked",
                                                "message": "document_url mengarah ke alamat jaringan yang tidak diizinkan.",
                                                "field": "document_url",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "anchor_not_found": {
                                        "summary": "anchor_not_found",
                                        "value": {
                                            "error": {
                                                "code": "anchor_not_found",
                                                "message": "Permintaan tidak dapat diproses.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "document_too_large": {
                                        "summary": "document_too_large",
                                        "value": {
                                            "error": {
                                                "code": "document_too_large",
                                                "message": "Ukuran berkas melebihi batas 25 MB.",
                                                "field": "document_url",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "document_not_pdf": {
                                        "summary": "document_not_pdf",
                                        "value": {
                                            "error": {
                                                "code": "document_not_pdf",
                                                "message": "Berkas bukan PDF yang valid.",
                                                "field": "document_url",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "document_encrypted": {
                                        "summary": "document_encrypted",
                                        "value": {
                                            "error": {
                                                "code": "document_encrypted",
                                                "message": "PDF terproteksi password tidak dapat diproses.",
                                                "field": "document_url",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "document_not_sanitisable": {
                                        "summary": "document_not_sanitisable",
                                        "value": {
                                            "error": {
                                                "code": "document_not_sanitisable",
                                                "message": "PDF ini memuat konten aktif (skrip atau lampiran) yang tidak bisa dibersihkan. Ekspor ulang berkasnya sebagai PDF biasa lalu unggah kembali.",
                                                "field": "document_url",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/signature-requests/{signatureRequest}": {
            "get": {
                "operationId": "getSignatureRequest",
                "description": "Returns the request with its documents, signers and CC recipients. The server is the only\nsource of truth for `status`: a browser landing on `redirect_url` is not a completion\nsignal. Use this to reconcile after a webhook, to show per-party progress (`signers[].status`\nand `waiting_turn`), or as a polling fallback when webhooks are not configured \u2014 in which\ncase poll no more than once a minute.",
                "summary": "Get a signature request with its current status",
                "tags": [
                    "Signature Requests"
                ],
                "parameters": [
                    {
                        "name": "signatureRequest",
                        "in": "path",
                        "required": true,
                        "description": "`gid` of the signature request.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "0199a1c4-3f1e-7d2a-8b3c-5e6f7a8b9c0d"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The request with its documents, signers and CC recipients.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "allOf": [
                                                {
                                                    "$ref": "#/components/schemas/SignatureRequestResource"
                                                },
                                                {
                                                    "type": "object",
                                                    "required": [
                                                        "documents",
                                                        "signers",
                                                        "cc_recipients"
                                                    ]
                                                }
                                            ]
                                        }
                                    },
                                    "required": [
                                        "data"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "**404** \u2014 `error.code` is one of:\n\n- `not_found` \u2014 No resource with that `gid` exists for your application. Also the answer for a `gid` that belongs to another application \u2014 existence is never disclosed across applications.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "not_found": {
                                        "summary": "not_found",
                                        "value": {
                                            "error": {
                                                "code": "not_found",
                                                "message": "Sumber daya tidak ditemukan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/signature-requests/{signatureRequest}/send": {
            "post": {
                "operationId": "sendSignatureRequest",
                "description": "Moves a `draft` to `sent` and emails the invitations: every signer at once, or only the\nfirst one when the request is `sequential`. Refused with 422 when the request has already\nended (`completed`, `declined`, `expired`, `voided`), when it has no documents or signers,\nwhen a signer has no signature field on any document, or when a document is still\nrendering (`documents_pending` > 0) \u2014 wait for it, or create the request with\n`send_when_ready` instead. Call it once per request; to nudge signers who have not acted,\nuse `POST /signature-requests/{gid}/remind`. The response carries the updated request and\nhow many invitations left.",
                "summary": "Send a signature request",
                "tags": [
                    "Signature Requests"
                ],
                "parameters": [
                    {
                        "name": "signatureRequest",
                        "in": "path",
                        "required": true,
                        "description": "`gid` of the signature request.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "0199a1c4-3f1e-7d2a-8b3c-5e6f7a8b9c0d"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The request after sending, and how many invitations left.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "description": "The request after sending, with `status` now `sent`.",
                                            "allOf": [
                                                {
                                                    "$ref": "#/components/schemas/SignatureRequestResource"
                                                },
                                                {
                                                    "type": "object",
                                                    "required": [
                                                        "documents",
                                                        "signers",
                                                        "cc_recipients"
                                                    ]
                                                }
                                            ]
                                        },
                                        "invitations_sent": {
                                            "type": "integer",
                                            "description": "Number of invitation emails dispatched by this call: all pending signers, or just the first one of a sequential request."
                                        }
                                    },
                                    "required": [
                                        "data",
                                        "invitations_sent"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "**404** \u2014 `error.code` is one of:\n\n- `not_found` \u2014 No resource with that `gid` exists for your application. Also the answer for a `gid` that belongs to another application \u2014 existence is never disclosed across applications.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "not_found": {
                                        "summary": "not_found",
                                        "value": {
                                            "error": {
                                                "code": "not_found",
                                                "message": "Sumber daya tidak ditemukan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "**422** \u2014 `error.code` is one of:\n\n- `validation_failed` \u2014 The payload or query string is invalid. `field` names the first thing to fix and `message` says why. Correct the request; retrying it unchanged will fail again.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "validation_failed": {
                                        "summary": "validation_failed",
                                        "value": {
                                            "error": {
                                                "code": "validation_failed",
                                                "message": "Permintaan tidak dapat diproses.",
                                                "field": "title",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/signature-requests/{signatureRequest}/void": {
            "post": {
                "operationId": "voidSignatureRequest",
                "description": "Withdraws a request that has not completed: its status becomes `voided`, every signing\nlink stops working at once, pending signers are not contacted further, and the\n`signature_request.voided` webhook fires. Drafts can be voided too. A `completed` request\ncannot \u2014 the parties have executed it, and the only honest answer is a new agreement.\nVoiding releases the request's `external_ref`, so a corrected request may reuse it.",
                "summary": "Void a signature request",
                "tags": [
                    "Signature Requests"
                ],
                "parameters": [
                    {
                        "name": "signatureRequest",
                        "in": "path",
                        "required": true,
                        "description": "`gid` of the signature request.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "0199a1c4-3f1e-7d2a-8b3c-5e6f7a8b9c0d"
                    }
                ],
                "requestBody": {
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object",
                                "properties": {
                                    "reason": {
                                        "type": [
                                            "string",
                                            "null"
                                        ],
                                        "description": "Why the request is withdrawn. Recorded in the audit trail and included in the `signature_request.voided` webhook; not shown to signers.",
                                        "maxLength": 500
                                    }
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The request, now `voided`.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "allOf": [
                                                {
                                                    "$ref": "#/components/schemas/SignatureRequestResource"
                                                },
                                                {
                                                    "type": "object",
                                                    "required": [
                                                        "documents",
                                                        "signers",
                                                        "cc_recipients"
                                                    ]
                                                }
                                            ]
                                        }
                                    },
                                    "required": [
                                        "data"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "**404** \u2014 `error.code` is one of:\n\n- `not_found` \u2014 No resource with that `gid` exists for your application. Also the answer for a `gid` that belongs to another application \u2014 existence is never disclosed across applications.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "not_found": {
                                        "summary": "not_found",
                                        "value": {
                                            "error": {
                                                "code": "not_found",
                                                "message": "Sumber daya tidak ditemukan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "409": {
                        "description": "**409** \u2014 `error.code` is one of:\n\n- `request_not_voidable` \u2014 The request has already ended (`completed`, `declined`, `expired` or `voided`) and cannot be voided. `message` names its current status.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "request_not_voidable": {
                                        "summary": "request_not_voidable",
                                        "value": {
                                            "error": {
                                                "code": "request_not_voidable",
                                                "message": "Request dengan status completed tidak dapat dibatalkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "**422** \u2014 `error.code` is one of:\n\n- `validation_failed` \u2014 The payload or query string is invalid. `field` names the first thing to fix and `message` says why. Correct the request; retrying it unchanged will fail again.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "validation_failed": {
                                        "summary": "validation_failed",
                                        "value": {
                                            "error": {
                                                "code": "validation_failed",
                                                "message": "Permintaan tidak dapat diproses.",
                                                "field": "title",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/signature-requests/{signatureRequest}/remind": {
            "post": {
                "operationId": "remindSignatureRequest",
                "description": "Emails a reminder to every signer whose turn it is and who has not signed yet \u2014 or to one\nsigner only when `signer_gid` is given. Only requests that are `sent` or\n`partially_signed` can be reminded. Each signer is protected by a 24-hour cooldown shared\nwith the platform's automatic reminders; when every candidate is inside it the call\nanswers `429 reminder_cooldown` and nothing is sent. The response tells you how many\nreminders actually left.",
                "summary": "Send a reminder to pending signers",
                "tags": [
                    "Signature Requests"
                ],
                "parameters": [
                    {
                        "name": "signatureRequest",
                        "in": "path",
                        "required": true,
                        "description": "`gid` of the signature request.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "0199a1c4-3f1e-7d2a-8b3c-5e6f7a8b9c0d"
                    }
                ],
                "requestBody": {
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object",
                                "properties": {
                                    "signer_gid": {
                                        "type": [
                                            "string",
                                            "null"
                                        ],
                                        "format": "uuid",
                                        "description": "`gid` of one signer to remind. Omit to remind everyone whose turn it is."
                                    }
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "How many reminders left.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "reminders_sent": {
                                            "type": "integer",
                                            "description": "Number of reminder emails dispatched by this call. Zero is impossible: a call that could send nothing answers 429 instead.",
                                            "minimum": 0
                                        }
                                    },
                                    "required": [
                                        "reminders_sent"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "**404** \u2014 `error.code` is one of:\n\n- `not_found` \u2014 No resource with that `gid` exists for your application. Also the answer for a `gid` that belongs to another application \u2014 existence is never disclosed across applications.\n- `signer_not_found` \u2014 The `signer_gid` does not belong to this request. Use a `signers[].gid` from `GET /signature-requests/{gid}`.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "not_found": {
                                        "summary": "not_found",
                                        "value": {
                                            "error": {
                                                "code": "not_found",
                                                "message": "Sumber daya tidak ditemukan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "signer_not_found": {
                                        "summary": "signer_not_found",
                                        "value": {
                                            "error": {
                                                "code": "signer_not_found",
                                                "message": "Signer dengan gid tersebut tidak ada pada request ini.",
                                                "field": "signer_gid",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "409": {
                        "description": "**409** \u2014 `error.code` is one of:\n\n- `request_not_remindable` \u2014 Reminders can only be sent while a request is `sent` or `partially_signed`. Read the request to see where it stands.\n- `signer_embedded` \u2014 Every signer you asked to remind has `delivery: embedded`: Lokasign never emailed them a link, so there is nothing to remind them of. Nudge them in your own interface and open a session with `POST /signing-sessions`.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "request_not_remindable": {
                                        "summary": "request_not_remindable",
                                        "value": {
                                            "error": {
                                                "code": "request_not_remindable",
                                                "message": "Reminder hanya dapat dikirim untuk request yang masih berjalan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "signer_embedded": {
                                        "summary": "signer_embedded",
                                        "value": {
                                            "error": {
                                                "code": "signer_embedded",
                                                "message": "Signer ini menandatangani di dalam aplikasi Anda (delivery: embedded), jadi Lokasign tidak mengirimkan email kepadanya. Buka sesi penandatanganan untuknya lewat POST /signing-sessions.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "**422** \u2014 `error.code` is one of:\n\n- `validation_failed` \u2014 The payload or query string is invalid. `field` names the first thing to fix and `message` says why. Correct the request; retrying it unchanged will fail again.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "validation_failed": {
                                        "summary": "validation_failed",
                                        "value": {
                                            "error": {
                                                "code": "validation_failed",
                                                "message": "Permintaan tidak dapat diproses.",
                                                "field": "title",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.\n- `reminder_cooldown` \u2014 Every signer who could be reminded was reminded less than 24 hours ago (manually or by the platform). Wait; nothing was sent.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "reminder_cooldown": {
                                        "summary": "reminder_cooldown",
                                        "value": {
                                            "error": {
                                                "code": "reminder_cooldown",
                                                "message": "Reminder terakhir belum melewati jeda 24 jam.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/signature-requests/{signatureRequest}/signers/{signer}": {
            "patch": {
                "operationId": "updateSigner",
                "description": "Changes the name or email of a signer who has not signed or declined yet, and \u2014 if they\nhad already been invited \u2014 invalidates the link sent to the old address and emails a\nfresh invitation to the new one. The correction is written to the audit trail with both\naddresses, so the earlier `invitation_sent` entry cannot be misread as having gone where\nit did not.\n\nNothing is sent when there was nothing to invalidate: a `draft` has invited nobody, and\nin a sequential request a signer whose turn has not come has not been invited either \u2014\ninviting them now would hand them a working link ahead of the person in front of them.\n`invitation_resent` says which happened. A call that changes nothing sends nothing.\n\nA signer who has already acted answers `409 signer_not_correctable`; so does any request\nthat has ended. `role_key` and `verification_method` cannot be changed \u2014 create a new\nrequest for those.",
                "summary": "Correct a signer's name or address",
                "tags": [
                    "Signature Requests"
                ],
                "parameters": [
                    {
                        "name": "signatureRequest",
                        "in": "path",
                        "required": true,
                        "description": "`gid` of the signature request.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "0199a1c4-3f1e-7d2a-8b3c-5e6f7a8b9c0d"
                    },
                    {
                        "name": "signer",
                        "in": "path",
                        "required": true,
                        "description": "`gid` of the signer to correct, from `signers[].gid`.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "0199a1c4-40aa-7e01-b2c3-d4e5f6a7b8c9"
                    }
                ],
                "requestBody": {
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/UpdateSignerRequest"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The request with the corrected signer, and whether an invitation went back out.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "description": "The request, with the corrected signer among its `signers`.",
                                            "allOf": [
                                                {
                                                    "$ref": "#/components/schemas/SignatureRequestResource"
                                                },
                                                {
                                                    "type": "object",
                                                    "required": [
                                                        "documents",
                                                        "signers",
                                                        "cc_recipients"
                                                    ]
                                                }
                                            ]
                                        },
                                        "invitation_resent": {
                                            "type": "string",
                                            "description": "True when a fresh invitation was emailed to the new address and the old link stopped working. False when the signer had not been invited yet, or nothing changed."
                                        }
                                    },
                                    "required": [
                                        "data",
                                        "invitation_resent"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "**404** \u2014 `error.code` is one of:\n\n- `not_found` \u2014 No resource with that `gid` exists for your application. Also the answer for a `gid` that belongs to another application \u2014 existence is never disclosed across applications.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "not_found": {
                                        "summary": "not_found",
                                        "value": {
                                            "error": {
                                                "code": "not_found",
                                                "message": "Sumber daya tidak ditemukan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "409": {
                        "description": "**409** \u2014 `error.code` is one of:\n\n- `signer_not_correctable` \u2014 The signer has already signed or declined, or the request has ended \u2014 either way the document is past the point where the recipient can be changed. Create a new request instead.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "signer_not_correctable": {
                                        "summary": "signer_not_correctable",
                                        "value": {
                                            "error": {
                                                "code": "signer_not_correctable",
                                                "message": "Signer tersebut sudah menandatangani atau menolak, sehingga namanya tidak dapat diubah.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "**422** \u2014 `error.code` is one of:\n\n- `validation_failed` \u2014 The payload or query string is invalid. `field` names the first thing to fix and `message` says why. Correct the request; retrying it unchanged will fail again.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "validation_failed": {
                                        "summary": "validation_failed",
                                        "value": {
                                            "error": {
                                                "code": "validation_failed",
                                                "message": "Permintaan tidak dapat diproses.",
                                                "field": "title",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/signature-requests/{signatureRequest}/document": {
            "get": {
                "operationId": "getFinalDocuments",
                "description": "Available only once the request is `completed` and every document has been sealed\n(PAdES platform seal plus timestamp); until then the call answers 409 rather than a link\nthe download route would refuse. Returns one entry per document, in signing order. Each\n`download_url` is a signed URL valid for 72 hours that can be minted again at any time,\nso store the file \u2014 and its digest \u2014 on your side, never the URL. The\n`signature_request.completed` webhook deliberately carries no link; call this endpoint\nfrom your handler.\n\n**Two digests, and they are not interchangeable.** `sealed_hash` is the SHA-256 of the\nbytes this link serves: that is the one to check a download against. `final_hash` is the\nSHA-256 of the composed document *before* the platform seal was applied \u2014 the digest the\naudit record fixes, and the one Verify Document recognises for a file held from that\nside of the seal. Checking a download against `final_hash` never matches, because the\nseal is written into the file after that digest is taken. To read documents while signing is still in progress, use\n`GET /signature-requests/{gid}/documents` instead.",
                "summary": "Get download links for the executed documents",
                "tags": [
                    "Signature Requests"
                ],
                "parameters": [
                    {
                        "name": "signatureRequest",
                        "in": "path",
                        "required": true,
                        "description": "`gid` of the signature request.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "0199a1c4-3f1e-7d2a-8b3c-5e6f7a8b9c0d"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Download links for every executed, sealed document, valid for 72 hours.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "description": "One entry per executed document, in signing order.",
                                            "items": {
                                                "type": "object",
                                                "properties": {
                                                    "document_gid": {
                                                        "type": "string",
                                                        "description": "Public identifier of the document."
                                                    },
                                                    "filename": {
                                                        "type": "string",
                                                        "description": "File name of the executed document."
                                                    },
                                                    "final_hash": {
                                                        "type": "string",
                                                        "description": "Lowercase hex SHA-256 of the composed document, before the platform seal was applied. It is the digest the audit record fixes, and it is **not** the digest of the file `download_url` serves \u2014 compare that one with `sealed_hash`."
                                                    },
                                                    "sealed_hash": {
                                                        "type": "string",
                                                        "description": "Lowercase hex SHA-256 of the sealed PDF `download_url` serves. This is the value to check the file you download against. Null only for a document sealed before this field existed."
                                                    },
                                                    "sealed_at": {
                                                        "type": [
                                                            "string",
                                                            "null"
                                                        ],
                                                        "description": "When the platform seal was applied (ISO-8601)."
                                                    },
                                                    "download_url": {
                                                        "type": "string",
                                                        "description": "Signed URL that serves the executed PDF. Valid until `expires_at`; a plain GET with no API key needed."
                                                    }
                                                },
                                                "required": [
                                                    "document_gid",
                                                    "filename",
                                                    "final_hash",
                                                    "sealed_hash",
                                                    "sealed_at",
                                                    "download_url"
                                                ]
                                            }
                                        },
                                        "expires_at": {
                                            "type": "string",
                                            "description": "When every `download_url` in this response stops working (ISO-8601, 72 hours from now). Call again for fresh links."
                                        }
                                    },
                                    "required": [
                                        "data",
                                        "expires_at"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "**404** \u2014 `error.code` is one of:\n\n- `not_found` \u2014 No resource with that `gid` exists for your application. Also the answer for a `gid` that belongs to another application \u2014 existence is never disclosed across applications.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "not_found": {
                                        "summary": "not_found",
                                        "value": {
                                            "error": {
                                                "code": "not_found",
                                                "message": "Sumber daya tidak ditemukan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "409": {
                        "description": "**409** \u2014 `error.code` is one of:\n\n- `request_not_completed` \u2014 Executed documents exist only once the request is `completed`. Wait for the `signature_request.completed` webhook, then call again.\n- `documents_not_sealed` \u2014 The request is completed but the platform seal has not been applied to its documents yet, so they are withheld. Retry in a few minutes; if it persists, contact support with `request_id`.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "request_not_completed": {
                                        "summary": "request_not_completed",
                                        "value": {
                                            "error": {
                                                "code": "request_not_completed",
                                                "message": "Dokumen final baru tersedia setelah request berstatus completed.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "documents_not_sealed": {
                                        "summary": "documents_not_sealed",
                                        "value": {
                                            "error": {
                                                "code": "documents_not_sealed",
                                                "message": "Dokumen final belum tersegel sehingga belum dapat diunduh.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/signature-requests/{signatureRequest}/documents": {
            "get": {
                "operationId": "getDocumentPreviews",
                "description": "Works in any status: while a request is still being signed the links serve the document\nevery signer is looking at, and after completion they serve the executed copy \u2014 `signed`\ntells you which. Use it to let your own users review a rendered template before you call\n`/send`, or to show \"what am I signing\" next to a signing session. Links are valid for\n15 minutes and meant to be resolved on click, not stored. A template-backed request has\nno documents until rendering finishes and answers `409 documents_not_ready` until then \u2014\nretry after a moment.",
                "summary": "Get links to read the request's documents as they are now",
                "tags": [
                    "Signature Requests"
                ],
                "parameters": [
                    {
                        "name": "signatureRequest",
                        "in": "path",
                        "required": true,
                        "description": "`gid` of the signature request.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "0199a1c4-3f1e-7d2a-8b3c-5e6f7a8b9c0d"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Read links for every document of the request as it stands now, valid for 15 minutes.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "description": "One entry per document, in signing order.",
                                            "items": {
                                                "type": "object",
                                                "properties": {
                                                    "document_gid": {
                                                        "type": "string",
                                                        "description": "Public identifier of the document."
                                                    },
                                                    "filename": {
                                                        "type": "string",
                                                        "description": "File name of the document."
                                                    },
                                                    "pages": {
                                                        "type": "integer",
                                                        "description": "Number of pages."
                                                    },
                                                    "sort_order": {
                                                        "type": "string",
                                                        "description": "Position of the document within the request, starting at 1."
                                                    },
                                                    "signed": {
                                                        "type": "string",
                                                        "description": "True when `preview_url` serves the executed, sealed copy; false while it serves the document still under signature."
                                                    },
                                                    "preview_url": {
                                                        "type": "string",
                                                        "description": "Signed URL that serves the PDF. Valid until `expires_at`; a plain GET with no API key needed."
                                                    }
                                                },
                                                "required": [
                                                    "document_gid",
                                                    "filename",
                                                    "pages",
                                                    "sort_order",
                                                    "signed",
                                                    "preview_url"
                                                ]
                                            }
                                        },
                                        "expires_at": {
                                            "type": "string",
                                            "description": "When every `preview_url` in this response stops working (ISO-8601, 15 minutes from now)."
                                        }
                                    },
                                    "required": [
                                        "data",
                                        "expires_at"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "**404** \u2014 `error.code` is one of:\n\n- `not_found` \u2014 No resource with that `gid` exists for your application. Also the answer for a `gid` that belongs to another application \u2014 existence is never disclosed across applications.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "not_found": {
                                        "summary": "not_found",
                                        "value": {
                                            "error": {
                                                "code": "not_found",
                                                "message": "Sumber daya tidak ditemukan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "409": {
                        "description": "**409** \u2014 `error.code` is one of:\n\n- `documents_not_ready` \u2014 The request's documents are still being rendered from their templates (`documents_pending` > 0). Retry shortly.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "documents_not_ready": {
                                        "summary": "documents_not_ready",
                                        "value": {
                                            "error": {
                                                "code": "documents_not_ready",
                                                "message": "Dokumen permintaan ini masih disiapkan. Coba lagi sebentar lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/signature-requests/{signatureRequest}/audit-trail": {
            "get": {
                "operationId": "getAuditTrail",
                "description": "Returns every recorded event of the request in the order it was written \u2014 creation,\ninvitations, views, consent, signatures, declines, reminders, completion \u2014 as a\nhash-chained list, and verifies the chain before answering. `chain.valid` is the\nplatform's own check; a client that stores `prev_hash`/`entry_hash` can repeat it\nindependently. Show this list as the request's history, or keep it as evidence beside\nthe executed documents.",
                "summary": "Get the audit trail of a signature request",
                "tags": [
                    "Signature Requests"
                ],
                "parameters": [
                    {
                        "name": "signatureRequest",
                        "in": "path",
                        "required": true,
                        "description": "`gid` of the signature request.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "0199a1c4-3f1e-7d2a-8b3c-5e6f7a8b9c0d"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The events, oldest first, and the result of verifying their hash chain.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "description": "The events, oldest first.",
                                            "items": {
                                                "allOf": [
                                                    {
                                                        "$ref": "#/components/schemas/AuditEventResource"
                                                    },
                                                    {
                                                        "type": "object",
                                                        "required": [
                                                            "signer_gid",
                                                            "signer_name"
                                                        ]
                                                    }
                                                ]
                                            }
                                        },
                                        "chain": {
                                            "type": "object",
                                            "description": "Result of verifying the hash chain at read time.",
                                            "properties": {
                                                "valid": {
                                                    "type": "string",
                                                    "description": "True when every entry's hash matches its content and its predecessor. False means the trail has been altered and must not be relied on."
                                                },
                                                "broken_at_gid": {
                                                    "type": "string",
                                                    "description": "`gid` of the first entry that failed verification. Null when the chain is valid."
                                                },
                                                "reason": {
                                                    "type": "string",
                                                    "description": "Why verification failed: `entry_hash_mismatch` (an entry's content changed) or `chain_break` (an entry no longer links to its predecessor). Null when the chain is valid."
                                                }
                                            },
                                            "required": [
                                                "valid",
                                                "broken_at_gid",
                                                "reason"
                                            ]
                                        }
                                    },
                                    "required": [
                                        "data",
                                        "chain"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "**404** \u2014 `error.code` is one of:\n\n- `not_found` \u2014 No resource with that `gid` exists for your application. Also the answer for a `gid` that belongs to another application \u2014 existence is never disclosed across applications.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "not_found": {
                                        "summary": "not_found",
                                        "value": {
                                            "error": {
                                                "code": "not_found",
                                                "message": "Sumber daya tidak ditemukan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/templates": {
            "get": {
                "operationId": "listTemplates",
                "description": "Returns your application's templates alphabetically, active and inactive alike, 25 per\npage unless `per_page` says otherwise. Filter with `active=true` to see only the ones a\nrequest may use right now. Each row carries the roles a request must cover; read\n`GET /templates/{code}` for the tags and collections.",
                "summary": "List templates",
                "tags": [
                    "Templates"
                ],
                "parameters": [
                    {
                        "name": "active",
                        "in": "query",
                        "description": "`true` for templates a request may use now, `false` for the ones still being authored or retired. Omit for both.",
                        "schema": {
                            "type": [
                                "string",
                                "null"
                            ],
                            "enum": [
                                "true",
                                "false",
                                "1",
                                "0",
                                null
                            ]
                        }
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "description": "Rows per page, 1\u2013100. Default 25. Use `page` to move through the pages.",
                        "schema": {
                            "type": [
                                "integer",
                                "null"
                            ],
                            "minimum": 1,
                            "maximum": 100
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "One page of templates, alphabetical by name.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/TemplateSummaryResource"
                                            },
                                            "description": "The rows of this page."
                                        },
                                        "links": {
                                            "type": "object",
                                            "properties": {
                                                "first": {
                                                    "type": [
                                                        "string",
                                                        "null"
                                                    ],
                                                    "description": "URL of the first page."
                                                },
                                                "last": {
                                                    "type": [
                                                        "string",
                                                        "null"
                                                    ],
                                                    "description": "URL of the last page."
                                                },
                                                "prev": {
                                                    "type": [
                                                        "string",
                                                        "null"
                                                    ],
                                                    "description": "URL of the previous page. Null on the first page."
                                                },
                                                "next": {
                                                    "type": [
                                                        "string",
                                                        "null"
                                                    ],
                                                    "description": "URL of the next page. Null on the last page."
                                                }
                                            },
                                            "required": [
                                                "first",
                                                "last",
                                                "prev",
                                                "next"
                                            ],
                                            "description": "Absolute URLs of neighbouring pages, ready to request as they are."
                                        },
                                        "meta": {
                                            "type": "object",
                                            "properties": {
                                                "current_page": {
                                                    "type": "integer",
                                                    "minimum": 1,
                                                    "description": "Number of this page, starting at 1."
                                                },
                                                "from": {
                                                    "type": [
                                                        "integer",
                                                        "null"
                                                    ],
                                                    "minimum": 1,
                                                    "description": "Position of the first row on this page within the whole result set (1-based). Null when the page is empty."
                                                },
                                                "last_page": {
                                                    "type": "integer",
                                                    "minimum": 1,
                                                    "description": "Number of the last page."
                                                },
                                                "links": {
                                                    "type": "array",
                                                    "description": "Generated paginator links.",
                                                    "items": {
                                                        "type": "object",
                                                        "properties": {
                                                            "url": {
                                                                "type": [
                                                                    "string",
                                                                    "null"
                                                                ],
                                                                "description": "URL of that page. Null for the disabled previous/next entry at either end."
                                                            },
                                                            "label": {
                                                                "type": "string",
                                                                "description": "Text of the link: a page number, or the localised previous/next label."
                                                            },
                                                            "active": {
                                                                "type": "boolean",
                                                                "description": "True for the entry of the current page."
                                                            }
                                                        },
                                                        "required": [
                                                            "url",
                                                            "label",
                                                            "active"
                                                        ]
                                                    }
                                                },
                                                "path": {
                                                    "type": [
                                                        "string",
                                                        "null"
                                                    ],
                                                    "description": "Base path for paginator generated URLs."
                                                },
                                                "per_page": {
                                                    "type": "integer",
                                                    "description": "Number of items shown per page.",
                                                    "minimum": 0
                                                },
                                                "to": {
                                                    "type": [
                                                        "integer",
                                                        "null"
                                                    ],
                                                    "description": "Number of the last item in the slice.",
                                                    "minimum": 1
                                                },
                                                "total": {
                                                    "type": "integer",
                                                    "description": "Total number of items being paginated.",
                                                    "minimum": 0
                                                }
                                            },
                                            "required": [
                                                "current_page",
                                                "from",
                                                "last_page",
                                                "links",
                                                "path",
                                                "per_page",
                                                "to",
                                                "total"
                                            ],
                                            "description": "Where this page sits in the whole result set."
                                        }
                                    },
                                    "required": [
                                        "data",
                                        "links",
                                        "meta"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "**422** \u2014 `error.code` is one of:\n\n- `validation_failed` \u2014 The payload or query string is invalid. `field` names the first thing to fix and `message` says why. Correct the request; retrying it unchanged will fail again.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "validation_failed": {
                                        "summary": "validation_failed",
                                        "value": {
                                            "error": {
                                                "code": "validation_failed",
                                                "message": "Permintaan tidak dapat diproses.",
                                                "field": "title",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/templates/{code}": {
            "get": {
                "operationId": "getTemplate",
                "description": "Everything needed to build a valid `documents[]` entry for this template without opening\nthe dashboard: the roles that `signers[].role_key` must cover, every merge tag with\nwhether it is required, its stored default and the format its value must satisfy, the\nrepeating collections `merge_rows` may fill and their columns, and the prefill keys of\nplaced fields. `activation` says whether the template passes its checks, and lists the\nproblems when it does not. Inactive templates are returned too, so they can be inspected\nand activated; only active ones can be used in a request.",
                "summary": "Get a template's contract",
                "tags": [
                    "Templates"
                ],
                "parameters": [
                    {
                        "name": "code",
                        "in": "path",
                        "required": true,
                        "description": "The template's `code`, as listed by `GET /templates`.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "MEMBER_LABEL"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The template with its documents, roles, merge tags, collections and activation state.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "$ref": "#/components/schemas/TemplateResource"
                                        }
                                    },
                                    "required": [
                                        "data"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "**404** \u2014 `error.code` is one of:\n\n- `not_found` \u2014 No resource with that `gid` exists for your application. Also the answer for a `gid` that belongs to another application \u2014 existence is never disclosed across applications.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "not_found": {
                                        "summary": "not_found",
                                        "value": {
                                            "error": {
                                                "code": "not_found",
                                                "message": "Sumber daya tidak ditemukan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/templates/{code}/check": {
            "post": {
                "operationId": "checkTemplateData",
                "description": "Runs the same checks `POST /signature-requests` runs on a template-backed document \u2014\nrequired tags, value formats, template roles \u2014 against the `merge_fields`, `merge_rows`\nand signer role keys you intend to send, and reports every finding at once as lists.\nNothing is stored and nothing is queued; always answers 200 and never 422, whatever the\ndata. Use it to iterate on a payload, then send the same data to\n`POST /signature-requests`. An inactive template can be checked, but `usable` will say\nwhy a request with it would still be refused.",
                "summary": "Check data against a template without creating anything",
                "tags": [
                    "Templates"
                ],
                "parameters": [
                    {
                        "name": "code",
                        "in": "path",
                        "required": true,
                        "description": "The template's `code`, as listed by `GET /templates`.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "MEMBER_LABEL"
                    }
                ],
                "requestBody": {
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/CheckTemplateDataRequest"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The findings: what would make `POST /signature-requests` refuse this data, and what would be silently ignored.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "type": "object",
                                            "description": "The verdict and every finding, as lists a client can act on in one round.",
                                            "properties": {
                                                "ready": {
                                                    "type": "boolean",
                                                    "description": "True when `POST /signature-requests` would accept this data for this template \u2014 provided the template is active."
                                                },
                                                "usable": {
                                                    "type": "boolean",
                                                    "description": "True when the template is active, i.e. a request may use it. A ready payload against an inactive template is still refused with `validation_failed` until the template is activated."
                                                },
                                                "missing_merge_fields": {
                                                    "type": "array",
                                                    "description": "Required tags that have neither a value in `merge_fields` nor a stored default. Blocking.",
                                                    "items": {
                                                        "type": "string"
                                                    }
                                                },
                                                "unreadable_merge_values": {
                                                    "type": "array",
                                                    "description": "Values that cannot be read in the format their tag declares. Blocking.",
                                                    "items": {
                                                        "type": "object",
                                                        "properties": {
                                                            "tag": {
                                                                "type": "string",
                                                                "description": "The tag whose value could not be read."
                                                            },
                                                            "problem": {
                                                                "type": [
                                                                    "string",
                                                                    "null"
                                                                ],
                                                                "description": "What is wrong with the value, in the language of `Accept-Language`."
                                                            }
                                                        },
                                                        "required": [
                                                            "tag",
                                                            "problem"
                                                        ]
                                                    }
                                                },
                                                "incomplete_optional_blocks": {
                                                    "type": "array",
                                                    "description": "Optional clauses (`{{?name}}` blocks) with some tags filled and others empty. The clause prints whole once any of its tags has a value, so it must be filled completely or left out completely. Blocking.",
                                                    "items": {
                                                        "type": "object",
                                                        "properties": {
                                                            "filled": {
                                                                "type": "array",
                                                                "description": "Keys in the clause that have a value.",
                                                                "items": {
                                                                    "type": "string"
                                                                }
                                                            },
                                                            "missing": {
                                                                "type": "array",
                                                                "description": "Keys in the clause that are still empty \u2014 supply them, or clear the filled ones.",
                                                                "items": {
                                                                    "type": "string"
                                                                }
                                                            }
                                                        },
                                                        "required": [
                                                            "filled",
                                                            "missing"
                                                        ]
                                                    }
                                                },
                                                "unreadable_row_values": {
                                                    "type": "array",
                                                    "description": "Values in `merge_rows` that cannot be read in the format their column declares, e.g. a date column given \"1 Okt 2026\" instead of \"2026-10-01\". Blocking.",
                                                    "items": {
                                                        "type": "object",
                                                        "properties": {
                                                            "collection": {
                                                                "type": "string",
                                                                "description": "The collection the row belongs to."
                                                            },
                                                            "row": {
                                                                "type": "integer",
                                                                "description": "Zero-based position of the row in the array you sent."
                                                            },
                                                            "column": {
                                                                "type": "string",
                                                                "description": "The column whose value could not be read."
                                                            },
                                                            "problem": {
                                                                "type": [
                                                                    "string",
                                                                    "null"
                                                                ],
                                                                "description": "What is wrong with the value."
                                                            }
                                                        },
                                                        "required": [
                                                            "collection",
                                                            "row",
                                                            "column",
                                                            "problem"
                                                        ]
                                                    }
                                                },
                                                "unfilled_roles": {
                                                    "type": "array",
                                                    "description": "Template roles no entry of `signer_role_keys` covers. Blocking.",
                                                    "items": {
                                                        "type": "string"
                                                    }
                                                },
                                                "unknown_collections": {
                                                    "type": "array",
                                                    "description": "Keys of `merge_rows` that the template has no repeating collection for. Not blocking: the renderer ignores them, which is usually a typo you want to know about.",
                                                    "items": {
                                                        "type": "string"
                                                    }
                                                },
                                                "unknown_columns": {
                                                    "type": "array",
                                                    "description": "Row columns the collection's row does not print. Not blocking: ignored by the renderer.",
                                                    "items": {
                                                        "type": "object",
                                                        "properties": {
                                                            "collection": {
                                                                "type": "string",
                                                                "description": "The collection the row belongs to."
                                                            },
                                                            "column": {
                                                                "type": "string",
                                                                "description": "The column key that was sent but is not printed."
                                                            }
                                                        },
                                                        "required": [
                                                            "collection",
                                                            "column"
                                                        ]
                                                    }
                                                }
                                            },
                                            "required": [
                                                "ready",
                                                "usable",
                                                "missing_merge_fields",
                                                "unreadable_merge_values",
                                                "incomplete_optional_blocks",
                                                "unreadable_row_values",
                                                "unfilled_roles",
                                                "unknown_collections",
                                                "unknown_columns"
                                            ]
                                        }
                                    },
                                    "required": [
                                        "data"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "**404** \u2014 `error.code` is one of:\n\n- `not_found` \u2014 No resource with that `gid` exists for your application. Also the answer for a `gid` that belongs to another application \u2014 existence is never disclosed across applications.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "not_found": {
                                        "summary": "not_found",
                                        "value": {
                                            "error": {
                                                "code": "not_found",
                                                "message": "Sumber daya tidak ditemukan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "**422** \u2014 `error.code` is one of:\n\n- `validation_failed` \u2014 The payload or query string is invalid. `field` names the first thing to fix and `message` says why. Correct the request; retrying it unchanged will fail again.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "validation_failed": {
                                        "summary": "validation_failed",
                                        "value": {
                                            "error": {
                                                "code": "validation_failed",
                                                "message": "Permintaan tidak dapat diproses.",
                                                "field": "title",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/templates/{code}/activate": {
            "post": {
                "operationId": "activateTemplate",
                "description": "Switches an authored template on so that `POST /signature-requests` may use its `code`.\nActivation is gated: the platform first runs the same checks the dashboard's review\nscreen shows \u2014 at least one document, every document readable, no tag typed as plain\ntext, every role with a signature field, every field with a role \u2014 and refuses with\n`409 template_not_activatable` while any of them blocks; `GET /templates/{code}` lists\nthem under `activation.blocking`. Activating an already active template is a no-op that\nanswers 200. Activation is a review step: it is meant to be called once a person has\nread the template, not as part of an automated pipeline.",
                "summary": "Activate a template",
                "tags": [
                    "Templates"
                ],
                "parameters": [
                    {
                        "name": "code",
                        "in": "path",
                        "required": true,
                        "description": "The template's `code`, as listed by `GET /templates`.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "MEMBER_LABEL"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The template, now active.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "$ref": "#/components/schemas/TemplateResource"
                                        }
                                    },
                                    "required": [
                                        "data"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "**404** \u2014 `error.code` is one of:\n\n- `not_found` \u2014 No resource with that `gid` exists for your application. Also the answer for a `gid` that belongs to another application \u2014 existence is never disclosed across applications.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "not_found": {
                                        "summary": "not_found",
                                        "value": {
                                            "error": {
                                                "code": "not_found",
                                                "message": "Sumber daya tidak ditemukan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "409": {
                        "description": "**409** \u2014 `error.code` is one of:\n\n- `template_not_activatable` \u2014 The template fails one of its activation checks \u2014 no document, an unreadable document, a tag typed as plain text, a role without a signature field, a field without a role. `message` names the first; `GET /templates/{code}` lists them all under `activation.blocking`. Fix the template in the dashboard, then activate again.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "template_not_activatable": {
                                        "summary": "template_not_activatable",
                                        "value": {
                                            "error": {
                                                "code": "template_not_activatable",
                                                "message": "Tambahkan minimal satu peran penanda tangan sebelum mengaktifkan template ini.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/templates/{code}/deactivate": {
            "post": {
                "operationId": "deactivateTemplate",
                "description": "Switches a template off so that new requests can no longer use its `code`; requests\nalready created from it are unaffected. Nothing is deleted \u2014 the template keeps its\ndocuments and can be activated again once reviewed. Deactivating an inactive template is\na no-op that answers 200.",
                "summary": "Deactivate a template",
                "tags": [
                    "Templates"
                ],
                "parameters": [
                    {
                        "name": "code",
                        "in": "path",
                        "required": true,
                        "description": "The template's `code`, as listed by `GET /templates`.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "MEMBER_LABEL"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The template, now inactive.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "$ref": "#/components/schemas/TemplateResource"
                                        }
                                    },
                                    "required": [
                                        "data"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "**404** \u2014 `error.code` is one of:\n\n- `not_found` \u2014 No resource with that `gid` exists for your application. Also the answer for a `gid` that belongs to another application \u2014 existence is never disclosed across applications.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "not_found": {
                                        "summary": "not_found",
                                        "value": {
                                            "error": {
                                                "code": "not_found",
                                                "message": "Sumber daya tidak ditemukan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/documents": {
            "get": {
                "operationId": "listDocuments",
                "description": "Returns the documents stored under your application, newest first, 25 per page unless\n`per_page` says otherwise. Includes files you uploaded, files fetched from a\n`document_url`, and documents rendered from templates.",
                "summary": "List documents",
                "tags": [
                    "Documents"
                ],
                "parameters": [
                    {
                        "name": "status",
                        "in": "query",
                        "description": "Only documents in this processing state.\n| |\n|---|\n| `draft` <br/> Uploaded, not yet attached to a sent request. |\n| `active` <br/> Attached to at least one request that is currently out for signature. |\n| `completed` <br/> Every request using it has finished. |\n| `voided` <br/> Withdrawn \u2014 must not be attached to any new request. |",
                        "schema": {
                            "anyOf": [
                                {
                                    "$ref": "#/components/schemas/DocumentStatusEnum"
                                },
                                {
                                    "type": "null"
                                }
                            ]
                        }
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "description": "Rows per page, 1\u2013100. Default 25. Use `page` to move through the pages.",
                        "schema": {
                            "type": [
                                "integer",
                                "null"
                            ],
                            "minimum": 1,
                            "maximum": 100
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "One page of documents, newest first.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/DocumentResource"
                                            },
                                            "description": "The rows of this page."
                                        },
                                        "links": {
                                            "type": "object",
                                            "properties": {
                                                "first": {
                                                    "type": [
                                                        "string",
                                                        "null"
                                                    ],
                                                    "description": "URL of the first page."
                                                },
                                                "last": {
                                                    "type": [
                                                        "string",
                                                        "null"
                                                    ],
                                                    "description": "URL of the last page."
                                                },
                                                "prev": {
                                                    "type": [
                                                        "string",
                                                        "null"
                                                    ],
                                                    "description": "URL of the previous page. Null on the first page."
                                                },
                                                "next": {
                                                    "type": [
                                                        "string",
                                                        "null"
                                                    ],
                                                    "description": "URL of the next page. Null on the last page."
                                                }
                                            },
                                            "required": [
                                                "first",
                                                "last",
                                                "prev",
                                                "next"
                                            ],
                                            "description": "Absolute URLs of neighbouring pages, ready to request as they are."
                                        },
                                        "meta": {
                                            "type": "object",
                                            "properties": {
                                                "current_page": {
                                                    "type": "integer",
                                                    "minimum": 1,
                                                    "description": "Number of this page, starting at 1."
                                                },
                                                "from": {
                                                    "type": [
                                                        "integer",
                                                        "null"
                                                    ],
                                                    "minimum": 1,
                                                    "description": "Position of the first row on this page within the whole result set (1-based). Null when the page is empty."
                                                },
                                                "last_page": {
                                                    "type": "integer",
                                                    "minimum": 1,
                                                    "description": "Number of the last page."
                                                },
                                                "links": {
                                                    "type": "array",
                                                    "description": "Generated paginator links.",
                                                    "items": {
                                                        "type": "object",
                                                        "properties": {
                                                            "url": {
                                                                "type": [
                                                                    "string",
                                                                    "null"
                                                                ],
                                                                "description": "URL of that page. Null for the disabled previous/next entry at either end."
                                                            },
                                                            "label": {
                                                                "type": "string",
                                                                "description": "Text of the link: a page number, or the localised previous/next label."
                                                            },
                                                            "active": {
                                                                "type": "boolean",
                                                                "description": "True for the entry of the current page."
                                                            }
                                                        },
                                                        "required": [
                                                            "url",
                                                            "label",
                                                            "active"
                                                        ]
                                                    }
                                                },
                                                "path": {
                                                    "type": [
                                                        "string",
                                                        "null"
                                                    ],
                                                    "description": "Base path for paginator generated URLs."
                                                },
                                                "per_page": {
                                                    "type": "integer",
                                                    "description": "Number of items shown per page.",
                                                    "minimum": 0
                                                },
                                                "to": {
                                                    "type": [
                                                        "integer",
                                                        "null"
                                                    ],
                                                    "description": "Number of the last item in the slice.",
                                                    "minimum": 1
                                                },
                                                "total": {
                                                    "type": "integer",
                                                    "description": "Total number of items being paginated.",
                                                    "minimum": 0
                                                }
                                            },
                                            "required": [
                                                "current_page",
                                                "from",
                                                "last_page",
                                                "links",
                                                "path",
                                                "per_page",
                                                "to",
                                                "total"
                                            ],
                                            "description": "Where this page sits in the whole result set."
                                        }
                                    },
                                    "required": [
                                        "data",
                                        "links",
                                        "meta"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "**422** \u2014 `error.code` is one of:\n\n- `validation_failed` \u2014 The payload or query string is invalid. `field` names the first thing to fix and `message` says why. Correct the request; retrying it unchanged will fail again.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "validation_failed": {
                                        "summary": "validation_failed",
                                        "value": {
                                            "error": {
                                                "code": "validation_failed",
                                                "message": "Permintaan tidak dapat diproses.",
                                                "field": "title",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            },
            "post": {
                "operationId": "uploadDocument",
                "description": "Stores one PDF for later use in signature requests, either sent as a multipart `file` or\nfetched by the platform from a public HTTPS `document_url`. The bytes are inspected before\nanything is stored: a file that is not a PDF, is password-protected, exceeds 25 MB, or\ncarries active content that cannot be removed is refused with 422 and one of the\n`document_*` error codes. Send an `Idempotency-Key` so a retried upload returns the\noriginal document instead of storing a second copy. Use the returned `gid` as\n`documents[].document_gid` when creating a request.",
                "summary": "Upload a document",
                "tags": [
                    "Documents"
                ],
                "requestBody": {
                    "content": {
                        "multipart/form-data": {
                            "schema": {
                                "$ref": "#/components/schemas/StoreDocumentRequest"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The stored document. Use its `gid` as `documents[].document_gid` when creating a request.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "$ref": "#/components/schemas/DocumentResource"
                                        }
                                    },
                                    "required": [
                                        "data"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "409": {
                        "description": "**409** \u2014 `error.code` is one of:\n\n- `idempotency_key_reused` \u2014 This `Idempotency-Key` was already used within the last 24 hours with a different body. Use a new key for new work; reuse a key only to retry the identical request.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "idempotency_key_reused": {
                                        "summary": "idempotency_key_reused",
                                        "value": {
                                            "error": {
                                                "code": "idempotency_key_reused",
                                                "message": "Idempotency-Key ini sudah dipakai dengan isi permintaan yang berbeda.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "**422** \u2014 `error.code` is one of:\n\n- `validation_failed` \u2014 The payload or query string is invalid. `field` names the first thing to fix and `message` says why. Correct the request; retrying it unchanged will fail again.\n- `document_fetch_failed` \u2014 The `document_url` could not be downloaded (connection error, non-2xx answer, or too many redirects). Check that the URL is public and serves the file directly.\n- `document_url_scheme` \u2014 `document_url` must use `https`.\n- `document_url_blocked` \u2014 `document_url` resolves to a private or reserved network address, which the platform refuses to fetch. Host the file on a public address.\n- `document_too_large` \u2014 The file exceeds the 25 MB limit. Reduce it (for example by downsampling images) and try again.\n- `document_not_pdf` \u2014 The bytes are not a PDF, whatever the file extension or `Content-Type` said. Export the document as PDF and upload that.\n- `document_encrypted` \u2014 The PDF is password-protected and cannot be processed. Remove the protection and upload again.\n- `document_not_sanitisable` \u2014 The PDF contains active content (scripts or attachments) that could not be stripped. Re-export it as a plain PDF and upload again.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "validation_failed": {
                                        "summary": "validation_failed",
                                        "value": {
                                            "error": {
                                                "code": "validation_failed",
                                                "message": "Permintaan tidak dapat diproses.",
                                                "field": "title",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "document_fetch_failed": {
                                        "summary": "document_fetch_failed",
                                        "value": {
                                            "error": {
                                                "code": "document_fetch_failed",
                                                "message": "Dokumen pada document_url tidak dapat diunduh.",
                                                "field": "document_url",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "document_url_scheme": {
                                        "summary": "document_url_scheme",
                                        "value": {
                                            "error": {
                                                "code": "document_url_scheme",
                                                "message": "document_url harus memakai skema https.",
                                                "field": "document_url",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "document_url_blocked": {
                                        "summary": "document_url_blocked",
                                        "value": {
                                            "error": {
                                                "code": "document_url_blocked",
                                                "message": "document_url mengarah ke alamat jaringan yang tidak diizinkan.",
                                                "field": "document_url",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "document_too_large": {
                                        "summary": "document_too_large",
                                        "value": {
                                            "error": {
                                                "code": "document_too_large",
                                                "message": "Ukuran berkas melebihi batas 25 MB.",
                                                "field": "document_url",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "document_not_pdf": {
                                        "summary": "document_not_pdf",
                                        "value": {
                                            "error": {
                                                "code": "document_not_pdf",
                                                "message": "Berkas bukan PDF yang valid.",
                                                "field": "document_url",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "document_encrypted": {
                                        "summary": "document_encrypted",
                                        "value": {
                                            "error": {
                                                "code": "document_encrypted",
                                                "message": "PDF terproteksi password tidak dapat diproses.",
                                                "field": "document_url",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "document_not_sanitisable": {
                                        "summary": "document_not_sanitisable",
                                        "value": {
                                            "error": {
                                                "code": "document_not_sanitisable",
                                                "message": "PDF ini memuat konten aktif (skrip atau lampiran) yang tidak bisa dibersihkan. Ekspor ulang berkasnya sebagai PDF biasa lalu unggah kembali.",
                                                "field": "document_url",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/documents/{document}": {
            "get": {
                "operationId": "getDocument",
                "description": "Returns the document's metadata plus every signature request it is attached to, each with\nits status and, once completed, the hash and seal time of the executed copy produced there.\nThe file itself is served through the request-scoped link endpoints, not here.",
                "summary": "Get a document and the requests it is used in",
                "tags": [
                    "Documents"
                ],
                "parameters": [
                    {
                        "name": "document",
                        "in": "path",
                        "required": true,
                        "description": "`gid` of the document.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "0199a1c4-5aa0-7b33-a1b2-c3d4e5f6a7b8"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The document with every request it is attached to.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "allOf": [
                                                {
                                                    "$ref": "#/components/schemas/DocumentResource"
                                                },
                                                {
                                                    "type": "object",
                                                    "required": [
                                                        "signature_requests"
                                                    ]
                                                }
                                            ]
                                        }
                                    },
                                    "required": [
                                        "data"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "**404** \u2014 `error.code` is one of:\n\n- `not_found` \u2014 No resource with that `gid` exists for your application. Also the answer for a `gid` that belongs to another application \u2014 existence is never disclosed across applications.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "not_found": {
                                        "summary": "not_found",
                                        "value": {
                                            "error": {
                                                "code": "not_found",
                                                "message": "Sumber daya tidak ditemukan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/signing-sessions/exchange": {
            "post": {
                "operationId": "exchangeSigningSession",
                "description": "Turns the one-time `exchangeCode` your page received from the framed signing session\ninto the verified result: the session's final state, the signer's status, and the\nrequest's overall status. Codes are valid for 5 minutes and for a single redemption \u2014\na second call, an expired code, or a code from another application answers\n`422 exchange_code_invalid`. This is the only trustworthy front-channel signal: act on\nthis response or on webhooks, never on the browser message alone.",
                "summary": "Redeem an exchange code for the verified outcome",
                "tags": [
                    "Signing Sessions"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object",
                                "properties": {
                                    "code": {
                                        "type": "string",
                                        "description": "The `exchangeCode` handed to your page by the framed signing session when the signer finished.",
                                        "maxLength": 255
                                    }
                                },
                                "required": [
                                    "code"
                                ]
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The verified outcome: what the signer did, and where the request stands.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "$ref": "#/components/schemas/SigningSessionOutcomeResource"
                                        }
                                    },
                                    "required": [
                                        "data"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "**422** \u2014 `error.code` is one of:\n\n- `validation_failed` \u2014 The payload or query string is invalid. `field` names the first thing to fix and `message` says why. Correct the request; retrying it unchanged will fail again.\n- `exchange_code_invalid` \u2014 The exchange code is unknown, was already redeemed, has expired (5 minutes), or belongs to another application. Codes are single-use; read `GET /signature-requests/{gid}` for the current state instead.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "validation_failed": {
                                        "summary": "validation_failed",
                                        "value": {
                                            "error": {
                                                "code": "validation_failed",
                                                "message": "Permintaan tidak dapat diproses.",
                                                "field": "title",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "exchange_code_invalid": {
                                        "summary": "exchange_code_invalid",
                                        "value": {
                                            "error": {
                                                "code": "exchange_code_invalid",
                                                "message": "Exchange code tidak valid, sudah dipakai, atau sudah kedaluwarsa.",
                                                "field": "code",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/signing-sessions": {
            "post": {
                "operationId": "createSigningSession",
                "description": "Mints a single-use signing URL for one signer of one request, to be opened inside your\nown product instead of an emailed link. The URL is valid for 5 minutes and for one\nopening. The signer must be pending and, in a sequential request, it must be their turn\n(`422 signer_not_pending` otherwise). Opening the session rotates the signer's emailed\nlink, so create such signers with `delivery: \"embedded\"` \u2014 Lokasign then emails them no\ninvitation and no reminder. Send an `Idempotency-Key`: a retried call must not mint a\nsecond session and invalidate the URL you already opened.\n\n**Web page (iframe).** Pass `embedder_origin`, the origin of the page that frames the URL;\nit must be on your API key's `allowed_origins` (`403 embedder_origin_not_allowed`\notherwise), and the browser refuses to frame the URL anywhere else. When the signer\nfinishes, the framed page posts\n`{ source: \"lokasign\", type: \"esign:completed\" | \"esign:declined\", requestId, exchangeCode }`\nto your page, addressed to `embedder_origin`.\n\n**Native app (WebView).** Omit `embedder_origin` and open the URL directly in a WebView.\nThe page reports the same message through whichever bridge your WebView exposes \u2014 a\nJavaScript channel named `LokasignBridge` (`LokasignBridge.postMessage(json)`, Flutter\n`webview_flutter` and Android `addJavascriptInterface`), `window.webkit.messageHandlers.lokasign`\n(iOS `WKWebView`), `window.ReactNativeWebView`, or a `flutter_inappwebview` handler named\n`lokasign`. Pass `return_url` as well, and the page navigates there when the signer\nfinishes, with `lokasign_event`, `request_id` and `exchange_code` in the query string:\nintercept that navigation, close the WebView, and you need no bridge at all. An http(s)\n`return_url` must be on `allowed_origins` (`403 return_url_not_allowed`); an app scheme\n(`myapp://signing-done`) is accepted as is.\n\nEither way your backend redeems the exchange code through\n`POST /signing-sessions/exchange`. Treat the message and the navigation as cues, not as\nthe result.",
                "summary": "Create an embedded signing session",
                "tags": [
                    "Signing Sessions"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/CreateSigningSessionRequest"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The session and the single-use URL to frame.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "$ref": "#/components/schemas/SigningSessionResource"
                                        }
                                    },
                                    "required": [
                                        "data"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.\n- `embedder_origin_not_allowed` \u2014 `embedder_origin` is not on the API key's `allowed_origins`. Add the origin to the key in the dashboard, or send the origin the page is really served from.\n- `return_url_not_allowed` \u2014 An `http(s)` `return_url` must be on the API key's `allowed_origins`, and `javascript:`, `data:`, `file:` and similar schemes are never accepted. Register the origin on the key, or use your app's own scheme (`myapp://\u2026`).",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "embedder_origin_not_allowed": {
                                        "summary": "embedder_origin_not_allowed",
                                        "value": {
                                            "error": {
                                                "code": "embedder_origin_not_allowed",
                                                "message": "embedder_origin tidak terdaftar pada allowed_origins API key ini.",
                                                "field": "embedder_origin",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "return_url_not_allowed": {
                                        "summary": "return_url_not_allowed",
                                        "value": {
                                            "error": {
                                                "code": "return_url_not_allowed",
                                                "message": "return_url http(s) harus terdaftar pada allowed_origins API key ini, dan skema seperti javascript: atau data: tidak diterima.",
                                                "field": "return_url",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "409": {
                        "description": "**409** \u2014 `error.code` is one of:\n\n- `idempotency_key_reused` \u2014 This `Idempotency-Key` was already used within the last 24 hours with a different body. Use a new key for new work; reuse a key only to retry the identical request.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "idempotency_key_reused": {
                                        "summary": "idempotency_key_reused",
                                        "value": {
                                            "error": {
                                                "code": "idempotency_key_reused",
                                                "message": "Idempotency-Key ini sudah dipakai dengan isi permintaan yang berbeda.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "**422** \u2014 `error.code` is one of:\n\n- `validation_failed` \u2014 The payload or query string is invalid. `field` names the first thing to fix and `message` says why. Correct the request; retrying it unchanged will fail again.\n- `signer_not_pending` \u2014 The signer has already signed or declined, or \u2014 in a sequential request \u2014 it is not their turn yet. Read the request to see who is up.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "validation_failed": {
                                        "summary": "validation_failed",
                                        "value": {
                                            "error": {
                                                "code": "validation_failed",
                                                "message": "Permintaan tidak dapat diproses.",
                                                "field": "title",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "signer_not_pending": {
                                        "summary": "signer_not_pending",
                                        "value": {
                                            "error": {
                                                "code": "signer_not_pending",
                                                "message": "Signer tersebut sudah menandatangani, menolak, atau belum tiba gilirannya.",
                                                "field": "signer_gid",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/webhook": {
            "get": {
                "operationId": "getWebhook",
                "description": "Returns where your events are delivered, which of them the endpoint subscribes to,\nwhether delivery is switched on, whether a signing secret exists, and the full list of\nevent names you may subscribe to. The secret itself is never returned; it is readable\nonly in the answer to `POST /webhook/rotate-secret`.",
                "summary": "Get the webhook endpoint",
                "tags": [
                    "Webhooks"
                ],
                "responses": {
                    "200": {
                        "description": "The endpoint as configured, and the events available to subscribe to.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "$ref": "#/components/schemas/WebhookResource"
                                        }
                                    },
                                    "required": [
                                        "data"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            },
            "put": {
                "operationId": "updateWebhook",
                "description": "Replaces the configuration: `subscribed_events` is the complete list you end up with, so\nan event you leave out stops arriving. The call that *creates* the endpoint returns its\nsigning secret, which is the only time that value is readable \u2014 store it before you read\nthe rest of the response. Later calls keep the secret your receiver already verifies\nagainst and return null; if you do not have it, get a fresh one with\n`POST /webhook/rotate-secret`.\n\nSending `url: null` stops delivery: `is_active` goes false and nothing further is sent.\nThe endpoint is remembered rather than deleted, so the record of what was already sent \u2014\nwhich is what you consult precisely when changing endpoints \u2014 survives, and `url` still\nreads back. Nothing is queued while delivery is off: events that happen meanwhile are not\ndelivered later.",
                "summary": "Configure the webhook endpoint",
                "tags": [
                    "Webhooks"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/UpdateWebhookRequest"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The endpoint as it now stands, with `secret` set only when this call created one.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "description": "The endpoint as it now stands.",
                                            "$ref": "#/components/schemas/WebhookResource"
                                        },
                                        "secret": {
                                            "type": [
                                                "string",
                                                "null"
                                            ],
                                            "description": "The signing secret, returned only by the call that creates the endpoint. Store it now; it is never readable again. Null on every later call \u2014 if you do not have it, get a fresh one with `POST /webhook/rotate-secret`."
                                        }
                                    },
                                    "required": [
                                        "data",
                                        "secret"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "**422** \u2014 `error.code` is one of:\n\n- `validation_failed` \u2014 The payload or query string is invalid. `field` names the first thing to fix and `message` says why. Correct the request; retrying it unchanged will fail again.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "validation_failed": {
                                        "summary": "validation_failed",
                                        "value": {
                                            "error": {
                                                "code": "validation_failed",
                                                "message": "Permintaan tidak dapat diproses.",
                                                "field": "title",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/webhook/rotate-secret": {
            "post": {
                "operationId": "rotateWebhookSecret",
                "description": "Mints a new HMAC key and returns it once. **This breaks your receiver until you deploy\nthe new secret**: deliveries signed with the old key stop verifying the moment this\nreturns, and there is no overlap period. Rotate when a secret may have leaked, or on a\nschedule you control \u2014 and have the new value ready to deploy before you call.",
                "summary": "Rotate the webhook signing secret",
                "tags": [
                    "Webhooks"
                ],
                "responses": {
                    "200": {
                        "description": "The new signing secret, readable only in this response.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "secret": {
                                            "type": "string",
                                            "description": "The new secret. Verify deliveries with this from now on; the previous one stops working immediately."
                                        }
                                    },
                                    "required": [
                                        "secret"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "409": {
                        "description": "**409** \u2014 `error.code` is one of:\n\n- `webhook_not_configured` \u2014 The application has no active webhook endpoint, so there is nothing to sign for or to ping. Configure one with `PUT /webhook` first.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "webhook_not_configured": {
                                        "summary": "webhook_not_configured",
                                        "value": {
                                            "error": {
                                                "code": "webhook_not_configured",
                                                "message": "Aplikasi klien ini belum punya endpoint webhook aktif. Atur lebih dulu lewat PUT /webhook.",
                                                "field": "url",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/webhook/ping": {
            "post": {
                "operationId": "pingWebhook",
                "description": "POSTs a `webhook.ping` event to your endpoint through the same job, the same signature\nand the same retry ladder as a real event \u2014 which is the point: it proves your receiver\nverifies the HMAC, answers in time, and is reachable from here. It ignores\n`subscribed_events`, because you asked for this one, and its envelope carries no\n`signature_request_gid`, because there is no request behind it.\n\nAnswers immediately with the queued delivery; watch how it went with\n`GET /webhook-deliveries` or by looking it up by `delivery_id`.",
                "summary": "Send a test delivery",
                "tags": [
                    "Webhooks"
                ],
                "responses": {
                    "202": {
                        "description": "The queued test delivery. Its `status` is `pending` until the attempt runs.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "$ref": "#/components/schemas/WebhookDeliveryResource"
                                        }
                                    },
                                    "required": [
                                        "data"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "409": {
                        "description": "**409** \u2014 `error.code` is one of:\n\n- `webhook_not_configured` \u2014 The application has no active webhook endpoint, so there is nothing to sign for or to ping. Configure one with `PUT /webhook` first.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "webhook_not_configured": {
                                        "summary": "webhook_not_configured",
                                        "value": {
                                            "error": {
                                                "code": "webhook_not_configured",
                                                "message": "Aplikasi klien ini belum punya endpoint webhook aktif. Atur lebih dulu lewat PUT /webhook.",
                                                "field": "url",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/webhook-deliveries": {
            "get": {
                "operationId": "listWebhookDeliveries",
                "description": "Returns what the platform sent to your endpoint, newest first, 25 per page unless\n`per_page` says otherwise. Filter by `status` to find what never landed, or by `event`.\nEach row carries the exact body that was POSTed, so a failed delivery can be replayed\ninto your own handler \u2014 or re-sent with\n`POST /webhook-deliveries/{delivery_id}/retry`.",
                "summary": "List webhook deliveries",
                "tags": [
                    "Webhooks"
                ],
                "parameters": [
                    {
                        "name": "status",
                        "in": "query",
                        "description": "Only deliveries in this state. `failed` is the one to ask for after an outage.\n| |\n|---|\n| `pending` <br/> Queued, not yet attempted. |\n| `delivered` <br/> The endpoint answered 2xx. |\n| `failed` <br/> Every retry was exhausted without a 2xx. |",
                        "schema": {
                            "anyOf": [
                                {
                                    "$ref": "#/components/schemas/WebhookDeliveryStatusEnum"
                                },
                                {
                                    "type": "null"
                                }
                            ]
                        }
                    },
                    {
                        "name": "event",
                        "in": "query",
                        "description": "Only deliveries of this event, for example `signature_request.completed`.",
                        "schema": {
                            "type": [
                                "string",
                                "null"
                            ],
                            "maxLength": 50
                        }
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "description": "Rows per page, 1\u2013100. Default 25. Use `page` to move through the pages.",
                        "schema": {
                            "type": [
                                "integer",
                                "null"
                            ],
                            "minimum": 1,
                            "maximum": 100
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "One page of deliveries, newest first.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/WebhookDeliveryResource"
                                            },
                                            "description": "The rows of this page."
                                        },
                                        "links": {
                                            "type": "object",
                                            "properties": {
                                                "first": {
                                                    "type": [
                                                        "string",
                                                        "null"
                                                    ],
                                                    "description": "URL of the first page."
                                                },
                                                "last": {
                                                    "type": [
                                                        "string",
                                                        "null"
                                                    ],
                                                    "description": "URL of the last page."
                                                },
                                                "prev": {
                                                    "type": [
                                                        "string",
                                                        "null"
                                                    ],
                                                    "description": "URL of the previous page. Null on the first page."
                                                },
                                                "next": {
                                                    "type": [
                                                        "string",
                                                        "null"
                                                    ],
                                                    "description": "URL of the next page. Null on the last page."
                                                }
                                            },
                                            "required": [
                                                "first",
                                                "last",
                                                "prev",
                                                "next"
                                            ],
                                            "description": "Absolute URLs of neighbouring pages, ready to request as they are."
                                        },
                                        "meta": {
                                            "type": "object",
                                            "properties": {
                                                "current_page": {
                                                    "type": "integer",
                                                    "minimum": 1,
                                                    "description": "Number of this page, starting at 1."
                                                },
                                                "from": {
                                                    "type": [
                                                        "integer",
                                                        "null"
                                                    ],
                                                    "minimum": 1,
                                                    "description": "Position of the first row on this page within the whole result set (1-based). Null when the page is empty."
                                                },
                                                "last_page": {
                                                    "type": "integer",
                                                    "minimum": 1,
                                                    "description": "Number of the last page."
                                                },
                                                "links": {
                                                    "type": "array",
                                                    "description": "Generated paginator links.",
                                                    "items": {
                                                        "type": "object",
                                                        "properties": {
                                                            "url": {
                                                                "type": [
                                                                    "string",
                                                                    "null"
                                                                ],
                                                                "description": "URL of that page. Null for the disabled previous/next entry at either end."
                                                            },
                                                            "label": {
                                                                "type": "string",
                                                                "description": "Text of the link: a page number, or the localised previous/next label."
                                                            },
                                                            "active": {
                                                                "type": "boolean",
                                                                "description": "True for the entry of the current page."
                                                            }
                                                        },
                                                        "required": [
                                                            "url",
                                                            "label",
                                                            "active"
                                                        ]
                                                    }
                                                },
                                                "path": {
                                                    "type": [
                                                        "string",
                                                        "null"
                                                    ],
                                                    "description": "Base path for paginator generated URLs."
                                                },
                                                "per_page": {
                                                    "type": "integer",
                                                    "description": "Number of items shown per page.",
                                                    "minimum": 0
                                                },
                                                "to": {
                                                    "type": [
                                                        "integer",
                                                        "null"
                                                    ],
                                                    "description": "Number of the last item in the slice.",
                                                    "minimum": 1
                                                },
                                                "total": {
                                                    "type": "integer",
                                                    "description": "Total number of items being paginated.",
                                                    "minimum": 0
                                                }
                                            },
                                            "required": [
                                                "current_page",
                                                "from",
                                                "last_page",
                                                "links",
                                                "path",
                                                "per_page",
                                                "to",
                                                "total"
                                            ],
                                            "description": "Where this page sits in the whole result set."
                                        }
                                    },
                                    "required": [
                                        "data",
                                        "links",
                                        "meta"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "**422** \u2014 `error.code` is one of:\n\n- `validation_failed` \u2014 The payload or query string is invalid. `field` names the first thing to fix and `message` says why. Correct the request; retrying it unchanged will fail again.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "validation_failed": {
                                        "summary": "validation_failed",
                                        "value": {
                                            "error": {
                                                "code": "validation_failed",
                                                "message": "Permintaan tidak dapat diproses.",
                                                "field": "title",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/webhook-deliveries/{delivery}/retry": {
            "post": {
                "operationId": "retryWebhookDelivery",
                "description": "Puts a delivery that failed \u2014 or is still pending \u2014 back on the queue for one more\nattempt, signed the same way and carrying the same `X-Delivery-Id`, so your receiver\ndeduplicates it exactly as it would any retry. `attempt_count` keeps counting up rather\nthan resetting: it is the history of this delivery, and how hard the platform tried is\npart of the answer.\n\nA delivery that already landed cannot be retried and answers\n`409 delivery_already_delivered` \u2014 re-sending an event your handler has processed is\nwork nobody asked for.",
                "summary": "Retry a webhook delivery",
                "tags": [
                    "Webhooks"
                ],
                "parameters": [
                    {
                        "name": "delivery",
                        "in": "path",
                        "required": true,
                        "description": "The `delivery_id` of the delivery, as sent in the `X-Delivery-Id` header.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "0199a1c5-0e1a-7f22-9c3b-6d7e8f9a0b1c"
                    }
                ],
                "responses": {
                    "202": {
                        "description": "The delivery, queued for another attempt.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "$ref": "#/components/schemas/WebhookDeliveryResource"
                                        }
                                    },
                                    "required": [
                                        "data"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "**404** \u2014 `error.code` is one of:\n\n- `not_found` \u2014 No resource with that `gid` exists for your application. Also the answer for a `gid` that belongs to another application \u2014 existence is never disclosed across applications.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "not_found": {
                                        "summary": "not_found",
                                        "value": {
                                            "error": {
                                                "code": "not_found",
                                                "message": "Sumber daya tidak ditemukan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "409": {
                        "description": "**409** \u2014 `error.code` is one of:\n\n- `delivery_already_delivered` \u2014 That delivery already landed, so it cannot be retried. Your handler has seen this event; if it was not processed, replay it from the `payload` in `GET /webhook-deliveries`.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "delivery_already_delivered": {
                                        "summary": "delivery_already_delivered",
                                        "value": {
                                            "error": {
                                                "code": "delivery_already_delivered",
                                                "message": "Delivery ini sudah berhasil diterima, jadi tidak dapat dikirim ulang.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/signature-requests/{signatureRequest}/signers/{signer}/simulate": {
            "post": {
                "operationId": "simulateSigner",
                "description": "Acts for one signer of a test-mode request exactly as the signing page would: every\nsignature box gets an image of the signer's name, every input a placeholder value, and\nconsent is recorded \u2014 through the same code path as a real signature, so the request\nadvances, webhooks fire (`signer.signed`, then `signature_request.completed` with a\nSPECIMEN document) and the next signer of a sequential request is invited to the outbox.\n`decline` ends the request as `declined` with the `reason` given.\n\nThe request must be `sent` or `partially_signed`, and in a sequential request it must be\nthis signer's turn (`422 signer_not_pending` otherwise). Only for test-mode keys: a live\nkey answers `403 test_mode_only`.",
                "summary": "Simulate a signer signing or declining",
                "tags": [
                    "Test Mode"
                ],
                "parameters": [
                    {
                        "name": "signatureRequest",
                        "in": "path",
                        "required": true,
                        "description": "`gid` of the test-mode signature request.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "0199a1c4-3f1e-7d2a-8b3c-5e6f7a8b9c0d"
                    },
                    {
                        "name": "signer",
                        "in": "path",
                        "required": true,
                        "description": "`gid` of the signer to act for, from `signers[].gid`.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "0199a1c4-40aa-7e01-b2c3-d4e5f6a7b8c9"
                    }
                ],
                "requestBody": {
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object",
                                "properties": {
                                    "action": {
                                        "type": [
                                            "string",
                                            "null"
                                        ],
                                        "description": "`sign` (default) or `decline`.",
                                        "enum": [
                                            "sign",
                                            "decline",
                                            null
                                        ]
                                    },
                                    "reason": {
                                        "type": [
                                            "string",
                                            "null"
                                        ],
                                        "description": "Why the signer declines \u2014 required with `action: decline`, at least 3 characters.",
                                        "maxLength": 2000
                                    }
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "The request after the simulated action.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "allOf": [
                                                {
                                                    "$ref": "#/components/schemas/SignatureRequestResource"
                                                },
                                                {
                                                    "type": "object",
                                                    "required": [
                                                        "documents",
                                                        "signers",
                                                        "cc_recipients"
                                                    ]
                                                }
                                            ]
                                        }
                                    },
                                    "required": [
                                        "data"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.\n- `test_mode_only` \u2014 The endpoint exists only for test-mode keys (`esk_test_\u2026`), or the request is live data. Issue a test key in the dashboard (API & Webhook \u2192 Buat key \u2192 Uji) and repeat the call with it.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "test_mode_only": {
                                        "summary": "test_mode_only",
                                        "value": {
                                            "error": {
                                                "code": "test_mode_only",
                                                "message": "Endpoint ini hanya untuk key mode uji (esk_test_\u2026). Key live tidak bisa mensimulasikan tanda tangan atau membaca outbox uji.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "**404** \u2014 `error.code` is one of:\n\n- `not_found` \u2014 No resource with that `gid` exists for your application. Also the answer for a `gid` that belongs to another application \u2014 existence is never disclosed across applications.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "not_found": {
                                        "summary": "not_found",
                                        "value": {
                                            "error": {
                                                "code": "not_found",
                                                "message": "Sumber daya tidak ditemukan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "**422** \u2014 `error.code` is one of:\n\n- `validation_failed` \u2014 The payload or query string is invalid. `field` names the first thing to fix and `message` says why. Correct the request; retrying it unchanged will fail again.\n- `signer_not_pending` \u2014 The signer has already signed or declined, or \u2014 in a sequential request \u2014 it is not their turn yet. Read the request to see who is up.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "validation_failed": {
                                        "summary": "validation_failed",
                                        "value": {
                                            "error": {
                                                "code": "validation_failed",
                                                "message": "Permintaan tidak dapat diproses.",
                                                "field": "title",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "signer_not_pending": {
                                        "summary": "signer_not_pending",
                                        "value": {
                                            "error": {
                                                "code": "signer_not_pending",
                                                "message": "Signer tersebut sudah menandatangani, menolak, atau belum tiba gilirannya.",
                                                "field": "signer_gid",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/test-mail": {
            "get": {
                "operationId": "listTestMail",
                "description": "Every email a test-mode request would have sent \u2014 invitations, one-time codes, reminders,\nstatus notices and executed copies \u2014 newest first, 25 per page unless `per_page` says\notherwise. Each message carries the six-digit `codes` and the `links` found in it, so a\nsigning link or an OTP can be used without opening an inbox. Messages are kept 30 days.\nOnly for test-mode keys: a live key answers `403 test_mode_only`.",
                "summary": "List the test outbox",
                "tags": [
                    "Test Mode"
                ],
                "parameters": [
                    {
                        "name": "to",
                        "in": "query",
                        "description": "Only messages to this address (case-insensitive).",
                        "schema": {
                            "type": [
                                "string",
                                "null"
                            ],
                            "maxLength": 255
                        }
                    },
                    {
                        "name": "signature_request_gid",
                        "in": "query",
                        "description": "Only messages of this signature request.",
                        "schema": {
                            "type": [
                                "string",
                                "null"
                            ],
                            "format": "uuid"
                        }
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "description": "Rows per page, 1\u2013100. Default 25.",
                        "schema": {
                            "type": [
                                "integer",
                                "null"
                            ],
                            "minimum": 1,
                            "maximum": 100
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "One page of outbox messages, newest first.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/TestMailMessageResource"
                                            },
                                            "description": "The rows of this page."
                                        },
                                        "links": {
                                            "type": "object",
                                            "properties": {
                                                "first": {
                                                    "type": [
                                                        "string",
                                                        "null"
                                                    ],
                                                    "description": "URL of the first page."
                                                },
                                                "last": {
                                                    "type": [
                                                        "string",
                                                        "null"
                                                    ],
                                                    "description": "URL of the last page."
                                                },
                                                "prev": {
                                                    "type": [
                                                        "string",
                                                        "null"
                                                    ],
                                                    "description": "URL of the previous page. Null on the first page."
                                                },
                                                "next": {
                                                    "type": [
                                                        "string",
                                                        "null"
                                                    ],
                                                    "description": "URL of the next page. Null on the last page."
                                                }
                                            },
                                            "required": [
                                                "first",
                                                "last",
                                                "prev",
                                                "next"
                                            ],
                                            "description": "Absolute URLs of neighbouring pages, ready to request as they are."
                                        },
                                        "meta": {
                                            "type": "object",
                                            "properties": {
                                                "current_page": {
                                                    "type": "integer",
                                                    "minimum": 1,
                                                    "description": "Number of this page, starting at 1."
                                                },
                                                "from": {
                                                    "type": [
                                                        "integer",
                                                        "null"
                                                    ],
                                                    "minimum": 1,
                                                    "description": "Position of the first row on this page within the whole result set (1-based). Null when the page is empty."
                                                },
                                                "last_page": {
                                                    "type": "integer",
                                                    "minimum": 1,
                                                    "description": "Number of the last page."
                                                },
                                                "links": {
                                                    "type": "array",
                                                    "description": "Generated paginator links.",
                                                    "items": {
                                                        "type": "object",
                                                        "properties": {
                                                            "url": {
                                                                "type": [
                                                                    "string",
                                                                    "null"
                                                                ],
                                                                "description": "URL of that page. Null for the disabled previous/next entry at either end."
                                                            },
                                                            "label": {
                                                                "type": "string",
                                                                "description": "Text of the link: a page number, or the localised previous/next label."
                                                            },
                                                            "active": {
                                                                "type": "boolean",
                                                                "description": "True for the entry of the current page."
                                                            }
                                                        },
                                                        "required": [
                                                            "url",
                                                            "label",
                                                            "active"
                                                        ]
                                                    }
                                                },
                                                "path": {
                                                    "type": [
                                                        "string",
                                                        "null"
                                                    ],
                                                    "description": "Base path for paginator generated URLs."
                                                },
                                                "per_page": {
                                                    "type": "integer",
                                                    "description": "Number of items shown per page.",
                                                    "minimum": 0
                                                },
                                                "to": {
                                                    "type": [
                                                        "integer",
                                                        "null"
                                                    ],
                                                    "description": "Number of the last item in the slice.",
                                                    "minimum": 1
                                                },
                                                "total": {
                                                    "type": "integer",
                                                    "description": "Total number of items being paginated.",
                                                    "minimum": 0
                                                }
                                            },
                                            "required": [
                                                "current_page",
                                                "from",
                                                "last_page",
                                                "links",
                                                "path",
                                                "per_page",
                                                "to",
                                                "total"
                                            ],
                                            "description": "Where this page sits in the whole result set."
                                        }
                                    },
                                    "required": [
                                        "data",
                                        "links",
                                        "meta"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.\n- `test_mode_only` \u2014 The endpoint exists only for test-mode keys (`esk_test_\u2026`), or the request is live data. Issue a test key in the dashboard (API & Webhook \u2192 Buat key \u2192 Uji) and repeat the call with it.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    },
                                    "test_mode_only": {
                                        "summary": "test_mode_only",
                                        "value": {
                                            "error": {
                                                "code": "test_mode_only",
                                                "message": "Endpoint ini hanya untuk key mode uji (esk_test_\u2026). Key live tidak bisa mensimulasikan tanda tangan atau membaca outbox uji.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "**422** \u2014 `error.code` is one of:\n\n- `validation_failed` \u2014 The payload or query string is invalid. `field` names the first thing to fix and `message` says why. Correct the request; retrying it unchanged will fail again.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "validation_failed": {
                                        "summary": "validation_failed",
                                        "value": {
                                            "error": {
                                                "code": "validation_failed",
                                                "message": "Permintaan tidak dapat diproses.",
                                                "field": "title",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/document-uploads": {
            "post": {
                "operationId": "createDocumentUpload",
                "description": "Returns a short-lived `upload_url` that takes one PDF for your application, for when you\ncannot send the file as multipart or give a public `document_url` \u2014 typically an AI agent\nacting for a person who has the file. Either hand the link to that person (opened in a\nbrowser, it shows a page to pick the PDF), or send the file yourself:\n`curl -X PUT --data-binary @contract.pdf -H \"Content-Type: application/pdf\" <upload_url>`.\nThe link lasts 15 minutes, accepts exactly one file, and applies the same checks as\n`POST /documents`; a refused file leaves it open for another try. Then call\n`GET /document-uploads/{gid}` until `status` is `completed` and use `document.gid` as\n`documents[].document_gid` when creating a signature request. Errors from the link itself\nuse the codes `upload_link_invalid`, `upload_link_expired` and `upload_link_used`.",
                "summary": "Create an upload link",
                "tags": [
                    "Documents"
                ],
                "requestBody": {
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/StoreDocumentUploadRequest"
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "The new link. `upload_url` appears only in this response \u2014 keep it until the file is sent.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "$ref": "#/components/schemas/DocumentUploadResource"
                                        }
                                    },
                                    "required": [
                                        "data"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "409": {
                        "description": "**409** \u2014 `error.code` is one of:\n\n- `idempotency_key_reused` \u2014 This `Idempotency-Key` was already used within the last 24 hours with a different body. Use a new key for new work; reuse a key only to retry the identical request.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "idempotency_key_reused": {
                                        "summary": "idempotency_key_reused",
                                        "value": {
                                            "error": {
                                                "code": "idempotency_key_reused",
                                                "message": "Idempotency-Key ini sudah dipakai dengan isi permintaan yang berbeda.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "**422** \u2014 `error.code` is one of:\n\n- `validation_failed` \u2014 The payload or query string is invalid. `field` names the first thing to fix and `message` says why. Correct the request; retrying it unchanged will fail again.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "validation_failed": {
                                        "summary": "validation_failed",
                                        "value": {
                                            "error": {
                                                "code": "validation_failed",
                                                "message": "Permintaan tidak dapat diproses.",
                                                "field": "title",
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/document-uploads/{documentUpload}": {
            "get": {
                "operationId": "getDocumentUpload",
                "description": "Reports whether the link has taken a file. Once `status` is `completed`, `document` is the\nstored PDF; use its `gid` as `documents[].document_gid`. Poll no more than every few\nseconds, and stop at `expired` \u2014 create a new link instead. `upload_url` is null here:\nonly the response that created the link carries it.",
                "summary": "Get an upload link",
                "tags": [
                    "Documents"
                ],
                "parameters": [
                    {
                        "name": "documentUpload",
                        "in": "path",
                        "required": true,
                        "description": "`gid` of the upload link.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "0199a1c4-5aa0-7b33-a1b2-c3d4e5f6a7b8"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The link and, once it has taken a file, the document.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "$ref": "#/components/schemas/DocumentUploadResource"
                                        }
                                    },
                                    "required": [
                                        "data"
                                    ]
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "**401** \u2014 `error.code` is one of:\n\n- `unauthorized` \u2014 The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "unauthorized": {
                                        "summary": "unauthorized",
                                        "value": {
                                            "error": {
                                                "code": "unauthorized",
                                                "message": "API key tidak valid atau tidak dikirim.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "**403** \u2014 `error.code` is one of:\n\n- `application_inactive` \u2014 The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "application_inactive": {
                                        "summary": "application_inactive",
                                        "value": {
                                            "error": {
                                                "code": "application_inactive",
                                                "message": "Aplikasi klien ini sedang dinonaktifkan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "**404** \u2014 `error.code` is one of:\n\n- `not_found` \u2014 No resource with that `gid` exists for your application. Also the answer for a `gid` that belongs to another application \u2014 existence is never disclosed across applications.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "not_found": {
                                        "summary": "not_found",
                                        "value": {
                                            "error": {
                                                "code": "not_found",
                                                "message": "Sumber daya tidak ditemukan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "**429** \u2014 `error.code` is one of:\n\n- `rate_limited` \u2014 Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "rate_limited": {
                                        "summary": "rate_limited",
                                        "value": {
                                            "error": {
                                                "code": "rate_limited",
                                                "message": "Terlalu banyak permintaan. Coba lagi beberapa saat lagi.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    },
                    "500": {
                        "description": "**500** \u2014 `error.code` is one of:\n\n- `server_error` \u2014 Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support.",
                        "headers": {
                            "X-Request-Id": {
                                "description": "The same value as `error.request_id`; quote it when contacting support.",
                                "schema": {
                                    "type": "string",
                                    "format": "uuid"
                                }
                            }
                        },
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/ApiError"
                                },
                                "examples": {
                                    "server_error": {
                                        "summary": "server_error",
                                        "value": {
                                            "error": {
                                                "code": "server_error",
                                                "message": "Terjadi kesalahan di server. Sertakan request_id saat menghubungi dukungan.",
                                                "field": null,
                                                "request_id": "0199a1c4-2b7e-7c11-9d3a-4f5e6a7b8c9d"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    },
    "components": {
        "securitySchemes": {
            "apiKey": {
                "type": "http",
                "description": "Your application's API key, issued from the dashboard at `/api-settings`: `Authorization: Bearer esk_live_\u2026`. Clients that reserve `Authorization` for something else (Claude custom connectors keep it for OAuth) may send the same key as `X-Api-Key: esk_live_\u2026` instead; the bearer token wins when both are present. Every operation requires it; every query it runs is confined to the application the key belongs to.",
                "scheme": "bearer"
            }
        },
        "schemas": {
            "ApplicationResource": {
                "type": "object",
                "properties": {
                    "gid": {
                        "type": "string",
                        "description": "Public identifier of the application."
                    },
                    "name": {
                        "type": "string",
                        "description": "Name of the application as registered by your organisation, for example \"Backend Produksi\"."
                    },
                    "is_active": {
                        "type": "boolean",
                        "description": "True while the application may call the API. A deactivated application answers `403 application_inactive` to everything."
                    },
                    "organisation": {
                        "type": "string",
                        "description": "Name of the organisation (tenant) that owns the application."
                    },
                    "api_key": {
                        "type": "object",
                        "description": "The API key this request was made with.",
                        "properties": {
                            "gid": {
                                "type": "string",
                                "description": "Public identifier of the key, as shown in the dashboard."
                            },
                            "name": {
                                "type": "string",
                                "description": "Label given to the key when it was created."
                            },
                            "prefix": {
                                "type": "string",
                                "description": "Leading characters of the key (16 for `esk_live_`/`esk_test_` keys, 12 for older ones). The rest is never shown again."
                            },
                            "is_primary": {
                                "type": "boolean",
                                "description": "True for the application's primary key."
                            },
                            "mode": {
                                "type": "string",
                                "description": "`live` or `test`. With a `test` key every request and document is test data, visible only to test keys: nothing is emailed (read it from `GET /test-mail`), executed documents carry a SPECIMEN watermark and no platform seal, and signers can be simulated with `POST /signature-requests/{gid}/signers/{signerGid}/simulate`."
                            },
                            "allowed_origins": {
                                "type": "array",
                                "description": "Origins (scheme and host) allowed to frame embedded signing sessions minted with this key. Empty when embedded signing is not set up.",
                                "items": {
                                    "type": "string"
                                }
                            },
                            "created_at": {
                                "type": [
                                    "string",
                                    "null"
                                ],
                                "description": "When the key was created (ISO-8601)."
                            }
                        },
                        "required": [
                            "gid",
                            "name",
                            "prefix",
                            "is_primary",
                            "mode",
                            "allowed_origins",
                            "created_at"
                        ]
                    },
                    "webhook": {
                        "type": [
                            "object",
                            "null"
                        ],
                        "description": "The webhook endpoint configured for the application in the dashboard. Null when none is configured \u2014 no events are delivered until one is.",
                        "properties": {
                            "url": {
                                "type": "string",
                                "description": "URL the platform POSTs events to."
                            },
                            "subscribed_events": {
                                "type": "array",
                                "description": "Event names the endpoint subscribes to. Events outside this list are not delivered.",
                                "items": {
                                    "type": "string"
                                }
                            },
                            "is_active": {
                                "type": "boolean",
                                "description": "False when deliveries are paused for this endpoint."
                            }
                        },
                        "required": [
                            "url",
                            "subscribed_events",
                            "is_active"
                        ]
                    },
                    "active_templates": {
                        "type": "integer",
                        "description": "Number of templates that are active, i.e. usable in `POST /signature-requests`.",
                        "minimum": 0
                    },
                    "limits": {
                        "type": "object",
                        "description": "The limits that apply to this application. Read them rather than hard-coding the numbers.",
                        "properties": {
                            "requests_per_minute": {
                                "type": "integer",
                                "description": "Requests per minute allowed for one API key before `429 rate_limited`."
                            },
                            "document_max_bytes": {
                                "type": "integer",
                                "description": "Largest document accepted, in bytes, whether uploaded or fetched from a URL."
                            },
                            "expiry_max_days": {
                                "type": "integer",
                                "description": "Largest value accepted for `expires_in_days`."
                            },
                            "final_document_link_hours": {
                                "type": "integer",
                                "description": "How long a link from `GET /signature-requests/{gid}/document` stays valid, in hours."
                            },
                            "document_preview_link_minutes": {
                                "type": "integer",
                                "description": "How long a link from `GET /signature-requests/{gid}/documents` stays valid, in minutes."
                            },
                            "reminder_cooldown_hours": {
                                "type": "integer",
                                "description": "Minimum gap between two reminders to the same signer, in hours."
                            }
                        },
                        "required": [
                            "requests_per_minute",
                            "document_max_bytes",
                            "expiry_max_days",
                            "final_document_link_hours",
                            "document_preview_link_minutes",
                            "reminder_cooldown_hours"
                        ]
                    }
                },
                "required": [
                    "gid",
                    "name",
                    "is_active",
                    "organisation",
                    "api_key",
                    "webhook",
                    "active_templates",
                    "limits"
                ],
                "title": "ApplicationResource",
                "description": "The application your API key belongs to, the key itself, how its webhook endpoint is configured, and the limits that apply to it \u2014 everything a client needs to confirm it is talking to the right place with the right credential. Secrets never appear here: the key is identified by its prefix, and the webhook secret is only ever shown once, in the dashboard, when it is created or rotated. The comments above each key become the property descriptions of the OpenAPI document. @mixin Application /"
            },
            "AuditEventResource": {
                "type": "object",
                "properties": {
                    "gid": {
                        "type": "string",
                        "description": "Public identifier of the entry. `chain.broken_at_gid` names an entry by this value."
                    },
                    "event": {
                        "description": "What happened. Stable machine value; see the enum for the meaning of each.\n| |\n|---|\n| `request_created` <br/> The request row was created. First entry of every chain, the only one with a NULL `prev_hash`. |\n| `invitation_sent` <br/> An invitation email went out to a signer. |\n| `viewed` <br/> A signer opened the document. |\n| `pages_reviewed` <br/> Every page of every document was displayed to the signer before they agreed (Spesifikasi Kekuatan Bukti K-09). Written immediately before `CONSENT_GIVEN`, and separate from it, because they answer different denials: consent answers \"I never agreed\", this one answers \"I never saw it\". Carries how long each page was visible, and \u2014 for a flow where no page was displayed at all, i.e. bulk signing (R68) \u2014 says so in as many words rather than being omitted. |\n| `consent_given` <br/> A signer accepted the electronic-signature disclosure \u2014 records locale + disclosure version (R36/R49). |\n| `signed` <br/> A signer submitted their fields. |\n| `declined` <br/> A signer refused, with the reason in `metadata`. |\n| `reminder_sent` <br/> A reminder was sent, automatic or manual (R38). |\n| `expired` <br/> The request passed `expires_at` without completing (R39). |\n| `completed` <br/> Every signer signed. Written the moment the last signature lands, *before* any artefact exists: R50 keeps the request's status independent of finalisation, so that the seal failing does not un-sign a document that really was signed. `FINALIZED` is the entry that says an artefact now exists. |\n| `finalized` <br/> The final document was composed, hashed, and sealed (FR-8/FR-8d, R10/R11/R50). |\n| `seal_failed` <br/> A sealing attempt failed (R50). Recorded rather than only logged because it is the difference between \"not finished      * yet\" and \"finished but undistributable\", and the sender is entitled to see which. |\n| `evidence_exported` <br/> An evidence package was exported, with the archive's own digest in `metadata` (Spesifikasi Kekuatan Bukti K-12). The receipt for a copy leaving our custody. Recorded because the package can be handed on \u2014 to a lawyer, an expert, a court \u2014 and the question \"is this the package they were      * given\" has to be answerable afterwards. It is also the one entry whose digest cannot live inside the thing it describes. |\n| `voided` <br/> The sender withdrew the request. |\n| `signer_corrected` <br/> A signer's name or address was corrected before they acted, and their invitation was re-issued to the new address (FR-13). Recorded because it changes *who* the document was put in front of, which is the one thing an evidence trail exists to answer. The metadata keeps both addresses: without the old one, the earlier `invitation_sent` entry reads as having gone to somebody it did not. |\n| `identity_verification_submitted` <br/> Fase 2 \u2014 identity documents submitted to the internal RA. |\n| `certificate_issued` <br/> Fase 2 \u2014 the internal CA issued a certificate to a signer. |\n| `certificate_revoked` <br/> Fase 2 \u2014 a certificate was revoked. |",
                        "$ref": "#/components/schemas/AuditEventTypeEnum"
                    },
                    "occurred_at": {
                        "type": "string",
                        "description": "When it happened (ISO-8601)."
                    },
                    "signer_gid": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "Public identifier of the signer this entry is about. Null for request-level events such as `request_created`."
                    },
                    "signer_name": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "Name of that signer at the time. Null for request-level events."
                    },
                    "ip_address": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "IP address the action came from, as seen by the platform. Null for actions the platform took itself."
                    },
                    "metadata": {
                        "type": [
                            "array",
                            "null"
                        ],
                        "description": "Event-specific details, for example the consent text version or the decline reason. Keys vary by `event`; may be null.",
                        "items": {}
                    },
                    "prev_hash": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "Hash of the previous entry, hex SHA-256. Null on the first entry of a request. Storing these lets you re-verify the sequence you hold against the one the platform wrote."
                    },
                    "entry_hash": {
                        "type": "string",
                        "description": "Hash of this entry over its own content plus `prev_hash`, hex SHA-256."
                    }
                },
                "required": [
                    "gid",
                    "event",
                    "occurred_at",
                    "ip_address",
                    "metadata",
                    "prev_hash",
                    "entry_hash"
                ],
                "title": "AuditEventResource",
                "description": "One entry of a request's hash-chained audit trail: what happened, when, to whom, and the hashes that let you verify the sequence yourself. Both hashes are included because they are what makes the chain checkable *outside* this system: a client that stores what it was given can later prove the sequence it holds is the sequence we wrote. A client can show this list as a contract's history. `broken_at` from `AuditTrail::verify()` stays unexposed \u2014 it is an internal row id, and R46 puts those off limits \u2014 but `broken_at_gid` beside it does not, so a client is now told *which* entry failed rather than only that one did. Naming it was impossible until entries had a public identifier of their own. @mixin AuditEvent /"
            },
            "AuditEventTypeEnum": {
                "type": "string",
                "description": "Event catalogue of the hash-chained document audit trail (SCHEMA.md \u00a72.7). Distinct from `ActivityLogEventTypeEnum`, which covers account/organisation events and is not hash-chained. Rows here are append-only at the database grant level (R32-R33).\n| |\n|---|\n| `request_created` <br/> The request row was created. First entry of every chain, the only one with a NULL `prev_hash`. |\n| `invitation_sent` <br/> An invitation email went out to a signer. |\n| `viewed` <br/> A signer opened the document. |\n| `pages_reviewed` <br/> Every page of every document was displayed to the signer before they agreed (Spesifikasi Kekuatan Bukti K-09). Written immediately before `CONSENT_GIVEN`, and separate from it, because they answer different denials: consent answers \"I never agreed\", this one answers \"I never saw it\". Carries how long each page was visible, and \u2014 for a flow where no page was displayed at all, i.e. bulk signing (R68) \u2014 says so in as many words rather than being omitted. |\n| `consent_given` <br/> A signer accepted the electronic-signature disclosure \u2014 records locale + disclosure version (R36/R49). |\n| `signed` <br/> A signer submitted their fields. |\n| `declined` <br/> A signer refused, with the reason in `metadata`. |\n| `reminder_sent` <br/> A reminder was sent, automatic or manual (R38). |\n| `expired` <br/> The request passed `expires_at` without completing (R39). |\n| `completed` <br/> Every signer signed. Written the moment the last signature lands, *before* any artefact exists: R50 keeps the request's status independent of finalisation, so that the seal failing does not un-sign a document that really was signed. `FINALIZED` is the entry that says an artefact now exists. |\n| `finalized` <br/> The final document was composed, hashed, and sealed (FR-8/FR-8d, R10/R11/R50). |\n| `seal_failed` <br/> A sealing attempt failed (R50). Recorded rather than only logged because it is the difference between \"not finished      * yet\" and \"finished but undistributable\", and the sender is entitled to see which. |\n| `evidence_exported` <br/> An evidence package was exported, with the archive's own digest in `metadata` (Spesifikasi Kekuatan Bukti K-12). The receipt for a copy leaving our custody. Recorded because the package can be handed on \u2014 to a lawyer, an expert, a court \u2014 and the question \"is this the package they were      * given\" has to be answerable afterwards. It is also the one entry whose digest cannot live inside the thing it describes. |\n| `voided` <br/> The sender withdrew the request. |\n| `signer_corrected` <br/> A signer's name or address was corrected before they acted, and their invitation was re-issued to the new address (FR-13). Recorded because it changes *who* the document was put in front of, which is the one thing an evidence trail exists to answer. The metadata keeps both addresses: without the old one, the earlier `invitation_sent` entry reads as having gone to somebody it did not. |\n| `identity_verification_submitted` <br/> Fase 2 \u2014 identity documents submitted to the internal RA. |\n| `certificate_issued` <br/> Fase 2 \u2014 the internal CA issued a certificate to a signer. |\n| `certificate_revoked` <br/> Fase 2 \u2014 a certificate was revoked. |",
                "enum": [
                    "request_created",
                    "invitation_sent",
                    "viewed",
                    "pages_reviewed",
                    "consent_given",
                    "signed",
                    "declined",
                    "reminder_sent",
                    "expired",
                    "completed",
                    "finalized",
                    "seal_failed",
                    "evidence_exported",
                    "voided",
                    "signer_corrected",
                    "identity_verification_submitted",
                    "certificate_issued",
                    "certificate_revoked"
                ],
                "title": "AuditEventTypeEnum"
            },
            "CheckTemplateDataRequest": {
                "type": "object",
                "description": "Payload of `POST /api/v1/templates/{code}/check`: the data you intend to send for one\ntemplate-backed document, so the platform can say what is missing or malformed before you\ncreate a request. Every field is optional \u2014 an empty body lists everything the template\nrequires.\n\nThe three keys mirror the `documents[]` entry and the `signers[].role_key` values of\n`POST /signature-requests`, so a payload that passes here can be copied across unchanged.",
                "properties": {
                    "merge_fields": {
                        "type": "object",
                        "description": "The `merge_fields` you would send for the document, keyed by tag.",
                        "examples": [
                            {
                                "signer1.party_name": "PT Musik Nusantara",
                                "signer1.deed_date": "2019-03-14"
                            }
                        ],
                        "additionalProperties": {
                            "type": [
                                "string",
                                "null"
                            ]
                        }
                    },
                    "merge_rows": {
                        "type": "object",
                        "description": "The `merge_rows` you would send, keyed by collection name (the tag prefix the template chose; see `collections` in `GET /templates/{code}`).",
                        "examples": [
                            {
                                "songs": [
                                    {
                                        "NO": "1",
                                        "TITLE": "Senja di Jakarta"
                                    }
                                ]
                            }
                        ],
                        "additionalProperties": {
                            "type": "array",
                            "items": {
                                "type": "object",
                                "additionalProperties": {
                                    "type": [
                                        "string",
                                        "null"
                                    ]
                                }
                            }
                        }
                    },
                    "signer_role_keys": {
                        "type": "array",
                        "description": "The `role_key` of every signer you would send, so unfilled template roles are reported.",
                        "examples": [
                            [
                                "party",
                                "operator"
                            ]
                        ],
                        "items": {
                            "type": "string"
                        }
                    }
                },
                "title": "CheckTemplateDataRequest"
            },
            "CreateSigningSessionRequest": {
                "type": "object",
                "description": "Payload of `POST /api/v1/signing-sessions`: which signer of which request is about to sign\ninside your own page, and from which origin.\n\nBoth gids are resolved through the application-scoped query layer in the controller rather\nthan validated with `exists:` here: an `exists` rule would answer across every tenant on\nthe platform, turning this form into a way to probe whether a given gid exists somewhere\nelse (R53).\n\n`embedder_origin` is a bare scheme-and-host, because that is what a browser sends as `Origin`\nand what `frame-ancestors` matches \u2014 a value carrying a path would be accepted here and then\nsilently never match anything. It is optional since a native app opens the URL top-level in\na WebView, where there is no page to frame it and no origin to name.\n\n`return_url` is checked against the key's allowlist in `EmbeddedSigningSessions`, not here:\nthe rule needs the API key, and the refusal is a 403 of its own rather than a 422.",
                "properties": {
                    "signature_request_gid": {
                        "type": "string",
                        "format": "uuid",
                        "description": "`gid` of the request the signer belongs to. It must be `sent` or `partially_signed`."
                    },
                    "signer_gid": {
                        "type": "string",
                        "format": "uuid",
                        "description": "`gid` of the signer who will sign in this session. They must be pending and, in a sequential request, it must be their turn."
                    },
                    "embedder_origin": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "Origin of the web page that will frame the signing URL in an iframe, as scheme and host only (for example `https:app.example.com`). It must be listed in your API key's `allowed_origins`; the browser refuses any other embedder. Omit it for a native app that opens the URL directly in a WebView \u2014 the page then refuses to be framed anywhere and reports to the app through a WebView bridge or `return_url` instead.",
                        "pattern": "#^https?://[^/\\s]+$#",
                        "maxLength": 255
                    },
                    "return_url": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "Where the signing page navigates when the signer signs or declines, with `lokasign_event` (`esign:completed` or `esign:declined`), `request_id` and `exchange_code` added to its query string. Meant for native apps: intercept the navigation in your WebView, close it, and redeem `exchange_code` from your backend. An `https:` (or `http:`) URL must be on your API key's `allowed_origins`; an app scheme such as `myapp:signing-done` is accepted as is. Omit it to stay on the confirmation screen.",
                        "pattern": "#^[a-zA-Z][a-zA-Z0-9+.\\-]*:[^\\s]+$#",
                        "maxLength": 2048
                    },
                    "locale": {
                        "anyOf": [
                            {
                                "description": "Language of the framed signing page (`id` or `en`): the language your user is reading your page in. Overrides the signer's and the request's locale for this session.\n\n| |\n|---|\n| `id` <br/> Bahasa Indonesia \u2014 the platform default. |\n| `en` <br/> English. |",
                                "$ref": "#/components/schemas/LocaleEnum"
                            },
                            {
                                "type": "null"
                            }
                        ]
                    }
                },
                "required": [
                    "signature_request_gid",
                    "signer_gid"
                ],
                "title": "CreateSigningSessionRequest"
            },
            "DocumentResource": {
                "type": "object",
                "properties": {
                    "gid": {
                        "type": "string",
                        "description": "Public identifier of the document (UUIDv7). Pass it as `documents[].document_gid` to reuse the file in a new request."
                    },
                    "test": {
                        "type": "boolean",
                        "description": "True when the document belongs to test mode. Only test-mode keys see it or can use it."
                    },
                    "filename": {
                        "type": "string",
                        "description": "File name as uploaded, or as given in `filename` when fetched from a URL."
                    },
                    "mime_type": {
                        "type": "string",
                        "description": "Always `application/pdf`: only PDFs are accepted, and the type is read from the bytes rather than from the upload."
                    },
                    "page_count": {
                        "type": "integer",
                        "description": "Number of pages. 0 while the page count has not been determined yet."
                    },
                    "status": {
                        "description": "Processing state of the stored file.\n| |\n|---|\n| `draft` <br/> Uploaded, not yet attached to a sent request. |\n| `active` <br/> Attached to at least one request that is currently out for signature. |\n| `completed` <br/> Every request using it has finished. |\n| `voided` <br/> Withdrawn \u2014 must not be attached to any new request. |",
                        "$ref": "#/components/schemas/DocumentStatusEnum"
                    },
                    "created_at": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "When the document was stored (ISO-8601)."
                    },
                    "signature_requests": {
                        "type": "array",
                        "description": "Every signature request this document is attached to, with the outcome it reached there. Only present on `GET /documents/{gid}`.",
                        "items": {
                            "type": "object",
                            "properties": {
                                "gid": {
                                    "type": "string",
                                    "description": "Public identifier of the request."
                                },
                                "title": {
                                    "type": "string",
                                    "description": "Title of the request."
                                },
                                "status": {
                                    "description": "Where that request is in its lifecycle.\n| |\n|---|\n| `draft` <br/> Being composed in the wizard. No signer has been invited yet. |\n| `sent` <br/> Invitations dispatched, nobody has signed. |\n| `partially_signed` <br/> At least one but not all signers have signed. |\n| `completed` <br/> Every signer signed; final documents sealed and downloadable (R50). |\n| `declined` <br/> A signer refused. Terminal \u2014 a new request is needed to try again. |\n| `expired` <br/> Passed `expires_at` before completion (R39). Terminal. |\n| `voided` <br/> Withdrawn by the sender before completion. Terminal. |",
                                    "$ref": "#/components/schemas/SignatureRequestStatusEnum"
                                },
                                "external_ref": {
                                    "type": [
                                        "string",
                                        "null"
                                    ],
                                    "description": "The request's `external_ref`. Null when none was given."
                                },
                                "final_hash": {
                                    "type": "string",
                                    "description": "Lowercase hex SHA-256 of the executed copy produced by that request. Null until the request completed."
                                },
                                "sealed_at": {
                                    "type": [
                                        "string",
                                        "null"
                                    ],
                                    "description": "When the executed copy was sealed (ISO-8601). Null until sealed."
                                },
                                "completed_at": {
                                    "type": [
                                        "string",
                                        "null"
                                    ],
                                    "description": "When that request completed (ISO-8601). Null until it did."
                                }
                            },
                            "required": [
                                "gid",
                                "title",
                                "status",
                                "external_ref",
                                "final_hash",
                                "sealed_at",
                                "completed_at"
                            ]
                        }
                    }
                },
                "required": [
                    "gid",
                    "test",
                    "filename",
                    "mime_type",
                    "page_count",
                    "status",
                    "created_at"
                ],
                "title": "DocumentResource",
                "description": "A PDF stored under your application \u2014 uploaded, fetched from a URL, or rendered from a template \u2014 and, on the detail endpoint, every signature request it is attached to. The reverse listing is the point of the detail endpoint: one uploaded PDF can back several signature requests, and the final artefact belongs to the *pair* \u2014 so `final_hash` and `sealed_at` are reported per request rather than on the document itself. `storage_path` is never exposed. It is an internal disk location, and a client has no use for it that a signed download URL does not serve better. @mixin Document /"
            },
            "DocumentStatusEnum": {
                "type": "string",
                "description": "Lifecycle of an uploaded source document (SCHEMA.md \u00a72.2). Note this is the *document's* own status, not the signature request's \u2014 one document can be reused by several requests (e.g. re-sent after a decline), which is why the finalisation artefacts live on the `signature_request_documents` pivot instead.\n| |\n|---|\n| `draft` <br/> Uploaded, not yet attached to a sent request. |\n| `active` <br/> Attached to at least one request that is currently out for signature. |\n| `completed` <br/> Every request using it has finished. |\n| `voided` <br/> Withdrawn \u2014 must not be attached to any new request. |",
                "enum": [
                    "draft",
                    "active",
                    "completed",
                    "voided"
                ],
                "title": "DocumentStatusEnum"
            },
            "DocumentUploadResource": {
                "type": "object",
                "properties": {
                    "gid": {
                        "type": "string",
                        "description": "Public identifier of the upload link. Pass it to `GET /document-uploads/{gid}` to see whether a file has arrived."
                    },
                    "test": {
                        "type": "boolean",
                        "description": "True when the link was created with a test-mode key; the document it produces is test data too."
                    },
                    "status": {
                        "description": "`pending` while waiting for a file, `completed` once one was accepted, `expired` when 15 minutes passed without one. A link takes exactly one file.\n| |\n|---|\n| `pending` <br/> Waiting for a file. |\n| `completed` <br/> A file was accepted and became a document; the link takes no more. |\n| `expired` <br/> No file arrived before `expires_at`; the link takes no more. |",
                        "$ref": "#/components/schemas/DocumentUploadStatusEnum"
                    },
                    "upload_url": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "Where the file goes, valid for 15 minutes and for one file. Open it in a browser to pick a PDF, or send the bytes yourself: `PUT` with `Content-Type: application/pdf` and the file as the body, or `POST` a multipart `file`. No API key is needed \u2014 the URL is the credential, so hand it only to the person uploading. Present only in the response that created the link; null when read back."
                    },
                    "uploaded_by": {
                        "description": "Who was expected to send the file, as given when the link was created: `person` or `agent`.",
                        "anyOf": [
                            {
                                "type": "string"
                            },
                            {
                                "type": "string",
                                "enum": [
                                    "person"
                                ]
                            }
                        ]
                    },
                    "expires_at": {
                        "type": "string",
                        "description": "When the link stops accepting a file (ISO-8601)."
                    },
                    "completed_at": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "When the file was accepted (ISO-8601). Null until then."
                    },
                    "document": {
                        "anyOf": [
                            {
                                "description": "The stored document, once the link has taken a file. Use its `gid` as `documents[].document_gid` when creating a signature request. Null until then.",
                                "$ref": "#/components/schemas/DocumentResource"
                            },
                            {
                                "type": "null"
                            }
                        ]
                    }
                },
                "required": [
                    "gid",
                    "test",
                    "status",
                    "upload_url",
                    "uploaded_by",
                    "expires_at",
                    "completed_at",
                    "document"
                ],
                "title": "DocumentUploadResource",
                "description": "An upload link and what became of it (RULES.md R72). `upload_url` carries the token, and the token is stored only as a digest \u2014 so the URL exists in exactly one response, the one that created the link. Reading the link back answers null there rather than pretending it can be reconstructed. @mixin DocumentUpload /"
            },
            "DocumentUploadStatusEnum": {
                "type": "string",
                "description": "State of an upload link (SCHEMA.md `document_uploads`, RULES.md R72). Only `pending` and `completed` are ever stored. `expired` is what a pending link reports once its `expires_at` has passed \u2014 storing it would need a sweeper to keep the column honest, and the time alone already says it.\n| |\n|---|\n| `pending` <br/> Waiting for a file. |\n| `completed` <br/> A file was accepted and became a document; the link takes no more. |\n| `expired` <br/> No file arrived before `expires_at`; the link takes no more. |",
                "enum": [
                    "pending",
                    "completed",
                    "expired"
                ],
                "title": "DocumentUploadStatusEnum"
            },
            "FieldTypeEnum": {
                "type": "string",
                "description": "Field types a sender can place on a document (SCHEMA.md \u00a72.5, UI_DESIGN.md \u00a74.3). Four groups with different filling behaviour \u2014 see `isAutoFilled()`, `isSignature()` and `belongsToSigner()`.\n| |\n|---|\n| `signature` <br/> Signature group \u2014 a drawn/typed/uploaded image, submitted with consent (R36). |\n| `initials` <br/> Signature group \u2014 initials, typically repeated once per page. |\n| `date_signed` <br/> Auto-fill \u2014 the moment the signer submits, in the request's effective locale. |\n| `full_name` <br/> Auto-fill \u2014 `signers.name`. |\n| `email_address` <br/> Auto-fill \u2014 `signers.email`. |\n| `company` <br/> Auto-fill \u2014 the signer's organisation, when known from the contact book. |\n| `title` <br/> Auto-fill \u2014 the signer's job title, when known from the contact book. |\n| `textbox` <br/> Standard \u2014 free text typed by the signer. |\n| `checkbox` <br/> Standard \u2014 a single boolean tick. |\n| `dropdown` <br/> Standard \u2014 one value chosen from `options`. |\n| `radio_group` <br/> Standard \u2014 one value chosen from `options`, rendered as radios. |\n| `materai` <br/> Placement \u2014 the area an e-Meterai is affixed to, reserved by the document rather than filled by anybody on this platform. It is a field only because a field is what carries \"this box, on this page, at these      * coordinates\" (SCHEMA.md \u00a72.5), and that box is exactly what an e-Meterai provider is handed when the stamp is bought. Nothing here draws it: the reserved area stays empty through composition, and the provider's own stamping step fills it \u2014 which is why this type has no signer, is never required, and never produces a `PdfStamp`. |",
                "enum": [
                    "signature",
                    "initials",
                    "date_signed",
                    "full_name",
                    "email_address",
                    "company",
                    "title",
                    "textbox",
                    "checkbox",
                    "dropdown",
                    "radio_group",
                    "materai"
                ],
                "title": "FieldTypeEnum"
            },
            "LocaleEnum": {
                "type": "string",
                "description": "The only two locales the platform accepts (RULES.md R49). Anything else is a validation error, never a silent fallback. Used by `users.locale`, `tenants.default_locale`, `signature_requests.locale`, `signers.locale`, and `signing_sessions.locale`.\n| |\n|---|\n| `id` <br/> Bahasa Indonesia \u2014 the platform default. |\n| `en` <br/> English. |",
                "enum": [
                    "id",
                    "en"
                ],
                "title": "LocaleEnum"
            },
            "NotificationEventEnum": {
                "type": "string",
                "description": "The event catalogue shared by outgoing email and (once it exists) webhooks \u2014 PRD.md FR-12c fixes these names as a stable API contract, so they are never translated and never renamed. One enum serves both transports on purpose. `users.notification_preferences` is keyed by these same strings (FR-28), which means a sender who mutes `signer.viewed` in the dashboard and a client application subscribing to `signer.viewed` are talking about one thing. Two parallel vocabularies would drift the first time an event is added.  Distinct from `AuditEventTypeEnum`: that one records what happened to a document and is hash-chained evidence; this one names what gets *announced*, and not every audit entry has an announcement (nor vice versa \u2014 a manual reminder announces without changing state).\n| |\n|---|\n| `signature_request.sent` <br/> Invitations went out; the request left `draft`. |\n| `signer.viewed` <br/> A signer opened the document for the first time. |\n| `signer.signed` <br/> A signer submitted their fields. |\n| `signer.declined` <br/> A signer refused. Also terminal for the request (R5), which is announced separately. |\n| `signature_request.completed` <br/> Every signer signed. |\n| `signature_request.declined` <br/> The request as a whole ended in refusal. |\n| `signature_request.expired` <br/> The request passed `expires_at` without completing (R39). |\n| `signature_request.voided` <br/> The sender withdrew the request. |\n| `signature_request.reminder_sent` <br/> A reminder went out to a signer, automatic or manual (R38). |\n| `signature_request.processing_failed` <br/> The platform could not finish its own part: rendering the documents from a template, or composing and sealing the executed documents. Retries are spent; someone has to look. |",
                "enum": [
                    "signature_request.sent",
                    "signer.viewed",
                    "signer.signed",
                    "signer.declined",
                    "signature_request.completed",
                    "signature_request.declined",
                    "signature_request.expired",
                    "signature_request.voided",
                    "signature_request.reminder_sent",
                    "signature_request.processing_failed"
                ],
                "title": "NotificationEventEnum"
            },
            "SignatureRequestResource": {
                "type": "object",
                "properties": {
                    "gid": {
                        "type": "string",
                        "description": "Public identifier of the request (UUIDv7). Use it in every other signature-request endpoint."
                    },
                    "test": {
                        "type": "boolean",
                        "description": "True when the request was made with a test-mode key: nothing was emailed (see `GET /test-mail`), and the executed documents carry a SPECIMEN watermark and no platform seal. Live keys never see test requests."
                    },
                    "status": {
                        "description": "Where the request is in its lifecycle. The server is the only source of truth for this value; a browser landing on `redirect_url` is never a completion signal.\n| |\n|---|\n| `draft` <br/> Being composed in the wizard. No signer has been invited yet. |\n| `sent` <br/> Invitations dispatched, nobody has signed. |\n| `partially_signed` <br/> At least one but not all signers have signed. |\n| `completed` <br/> Every signer signed; final documents sealed and downloadable (R50). |\n| `declined` <br/> A signer refused. Terminal \u2014 a new request is needed to try again. |\n| `expired` <br/> Passed `expires_at` before completion (R39). Terminal. |\n| `voided` <br/> Withdrawn by the sender before completion. Terminal. |",
                        "$ref": "#/components/schemas/SignatureRequestStatusEnum"
                    },
                    "title": {
                        "type": "string",
                        "description": "Title shown to signers in the invitation email and on the signing page."
                    },
                    "message": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "Optional message shown to signers in the invitation email. Null when none was given."
                    },
                    "locale": {
                        "description": "Language of the signing page and emails for this request (`id` or `en`), unless a signer or session overrides it.\n| |\n|---|\n| `id` <br/> Bahasa Indonesia \u2014 the platform default. |\n| `en` <br/> English. |",
                        "$ref": "#/components/schemas/LocaleEnum"
                    },
                    "sequential": {
                        "type": "boolean",
                        "description": "True when signers are invited one at a time in `order_index` order; false when everyone is invited at once."
                    },
                    "external_ref": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "Your own identifier for this request, exactly as sent at creation. Null when none was given. Echoed at the top level of every webhook payload."
                    },
                    "redirect_url": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "Where the signer's browser is sent after signing or declining. Null when none was given."
                    },
                    "signing_urls": {
                        "type": "null",
                        "description": "Always null. Hosted signing links are only ever emailed to the signer, and embedded signing mints its own URL through `POST /signing-sessions`. The key is kept so a client reading it finds null rather than a missing property."
                    },
                    "documents_pending": {
                        "type": "integer",
                        "description": "Number of documents still being rendered from a template. Greater than zero only between creating a template-backed request and the render queue finishing; `documents` is empty until it reaches zero."
                    },
                    "processing_error": {
                        "type": [
                            "object",
                            "null"
                        ],
                        "description": "Null unless the platform could not finish its own part after retrying. `stage` is `preparation` (a template could not be rendered: the request will not become sendable \u2014 void it and create a new one) or `finalization` (the executed documents could not be composed or sealed: the platform keeps retrying on its own). `occurred_at` is when it gave up (ISO-8601). Announced once as the `signature_request.processing_failed` webhook.",
                        "properties": {
                            "stage": {
                                "type": "string",
                                "description": "Where it failed: `preparation` (template rendering) or `finalization` (composing and sealing the executed documents)."
                            },
                            "occurred_at": {
                                "type": [
                                    "string",
                                    "null"
                                ],
                                "description": "When the platform gave up (ISO-8601)."
                            }
                        },
                        "required": [
                            "stage",
                            "occurred_at"
                        ]
                    },
                    "expires_at": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "Deadline for signing (ISO-8601). Null while no expiry has been set; a request past this instant becomes `expired`."
                    },
                    "completed_at": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "When the last signer signed (ISO-8601). Null until `status` is `completed`."
                    },
                    "created_at": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "When the request was created (ISO-8601)."
                    },
                    "updated_at": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "When the request last changed (ISO-8601)."
                    },
                    "documents": {
                        "type": "array",
                        "description": "The documents of this request in signing order. Empty while `documents_pending` is greater than zero.",
                        "items": {
                            "type": "object",
                            "properties": {
                                "gid": {
                                    "type": "string",
                                    "description": "Public identifier of the document. The same document may appear in several requests."
                                },
                                "filename": {
                                    "type": "string",
                                    "description": "File name as uploaded or as rendered from the template."
                                },
                                "page_count": {
                                    "type": "integer",
                                    "description": "Number of pages. 0 while the page count has not been determined yet."
                                },
                                "sort_order": {
                                    "type": "string",
                                    "description": "Position of the document within the request, starting at 1."
                                },
                                "final_hash": {
                                    "type": "string",
                                    "description": "Lowercase hex SHA-256 of the executed document's bytes. Null until the request is completed and this document has been composed; compare it with the file you download."
                                },
                                "sealed_at": {
                                    "type": [
                                        "string",
                                        "null"
                                    ],
                                    "description": "When the platform seal was applied to the executed document (ISO-8601). Null until sealed; download links are only issued once this is set."
                                }
                            },
                            "required": [
                                "gid",
                                "filename",
                                "page_count",
                                "sort_order",
                                "final_hash",
                                "sealed_at"
                            ]
                        }
                    },
                    "signers": {
                        "type": "array",
                        "description": "Every signer of the request, in `order_index` order, each with their own progress.",
                        "items": {
                            "type": "object",
                            "properties": {
                                "gid": {
                                    "type": "string",
                                    "description": "Public identifier of the signer. Use it for `POST /signature-requests/{gid}/remind` and `POST /signing-sessions`."
                                },
                                "name": {
                                    "type": "string",
                                    "description": "Signer's name as it will appear on the document."
                                },
                                "email": {
                                    "type": "string",
                                    "description": "Address the invitation and reminders are sent to."
                                },
                                "order_index": {
                                    "type": "integer",
                                    "description": "Position in the signing order, starting at 1. Only meaningful when the request is `sequential`."
                                },
                                "role_label": {
                                    "type": [
                                        "string",
                                        "null"
                                    ],
                                    "description": "Human-readable role shown to the signer (for example \"Pihak Pertama\"). Null when none was given."
                                },
                                "role_key": {
                                    "type": [
                                        "string",
                                        "null"
                                    ],
                                    "description": "Machine role key matching a template role (for example `party`, `operator`). Null for requests that do not use templates."
                                },
                                "status": {
                                    "description": "This signer's own progress, independent of the request's overall `status`.\n| |\n|---|\n| `pending` <br/> Invited, has not opened the document. |\n| `viewed` <br/> Opened the signing page but has not submitted. |\n| `signed` <br/> Submitted; consent recorded in the same transaction (R36). |\n| `declined` <br/> Refused, with a reason in `declined_reason`. |\n| `expired` <br/> The request expired before this signer acted. |",
                                    "$ref": "#/components/schemas/SignerStatusEnum"
                                },
                                "waiting_turn": {
                                    "type": "boolean",
                                    "description": "True when the request is sequential and an earlier signer has not finished yet, so this signer has not been invited. Distinguishes \"has not acted\" from \"has not been asked\"."
                                },
                                "verification_method": {
                                    "description": "How the signer proves they are the invited recipient before the document opens.\n| |\n|---|\n| `none` <br/> Possession of the emailed link is enough. |\n| `otp` <br/> A one-time code is emailed and must be entered before the document opens. |\n| `email_link` <br/> The signer re-confirms via a second emailed link. |",
                                    "$ref": "#/components/schemas/SignerVerificationMethodEnum"
                                },
                                "delivery": {
                                    "description": "How the signer reaches the signing page: `email` (Lokasign emails the invitation and reminders) or `embedded` (your application opens a signing session for them; nothing is emailed but one-time codes and the executed copy).\n| |\n|---|\n| `email` <br/> Lokasign emails the invitation and the reminders; the signer follows the emailed link. |\n| `embedded` <br/> The client application brings the signer to the page itself, through `POST /signing-sessions`. Lokasign sends no invitation and no reminder \u2014 an emailed link would stop working the moment the embedded session opens (the signer token rotates), so sending one only puts a dead link in the signer's inbox. |",
                                    "$ref": "#/components/schemas/SignerDeliveryEnum"
                                },
                                "viewed_at": {
                                    "type": [
                                        "string",
                                        "null"
                                    ],
                                    "description": "When the signer first opened the signing page (ISO-8601). Null until they do."
                                },
                                "signed_at": {
                                    "type": [
                                        "string",
                                        "null"
                                    ],
                                    "description": "When the signer submitted their signature (ISO-8601). Null until `status` is `signed`."
                                },
                                "declined_reason": {
                                    "type": [
                                        "string",
                                        "null"
                                    ],
                                    "description": "Reason given by the signer when declining. Null unless `status` is `declined`."
                                }
                            },
                            "required": [
                                "gid",
                                "name",
                                "email",
                                "order_index",
                                "role_label",
                                "role_key",
                                "status",
                                "waiting_turn",
                                "verification_method",
                                "delivery",
                                "viewed_at",
                                "signed_at",
                                "declined_reason"
                            ]
                        }
                    },
                    "cc_recipients": {
                        "type": "array",
                        "description": "Recipients who receive a copy of the executed documents without signing.",
                        "items": {
                            "type": "object",
                            "properties": {
                                "name": {
                                    "type": [
                                        "string",
                                        "null"
                                    ],
                                    "description": "Recipient's name. Null when none was given."
                                },
                                "email": {
                                    "type": "string",
                                    "description": "Address the copy is sent to."
                                }
                            },
                            "required": [
                                "name",
                                "email"
                            ]
                        }
                    }
                },
                "required": [
                    "gid",
                    "test",
                    "status",
                    "title",
                    "message",
                    "locale",
                    "sequential",
                    "external_ref",
                    "redirect_url",
                    "signing_urls",
                    "documents_pending",
                    "processing_error",
                    "expires_at",
                    "completed_at",
                    "created_at",
                    "updated_at"
                ],
                "title": "SignatureRequestResource",
                "description": "A signature request: its lifecycle `status`, the documents to sign, every signer with their own progress, and the CC recipients of the executed copy. Distinct from the dashboard resource of the same name, and deliberately so: that one emits pre-formatted labels in the viewer's timezone for a Vue table, while this one emits raw ISO-8601 instants and `snake_case` keys for a machine that will render them itself. No `id` anywhere \u2014 `gid` is the only identifier that may leave the application (R46). Enum-typed attributes are returned as the enum itself rather than `->value`: JSON output is identical (backed enums serialise to their value), and the generated OpenAPI document then references the enum schema \u2014 with every case described \u2014 instead of a bare string. The comments above each key are not decoration: Scramble lifts them into the OpenAPI document as the property's description, so they are written for the client reading the spec, not for the maintainer reading this file. @mixin SignatureRequest /"
            },
            "SignatureRequestStatusEnum": {
                "type": "string",
                "description": "State machine of a signature request (SCHEMA.md \u00a72.3, DESIGN.md \u00a71.1). The server is the sole source of truth for this value (RULES.md R28) \u2014 a browser landing on `redirect_url` is a front-channel hint, never a status signal.\n| |\n|---|\n| `draft` <br/> Being composed in the wizard. No signer has been invited yet. |\n| `sent` <br/> Invitations dispatched, nobody has signed. |\n| `partially_signed` <br/> At least one but not all signers have signed. |\n| `completed` <br/> Every signer signed; final documents sealed and downloadable (R50). |\n| `declined` <br/> A signer refused. Terminal \u2014 a new request is needed to try again. |\n| `expired` <br/> Passed `expires_at` before completion (R39). Terminal. |\n| `voided` <br/> Withdrawn by the sender before completion. Terminal. |",
                "enum": [
                    "draft",
                    "sent",
                    "partially_signed",
                    "completed",
                    "declined",
                    "expired",
                    "voided"
                ],
                "title": "SignatureRequestStatusEnum"
            },
            "SignerDeliveryEnum": {
                "type": "string",
                "description": "How a signer reaches the signing page (SCHEMA.md \u00a72.4, PRD.md FR-5b). Decides who owns the *invitation*, nothing else: both kinds of signer go through the same signing engine, consent and audit trail, and either may be handed an embedded session.\n| |\n|---|\n| `email` <br/> Lokasign emails the invitation and the reminders; the signer follows the emailed link. |\n| `embedded` <br/> The client application brings the signer to the page itself, through `POST /signing-sessions`. Lokasign sends no invitation and no reminder \u2014 an emailed link would stop working the moment the embedded session opens (the signer token rotates), so sending one only puts a dead link in the signer's inbox. |",
                "enum": [
                    "email",
                    "embedded"
                ],
                "title": "SignerDeliveryEnum"
            },
            "SignerStatusEnum": {
                "type": "string",
                "description": "Per-signer progress within a request (SCHEMA.md \u00a72.4). The UI shows a sixth, derived state (\"waiting turn\") for a pending signer in a sequential request whose turn has not arrived \u2014 that is presentation only and is computed from `sequential` + `order_index`, never stored here.\n| |\n|---|\n| `pending` <br/> Invited, has not opened the document. |\n| `viewed` <br/> Opened the signing page but has not submitted. |\n| `signed` <br/> Submitted; consent recorded in the same transaction (R36). |\n| `declined` <br/> Refused, with a reason in `declined_reason`. |\n| `expired` <br/> The request expired before this signer acted. |",
                "enum": [
                    "pending",
                    "viewed",
                    "signed",
                    "declined",
                    "expired"
                ],
                "title": "SignerStatusEnum"
            },
            "SignerVerificationMethodEnum": {
                "type": "string",
                "description": "How a signer proves they are the invited recipient before signing (SCHEMA.md \u00a72.4, PRD.md FR-6).\n| |\n|---|\n| `none` <br/> Possession of the emailed link is enough. |\n| `otp` <br/> A one-time code is emailed and must be entered before the document opens. |\n| `email_link` <br/> The signer re-confirms via a second emailed link. |",
                "enum": [
                    "none",
                    "otp",
                    "email_link"
                ],
                "title": "SignerVerificationMethodEnum"
            },
            "SigningSessionModeEnum": {
                "type": "string",
                "description": "How a signing session was opened (SCHEMA.md \u00a72.4.1, PRD.md FR-5b).\n| |\n|---|\n| `hosted` <br/> Signer followed the emailed link to the platform's own signing page. |\n| `embedded` <br/> Client application created the session over the API and renders it in an iframe. Requires `embedder_origin` to be listed in `api_keys.allowed_origins` (R43). |",
                "enum": [
                    "hosted",
                    "embedded"
                ],
                "title": "SigningSessionModeEnum"
            },
            "SigningSessionOutcomeResource": {
                "type": "object",
                "properties": {
                    "gid": {
                        "type": "string",
                        "description": "Public identifier of the session the code belonged to."
                    },
                    "state": {
                        "description": "Final state of the session at the moment the code was redeemed.\n| |\n|---|\n| `created` <br/> Session row minted, `signing_url` not yet opened. |\n| `authenticated` <br/> Identity check passed (or was not required). |\n| `in_progress` <br/> Signer is filling fields. |\n| `submitted` <br/> Signer pressed submit; finalisation job not finished. |\n| `completed` <br/> Finished successfully; exchange code available to the client application (R44). |\n| `declined` <br/> Signer refused inside this session. |\n| `blocked` <br/> Locked out, e.g. too many failed OTP attempts. |\n| `expired` <br/> Passed `expires_at` without completing. |",
                        "$ref": "#/components/schemas/SigningSessionStateEnum"
                    },
                    "signature_request": {
                        "type": "object",
                        "description": "The request the session was part of, as it stands now.",
                        "properties": {
                            "gid": {
                                "type": "string",
                                "description": "Public identifier of the request."
                            },
                            "status": {
                                "description": "Overall status of the request \u2014 other signers may still be pending even when this session's signer has signed.\n| |\n|---|\n| `draft` <br/> Being composed in the wizard. No signer has been invited yet. |\n| `sent` <br/> Invitations dispatched, nobody has signed. |\n| `partially_signed` <br/> At least one but not all signers have signed. |\n| `completed` <br/> Every signer signed; final documents sealed and downloadable (R50). |\n| `declined` <br/> A signer refused. Terminal \u2014 a new request is needed to try again. |\n| `expired` <br/> Passed `expires_at` before completion (R39). Terminal. |\n| `voided` <br/> Withdrawn by the sender before completion. Terminal. |",
                                "$ref": "#/components/schemas/SignatureRequestStatusEnum"
                            },
                            "external_ref": {
                                "type": [
                                    "string",
                                    "null"
                                ],
                                "description": "The request's `external_ref`. Null when none was given."
                            },
                            "completed_at": {
                                "type": [
                                    "string",
                                    "null"
                                ],
                                "description": "When the request completed (ISO-8601). Null unless `status` is `completed`."
                            }
                        },
                        "required": [
                            "gid",
                            "status",
                            "external_ref",
                            "completed_at"
                        ]
                    },
                    "signer": {
                        "type": "object",
                        "description": "The signer who used the session, with what they did.",
                        "properties": {
                            "gid": {
                                "type": "string",
                                "description": "Public identifier of the signer."
                            },
                            "name": {
                                "type": "string",
                                "description": "Signer's name."
                            },
                            "email": {
                                "type": "string",
                                "description": "Signer's email address."
                            },
                            "status": {
                                "description": "What the signer did in the session: `signed` or `declined`, or still `pending`/`viewed` if they left without finishing.\n| |\n|---|\n| `pending` <br/> Invited, has not opened the document. |\n| `viewed` <br/> Opened the signing page but has not submitted. |\n| `signed` <br/> Submitted; consent recorded in the same transaction (R36). |\n| `declined` <br/> Refused, with a reason in `declined_reason`. |\n| `expired` <br/> The request expired before this signer acted. |",
                                "$ref": "#/components/schemas/SignerStatusEnum"
                            },
                            "signed_at": {
                                "type": [
                                    "string",
                                    "null"
                                ],
                                "description": "When the signer signed (ISO-8601). Null unless `status` is `signed`."
                            },
                            "declined_reason": {
                                "type": [
                                    "string",
                                    "null"
                                ],
                                "description": "Reason given when declining. Null unless `status` is `declined`."
                            }
                        },
                        "required": [
                            "gid",
                            "name",
                            "email",
                            "status",
                            "signed_at",
                            "declined_reason"
                        ]
                    }
                },
                "required": [
                    "gid",
                    "state",
                    "signature_request",
                    "signer"
                ],
                "title": "SigningSessionOutcomeResource",
                "description": "The verified outcome of an embedded signing session, handed back for a redeemed exchange code: what the signer did and where the request stands now. This is the shape R28 calls a source of truth: it is produced by the platform, for a caller that authenticated with its own API key, and it says what the *database* holds rather than what a browser claimed. The `postMessage` the iframe sent carried a code and an event name and nothing else, precisely so that this call is what a client acts on. @mixin SigningSession /"
            },
            "SigningSessionResource": {
                "type": "object",
                "properties": {
                    "gid": {
                        "type": "string",
                        "description": "Public identifier of the session. Informational only: sessions are never addressed by id from outside."
                    },
                    "mode": {
                        "description": "Always `embedded` for sessions minted through the API.\n| |\n|---|\n| `hosted` <br/> Signer followed the emailed link to the platform's own signing page. |\n| `embedded` <br/> Client application created the session over the API and renders it in an iframe. Requires `embedder_origin` to be listed in `api_keys.allowed_origins` (R43). |",
                        "$ref": "#/components/schemas/SigningSessionModeEnum"
                    },
                    "state": {
                        "description": "Lifecycle of the session. A new session is `created`; opening the URL makes it `opened`; it ends `completed`, `declined` or `expired`.\n| |\n|---|\n| `created` <br/> Session row minted, `signing_url` not yet opened. |\n| `authenticated` <br/> Identity check passed (or was not required). |\n| `in_progress` <br/> Signer is filling fields. |\n| `submitted` <br/> Signer pressed submit; finalisation job not finished. |\n| `completed` <br/> Finished successfully; exchange code available to the client application (R44). |\n| `declined` <br/> Signer refused inside this session. |\n| `blocked` <br/> Locked out, e.g. too many failed OTP attempts. |\n| `expired` <br/> Passed `expires_at` without completing. |",
                        "$ref": "#/components/schemas/SigningSessionStateEnum"
                    },
                    "signing_url": {
                        "type": "string",
                        "description": "The URL to open for the signer. Single-use and short-lived: open it once \u2014 in an iframe on `embedder_origin`, in your app's WebView, or, for a session without `embedder_origin`, in the signer's own browser (as an AI agent does for the person it is talking to). Do not email it: it expires in minutes and opens once."
                    },
                    "embedder_origin": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "Origin the session may be framed from, as registered on your API key's `allowed_origins`. Any other origin is refused by the browser through `frame-ancestors`. Null for a native-app session, which may not be framed at all."
                    },
                    "return_url": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "Where the page navigates when the signer signs or declines, with `lokasign_event`, `request_id` and `exchange_code` added to the query string. Null when you did not ask for one."
                    },
                    "locale": {
                        "anyOf": [
                            {
                                "description": "Language of the framed signing page. Null when the signer's or the request's locale applies instead.\n| |\n|---|\n| `id` <br/> Bahasa Indonesia \u2014 the platform default. |\n| `en` <br/> English. |",
                                "$ref": "#/components/schemas/LocaleEnum"
                            },
                            {
                                "type": "null"
                            }
                        ]
                    },
                    "expires_at": {
                        "type": "string",
                        "description": "When `signing_url` stops working (ISO-8601). Mint a new session after that."
                    }
                },
                "required": [
                    "gid",
                    "mode",
                    "state",
                    "signing_url",
                    "embedder_origin",
                    "return_url",
                    "locale",
                    "expires_at"
                ],
                "title": "SigningSessionResource",
                "description": "A freshly minted embedded signing session: the single-use URL to frame, where it may be framed, and until when. `signing_url` appears exactly once, in the response that created it: the token behind it is stored only as a hash, so this is the single moment it exists in readable form \u2014 the same contract as an API key. Nothing here reports an *outcome*. A session that has just been created has none, and the client learns the result by redeeming the exchange code or from a webhook, never from this shape (R28). @mixin SigningSession /"
            },
            "SigningSessionStateEnum": {
                "type": "string",
                "description": "Server-enforced state of one signing session (SCHEMA.md \u00a72.4.1). Enforced server-side precisely so reloading the signing page is always safe \u2014 the browser never decides what step it is on.\n| |\n|---|\n| `created` <br/> Session row minted, `signing_url` not yet opened. |\n| `authenticated` <br/> Identity check passed (or was not required). |\n| `in_progress` <br/> Signer is filling fields. |\n| `submitted` <br/> Signer pressed submit; finalisation job not finished. |\n| `completed` <br/> Finished successfully; exchange code available to the client application (R44). |\n| `declined` <br/> Signer refused inside this session. |\n| `blocked` <br/> Locked out, e.g. too many failed OTP attempts. |\n| `expired` <br/> Passed `expires_at` without completing. |",
                "enum": [
                    "created",
                    "authenticated",
                    "in_progress",
                    "submitted",
                    "completed",
                    "declined",
                    "blocked",
                    "expired"
                ],
                "title": "SigningSessionStateEnum"
            },
            "StoreDocumentRequest": {
                "type": "object",
                "description": "Payload of `POST /api/v1/documents`: one PDF, sent either as a multipart `file` or as a\n`document_url` the platform fetches. Exactly one of the two is required.\n\nOnly the shape is checked here. Whether the bytes are really a PDF, and whether they are\nencrypted, is decided from the file's own header by `PdfInspector` (R31/R41) \u2014 a\n`Content-Type` the caller chose proves nothing.",
                "properties": {
                    "file": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "format": "binary",
                        "contentMediaType": "application/octet-stream",
                        "description": "The PDF itself, as a `multipart/form-data` part (at most 25 MB, not password-protected). Use this or `document_url`, not both."
                    },
                    "document_url": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "format": "uri",
                        "description": "Public HTTPS URL of the PDF for the platform to fetch now (at most 25 MB, not password-protected). Private network addresses are refused. Use this or `file`, not both.",
                        "maxLength": 1000
                    },
                    "filename": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "File name to store the document under when fetched from `document_url`. Omit to use the name from the URL.",
                        "maxLength": 250
                    }
                },
                "title": "StoreDocumentRequest"
            },
            "StoreDocumentUploadRequest": {
                "type": "object",
                "description": "Body of `POST /api/v1/document-uploads` (RULES.md R72).",
                "properties": {
                    "filename": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "Name to store the document under. Omit to keep the name of the file that is uploaded; a raw `PUT` carries no name, so it is stored as `document.pdf` unless you give one here.",
                        "maxLength": 250
                    },
                    "uploaded_by": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "Who will send the file: `person` (default) when you hand `upload_url` to someone, `agent` when you will PUT the file yourself \u2014 an AI agent holding the person's chat attachment. Clients that show the link in a chat use it to wait for the file instead of offering a file picker.",
                        "enum": [
                            "person",
                            "agent",
                            null
                        ]
                    }
                },
                "title": "StoreDocumentUploadRequest"
            },
            "StoreSignatureRequestRequest": {
                "type": "object",
                "description": "Payload of `POST /api/v1/signature-requests`: the documents to sign, the people who sign\nthem, where each signature goes, and how the request behaves.\n\nEverything structural is checked here so the builder never has to guard against a missing\nindex or a signer that does not exist \u2014 the cross-references between `fields[]`, `documents[]`\nand `signers[]` are validated as part of the payload rather than discovered halfway through\na transaction. The first paragraph of this docblock is the schema's description in the\ngenerated OpenAPI document; the attributes below correct the two map-shaped fields that\nvalidation rules alone can only describe as lists.",
                "properties": {
                    "title": {
                        "type": "string",
                        "description": "Title shown to signers in the invitation email and at the top of the signing page.",
                        "maxLength": 255
                    },
                    "message": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "Optional message included in the invitation email, for example the deadline or who to contact.",
                        "maxLength": 2000
                    },
                    "sequential": {
                        "type": [
                            "boolean",
                            "null"
                        ],
                        "description": "True to invite signers one at a time in `order_index` order (the next signer is invited when the previous one signs); false to invite everyone at once. Omit to use your organisation's default."
                    },
                    "stamp_attribution": {
                        "type": [
                            "boolean",
                            "null"
                        ],
                        "description": "True to print the signer's name and signing time in small type over the top-left corner of each signature on the finished PDF (\"Ditandatangani oleh \u2026\" / \"Signed by \u2026\", then the time); false to flatten the signature bare and leave attribution to the completion certificate. Omit to use your organisation's default."
                    },
                    "attach_final_documents": {
                        "type": [
                            "boolean",
                            "null"
                        ],
                        "description": "True to also attach the finished PDFs to the completion email sent to every party, on top of the download links; false for links only. Attachments are skipped, leaving the links, when the documents together exceed the platform's size limit. Omit to use your organisation's default."
                    },
                    "locale": {
                        "anyOf": [
                            {
                                "description": "Language of the signing page, emails and \u2014 for template documents \u2014 the template edition (`id` or `en`). Omit to use your organisation's default. A signer's own `locale` overrides it for that signer.\n\n| |\n|---|\n| `id` <br/> Bahasa Indonesia \u2014 the platform default. |\n| `en` <br/> English. |",
                                "$ref": "#/components/schemas/LocaleEnum"
                            },
                            {
                                "type": "null"
                            }
                        ]
                    },
                    "expires_in_days": {
                        "type": [
                            "integer",
                            "null"
                        ],
                        "description": "Days until the request expires, counted from creation. Omit to use your organisation's default. Once past, the request becomes `expired` and every signing link stops working.",
                        "minimum": 1,
                        "maximum": 90
                    },
                    "external_ref": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "Your own identifier for this request, such as your contract or order id. Unique per application: it is echoed at the top level of every webhook and lets you find the request with `GET /signature-requests?external_ref=`. A reference is reserved while its request is live or completed and freed once that request is voided, declined or expired; sending one that is still reserved answers `422 external_ref_taken`.",
                        "maxLength": 191
                    },
                    "redirect_url": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "format": "uri",
                        "description": "Where the signer's browser is sent after signing or declining. Convenience only: arrival there is not a status signal \u2014 read the status from the API or webhooks.",
                        "maxLength": 500
                    },
                    "documents": {
                        "type": "array",
                        "description": "The documents to sign, in signing order. Each entry supplies its document in exactly one of three ways: `document_url` (a PDF the platform fetches now), `document_gid` (a PDF uploaded earlier through `POST /documents`), or `template_code` with `merge_fields`/`merge_rows` (a document the platform renders from one of your templates). At least one entry is required.",
                        "items": {
                            "oneOf": [
                                {
                                    "$ref": "#/components/schemas/SignatureRequestDocumentFromUrl"
                                },
                                {
                                    "$ref": "#/components/schemas/SignatureRequestDocumentFromGid"
                                },
                                {
                                    "$ref": "#/components/schemas/SignatureRequestDocumentFromTemplate"
                                }
                            ]
                        },
                        "minItems": 1
                    },
                    "send_when_ready": {
                        "type": [
                            "boolean",
                            "null"
                        ],
                        "description": "True to send the invitations automatically as soon as every template document has finished rendering, so you need not poll and call `/send` yourself. Requests without template documents are sent immediately. Omit or send false to keep the request as a draft you can review through `GET /signature-requests/{gid}/documents` before calling `POST /signature-requests/{gid}/send`."
                    },
                    "signers": {
                        "type": "array",
                        "description": "The people who must sign, at least one. In a `sequential` request they are invited in `order_index` order.",
                        "items": {
                            "type": "object",
                            "properties": {
                                "name": {
                                    "type": "string",
                                    "description": "Signer's full name as it should appear on the document.",
                                    "maxLength": 255
                                },
                                "email": {
                                    "type": "string",
                                    "format": "email",
                                    "description": "Address the invitation, reminders and the executed copy are sent to.",
                                    "maxLength": 255
                                },
                                "order_index": {
                                    "type": [
                                        "integer",
                                        "null"
                                    ],
                                    "description": "Position in the signing order, starting at 1. Only meaningful when the request is `sequential`; omit to use the array order.",
                                    "minimum": 1,
                                    "maximum": 65535
                                },
                                "role_label": {
                                    "type": [
                                        "string",
                                        "null"
                                    ],
                                    "description": "Human-readable role shown to the signer, for example \"Pihak Pertama\" or \"Approver\".",
                                    "maxLength": 100
                                },
                                "role_key": {
                                    "type": [
                                        "string",
                                        "null"
                                    ],
                                    "description": "Machine role that maps this signer to a template role (for example `party`, `operator`). Required for every role a `template_code` document declares; ignored for other documents.",
                                    "maxLength": 50
                                },
                                "locale": {
                                    "anyOf": [
                                        {
                                            "description": "Language of this signer's emails and signing page (`id` or `en`). Overrides the request's `locale` for this signer only.\n\n| |\n|---|\n| `id` <br/> Bahasa Indonesia \u2014 the platform default. |\n| `en` <br/> English. |",
                                            "$ref": "#/components/schemas/LocaleEnum"
                                        },
                                        {
                                            "type": "null"
                                        }
                                    ]
                                },
                                "verification_method": {
                                    "anyOf": [
                                        {
                                            "description": "How the signer proves they are the invited recipient before the document opens. Omit to use your organisation's default.\n\n| |\n|---|\n| `none` <br/> Possession of the emailed link is enough. |\n| `otp` <br/> A one-time code is emailed and must be entered before the document opens. |\n| `email_link` <br/> The signer re-confirms via a second emailed link. |",
                                            "$ref": "#/components/schemas/SignerVerificationMethodEnum"
                                        },
                                        {
                                            "type": "null"
                                        }
                                    ]
                                },
                                "delivery": {
                                    "anyOf": [
                                        {
                                            "description": "How the signer reaches the signing page. `email` (the default): Lokasign emails the invitation and the reminders. `embedded`: your application brings the signer to the page itself through `POST /signing-sessions` \u2014 no invitation or reminder is emailed, because an emailed link would stop working the moment the embedded session opens. One-time codes (`verification_method: otp`) and the executed copy are still emailed. Fixed once the request is created.\n\n| |\n|---|\n| `email` <br/> Lokasign emails the invitation and the reminders; the signer follows the emailed link. |\n| `embedded` <br/> The client application brings the signer to the page itself, through `POST /signing-sessions`. Lokasign sends no invitation and no reminder \u2014 an emailed link would stop working the moment the embedded session opens (the signer token rotates), so sending one only puts a dead link in the signer's inbox. |",
                                            "$ref": "#/components/schemas/SignerDeliveryEnum"
                                        },
                                        {
                                            "type": "null"
                                        }
                                    ]
                                }
                            },
                            "required": [
                                "name",
                                "email"
                            ]
                        },
                        "minItems": 1
                    },
                    "fields": {
                        "type": [
                            "array",
                            "null"
                        ],
                        "description": "Boxes to draw on documents supplied by `document_url` or `document_gid`: signatures, initials, auto-filled data and form inputs. Not allowed on `template_code` documents, which place their own fields from the tags in the template. Every signer must end up with at least one signature field somewhere, or `/send` is refused.",
                        "items": {
                            "type": "object",
                            "properties": {
                                "document_index": {
                                    "type": "integer",
                                    "description": "Index into `documents` of the document this field is drawn on, starting at 0. Must not point at a `template_code` entry.",
                                    "minimum": 0
                                },
                                "signer_index": {
                                    "type": "integer",
                                    "description": "Index into `signers` of the signer who fills this field, starting at 0. Required for every type except `materai`, which reserves an area on the document itself and must not name a signer.",
                                    "minimum": 0
                                },
                                "type": {
                                    "description": "What the box is: a signature or initials the signer draws, a value the platform fills in, a form input the signer completes, or a reserved e-Meterai area.\n\n| |\n|---|\n| `signature` <br/> Signature group \u2014 a drawn/typed/uploaded image, submitted with consent (R36). |\n| `initials` <br/> Signature group \u2014 initials, typically repeated once per page. |\n| `date_signed` <br/> Auto-fill \u2014 the moment the signer submits, in the request's effective locale. |\n| `full_name` <br/> Auto-fill \u2014 `signers.name`. |\n| `email_address` <br/> Auto-fill \u2014 `signers.email`. |\n| `company` <br/> Auto-fill \u2014 the signer's organisation, when known from the contact book. |\n| `title` <br/> Auto-fill \u2014 the signer's job title, when known from the contact book. |\n| `textbox` <br/> Standard \u2014 free text typed by the signer. |\n| `checkbox` <br/> Standard \u2014 a single boolean tick. |\n| `dropdown` <br/> Standard \u2014 one value chosen from `options`. |\n| `radio_group` <br/> Standard \u2014 one value chosen from `options`, rendered as radios. |\n| `materai` <br/> Placement \u2014 the area an e-Meterai is affixed to, reserved by the document rather than filled by anybody on this platform. It is a field only because a field is what carries \"this box, on this page, at these      * coordinates\" (SCHEMA.md \u00a72.5), and that box is exactly what an e-Meterai provider is handed when the stamp is bought. Nothing here draws it: the reserved area stays empty through composition, and the provider's own stamping step fills it \u2014 which is why this type has no signer, is never required, and never produces a `PdfStamp`. |",
                                    "$ref": "#/components/schemas/FieldTypeEnum"
                                },
                                "field_name": {
                                    "type": [
                                        "string",
                                        "null"
                                    ],
                                    "description": "Your own name for the field, returned with the signed value in the audit trail. Optional.",
                                    "maxLength": 100
                                },
                                "placeholder_text": {
                                    "type": [
                                        "string",
                                        "null"
                                    ],
                                    "description": "Hint shown inside an empty form input. Optional.",
                                    "maxLength": 255
                                },
                                "font_name": {
                                    "type": [
                                        "string",
                                        "null"
                                    ],
                                    "description": "Font family for text drawn into the field. Omit to use the platform default.",
                                    "maxLength": 50
                                },
                                "font_size": {
                                    "type": [
                                        "integer",
                                        "null"
                                    ],
                                    "description": "Font size in points for text drawn into the field, 6\u201372. Omit to use the platform default.",
                                    "minimum": 6,
                                    "maximum": 72
                                },
                                "page_number": {
                                    "type": [
                                        "integer",
                                        "null"
                                    ],
                                    "description": "Page the field is drawn on, starting at 1. Required together with `x` and `y` unless `anchor` is used.",
                                    "minimum": 1
                                },
                                "x": {
                                    "type": [
                                        "number",
                                        "null"
                                    ],
                                    "description": "Left edge of the box as a fraction of the page width, 0 (left) to 1 (right). Required with `page_number` unless `anchor` is used.",
                                    "minimum": 0,
                                    "maximum": 1
                                },
                                "y": {
                                    "type": [
                                        "number",
                                        "null"
                                    ],
                                    "description": "Top edge of the box as a fraction of the page height, 0 (top) to 1 (bottom). Required with `page_number` unless `anchor` is used.",
                                    "minimum": 0,
                                    "maximum": 1
                                },
                                "width": {
                                    "type": [
                                        "number",
                                        "null"
                                    ],
                                    "description": "Width of the box as a fraction of the page width, 0\u20131. Omit to use the default size for the field type.",
                                    "minimum": 0,
                                    "maximum": 1
                                },
                                "height": {
                                    "type": [
                                        "number",
                                        "null"
                                    ],
                                    "description": "Height of the box as a fraction of the page height, 0\u20131. Omit to use the default size for the field type.",
                                    "minimum": 0,
                                    "maximum": 1
                                },
                                "is_required": {
                                    "type": [
                                        "boolean",
                                        "null"
                                    ],
                                    "description": "Whether the signer must complete this field before submitting. Signature fields are always required."
                                },
                                "options": {
                                    "type": "array",
                                    "description": "Choices for `dropdown` and `radio_group` fields, in display order. Ignored for other types.",
                                    "examples": [
                                        [
                                            "Ya",
                                            "Tidak"
                                        ]
                                    ],
                                    "items": {
                                        "type": "string"
                                    }
                                },
                                "anchor": {
                                    "type": [
                                        "object",
                                        "null"
                                    ],
                                    "description": "Place the field relative to a piece of text in the document instead of by coordinates. Resolved when the request is created, on the first occurrence of `text` (pages in order); the box is centred horizontally on it. Without `offset_y` the box goes in the gap under the text \u2014 4 pt below it, at the field type's usual height or less, so it stays clear of the next line (the usual signature block: \"Pihak Pertama,\" above, the typed name below). With `offset_y` the box's top is that many points below the top of the text instead. Text that does not occur refuses the request with `422 anchor_not_found`. Ignored when `page_number` is given.",
                                    "properties": {
                                        "text": {
                                            "type": "string",
                                            "description": "Exact text to search for in the document, for example a placeholder such as `{{sign:1}}`.",
                                            "maxLength": 255
                                        },
                                        "offset_x": {
                                            "type": [
                                                "number",
                                                "null"
                                            ],
                                            "description": "Horizontal shift from the anchored position, in PDF points (positive moves right). Default 0."
                                        },
                                        "offset_y": {
                                            "type": [
                                                "number",
                                                "null"
                                            ],
                                            "description": "Vertical shift from the anchored position, in PDF points (positive moves down). Default 0."
                                        }
                                    }
                                }
                            },
                            "required": [
                                "document_index",
                                "type"
                            ]
                        }
                    },
                    "cc_recipients": {
                        "type": [
                            "array",
                            "null"
                        ],
                        "description": "People who receive a copy of the executed documents without signing, for example a finance or legal mailbox.",
                        "items": {
                            "type": "object",
                            "properties": {
                                "name": {
                                    "type": [
                                        "string",
                                        "null"
                                    ],
                                    "description": "Recipient's name, used in the email greeting. Optional.",
                                    "maxLength": 255
                                },
                                "email": {
                                    "type": "string",
                                    "format": "email",
                                    "description": "Address the copy is sent to.",
                                    "maxLength": 255
                                }
                            },
                            "required": [
                                "email"
                            ]
                        }
                    }
                },
                "required": [
                    "title",
                    "documents",
                    "signers"
                ],
                "title": "StoreSignatureRequestRequest"
            },
            "TemplateDocumentKindEnum": {
                "type": "string",
                "description": "What a document inside a template is made of, and therefore how fields behave on it. Never chosen by the author. It follows from the file they brought: a PDF cannot be reflowed, everything else can. Presenting it as a mode to pick would only offer a way to pick the wrong one.\n| |\n|---|\n| `rich` <br/> Written here or imported from `.doc`/`.docx`, stored as an editable document. Text reflows when merge values are substituted, so fields are anchored and their coordinates are recovered from the rendered PDF, per request. |\n| `pdf` <br/> A PDF used exactly as uploaded. Nothing reflows, so fields carry final coordinates from the moment they are placed and no rendering happens when a request is built \u2014 the file is copied. |",
                "enum": [
                    "rich",
                    "pdf"
                ],
                "title": "TemplateDocumentKindEnum"
            },
            "TemplateResource": {
                "type": "object",
                "properties": {
                    "gid": {
                        "type": "string",
                        "description": "Public identifier of the template. Informational: the API addresses templates by `code`."
                    },
                    "code": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "Stable machine key, unique within your application. Send it as `documents[].template_code`."
                    },
                    "name": {
                        "type": "string",
                        "description": "Name as authored in the dashboard."
                    },
                    "description": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "Short explanation for people choosing a template. Null when none was written."
                    },
                    "is_active": {
                        "type": "boolean",
                        "description": "True when the template can be used in `POST /signature-requests`. Switch it on with `POST /templates/{code}/activate` once `activation.ready` is true."
                    },
                    "default_sequential": {
                        "type": [
                            "boolean",
                            "null"
                        ],
                        "description": "Whether the template suggests sequential signing. A suggestion for `sequential` on the request, not a rule."
                    },
                    "locales": {
                        "type": "array",
                        "description": "Language editions the template has (`id`, `en`). A request's `locale` picks the edition, falling back to Indonesian. Empty when every document is language-neutral.",
                        "items": {
                            "type": [
                                "string",
                                "null"
                            ]
                        }
                    },
                    "documents": {
                        "type": "array",
                        "description": "The documents the template renders into one request, in signing order.",
                        "items": {
                            "type": "object",
                            "properties": {
                                "gid": {
                                    "type": "string",
                                    "description": "Public identifier of the template document; the key of `prefill_keys` for PDF documents."
                                },
                                "name": {
                                    "type": "string",
                                    "description": "Title the signer sees above this document."
                                },
                                "kind": {
                                    "description": "`rich` for an editable document whose tags are substituted from `merge_fields`; `pdf` for a fixed file whose placed fields take data through `prefill`.\n| |\n|---|\n| `rich` <br/> Written here or imported from `.doc`/`.docx`, stored as an editable document. Text reflows when merge values are substituted, so fields are anchored and their coordinates are recovered from the rendered PDF, per request. |\n| `pdf` <br/> A PDF used exactly as uploaded. Nothing reflows, so fields carry final coordinates from the moment they are placed and no rendering happens when a request is built \u2014 the file is copied. |",
                                    "$ref": "#/components/schemas/TemplateDocumentKindEnum"
                                },
                                "locale": {
                                    "type": [
                                        "string",
                                        "null"
                                    ],
                                    "description": "Language edition of this document (`id` or `en`). Null when it is language-neutral and used for every locale."
                                },
                                "position": {
                                    "type": "integer",
                                    "description": "Position within the request, starting at 1."
                                },
                                "page_count": {
                                    "type": [
                                        "integer",
                                        "null"
                                    ],
                                    "description": "Number of pages. For a rich document, the page count of the last render; null before any render."
                                },
                                "prefill_keys": {
                                    "type": "array",
                                    "description": "Keys accepted in `documents[].prefill` for this document \u2014 the placed fields whose starting value the caller may supply. Empty for documents that take no prefill.",
                                    "items": {
                                        "type": "string"
                                    }
                                }
                            },
                            "required": [
                                "gid",
                                "name",
                                "kind",
                                "locale",
                                "position",
                                "page_count",
                                "prefill_keys"
                            ]
                        }
                    },
                    "roles": {
                        "type": "array",
                        "description": "The signing roles, in suggested signing order. Every key must be covered by a signer with the same `role_key`, or the request is refused.",
                        "items": {
                            "type": "object",
                            "properties": {
                                "key": {
                                    "type": "string",
                                    "description": "Value to send as `signers[].role_key`."
                                },
                                "label": {
                                    "type": "string",
                                    "description": "Human-readable name of the role as authored, for example \"Pihak Pertama\"."
                                },
                                "signing_order": {
                                    "type": "integer",
                                    "description": "Suggested position in the signing order, starting at 1."
                                }
                            },
                            "required": [
                                "key",
                                "label",
                                "signing_order"
                            ]
                        }
                    },
                    "merge_fields": {
                        "type": "array",
                        "description": "Every merge tag the template's documents substitute, in tag order. Send values keyed by `tag` in `documents[].merge_fields`.",
                        "items": {
                            "type": "object",
                            "properties": {
                                "tag": {
                                    "type": "string",
                                    "description": "The key to send in `merge_fields`, for example `signer1.party_name` or `agreement.number`."
                                },
                                "label": {
                                    "type": "string",
                                    "description": "What the value is, for people filling a form."
                                },
                                "required": {
                                    "type": "boolean",
                                    "description": "True when the rendered document needs a value: send one unless `default_value` is set. False for tags inside optional blocks."
                                },
                                "default_value": {
                                    "type": [
                                        "string",
                                        "null"
                                    ],
                                    "description": "Value used when you send none \u2014 boilerplate that lives in the template. A value you send always wins. Null when there is no default."
                                },
                                "formats": {
                                    "type": "array",
                                    "description": "Formats the value must be readable as, in the order the document uses them (for example `date`, `number`). Empty when the value is printed as sent.",
                                    "items": {
                                        "type": "string"
                                    }
                                },
                                "occurrences": {
                                    "type": "integer",
                                    "description": "How many times the tag appears across the documents. Informational."
                                }
                            },
                            "required": [
                                "tag",
                                "label",
                                "required",
                                "default_value",
                                "formats",
                                "occurrences"
                            ]
                        }
                    },
                    "collections": {
                        "type": "array",
                        "description": "The repeating tables `documents[].merge_rows` may fill, keyed by collection name, each listing the column keys of one row.",
                        "items": {
                            "type": "object",
                            "properties": {
                                "name": {
                                    "type": "string",
                                    "description": "Key to use in `merge_rows`."
                                },
                                "columns": {
                                    "type": "array",
                                    "description": "Column keys accepted in each row, left to right as printed.",
                                    "items": {
                                        "type": "string"
                                    }
                                }
                            },
                            "required": [
                                "name",
                                "columns"
                            ]
                        }
                    },
                    "materai_slots": {
                        "type": "integer",
                        "description": "Number of e-Meterai areas the template reserves. Informational; the stamp is affixed outside the platform.",
                        "minimum": 0
                    },
                    "activation": {
                        "type": "object",
                        "description": "Whether the template passes its activation checks right now, and why not when it does not.",
                        "properties": {
                            "ready": {
                                "type": "boolean",
                                "description": "True when `POST /templates/{code}/activate` would succeed."
                            },
                            "blocking": {
                                "type": "array",
                                "description": "Problems that block activation, in the language of `Accept-Language`. Empty when ready.",
                                "items": {
                                    "type": "string"
                                }
                            },
                            "warnings": {
                                "type": "array",
                                "description": "Things worth fixing that do not block activation.",
                                "items": {
                                    "type": "string"
                                }
                            }
                        },
                        "required": [
                            "ready",
                            "blocking",
                            "warnings"
                        ]
                    },
                    "updated_at": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "When the template was last changed (ISO-8601)."
                    }
                },
                "required": [
                    "gid",
                    "code",
                    "name",
                    "description",
                    "is_active",
                    "default_sequential",
                    "locales",
                    "documents",
                    "roles",
                    "merge_fields",
                    "collections",
                    "materai_slots",
                    "activation",
                    "updated_at"
                ],
                "title": "TemplateResource",
                "description": "A template in full: its documents, the roles a request must cover, every merge tag with whether it is required and how it must be formatted, the repeating collections `merge_rows` may fill, and whether the template passes its activation checks. The derived parts \u2014 formats, collections, prefill keys, activation \u2014 are computed by `TemplateContract` and handed in by the controller, so this class stays a literal array that Scramble can turn into a schema. The comments above each key become the property descriptions of the OpenAPI document. @mixin Template /"
            },
            "TemplateSummaryResource": {
                "type": "object",
                "properties": {
                    "gid": {
                        "type": "string",
                        "description": "Public identifier of the template. Informational: the API addresses templates by `code`."
                    },
                    "code": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "Stable machine key, unique within your application. Send it as `documents[].template_code`."
                    },
                    "name": {
                        "type": "string",
                        "description": "Name as authored in the dashboard."
                    },
                    "description": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "Short explanation for people choosing a template. Null when none was written."
                    },
                    "is_active": {
                        "type": "boolean",
                        "description": "True when the template can be used in `POST /signature-requests`. A template is born inactive and is switched on with `POST /templates/{code}/activate` once it passes its checks."
                    },
                    "default_sequential": {
                        "type": [
                            "boolean",
                            "null"
                        ],
                        "description": "Whether the template suggests sequential signing. A suggestion for `sequential` on the request, not a rule."
                    },
                    "locales": {
                        "type": "array",
                        "description": "Language editions the template has (`id`, `en`). A request's `locale` picks the edition, falling back to Indonesian. Empty when every document is language-neutral.",
                        "items": {
                            "type": [
                                "string",
                                "null"
                            ]
                        }
                    },
                    "document_count": {
                        "type": "integer",
                        "description": "Number of documents the template renders into one request.",
                        "minimum": 0
                    },
                    "roles": {
                        "type": "array",
                        "description": "The signing roles, in suggested signing order. Every key must be covered by a signer with the same `role_key`.",
                        "items": {
                            "type": "object",
                            "properties": {
                                "key": {
                                    "type": "string",
                                    "description": "Value to send as `signers[].role_key`."
                                },
                                "label": {
                                    "type": "string",
                                    "description": "Human-readable name of the role as authored, for example \"Pihak Pertama\"."
                                },
                                "signing_order": {
                                    "type": "integer",
                                    "description": "Suggested position in the signing order, starting at 1."
                                }
                            },
                            "required": [
                                "key",
                                "label",
                                "signing_order"
                            ]
                        }
                    },
                    "updated_at": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "When the template was last changed (ISO-8601)."
                    }
                },
                "required": [
                    "gid",
                    "code",
                    "name",
                    "description",
                    "is_active",
                    "default_sequential",
                    "locales",
                    "document_count",
                    "roles",
                    "updated_at"
                ],
                "title": "TemplateSummaryResource",
                "description": "One of your templates as the list shows it: identity, whether it can be used, and the roles a request must cover. Read `GET /templates/{code}` for the tags and collections it expects. The comments above each key become the property descriptions of the OpenAPI document. @mixin Template /"
            },
            "TestMailMessageResource": {
                "type": "object",
                "properties": {
                    "gid": {
                        "type": "string",
                        "description": "Public identifier of the message."
                    },
                    "signature_request_gid": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "`gid` of the test-mode signature request the message belongs to. Null when that request no longer exists."
                    },
                    "to": {
                        "type": "string",
                        "description": "Address the message would have been delivered to."
                    },
                    "to_name": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "Recipient name as it would have appeared. Null when none was given."
                    },
                    "subject": {
                        "type": "string",
                        "description": "Subject line."
                    },
                    "kind": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "Which kind of message this is, e.g. `SignerInvitationMail`, `SignerOtpMail`, `SignerReminderMail`, `FinalDocumentsMail`, `SenderStatusMail`."
                    },
                    "codes": {
                        "type": "array",
                        "description": "Six-digit codes found in the message, in order \u2014 the one-time code of a `SignerOtpMail` is the first.",
                        "items": {}
                    },
                    "links": {
                        "type": "array",
                        "description": "Links a reader could follow, in order, without `mailto:` addresses. An invitation's first link opens the signing page.",
                        "items": {}
                    },
                    "text": {
                        "type": "string",
                        "description": "The message as plain text."
                    },
                    "html": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "The HTML body as it would have been sent. Null for a plain-text message."
                    },
                    "created_at": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "When the message was written to the outbox (ISO-8601)."
                    }
                },
                "required": [
                    "gid",
                    "signature_request_gid",
                    "to",
                    "to_name",
                    "subject",
                    "kind",
                    "codes",
                    "links",
                    "text",
                    "html",
                    "created_at"
                ],
                "title": "TestMailMessageResource",
                "description": "One message from the test outbox \u2014 what a test-mode request would have emailed (R70). The code and the links are read out for the caller, because that is what a message is opened for: an agent or a CI job needs the one-time code or the signing link, not a DOM. @mixin TestMailMessage /"
            },
            "UpdateSignerRequest": {
                "type": "object",
                "description": "Payload of `PATCH /api/v1/signature-requests/{gid}/signers/{signerGid}`: the corrected name\nor address of somebody who has not signed yet. Send only what changes.\n\nDeliberately just these two. A signer's `role_key` decides which part of a template they\nsign, and `verification_method` decides how hard it is to prove they are who the invitation\nwent to \u2014 changing either after a document is out would rewrite terms the other parties are\nalready acting on. Those stay as the request was created.",
                "properties": {
                    "name": {
                        "type": "string",
                        "description": "The signer's corrected name, as it should appear on the document.",
                        "maxLength": 255
                    },
                    "email": {
                        "type": "string",
                        "format": "email",
                        "description": "The corrected address. Changing it invalidates any signing link already sent to the old one and emails a new invitation to this address.",
                        "maxLength": 255
                    }
                },
                "title": "UpdateSignerRequest"
            },
            "UpdateWebhookRequest": {
                "type": "object",
                "description": "Payload of `PUT /api/v1/webhook`: where your application's events go, which of them you want,\nand whether delivery is switched on.\n\nA full replacement, not a patch \u2014 `subscribed_events` is the list you end up with, so an\nomitted event is an unsubscribed event. That is deliberate for a setting a client may write\nfrom its own configuration: a merge would make a removed line in that configuration do\nnothing, which is the one behaviour nobody expects from an endpoint called PUT.",
                "properties": {
                    "url": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "format": "uri",
                        "description": "HTTPS URL the platform POSTs events to, reachable from the public internet \u2014 local and private-network addresses are refused. Send null to stop delivering: the endpoint is remembered and switched off rather than deleted, so the history of what was already sent is kept.",
                        "maxLength": 500
                    },
                    "subscribed_events": {
                        "type": "array",
                        "description": "The events you want delivered, as a complete list. Everything you do not name stops arriving. See `available_events` in `GET /webhook` for the valid names.",
                        "examples": [
                            [
                                "signature_request.completed",
                                "signer.declined"
                            ]
                        ],
                        "items": {
                            "type": "string"
                        }
                    },
                    "is_active": {
                        "type": [
                            "boolean",
                            "null"
                        ],
                        "description": "False to pause delivery without forgetting the endpoint \u2014 nothing is sent while it is off, and events that happen meanwhile are not queued for later. Defaults to true."
                    }
                },
                "required": [
                    "url"
                ],
                "title": "UpdateWebhookRequest"
            },
            "WebhookDeliveryResource": {
                "type": "object",
                "properties": {
                    "delivery_id": {
                        "type": "string",
                        "description": "Identifier of this delivery, identical to the `X-Delivery-Id` header your endpoint received and stable across retries. Use it to retry, and to look up what you deduplicated on."
                    },
                    "event": {
                        "type": "string",
                        "description": "The event that was delivered, for example `signature_request.completed`. `webhook.ping` for a test delivery."
                    },
                    "status": {
                        "description": "Where the delivery stands.\n| |\n|---|\n| `pending` <br/> Queued, not yet attempted. |\n| `delivered` <br/> The endpoint answered 2xx. |\n| `failed` <br/> Every retry was exhausted without a 2xx. |",
                        "$ref": "#/components/schemas/WebhookDeliveryStatusEnum"
                    },
                    "attempt_count": {
                        "type": "integer",
                        "description": "How many times the platform has tried, including the attempt in flight. Retries run 1 minute, 5 minutes, 30 minutes, 2 hours and 12 hours after the first failure."
                    },
                    "response_status_code": {
                        "type": [
                            "integer",
                            "null"
                        ],
                        "description": "HTTP status your endpoint answered with on the last attempt. Null when the attempt never got an answer \u2014 a timeout or a connection failure."
                    },
                    "last_attempted_at": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "When the last attempt was made (ISO-8601). Null while the first attempt is still queued."
                    },
                    "created_at": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "When the event happened and the delivery was queued (ISO-8601)."
                    },
                    "payload": {
                        "type": "array",
                        "description": "The exact body that was POSTed, envelope included. What was signed, so you can replay verification against it.",
                        "items": {}
                    },
                    "is_retryable": {
                        "type": "boolean",
                        "description": "True while `POST /webhook-deliveries/{delivery_id}/retry` would do something. False once the delivery has landed."
                    }
                },
                "required": [
                    "delivery_id",
                    "event",
                    "status",
                    "attempt_count",
                    "response_status_code",
                    "last_attempted_at",
                    "created_at",
                    "payload",
                    "is_retryable"
                ],
                "title": "WebhookDeliveryResource",
                "description": "One attempt to hand an event to your endpoint: which event, how it went, how many attempts it took, and what your server answered. This is the record a client consults when an event never arrived \u2014 the platform's side of the story, including the deliveries that are still being retried. The comments above each key become the property descriptions of the OpenAPI document. @mixin WebhookDelivery /"
            },
            "WebhookDeliveryStatusEnum": {
                "type": "string",
                "description": "Outcome of one webhook delivery attempt (SCHEMA.md \u00a72.9). Delivery is at-least-once and unordered, so the receiving application deduplicates on the `X-Delivery-Id` header rather than trusting arrival order (R34).\n| |\n|---|\n| `pending` <br/> Queued, not yet attempted. |\n| `delivered` <br/> The endpoint answered 2xx. |\n| `failed` <br/> Every retry was exhausted without a 2xx. |",
                "enum": [
                    "pending",
                    "delivered",
                    "failed"
                ],
                "title": "WebhookDeliveryStatusEnum"
            },
            "WebhookResource": {
                "type": "object",
                "properties": {
                    "url": {
                        "type": "string",
                        "description": "The endpoint the platform remembers for this application. Null when none has ever been configured. Delivery happens only while `is_active` is true, so a URL here with `is_active` false means nothing is being sent."
                    },
                    "subscribed_events": {
                        "type": "array",
                        "description": "Events this endpoint receives. Anything outside the list is not delivered, whatever happens on the platform.",
                        "items": {
                            "type": "string"
                        }
                    },
                    "is_active": {
                        "type": "boolean",
                        "description": "Whether events are being delivered. False when no endpoint has been configured, and when one was switched off or cleared \u2014 the endpoint is remembered, and nothing is sent to it."
                    },
                    "has_secret": {
                        "type": "boolean",
                        "description": "Whether a signing secret exists. The secret itself is only ever shown once, by `POST /webhook/rotate-secret`; without one, deliveries cannot be signed."
                    },
                    "available_events": {
                        "type": "array",
                        "description": "Every event name you may subscribe to. `webhook.ping` is not among them: a ping is sent only when you ask for one, and always reaches the endpoint whatever it subscribes to.",
                        "items": {
                            "type": "string"
                        }
                    }
                },
                "required": [
                    "url",
                    "subscribed_events",
                    "is_active",
                    "has_secret",
                    "available_events"
                ],
                "title": "WebhookResource",
                "description": "Where your application's events are delivered: the URL, the events it subscribes to, whether delivery is switched on, and whether a signing secret exists. Read from the `webhooks` row and nowhere else, because that row is what `WebhookDispatcher` delivers to. `applications.account_callback_url` mirrors it for the dashboard's settings screen, and reporting *that* would let this endpoint answer \"your events go here\" for an application where nothing is delivered at all \u2014 the one answer a client cannot afford to be told. An application carrying only the column reads as unconfigured, and configuring it through `PUT /webhook` makes both true at once. The secret itself is never here. It is readable exactly once, in the answer to `POST /webhook/rotate-secret` or when it is first created; after that the API can only say that there is one. The comments above each key become the property descriptions of the OpenAPI document. /"
            },
            "ErrorCode": {
                "type": "string",
                "title": "ErrorCode",
                "description": "Machine-readable reason of an API error. Stable and never translated \u2014 branch on this, not on `message`.\n\n| Code | HTTP | Meaning and what to do |\n|---|---|---|\n| `unauthorized` | 401 | The API key is missing, malformed, unknown or revoked. Check the `Authorization: Bearer` header; do not retry automatically. |\n| `application_inactive` | 403 | The key is valid but its application has been deactivated by the platform operator. Contact Lokasign support. |\n| `forbidden` | 403 | The key may not perform this action on this resource. Reserved for future permission scopes; not answered by any current operation. |\n| `not_found` | 404 | No resource with that `gid` exists for your application. Also the answer for a `gid` that belongs to another application \u2014 existence is never disclosed across applications. |\n| `method_not_allowed` | 405 | The path exists but not with this HTTP method. |\n| `validation_failed` | 422 | The payload or query string is invalid. `field` names the first thing to fix and `message` says why. Correct the request; retrying it unchanged will fail again. |\n| `rate_limited` | 429 | Too many requests in a minute for this API key (see `limits.requests_per_minute` in `GET /application`), or too many requests with a missing or wrong key from one address. Wait for the number of seconds in `Retry-After`, then retry. |\n| `http_error` | 400 | The request could not be processed for an HTTP-level reason not covered by a more specific code (for example an unreadable body). The actual status varies. |\n| `server_error` | 500 | Something failed on the platform; details are not disclosed. Retry with backoff, and quote `request_id` when contacting support. |\n| `idempotency_key_reused` | 409 | This `Idempotency-Key` was already used within the last 24 hours with a different body. Use a new key for new work; reuse a key only to retry the identical request. |\n| `external_ref_taken` | 422 | Another live or completed request of your application already carries this `external_ref`. Look it up with `GET /signature-requests?external_ref=` instead of creating a duplicate. A reference is freed when its request is voided, declined or expired. |\n| `document_not_found` | 422 | A `documents[].document_gid` does not name a document of your application. Upload it first with `POST /documents`, or check the `gid`. |\n| `application_without_sender` | 409 | Your application's organisation has no owner account to act as the sender of record, so no request can be created yet. Ask the organisation owner to complete their Lokasign account. |\n| `request_not_draft` | 409 | The request has already been sent, so its content can no longer be rewritten. Void it and create a new one. |\n| `request_not_voidable` | 409 | The request has already ended (`completed`, `declined`, `expired` or `voided`) and cannot be voided. `message` names its current status. |\n| `request_not_remindable` | 409 | Reminders can only be sent while a request is `sent` or `partially_signed`. Read the request to see where it stands. |\n| `reminder_cooldown` | 429 | Every signer who could be reminded was reminded less than 24 hours ago (manually or by the platform). Wait; nothing was sent. |\n| `signer_embedded` | 409 | Every signer you asked to remind has `delivery: embedded`: Lokasign never emailed them a link, so there is nothing to remind them of. Nudge them in your own interface and open a session with `POST /signing-sessions`. |\n| `signer_not_found` | 404 | The `signer_gid` does not belong to this request. Use a `signers[].gid` from `GET /signature-requests/{gid}`. |\n| `request_not_completed` | 409 | Executed documents exist only once the request is `completed`. Wait for the `signature_request.completed` webhook, then call again. |\n| `documents_not_sealed` | 409 | The request is completed but the platform seal has not been applied to its documents yet, so they are withheld. Retry in a few minutes; if it persists, contact support with `request_id`. |\n| `documents_not_ready` | 409 | The request's documents are still being rendered from their templates (`documents_pending` > 0). Retry shortly. |\n| `document_fetch_failed` | 422 | The `document_url` could not be downloaded (connection error, non-2xx answer, or too many redirects). Check that the URL is public and serves the file directly. |\n| `document_url_scheme` | 422 | `document_url` must use `https`. |\n| `document_url_blocked` | 422 | `document_url` resolves to a private or reserved network address, which the platform refuses to fetch. Host the file on a public address. |\n| `anchor_not_found` | 422 | A field's `anchor.text` does not occur anywhere in its document, so the box has nowhere to go. `field` names the entry (`fields.N.anchor.text`). Check the exact wording, punctuation included, or place the field with `page_number`, `x` and `y`. |\n| `document_too_large` | 422 | The file exceeds the 25 MB limit. Reduce it (for example by downsampling images) and try again. |\n| `document_not_pdf` | 422 | The bytes are not a PDF, whatever the file extension or `Content-Type` said. Export the document as PDF and upload that. |\n| `document_encrypted` | 422 | The PDF is password-protected and cannot be processed. Remove the protection and upload again. |\n| `document_not_sanitisable` | 422 | The PDF contains active content (scripts or attachments) that could not be stripped. Re-export it as a plain PDF and upload again. |\n| `template_not_activatable` | 409 | The template fails one of its activation checks \u2014 no document, an unreadable document, a tag typed as plain text, a role without a signature field, a field without a role. `message` names the first; `GET /templates/{code}` lists them all under `activation.blocking`. Fix the template in the dashboard, then activate again. |\n| `signer_not_correctable` | 409 | The signer has already signed or declined, or the request has ended \u2014 either way the document is past the point where the recipient can be changed. Create a new request instead. |\n| `webhook_not_configured` | 409 | The application has no active webhook endpoint, so there is nothing to sign for or to ping. Configure one with `PUT /webhook` first. |\n| `delivery_already_delivered` | 409 | That delivery already landed, so it cannot be retried. Your handler has seen this event; if it was not processed, replay it from the `payload` in `GET /webhook-deliveries`. |\n| `upload_link_invalid` | 404 | The upload link is unknown, or the API key that issued it was revoked or its application deactivated. Create a new link with `createDocumentUpload`. |\n| `upload_link_expired` | 410 | The upload link passed its 15 minutes without receiving a file. Create a new link with `createDocumentUpload`. |\n| `upload_link_used` | 409 | The upload link already took one file, which is all a link takes. Read the document from `getDocumentUpload`, or create a new link for another file. |\n| `test_mode_only` | 403 | The endpoint exists only for test-mode keys (`esk_test_\u2026`), or the request is live data. Issue a test key in the dashboard (API & Webhook \u2192 Buat key \u2192 Uji) and repeat the call with it. |\n| `embedder_origin_not_allowed` | 403 | `embedder_origin` is not on the API key's `allowed_origins`. Add the origin to the key in the dashboard, or send the origin the page is really served from. |\n| `return_url_not_allowed` | 403 | An `http(s)` `return_url` must be on the API key's `allowed_origins`, and `javascript:`, `data:`, `file:` and similar schemes are never accepted. Register the origin on the key, or use your app's own scheme (`myapp://\u2026`). |\n| `signer_not_pending` | 422 | The signer has already signed or declined, or \u2014 in a sequential request \u2014 it is not their turn yet. Read the request to see who is up. |\n| `exchange_code_invalid` | 422 | The exchange code is unknown, was already redeemed, has expired (5 minutes), or belongs to another application. Codes are single-use; read `GET /signature-requests/{gid}` for the current state instead. |",
                "enum": [
                    "unauthorized",
                    "application_inactive",
                    "forbidden",
                    "not_found",
                    "method_not_allowed",
                    "validation_failed",
                    "rate_limited",
                    "http_error",
                    "server_error",
                    "idempotency_key_reused",
                    "external_ref_taken",
                    "document_not_found",
                    "application_without_sender",
                    "request_not_draft",
                    "request_not_voidable",
                    "request_not_remindable",
                    "reminder_cooldown",
                    "signer_embedded",
                    "signer_not_found",
                    "request_not_completed",
                    "documents_not_sealed",
                    "documents_not_ready",
                    "document_fetch_failed",
                    "document_url_scheme",
                    "document_url_blocked",
                    "anchor_not_found",
                    "document_too_large",
                    "document_not_pdf",
                    "document_encrypted",
                    "document_not_sanitisable",
                    "template_not_activatable",
                    "signer_not_correctable",
                    "webhook_not_configured",
                    "delivery_already_delivered",
                    "upload_link_invalid",
                    "upload_link_expired",
                    "upload_link_used",
                    "test_mode_only",
                    "embedder_origin_not_allowed",
                    "return_url_not_allowed",
                    "signer_not_pending",
                    "exchange_code_invalid"
                ]
            },
            "ApiError": {
                "type": "object",
                "title": "ApiError",
                "description": "The one shape every error answer has, whatever the status. `code` is for your logic, `message` for your logs, `request_id` for support.",
                "required": [
                    "error"
                ],
                "properties": {
                    "error": {
                        "type": "object",
                        "description": "The error. Always present on an error response, never on a successful one.",
                        "required": [
                            "code",
                            "message",
                            "field",
                            "request_id"
                        ],
                        "properties": {
                            "code": {
                                "$ref": "#/components/schemas/ErrorCode"
                            },
                            "message": {
                                "type": "string",
                                "description": "Human-readable explanation in the language of `Accept-Language` (`id` by default, `en` supported). Wording may change; never branch on it."
                            },
                            "field": {
                                "type": [
                                    "string",
                                    "null"
                                ],
                                "description": "Dotted path of the first invalid input (for example `documents.0.merge_fields`) when the error is about one; null otherwise."
                            },
                            "request_id": {
                                "type": "string",
                                "format": "uuid",
                                "description": "Identifier of this request on the platform, also sent as the `X-Request-Id` header. Quote it when contacting support."
                            }
                        }
                    }
                }
            },
            "SignatureRequestDocumentFromUrl": {
                "title": "Document from a URL",
                "description": "A PDF the platform fetches from a public HTTPS URL when the request is created.",
                "type": "object",
                "properties": {
                    "document_url": {
                        "type": "string",
                        "format": "uri",
                        "description": "Public HTTPS URL of a PDF to fetch now (at most 25 MB, not password-protected). The platform downloads and stores it before answering; private network addresses are refused. Use exactly one of `document_url`, `document_gid`, `template_code`.",
                        "maxLength": 1000
                    },
                    "sort_order": {
                        "type": [
                            "integer",
                            "null"
                        ],
                        "description": "Position of this document within the request. Omit to keep the order of the array.",
                        "minimum": 0
                    }
                },
                "required": [
                    "document_url"
                ]
            },
            "SignatureRequestDocumentFromGid": {
                "title": "Document uploaded earlier",
                "description": "A PDF already stored through `POST /documents`, referenced by its `gid`.",
                "type": "object",
                "properties": {
                    "document_gid": {
                        "type": "string",
                        "format": "uuid",
                        "description": "`gid` of a document previously stored through `POST /documents`, to reuse it in this request. Use exactly one of `document_url`, `document_gid`, `template_code`."
                    },
                    "sort_order": {
                        "type": [
                            "integer",
                            "null"
                        ],
                        "description": "Position of this document within the request. Omit to keep the order of the array.",
                        "minimum": 0
                    }
                },
                "required": [
                    "document_gid"
                ]
            },
            "SignatureRequestDocumentFromTemplate": {
                "title": "Document rendered from a template",
                "description": "A document the platform renders from one of your templates with the data you send. The only way to send data instead of a file; used by clients that have no PDF renderer of their own.",
                "type": "object",
                "properties": {
                    "template_code": {
                        "type": "string",
                        "description": "Code of one of your active templates (see `GET /templates`). The platform renders the template's documents with `merge_fields` and `merge_rows` on a queue; the request stays `draft` with `documents_pending` > 0 until rendering finishes. Every role the template declares must be covered by a signer with the same `role_key`. Use exactly one of `document_url`, `document_gid`, `template_code`.",
                        "maxLength": 100
                    },
                    "merge_fields": {
                        "type": "object",
                        "description": "Values for the template's merge tags, keyed by tag name (for example `signer1.party_name`). Only with `template_code`. A required tag with neither a value here nor a stored default is refused with 422; a value sent here always wins over the default. Values must be readable in the format the tag declares (dates as ISO-8601 `YYYY-MM-DD`, numbers as plain digits).",
                        "examples": [
                            {
                                "signer1.party_name": "PT Musik Nusantara",
                                "signer1.deed_date": "2019-03-14"
                            }
                        ],
                        "additionalProperties": {
                            "type": [
                                "string",
                                "null"
                            ]
                        }
                    },
                    "merge_rows": {
                        "type": "object",
                        "description": "Rows for the template's repeating tables, keyed by collection name, each an array of rows keyed by column. The collection name is the tag prefix the template chose \u2014 `songs` for `{{data|name:songs.TITLE}}`, `sessions` for `{{data|name:sessions.DATE}}`; none is reserved, and `GET /templates/{code}` lists them under `collections`. Only with `template_code`. The template's row is cloned once per entry; an empty array removes the row.",
                        "examples": [
                            {
                                "songs": [
                                    {
                                        "NO": "1",
                                        "TITLE": "Senja di Jakarta",
                                        "ISWC": "T-123.456.789-0"
                                    }
                                ]
                            }
                        ],
                        "additionalProperties": {
                            "type": "array",
                            "items": {
                                "type": "object",
                                "additionalProperties": {
                                    "type": [
                                        "string",
                                        "null"
                                    ]
                                }
                            }
                        }
                    },
                    "prefill": {
                        "type": "object",
                        "description": "Starting values for the fields placed on a template's PDF document, keyed by the field's `prefill_key` (see `GET /templates/{code}`). Only with `template_code`. The signer may still edit a prefilled field; what you sent and what was signed are both kept.",
                        "examples": [
                            {
                                "SONG_TITLE": "Senja di Jakarta"
                            }
                        ],
                        "additionalProperties": {
                            "type": [
                                "string",
                                "null"
                            ]
                        }
                    },
                    "sort_order": {
                        "type": [
                            "integer",
                            "null"
                        ],
                        "description": "Position of this document within the request. Omit to keep the order of the array.",
                        "minimum": 0
                    }
                },
                "required": [
                    "template_code"
                ]
            },
            "WebhookEnvelope": {
                "type": "object",
                "title": "WebhookEnvelope",
                "description": "The body every webhook delivery has. `external_ref` sits at the top level so a receiver can find its own record without knowing the event type; `occurred_at` \u2014 not arrival order \u2014 is what to reconcile against, because deliveries can arrive out of order and more than once.",
                "required": [
                    "event",
                    "signature_request_gid",
                    "external_ref",
                    "test",
                    "occurred_at",
                    "data"
                ],
                "properties": {
                    "event": {
                        "type": "string",
                        "description": "What happened. One of the `NotificationEventEnum` values, or `webhook.ping` for a test delivery."
                    },
                    "signature_request_gid": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "format": "uuid",
                        "description": "Public identifier of the request the event is about. Null only for `webhook.ping`, which belongs to no request."
                    },
                    "external_ref": {
                        "type": [
                            "string",
                            "null"
                        ],
                        "description": "The request's `external_ref` as you sent it at creation. Null when none was given, and for `webhook.ping`."
                    },
                    "test": {
                        "type": "boolean",
                        "description": "True when the request was made with a test-mode key: nothing was emailed, and its executed documents carry a SPECIMEN watermark and no platform seal. Route these to your test handling, or ignore them in production. False for `webhook.ping`."
                    },
                    "occurred_at": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When the event happened on the platform (ISO-8601). Order events by this, not by when they arrived."
                    },
                    "data": {
                        "type": "object",
                        "description": "Event-specific details; see each event."
                    }
                }
            }
        }
    },
    "webhooks": {
        "signatureRequestSent": {
            "post": {
                "operationId": "webhook.signatureRequestSent",
                "tags": [
                    "Webhooks"
                ],
                "summary": "Invitations went out; the request left `draft`.",
                "description": "Sent after the invitation emails have been dispatched \u2014 a client that hears `sent` may assume someone was actually asked. Fires for `POST /signature-requests/{gid}/send` and for requests created with `send_when_ready`.\n\nDelivered as a `POST` to your endpoint, signed with your webhook secret. See the *Webhooks* section of the introduction for verification, retries and ordering.",
                "parameters": [
                    {
                        "name": "X-Signature",
                        "in": "header",
                        "required": true,
                        "description": "`t=<unix timestamp>,v1=<hex HMAC-SHA256>` where the HMAC is computed with your webhook secret over the string `{t}.{raw request body}`. Recompute it over the raw bytes, compare in constant time, and reject a `t` more than 5 minutes from now.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "t=1758178981,v1=5f1c9a0e7c3b2d8e6a4f1b0c9d8e7f6a5b4c3d2e1f0a9b8c7d6e5f4a3b2c1d0e"
                    },
                    {
                        "name": "X-Delivery-Id",
                        "in": "header",
                        "required": true,
                        "description": "Identifier of this delivery, identical across retries of the same event. Deduplicate on it: process each value once and acknowledge repeats.",
                        "schema": {
                            "type": "string",
                            "format": "uuid"
                        },
                        "example": "0199a1c5-0e1a-7f22-9c3b-6d7e8f9a0b1c"
                    },
                    {
                        "name": "X-Delivery-Attempt",
                        "in": "header",
                        "required": true,
                        "description": "Attempt number of this delivery, starting at 1.",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "example": 1
                    },
                    {
                        "name": "X-Event-Type",
                        "in": "header",
                        "required": true,
                        "description": "The event name, identical to `event` in the body, so a receiver can route before parsing.",
                        "schema": {
                            "type": "string",
                            "const": "signature_request.sent"
                        },
                        "example": "signature_request.sent"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "allOf": [
                                    {
                                        "$ref": "#/components/schemas/WebhookEnvelope"
                                    },
                                    {
                                        "type": "object",
                                        "properties": {
                                            "event": {
                                                "type": "string",
                                                "const": "signature_request.sent",
                                                "description": "Always `signature_request.sent` for this webhook."
                                            },
                                            "data": {
                                                "type": "object",
                                                "description": "Event-specific details, on top of the request's `status` and `title` that every event about a request carries.",
                                                "properties": {
                                                    "status": {
                                                        "$ref": "#/components/schemas/SignatureRequestStatusEnum"
                                                    },
                                                    "title": {
                                                        "type": "string",
                                                        "description": "Title of the request."
                                                    },
                                                    "invitations_sent": {
                                                        "type": "integer",
                                                        "description": "How many invitation emails were dispatched: every signer, or only the first one of a sequential request."
                                                    },
                                                    "expires_at": {
                                                        "type": [
                                                            "string",
                                                            "null"
                                                        ],
                                                        "format": "date-time",
                                                        "description": "Deadline for signing (ISO-8601), set at send time from the request or your organisation's default."
                                                    }
                                                },
                                                "required": [
                                                    "status",
                                                    "title"
                                                ]
                                            }
                                        }
                                    }
                                ]
                            },
                            "example": {
                                "event": "signature_request.sent",
                                "signature_request_gid": "0199a1c4-3f1e-7d2a-8b3c-5e6f7a8b9c0d",
                                "external_ref": "company:0198f1a2-8c4d-7e5b-9a6f-1b2c3d4e5f60",
                                "test": false,
                                "occurred_at": "2026-09-18T14:03:01+07:00",
                                "data": {
                                    "status": "sent",
                                    "title": "Perjanjian Kerjasama \u2014 PT Musik Nusantara",
                                    "invitations_sent": 1,
                                    "expires_at": "2026-10-17T09:04:00+07:00"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "2XX": {
                        "description": "Acknowledged. Answer within 10 seconds and do the real work afterwards; the body is ignored."
                    },
                    "default": {
                        "description": "Any other status, or no answer within 10 seconds, counts as a failed attempt. The delivery is retried after 1 minute, 5 minutes, 30 minutes, 2 hours and 12 hours, then marked failed; a failed delivery can be replayed from the dashboard."
                    }
                }
            }
        },
        "signerViewed": {
            "post": {
                "operationId": "webhook.signerViewed",
                "tags": [
                    "Webhooks"
                ],
                "summary": "A signer opened the document for the first time.",
                "description": "Fires once per signer, the first time they pass the verification step and see the document. Useful for \"viewed, not yet signed\" nudges.\n\nDelivered as a `POST` to your endpoint, signed with your webhook secret. See the *Webhooks* section of the introduction for verification, retries and ordering.",
                "parameters": [
                    {
                        "name": "X-Signature",
                        "in": "header",
                        "required": true,
                        "description": "`t=<unix timestamp>,v1=<hex HMAC-SHA256>` where the HMAC is computed with your webhook secret over the string `{t}.{raw request body}`. Recompute it over the raw bytes, compare in constant time, and reject a `t` more than 5 minutes from now.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "t=1758178981,v1=5f1c9a0e7c3b2d8e6a4f1b0c9d8e7f6a5b4c3d2e1f0a9b8c7d6e5f4a3b2c1d0e"
                    },
                    {
                        "name": "X-Delivery-Id",
                        "in": "header",
                        "required": true,
                        "description": "Identifier of this delivery, identical across retries of the same event. Deduplicate on it: process each value once and acknowledge repeats.",
                        "schema": {
                            "type": "string",
                            "format": "uuid"
                        },
                        "example": "0199a1c5-0e1a-7f22-9c3b-6d7e8f9a0b1c"
                    },
                    {
                        "name": "X-Delivery-Attempt",
                        "in": "header",
                        "required": true,
                        "description": "Attempt number of this delivery, starting at 1.",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "example": 1
                    },
                    {
                        "name": "X-Event-Type",
                        "in": "header",
                        "required": true,
                        "description": "The event name, identical to `event` in the body, so a receiver can route before parsing.",
                        "schema": {
                            "type": "string",
                            "const": "signer.viewed"
                        },
                        "example": "signer.viewed"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "allOf": [
                                    {
                                        "$ref": "#/components/schemas/WebhookEnvelope"
                                    },
                                    {
                                        "type": "object",
                                        "properties": {
                                            "event": {
                                                "type": "string",
                                                "const": "signer.viewed",
                                                "description": "Always `signer.viewed` for this webhook."
                                            },
                                            "data": {
                                                "type": "object",
                                                "description": "Event-specific details, on top of the request's `status` and `title` that every event about a request carries.",
                                                "properties": {
                                                    "status": {
                                                        "$ref": "#/components/schemas/SignatureRequestStatusEnum"
                                                    },
                                                    "title": {
                                                        "type": "string",
                                                        "description": "Title of the request."
                                                    },
                                                    "signer": {
                                                        "type": "object",
                                                        "description": "The signer this event is about.",
                                                        "properties": {
                                                            "gid": {
                                                                "type": "string",
                                                                "format": "uuid",
                                                                "description": "Public identifier of the signer."
                                                            },
                                                            "name": {
                                                                "type": "string",
                                                                "description": "Signer's name."
                                                            },
                                                            "email": {
                                                                "type": "string",
                                                                "format": "email",
                                                                "description": "Signer's email address."
                                                            },
                                                            "status": {
                                                                "$ref": "#/components/schemas/SignerStatusEnum"
                                                            },
                                                            "order_index": {
                                                                "type": "integer",
                                                                "description": "Position in the signing order, starting at 1."
                                                            },
                                                            "role_key": {
                                                                "type": [
                                                                    "string",
                                                                    "null"
                                                                ],
                                                                "description": "Machine role key of the signer (for example `party`, `operator`). Null when none was given."
                                                            }
                                                        },
                                                        "required": [
                                                            "gid",
                                                            "name",
                                                            "email",
                                                            "status",
                                                            "order_index",
                                                            "role_key"
                                                        ]
                                                    }
                                                },
                                                "required": [
                                                    "status",
                                                    "title"
                                                ]
                                            }
                                        }
                                    }
                                ]
                            },
                            "example": {
                                "event": "signer.viewed",
                                "signature_request_gid": "0199a1c4-3f1e-7d2a-8b3c-5e6f7a8b9c0d",
                                "external_ref": "company:0198f1a2-8c4d-7e5b-9a6f-1b2c3d4e5f60",
                                "test": false,
                                "occurred_at": "2026-09-18T14:03:01+07:00",
                                "data": {
                                    "status": "sent",
                                    "title": "Perjanjian Kerjasama \u2014 PT Musik Nusantara",
                                    "signer": {
                                        "gid": "0199a1c4-40aa-7e01-b2c3-d4e5f6a7b8c9",
                                        "name": "Rina Kartika",
                                        "email": "rina@musiknusantara.id",
                                        "status": "viewed",
                                        "order_index": 1,
                                        "role_key": "party"
                                    }
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "2XX": {
                        "description": "Acknowledged. Answer within 10 seconds and do the real work afterwards; the body is ignored."
                    },
                    "default": {
                        "description": "Any other status, or no answer within 10 seconds, counts as a failed attempt. The delivery is retried after 1 minute, 5 minutes, 30 minutes, 2 hours and 12 hours, then marked failed; a failed delivery can be replayed from the dashboard."
                    }
                }
            }
        },
        "signerSigned": {
            "post": {
                "operationId": "webhook.signerSigned",
                "tags": [
                    "Webhooks"
                ],
                "summary": "A signer submitted their fields.",
                "description": "Fires for each signer as they sign. The request's own `status` in the payload says whether others are still pending (`partially_signed`) \u2014 completion is announced separately by `signature_request.completed`, and only after sealing.\n\nDelivered as a `POST` to your endpoint, signed with your webhook secret. See the *Webhooks* section of the introduction for verification, retries and ordering.",
                "parameters": [
                    {
                        "name": "X-Signature",
                        "in": "header",
                        "required": true,
                        "description": "`t=<unix timestamp>,v1=<hex HMAC-SHA256>` where the HMAC is computed with your webhook secret over the string `{t}.{raw request body}`. Recompute it over the raw bytes, compare in constant time, and reject a `t` more than 5 minutes from now.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "t=1758178981,v1=5f1c9a0e7c3b2d8e6a4f1b0c9d8e7f6a5b4c3d2e1f0a9b8c7d6e5f4a3b2c1d0e"
                    },
                    {
                        "name": "X-Delivery-Id",
                        "in": "header",
                        "required": true,
                        "description": "Identifier of this delivery, identical across retries of the same event. Deduplicate on it: process each value once and acknowledge repeats.",
                        "schema": {
                            "type": "string",
                            "format": "uuid"
                        },
                        "example": "0199a1c5-0e1a-7f22-9c3b-6d7e8f9a0b1c"
                    },
                    {
                        "name": "X-Delivery-Attempt",
                        "in": "header",
                        "required": true,
                        "description": "Attempt number of this delivery, starting at 1.",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "example": 1
                    },
                    {
                        "name": "X-Event-Type",
                        "in": "header",
                        "required": true,
                        "description": "The event name, identical to `event` in the body, so a receiver can route before parsing.",
                        "schema": {
                            "type": "string",
                            "const": "signer.signed"
                        },
                        "example": "signer.signed"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "allOf": [
                                    {
                                        "$ref": "#/components/schemas/WebhookEnvelope"
                                    },
                                    {
                                        "type": "object",
                                        "properties": {
                                            "event": {
                                                "type": "string",
                                                "const": "signer.signed",
                                                "description": "Always `signer.signed` for this webhook."
                                            },
                                            "data": {
                                                "type": "object",
                                                "description": "Event-specific details, on top of the request's `status` and `title` that every event about a request carries.",
                                                "properties": {
                                                    "status": {
                                                        "$ref": "#/components/schemas/SignatureRequestStatusEnum"
                                                    },
                                                    "title": {
                                                        "type": "string",
                                                        "description": "Title of the request."
                                                    },
                                                    "signer": {
                                                        "type": "object",
                                                        "description": "The signer this event is about.",
                                                        "properties": {
                                                            "gid": {
                                                                "type": "string",
                                                                "format": "uuid",
                                                                "description": "Public identifier of the signer."
                                                            },
                                                            "name": {
                                                                "type": "string",
                                                                "description": "Signer's name."
                                                            },
                                                            "email": {
                                                                "type": "string",
                                                                "format": "email",
                                                                "description": "Signer's email address."
                                                            },
                                                            "status": {
                                                                "$ref": "#/components/schemas/SignerStatusEnum"
                                                            },
                                                            "order_index": {
                                                                "type": "integer",
                                                                "description": "Position in the signing order, starting at 1."
                                                            },
                                                            "role_key": {
                                                                "type": [
                                                                    "string",
                                                                    "null"
                                                                ],
                                                                "description": "Machine role key of the signer (for example `party`, `operator`). Null when none was given."
                                                            }
                                                        },
                                                        "required": [
                                                            "gid",
                                                            "name",
                                                            "email",
                                                            "status",
                                                            "order_index",
                                                            "role_key"
                                                        ]
                                                    }
                                                },
                                                "required": [
                                                    "status",
                                                    "title"
                                                ]
                                            }
                                        }
                                    }
                                ]
                            },
                            "example": {
                                "event": "signer.signed",
                                "signature_request_gid": "0199a1c4-3f1e-7d2a-8b3c-5e6f7a8b9c0d",
                                "external_ref": "company:0198f1a2-8c4d-7e5b-9a6f-1b2c3d4e5f60",
                                "test": false,
                                "occurred_at": "2026-09-18T14:03:01+07:00",
                                "data": {
                                    "status": "partially_signed",
                                    "title": "Perjanjian Kerjasama \u2014 PT Musik Nusantara",
                                    "signer": {
                                        "gid": "0199a1c4-40aa-7e01-b2c3-d4e5f6a7b8c9",
                                        "name": "Rina Kartika",
                                        "email": "rina@musiknusantara.id",
                                        "status": "signed",
                                        "order_index": 1,
                                        "role_key": "party"
                                    }
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "2XX": {
                        "description": "Acknowledged. Answer within 10 seconds and do the real work afterwards; the body is ignored."
                    },
                    "default": {
                        "description": "Any other status, or no answer within 10 seconds, counts as a failed attempt. The delivery is retried after 1 minute, 5 minutes, 30 minutes, 2 hours and 12 hours, then marked failed; a failed delivery can be replayed from the dashboard."
                    }
                }
            }
        },
        "signerDeclined": {
            "post": {
                "operationId": "webhook.signerDeclined",
                "tags": [
                    "Webhooks"
                ],
                "summary": "A signer refused.",
                "description": "Fires for the signer who declined. Because one refusal ends the whole request, `signature_request.declined` follows immediately with the same reason.\n\nDelivered as a `POST` to your endpoint, signed with your webhook secret. See the *Webhooks* section of the introduction for verification, retries and ordering.",
                "parameters": [
                    {
                        "name": "X-Signature",
                        "in": "header",
                        "required": true,
                        "description": "`t=<unix timestamp>,v1=<hex HMAC-SHA256>` where the HMAC is computed with your webhook secret over the string `{t}.{raw request body}`. Recompute it over the raw bytes, compare in constant time, and reject a `t` more than 5 minutes from now.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "t=1758178981,v1=5f1c9a0e7c3b2d8e6a4f1b0c9d8e7f6a5b4c3d2e1f0a9b8c7d6e5f4a3b2c1d0e"
                    },
                    {
                        "name": "X-Delivery-Id",
                        "in": "header",
                        "required": true,
                        "description": "Identifier of this delivery, identical across retries of the same event. Deduplicate on it: process each value once and acknowledge repeats.",
                        "schema": {
                            "type": "string",
                            "format": "uuid"
                        },
                        "example": "0199a1c5-0e1a-7f22-9c3b-6d7e8f9a0b1c"
                    },
                    {
                        "name": "X-Delivery-Attempt",
                        "in": "header",
                        "required": true,
                        "description": "Attempt number of this delivery, starting at 1.",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "example": 1
                    },
                    {
                        "name": "X-Event-Type",
                        "in": "header",
                        "required": true,
                        "description": "The event name, identical to `event` in the body, so a receiver can route before parsing.",
                        "schema": {
                            "type": "string",
                            "const": "signer.declined"
                        },
                        "example": "signer.declined"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "allOf": [
                                    {
                                        "$ref": "#/components/schemas/WebhookEnvelope"
                                    },
                                    {
                                        "type": "object",
                                        "properties": {
                                            "event": {
                                                "type": "string",
                                                "const": "signer.declined",
                                                "description": "Always `signer.declined` for this webhook."
                                            },
                                            "data": {
                                                "type": "object",
                                                "description": "Event-specific details, on top of the request's `status` and `title` that every event about a request carries.",
                                                "properties": {
                                                    "status": {
                                                        "$ref": "#/components/schemas/SignatureRequestStatusEnum"
                                                    },
                                                    "title": {
                                                        "type": "string",
                                                        "description": "Title of the request."
                                                    },
                                                    "signer": {
                                                        "type": "object",
                                                        "description": "The signer this event is about.",
                                                        "properties": {
                                                            "gid": {
                                                                "type": "string",
                                                                "format": "uuid",
                                                                "description": "Public identifier of the signer."
                                                            },
                                                            "name": {
                                                                "type": "string",
                                                                "description": "Signer's name."
                                                            },
                                                            "email": {
                                                                "type": "string",
                                                                "format": "email",
                                                                "description": "Signer's email address."
                                                            },
                                                            "status": {
                                                                "$ref": "#/components/schemas/SignerStatusEnum"
                                                            },
                                                            "order_index": {
                                                                "type": "integer",
                                                                "description": "Position in the signing order, starting at 1."
                                                            },
                                                            "role_key": {
                                                                "type": [
                                                                    "string",
                                                                    "null"
                                                                ],
                                                                "description": "Machine role key of the signer (for example `party`, `operator`). Null when none was given."
                                                            }
                                                        },
                                                        "required": [
                                                            "gid",
                                                            "name",
                                                            "email",
                                                            "status",
                                                            "order_index",
                                                            "role_key"
                                                        ]
                                                    },
                                                    "declined_reason": {
                                                        "type": "string",
                                                        "description": "The reason the signer gave."
                                                    }
                                                },
                                                "required": [
                                                    "status",
                                                    "title"
                                                ]
                                            }
                                        }
                                    }
                                ]
                            },
                            "example": {
                                "event": "signer.declined",
                                "signature_request_gid": "0199a1c4-3f1e-7d2a-8b3c-5e6f7a8b9c0d",
                                "external_ref": "company:0198f1a2-8c4d-7e5b-9a6f-1b2c3d4e5f60",
                                "test": false,
                                "occurred_at": "2026-09-18T14:03:01+07:00",
                                "data": {
                                    "status": "declined",
                                    "title": "Perjanjian Kerjasama \u2014 PT Musik Nusantara",
                                    "signer": {
                                        "gid": "0199a1c4-40aa-7e01-b2c3-d4e5f6a7b8c9",
                                        "name": "Rina Kartika",
                                        "email": "rina@musiknusantara.id",
                                        "status": "declined",
                                        "order_index": 1,
                                        "role_key": "party"
                                    },
                                    "declined_reason": "Nilai bagi hasil belum sesuai kesepakatan."
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "2XX": {
                        "description": "Acknowledged. Answer within 10 seconds and do the real work afterwards; the body is ignored."
                    },
                    "default": {
                        "description": "Any other status, or no answer within 10 seconds, counts as a failed attempt. The delivery is retried after 1 minute, 5 minutes, 30 minutes, 2 hours and 12 hours, then marked failed; a failed delivery can be replayed from the dashboard."
                    }
                }
            }
        },
        "signatureRequestCompleted": {
            "post": {
                "operationId": "webhook.signatureRequestCompleted",
                "tags": [
                    "Webhooks"
                ],
                "summary": "Every signer signed; the executed documents are sealed and downloadable.",
                "description": "Sent from the finalisation job after the platform seal is applied, so when this arrives `GET /signature-requests/{gid}/document` already answers. Fires once per request. Deliberately carries no download URL: mint one with your API key instead of storing a bearer link from a webhook log.\n\nDelivered as a `POST` to your endpoint, signed with your webhook secret. See the *Webhooks* section of the introduction for verification, retries and ordering.",
                "parameters": [
                    {
                        "name": "X-Signature",
                        "in": "header",
                        "required": true,
                        "description": "`t=<unix timestamp>,v1=<hex HMAC-SHA256>` where the HMAC is computed with your webhook secret over the string `{t}.{raw request body}`. Recompute it over the raw bytes, compare in constant time, and reject a `t` more than 5 minutes from now.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "t=1758178981,v1=5f1c9a0e7c3b2d8e6a4f1b0c9d8e7f6a5b4c3d2e1f0a9b8c7d6e5f4a3b2c1d0e"
                    },
                    {
                        "name": "X-Delivery-Id",
                        "in": "header",
                        "required": true,
                        "description": "Identifier of this delivery, identical across retries of the same event. Deduplicate on it: process each value once and acknowledge repeats.",
                        "schema": {
                            "type": "string",
                            "format": "uuid"
                        },
                        "example": "0199a1c5-0e1a-7f22-9c3b-6d7e8f9a0b1c"
                    },
                    {
                        "name": "X-Delivery-Attempt",
                        "in": "header",
                        "required": true,
                        "description": "Attempt number of this delivery, starting at 1.",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "example": 1
                    },
                    {
                        "name": "X-Event-Type",
                        "in": "header",
                        "required": true,
                        "description": "The event name, identical to `event` in the body, so a receiver can route before parsing.",
                        "schema": {
                            "type": "string",
                            "const": "signature_request.completed"
                        },
                        "example": "signature_request.completed"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "allOf": [
                                    {
                                        "$ref": "#/components/schemas/WebhookEnvelope"
                                    },
                                    {
                                        "type": "object",
                                        "properties": {
                                            "event": {
                                                "type": "string",
                                                "const": "signature_request.completed",
                                                "description": "Always `signature_request.completed` for this webhook."
                                            },
                                            "data": {
                                                "type": "object",
                                                "description": "Event-specific details, on top of the request's `status` and `title` that every event about a request carries.",
                                                "properties": {
                                                    "status": {
                                                        "$ref": "#/components/schemas/SignatureRequestStatusEnum"
                                                    },
                                                    "title": {
                                                        "type": "string",
                                                        "description": "Title of the request."
                                                    },
                                                    "completed_at": {
                                                        "type": [
                                                            "string",
                                                            "null"
                                                        ],
                                                        "format": "date-time",
                                                        "description": "When the last signer signed (ISO-8601)."
                                                    },
                                                    "documents": {
                                                        "type": "array",
                                                        "description": "The executed documents, in signing order. No download link on purpose: call `GET /signature-requests/{gid}/document` with your API key for a fresh one.",
                                                        "items": {
                                                            "type": "object",
                                                            "properties": {
                                                                "gid": {
                                                                    "type": "string",
                                                                    "format": "uuid",
                                                                    "description": "Public identifier of the document."
                                                                },
                                                                "filename": {
                                                                    "type": "string",
                                                                    "description": "File name of the executed document."
                                                                },
                                                                "final_hash": {
                                                                    "type": "string",
                                                                    "description": "Lowercase hex SHA-256 of the executed document's bytes."
                                                                },
                                                                "sealed_at": {
                                                                    "type": [
                                                                        "string",
                                                                        "null"
                                                                    ],
                                                                    "format": "date-time",
                                                                    "description": "When the platform seal was applied (ISO-8601)."
                                                                }
                                                            },
                                                            "required": [
                                                                "gid",
                                                                "filename",
                                                                "final_hash",
                                                                "sealed_at"
                                                            ]
                                                        }
                                                    }
                                                },
                                                "required": [
                                                    "status",
                                                    "title"
                                                ]
                                            }
                                        }
                                    }
                                ]
                            },
                            "example": {
                                "event": "signature_request.completed",
                                "signature_request_gid": "0199a1c4-3f1e-7d2a-8b3c-5e6f7a8b9c0d",
                                "external_ref": "company:0198f1a2-8c4d-7e5b-9a6f-1b2c3d4e5f60",
                                "test": false,
                                "occurred_at": "2026-09-18T14:03:01+07:00",
                                "data": {
                                    "status": "completed",
                                    "title": "Perjanjian Kerjasama \u2014 PT Musik Nusantara",
                                    "completed_at": "2026-09-18T14:01:20+07:00",
                                    "documents": [
                                        {
                                            "gid": "0199a1c4-5aa0-7b33-a1b2-c3d4e5f6a7b8",
                                            "filename": "Perjanjian Kerjasama - Record Label.pdf",
                                            "final_hash": "7d9c1e0f2a3b4c5d6e7f8091a2b3c4d5e6f708192a3b4c5d6e7f8091a2b3c4d5",
                                            "sealed_at": "2026-09-18T14:02:55+07:00"
                                        }
                                    ]
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "2XX": {
                        "description": "Acknowledged. Answer within 10 seconds and do the real work afterwards; the body is ignored."
                    },
                    "default": {
                        "description": "Any other status, or no answer within 10 seconds, counts as a failed attempt. The delivery is retried after 1 minute, 5 minutes, 30 minutes, 2 hours and 12 hours, then marked failed; a failed delivery can be replayed from the dashboard."
                    }
                }
            }
        },
        "signatureRequestDeclined": {
            "post": {
                "operationId": "webhook.signatureRequestDeclined",
                "tags": [
                    "Webhooks"
                ],
                "summary": "The request as a whole ended in refusal.",
                "description": "Terminal. Signing links stop working, no further reminders are sent, and the request's `external_ref` is released so a corrected request may reuse it. Create a new request to try again.\n\nDelivered as a `POST` to your endpoint, signed with your webhook secret. See the *Webhooks* section of the introduction for verification, retries and ordering.",
                "parameters": [
                    {
                        "name": "X-Signature",
                        "in": "header",
                        "required": true,
                        "description": "`t=<unix timestamp>,v1=<hex HMAC-SHA256>` where the HMAC is computed with your webhook secret over the string `{t}.{raw request body}`. Recompute it over the raw bytes, compare in constant time, and reject a `t` more than 5 minutes from now.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "t=1758178981,v1=5f1c9a0e7c3b2d8e6a4f1b0c9d8e7f6a5b4c3d2e1f0a9b8c7d6e5f4a3b2c1d0e"
                    },
                    {
                        "name": "X-Delivery-Id",
                        "in": "header",
                        "required": true,
                        "description": "Identifier of this delivery, identical across retries of the same event. Deduplicate on it: process each value once and acknowledge repeats.",
                        "schema": {
                            "type": "string",
                            "format": "uuid"
                        },
                        "example": "0199a1c5-0e1a-7f22-9c3b-6d7e8f9a0b1c"
                    },
                    {
                        "name": "X-Delivery-Attempt",
                        "in": "header",
                        "required": true,
                        "description": "Attempt number of this delivery, starting at 1.",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "example": 1
                    },
                    {
                        "name": "X-Event-Type",
                        "in": "header",
                        "required": true,
                        "description": "The event name, identical to `event` in the body, so a receiver can route before parsing.",
                        "schema": {
                            "type": "string",
                            "const": "signature_request.declined"
                        },
                        "example": "signature_request.declined"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "allOf": [
                                    {
                                        "$ref": "#/components/schemas/WebhookEnvelope"
                                    },
                                    {
                                        "type": "object",
                                        "properties": {
                                            "event": {
                                                "type": "string",
                                                "const": "signature_request.declined",
                                                "description": "Always `signature_request.declined` for this webhook."
                                            },
                                            "data": {
                                                "type": "object",
                                                "description": "Event-specific details, on top of the request's `status` and `title` that every event about a request carries.",
                                                "properties": {
                                                    "status": {
                                                        "$ref": "#/components/schemas/SignatureRequestStatusEnum"
                                                    },
                                                    "title": {
                                                        "type": "string",
                                                        "description": "Title of the request."
                                                    },
                                                    "signer": {
                                                        "type": "object",
                                                        "description": "The signer this event is about.",
                                                        "properties": {
                                                            "gid": {
                                                                "type": "string",
                                                                "format": "uuid",
                                                                "description": "Public identifier of the signer."
                                                            },
                                                            "name": {
                                                                "type": "string",
                                                                "description": "Signer's name."
                                                            },
                                                            "email": {
                                                                "type": "string",
                                                                "format": "email",
                                                                "description": "Signer's email address."
                                                            },
                                                            "status": {
                                                                "$ref": "#/components/schemas/SignerStatusEnum"
                                                            },
                                                            "order_index": {
                                                                "type": "integer",
                                                                "description": "Position in the signing order, starting at 1."
                                                            },
                                                            "role_key": {
                                                                "type": [
                                                                    "string",
                                                                    "null"
                                                                ],
                                                                "description": "Machine role key of the signer (for example `party`, `operator`). Null when none was given."
                                                            }
                                                        },
                                                        "required": [
                                                            "gid",
                                                            "name",
                                                            "email",
                                                            "status",
                                                            "order_index",
                                                            "role_key"
                                                        ]
                                                    },
                                                    "declined_reason": {
                                                        "type": "string",
                                                        "description": "The reason the declining signer gave."
                                                    }
                                                },
                                                "required": [
                                                    "status",
                                                    "title"
                                                ]
                                            }
                                        }
                                    }
                                ]
                            },
                            "example": {
                                "event": "signature_request.declined",
                                "signature_request_gid": "0199a1c4-3f1e-7d2a-8b3c-5e6f7a8b9c0d",
                                "external_ref": "company:0198f1a2-8c4d-7e5b-9a6f-1b2c3d4e5f60",
                                "test": false,
                                "occurred_at": "2026-09-18T14:03:01+07:00",
                                "data": {
                                    "status": "declined",
                                    "title": "Perjanjian Kerjasama \u2014 PT Musik Nusantara",
                                    "signer": {
                                        "gid": "0199a1c4-40aa-7e01-b2c3-d4e5f6a7b8c9",
                                        "name": "Rina Kartika",
                                        "email": "rina@musiknusantara.id",
                                        "status": "declined",
                                        "order_index": 1,
                                        "role_key": "party"
                                    },
                                    "declined_reason": "Nilai bagi hasil belum sesuai kesepakatan."
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "2XX": {
                        "description": "Acknowledged. Answer within 10 seconds and do the real work afterwards; the body is ignored."
                    },
                    "default": {
                        "description": "Any other status, or no answer within 10 seconds, counts as a failed attempt. The delivery is retried after 1 minute, 5 minutes, 30 minutes, 2 hours and 12 hours, then marked failed; a failed delivery can be replayed from the dashboard."
                    }
                }
            }
        },
        "signatureRequestExpired": {
            "post": {
                "operationId": "webhook.signatureRequestExpired",
                "tags": [
                    "Webhooks"
                ],
                "summary": "The request passed its deadline without completing.",
                "description": "Terminal. Sent by the hourly expiry job once `expires_at` is in the past; signing links stop working and the `external_ref` is released.\n\nDelivered as a `POST` to your endpoint, signed with your webhook secret. See the *Webhooks* section of the introduction for verification, retries and ordering.",
                "parameters": [
                    {
                        "name": "X-Signature",
                        "in": "header",
                        "required": true,
                        "description": "`t=<unix timestamp>,v1=<hex HMAC-SHA256>` where the HMAC is computed with your webhook secret over the string `{t}.{raw request body}`. Recompute it over the raw bytes, compare in constant time, and reject a `t` more than 5 minutes from now.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "t=1758178981,v1=5f1c9a0e7c3b2d8e6a4f1b0c9d8e7f6a5b4c3d2e1f0a9b8c7d6e5f4a3b2c1d0e"
                    },
                    {
                        "name": "X-Delivery-Id",
                        "in": "header",
                        "required": true,
                        "description": "Identifier of this delivery, identical across retries of the same event. Deduplicate on it: process each value once and acknowledge repeats.",
                        "schema": {
                            "type": "string",
                            "format": "uuid"
                        },
                        "example": "0199a1c5-0e1a-7f22-9c3b-6d7e8f9a0b1c"
                    },
                    {
                        "name": "X-Delivery-Attempt",
                        "in": "header",
                        "required": true,
                        "description": "Attempt number of this delivery, starting at 1.",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "example": 1
                    },
                    {
                        "name": "X-Event-Type",
                        "in": "header",
                        "required": true,
                        "description": "The event name, identical to `event` in the body, so a receiver can route before parsing.",
                        "schema": {
                            "type": "string",
                            "const": "signature_request.expired"
                        },
                        "example": "signature_request.expired"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "allOf": [
                                    {
                                        "$ref": "#/components/schemas/WebhookEnvelope"
                                    },
                                    {
                                        "type": "object",
                                        "properties": {
                                            "event": {
                                                "type": "string",
                                                "const": "signature_request.expired",
                                                "description": "Always `signature_request.expired` for this webhook."
                                            },
                                            "data": {
                                                "type": "object",
                                                "description": "Event-specific details, on top of the request's `status` and `title` that every event about a request carries.",
                                                "properties": {
                                                    "status": {
                                                        "$ref": "#/components/schemas/SignatureRequestStatusEnum"
                                                    },
                                                    "title": {
                                                        "type": "string",
                                                        "description": "Title of the request."
                                                    },
                                                    "expires_at": {
                                                        "type": [
                                                            "string",
                                                            "null"
                                                        ],
                                                        "format": "date-time",
                                                        "description": "The deadline that passed (ISO-8601)."
                                                    }
                                                },
                                                "required": [
                                                    "status",
                                                    "title"
                                                ]
                                            }
                                        }
                                    }
                                ]
                            },
                            "example": {
                                "event": "signature_request.expired",
                                "signature_request_gid": "0199a1c4-3f1e-7d2a-8b3c-5e6f7a8b9c0d",
                                "external_ref": "company:0198f1a2-8c4d-7e5b-9a6f-1b2c3d4e5f60",
                                "test": false,
                                "occurred_at": "2026-09-18T14:03:01+07:00",
                                "data": {
                                    "status": "expired",
                                    "title": "Perjanjian Kerjasama \u2014 PT Musik Nusantara",
                                    "expires_at": "2026-10-17T09:04:00+07:00"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "2XX": {
                        "description": "Acknowledged. Answer within 10 seconds and do the real work afterwards; the body is ignored."
                    },
                    "default": {
                        "description": "Any other status, or no answer within 10 seconds, counts as a failed attempt. The delivery is retried after 1 minute, 5 minutes, 30 minutes, 2 hours and 12 hours, then marked failed; a failed delivery can be replayed from the dashboard."
                    }
                }
            }
        },
        "signatureRequestVoided": {
            "post": {
                "operationId": "webhook.signatureRequestVoided",
                "tags": [
                    "Webhooks"
                ],
                "summary": "The sender withdrew the request.",
                "description": "Terminal. Fires for `POST /signature-requests/{gid}/void` and for voids made from the dashboard, so a client showing its own \"sign now\" button learns that the links are dead. The `external_ref` is released.\n\nDelivered as a `POST` to your endpoint, signed with your webhook secret. See the *Webhooks* section of the introduction for verification, retries and ordering.",
                "parameters": [
                    {
                        "name": "X-Signature",
                        "in": "header",
                        "required": true,
                        "description": "`t=<unix timestamp>,v1=<hex HMAC-SHA256>` where the HMAC is computed with your webhook secret over the string `{t}.{raw request body}`. Recompute it over the raw bytes, compare in constant time, and reject a `t` more than 5 minutes from now.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "t=1758178981,v1=5f1c9a0e7c3b2d8e6a4f1b0c9d8e7f6a5b4c3d2e1f0a9b8c7d6e5f4a3b2c1d0e"
                    },
                    {
                        "name": "X-Delivery-Id",
                        "in": "header",
                        "required": true,
                        "description": "Identifier of this delivery, identical across retries of the same event. Deduplicate on it: process each value once and acknowledge repeats.",
                        "schema": {
                            "type": "string",
                            "format": "uuid"
                        },
                        "example": "0199a1c5-0e1a-7f22-9c3b-6d7e8f9a0b1c"
                    },
                    {
                        "name": "X-Delivery-Attempt",
                        "in": "header",
                        "required": true,
                        "description": "Attempt number of this delivery, starting at 1.",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "example": 1
                    },
                    {
                        "name": "X-Event-Type",
                        "in": "header",
                        "required": true,
                        "description": "The event name, identical to `event` in the body, so a receiver can route before parsing.",
                        "schema": {
                            "type": "string",
                            "const": "signature_request.voided"
                        },
                        "example": "signature_request.voided"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "allOf": [
                                    {
                                        "$ref": "#/components/schemas/WebhookEnvelope"
                                    },
                                    {
                                        "type": "object",
                                        "properties": {
                                            "event": {
                                                "type": "string",
                                                "const": "signature_request.voided",
                                                "description": "Always `signature_request.voided` for this webhook."
                                            },
                                            "data": {
                                                "type": "object",
                                                "description": "Event-specific details, on top of the request's `status` and `title` that every event about a request carries.",
                                                "properties": {
                                                    "status": {
                                                        "$ref": "#/components/schemas/SignatureRequestStatusEnum"
                                                    },
                                                    "title": {
                                                        "type": "string",
                                                        "description": "Title of the request."
                                                    },
                                                    "reason": {
                                                        "type": "string",
                                                        "description": "The reason given when voiding. Absent when none was given."
                                                    }
                                                },
                                                "required": [
                                                    "status",
                                                    "title"
                                                ]
                                            }
                                        }
                                    }
                                ]
                            },
                            "example": {
                                "event": "signature_request.voided",
                                "signature_request_gid": "0199a1c4-3f1e-7d2a-8b3c-5e6f7a8b9c0d",
                                "external_ref": "company:0198f1a2-8c4d-7e5b-9a6f-1b2c3d4e5f60",
                                "test": false,
                                "occurred_at": "2026-09-18T14:03:01+07:00",
                                "data": {
                                    "status": "voided",
                                    "title": "Perjanjian Kerjasama \u2014 PT Musik Nusantara",
                                    "reason": "Katalog lagu berubah sebelum pengiriman; perjanjian diterbitkan ulang."
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "2XX": {
                        "description": "Acknowledged. Answer within 10 seconds and do the real work afterwards; the body is ignored."
                    },
                    "default": {
                        "description": "Any other status, or no answer within 10 seconds, counts as a failed attempt. The delivery is retried after 1 minute, 5 minutes, 30 minutes, 2 hours and 12 hours, then marked failed; a failed delivery can be replayed from the dashboard."
                    }
                }
            }
        },
        "signatureRequestProcessingFailed": {
            "post": {
                "operationId": "webhook.signatureRequestProcessingFailed",
                "tags": [
                    "Webhooks"
                ],
                "summary": "The platform could not finish rendering or sealing the request's documents.",
                "description": "Sent once the platform's own retries are spent. `stage` says where: `preparation` means a template could not be rendered, so the request stays a `draft` with `documents_pending` above zero and will not be sent \u2014 void it and create a new one after checking the merge data. `finalization` means everyone signed but the executed documents could not be composed or sealed; the request is `completed` and the platform keeps retrying automatically, so no action is needed unless it persists. The same information is on `GET /signature-requests/{gid}` as `processing_error`.\n\nDelivered as a `POST` to your endpoint, signed with your webhook secret. See the *Webhooks* section of the introduction for verification, retries and ordering.",
                "parameters": [
                    {
                        "name": "X-Signature",
                        "in": "header",
                        "required": true,
                        "description": "`t=<unix timestamp>,v1=<hex HMAC-SHA256>` where the HMAC is computed with your webhook secret over the string `{t}.{raw request body}`. Recompute it over the raw bytes, compare in constant time, and reject a `t` more than 5 minutes from now.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "t=1758178981,v1=5f1c9a0e7c3b2d8e6a4f1b0c9d8e7f6a5b4c3d2e1f0a9b8c7d6e5f4a3b2c1d0e"
                    },
                    {
                        "name": "X-Delivery-Id",
                        "in": "header",
                        "required": true,
                        "description": "Identifier of this delivery, identical across retries of the same event. Deduplicate on it: process each value once and acknowledge repeats.",
                        "schema": {
                            "type": "string",
                            "format": "uuid"
                        },
                        "example": "0199a1c5-0e1a-7f22-9c3b-6d7e8f9a0b1c"
                    },
                    {
                        "name": "X-Delivery-Attempt",
                        "in": "header",
                        "required": true,
                        "description": "Attempt number of this delivery, starting at 1.",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "example": 1
                    },
                    {
                        "name": "X-Event-Type",
                        "in": "header",
                        "required": true,
                        "description": "The event name, identical to `event` in the body, so a receiver can route before parsing.",
                        "schema": {
                            "type": "string",
                            "const": "signature_request.processing_failed"
                        },
                        "example": "signature_request.processing_failed"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "allOf": [
                                    {
                                        "$ref": "#/components/schemas/WebhookEnvelope"
                                    },
                                    {
                                        "type": "object",
                                        "properties": {
                                            "event": {
                                                "type": "string",
                                                "const": "signature_request.processing_failed",
                                                "description": "Always `signature_request.processing_failed` for this webhook."
                                            },
                                            "data": {
                                                "type": "object",
                                                "description": "Event-specific details, on top of the request's `status` and `title` that every event about a request carries.",
                                                "properties": {
                                                    "status": {
                                                        "$ref": "#/components/schemas/SignatureRequestStatusEnum"
                                                    },
                                                    "title": {
                                                        "type": "string",
                                                        "description": "Title of the request."
                                                    },
                                                    "stage": {
                                                        "type": "string",
                                                        "enum": [
                                                            "preparation",
                                                            "finalization"
                                                        ],
                                                        "description": "`preparation` for template rendering, `finalization` for composing and sealing the executed documents."
                                                    },
                                                    "template_code": {
                                                        "type": [
                                                            "string",
                                                            "null"
                                                        ],
                                                        "description": "The template that could not be rendered. Null at `finalization`."
                                                    }
                                                },
                                                "required": [
                                                    "status",
                                                    "title"
                                                ]
                                            }
                                        }
                                    }
                                ]
                            },
                            "example": {
                                "event": "signature_request.processing_failed",
                                "signature_request_gid": "0199a1c4-3f1e-7d2a-8b3c-5e6f7a8b9c0d",
                                "external_ref": "company:0198f1a2-8c4d-7e5b-9a6f-1b2c3d4e5f60",
                                "test": false,
                                "occurred_at": "2026-09-18T14:03:01+07:00",
                                "data": {
                                    "status": "draft",
                                    "title": "Perjanjian Kerjasama \u2014 PT Musik Nusantara",
                                    "stage": "preparation",
                                    "template_code": "PERJANJIAN_LABEL"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "2XX": {
                        "description": "Acknowledged. Answer within 10 seconds and do the real work afterwards; the body is ignored."
                    },
                    "default": {
                        "description": "Any other status, or no answer within 10 seconds, counts as a failed attempt. The delivery is retried after 1 minute, 5 minutes, 30 minutes, 2 hours and 12 hours, then marked failed; a failed delivery can be replayed from the dashboard."
                    }
                }
            }
        },
        "webhookPing": {
            "post": {
                "operationId": "webhook.webhookPing",
                "tags": [
                    "Webhooks"
                ],
                "summary": "A test delivery you asked for.",
                "description": "Sent only in answer to `POST /webhook/ping`, never on its own. It travels the same job, signature and retry ladder as a real event, which is what makes it worth sending: it proves your endpoint is reachable from here, verifies the HMAC correctly and answers in time. It ignores `subscribed_events`, and it names no signature request \u2014 `signature_request_gid` and `external_ref` are null.\n\nDelivered as a `POST` to your endpoint, signed with your webhook secret. See the *Webhooks* section of the introduction for verification, retries and ordering.",
                "parameters": [
                    {
                        "name": "X-Signature",
                        "in": "header",
                        "required": true,
                        "description": "`t=<unix timestamp>,v1=<hex HMAC-SHA256>` where the HMAC is computed with your webhook secret over the string `{t}.{raw request body}`. Recompute it over the raw bytes, compare in constant time, and reject a `t` more than 5 minutes from now.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "t=1758178981,v1=5f1c9a0e7c3b2d8e6a4f1b0c9d8e7f6a5b4c3d2e1f0a9b8c7d6e5f4a3b2c1d0e"
                    },
                    {
                        "name": "X-Delivery-Id",
                        "in": "header",
                        "required": true,
                        "description": "Identifier of this delivery, identical across retries of the same event. Deduplicate on it: process each value once and acknowledge repeats.",
                        "schema": {
                            "type": "string",
                            "format": "uuid"
                        },
                        "example": "0199a1c5-0e1a-7f22-9c3b-6d7e8f9a0b1c"
                    },
                    {
                        "name": "X-Delivery-Attempt",
                        "in": "header",
                        "required": true,
                        "description": "Attempt number of this delivery, starting at 1.",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "example": 1
                    },
                    {
                        "name": "X-Event-Type",
                        "in": "header",
                        "required": true,
                        "description": "The event name, identical to `event` in the body, so a receiver can route before parsing.",
                        "schema": {
                            "type": "string",
                            "const": "webhook.ping"
                        },
                        "example": "webhook.ping"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "allOf": [
                                    {
                                        "$ref": "#/components/schemas/WebhookEnvelope"
                                    },
                                    {
                                        "type": "object",
                                        "properties": {
                                            "event": {
                                                "type": "string",
                                                "const": "webhook.ping",
                                                "description": "Always `webhook.ping` for this webhook."
                                            },
                                            "data": {
                                                "type": "object",
                                                "description": "Event-specific details.",
                                                "properties": {
                                                    "message": {
                                                        "type": "string",
                                                        "description": "A human-readable line saying this is a test, in the application's default language."
                                                    }
                                                },
                                                "required": [
                                                    "message"
                                                ]
                                            }
                                        }
                                    }
                                ]
                            },
                            "example": {
                                "event": "webhook.ping",
                                "signature_request_gid": null,
                                "external_ref": null,
                                "test": false,
                                "occurred_at": "2026-09-18T14:03:01+07:00",
                                "data": {
                                    "message": "Test delivery from Lokasign. Your endpoint is reachable and this signature can be verified."
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "2XX": {
                        "description": "Acknowledged. Answer within 10 seconds and do the real work afterwards; the body is ignored."
                    },
                    "default": {
                        "description": "Any other status, or no answer within 10 seconds, counts as a failed attempt. The delivery is retried after 1 minute, 5 minutes, 30 minutes, 2 hours and 12 hours, then marked failed; a failed delivery can be replayed from the dashboard."
                    }
                }
            }
        },
        "signatureRequestReminderSent": {
            "post": {
                "operationId": "webhook.signatureRequestReminderSent",
                "tags": [
                    "Webhooks"
                ],
                "summary": "A reminder email went to a signer.",
                "description": "Fires per signer reminded, whether by `POST /signature-requests/{gid}/remind` or by the platform's automatic reminders before the deadline. Informational; the request's state does not change.\n\nDelivered as a `POST` to your endpoint, signed with your webhook secret. See the *Webhooks* section of the introduction for verification, retries and ordering.",
                "parameters": [
                    {
                        "name": "X-Signature",
                        "in": "header",
                        "required": true,
                        "description": "`t=<unix timestamp>,v1=<hex HMAC-SHA256>` where the HMAC is computed with your webhook secret over the string `{t}.{raw request body}`. Recompute it over the raw bytes, compare in constant time, and reject a `t` more than 5 minutes from now.",
                        "schema": {
                            "type": "string"
                        },
                        "example": "t=1758178981,v1=5f1c9a0e7c3b2d8e6a4f1b0c9d8e7f6a5b4c3d2e1f0a9b8c7d6e5f4a3b2c1d0e"
                    },
                    {
                        "name": "X-Delivery-Id",
                        "in": "header",
                        "required": true,
                        "description": "Identifier of this delivery, identical across retries of the same event. Deduplicate on it: process each value once and acknowledge repeats.",
                        "schema": {
                            "type": "string",
                            "format": "uuid"
                        },
                        "example": "0199a1c5-0e1a-7f22-9c3b-6d7e8f9a0b1c"
                    },
                    {
                        "name": "X-Delivery-Attempt",
                        "in": "header",
                        "required": true,
                        "description": "Attempt number of this delivery, starting at 1.",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "example": 1
                    },
                    {
                        "name": "X-Event-Type",
                        "in": "header",
                        "required": true,
                        "description": "The event name, identical to `event` in the body, so a receiver can route before parsing.",
                        "schema": {
                            "type": "string",
                            "const": "signature_request.reminder_sent"
                        },
                        "example": "signature_request.reminder_sent"
                    }
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "allOf": [
                                    {
                                        "$ref": "#/components/schemas/WebhookEnvelope"
                                    },
                                    {
                                        "type": "object",
                                        "properties": {
                                            "event": {
                                                "type": "string",
                                                "const": "signature_request.reminder_sent",
                                                "description": "Always `signature_request.reminder_sent` for this webhook."
                                            },
                                            "data": {
                                                "type": "object",
                                                "description": "Event-specific details, on top of the request's `status` and `title` that every event about a request carries.",
                                                "properties": {
                                                    "status": {
                                                        "$ref": "#/components/schemas/SignatureRequestStatusEnum"
                                                    },
                                                    "title": {
                                                        "type": "string",
                                                        "description": "Title of the request."
                                                    },
                                                    "signer": {
                                                        "type": "object",
                                                        "description": "The signer this event is about.",
                                                        "properties": {
                                                            "gid": {
                                                                "type": "string",
                                                                "format": "uuid",
                                                                "description": "Public identifier of the signer."
                                                            },
                                                            "name": {
                                                                "type": "string",
                                                                "description": "Signer's name."
                                                            },
                                                            "email": {
                                                                "type": "string",
                                                                "format": "email",
                                                                "description": "Signer's email address."
                                                            },
                                                            "status": {
                                                                "$ref": "#/components/schemas/SignerStatusEnum"
                                                            },
                                                            "order_index": {
                                                                "type": "integer",
                                                                "description": "Position in the signing order, starting at 1."
                                                            },
                                                            "role_key": {
                                                                "type": [
                                                                    "string",
                                                                    "null"
                                                                ],
                                                                "description": "Machine role key of the signer (for example `party`, `operator`). Null when none was given."
                                                            }
                                                        },
                                                        "required": [
                                                            "gid",
                                                            "name",
                                                            "email",
                                                            "status",
                                                            "order_index",
                                                            "role_key"
                                                        ]
                                                    },
                                                    "trigger": {
                                                        "type": "string",
                                                        "enum": [
                                                            "manual",
                                                            "automatic"
                                                        ],
                                                        "description": "`manual` for a reminder requested through the API or dashboard, `automatic` for the platform's scheduled reminders."
                                                    }
                                                },
                                                "required": [
                                                    "status",
                                                    "title"
                                                ]
                                            }
                                        }
                                    }
                                ]
                            },
                            "example": {
                                "event": "signature_request.reminder_sent",
                                "signature_request_gid": "0199a1c4-3f1e-7d2a-8b3c-5e6f7a8b9c0d",
                                "external_ref": "company:0198f1a2-8c4d-7e5b-9a6f-1b2c3d4e5f60",
                                "test": false,
                                "occurred_at": "2026-09-18T14:03:01+07:00",
                                "data": {
                                    "status": "sent",
                                    "title": "Perjanjian Kerjasama \u2014 PT Musik Nusantara",
                                    "signer": {
                                        "gid": "0199a1c4-40aa-7e01-b2c3-d4e5f6a7b8c9",
                                        "name": "Rina Kartika",
                                        "email": "rina@musiknusantara.id",
                                        "status": "pending",
                                        "order_index": 1,
                                        "role_key": "party"
                                    },
                                    "trigger": "manual"
                                }
                            }
                        }
                    }
                },
                "responses": {
                    "2XX": {
                        "description": "Acknowledged. Answer within 10 seconds and do the real work afterwards; the body is ignored."
                    },
                    "default": {
                        "description": "Any other status, or no answer within 10 seconds, counts as a failed attempt. The delivery is retried after 1 minute, 5 minutes, 30 minutes, 2 hours and 12 hours, then marked failed; a failed delivery can be replayed from the dashboard."
                    }
                }
            }
        }
    }
}