# Get one template

> GET /api/v1/templates/{id}: Get one template.

`GET https://appliflo.com/api/v1/templates/{id}`

The template as GET /templates lists it in items[] (and MCP get_template returns it): a saved template (every saved_templates[] field), an AppliFlo contract or an official form (a lib_ id). Its status (only `ready` sends), current version, each role's key, label, kind and signing order, and the boxes the sender may prefill. Another workspace's template is a 404.

Send your API key in the `Authorization: Bearer` header. Every response is JSON: `{ success, data, error }`.

## Parameters

| Name | In | Required | Description |
| --- | --- | --- | --- |
| `id` | path | yes | Saved template id (saved_templates[].template_id from GET /templates) |

## Responses

| Status | Description |
| --- | --- |
| 200 | The template. |
| 401 | Missing or invalid API key, or `api_key_expired` for a key past its expiry. |
| 403 | The API key's workspace does not have access to this resource, or `insufficient_scope` (with `required_scope`) for a key without the scope this route needs. |
| 404 | Resource not found in this workspace. |
| 422 | Request failed validation. |
| 500 | Internal error. |

## 200 response

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `success` | true | yes |  |
| `data` | object | yes |  |
| `data.template` | object | yes | A saved template (kind saved, every saved_templates[] field), a contract template the workspace wrote in the older model (kind contract: drafted with values + recipients in party order), an AppliFlo contract template (kind library) or an official government form (kind official). Library and official ids are "lib_<slug>" |
| `data.template.template_id` | string | yes |  |
| `data.template.kind` | string | yes | One of: saved, contract, library, official |
| `data.template.name` | string | yes |  |
| `data.template.status` | string | yes | ready: set up with roles (send it, or create a document with each role's person). draft: a saved template an owner or admin hasn't finalised, or an official form AppliFlo hasn't set up (POST /templates/{id}/create-document imports it as a document with its fields read; it can't be sent from a template). One of: draft, ready |
| `data.template.version` | integer \| null | yes | The current version (null while draft). POST /templates/{id}/bulk requires it |
| `data.template.field_count` | integer | yes | At least 0 |
| `data.template.pages` | integer \| null | yes | At least 1 |
| `data.template.roles` | object[] | yes | Recipient roles, in signing order (the current version's; a draft's planned ones) |
| `data.template.roles[].key` | string | yes | The key send and bulk take in `people` / `recipients[].role`, e.g. "r1" |
| `data.template.roles[].label` | string | yes | The role's name, e.g. "Client" |
| `data.template.roles[].kind` | string | yes | signer: fills and signs; filler: fills only. One of: signer, filler |
| `data.template.roles[].order` | integer | yes | Signing order. At least 1 |
| `data.template.sender_fields` | object[] | yes | The boxes the sender fills (empty while draft) |
| `data.template.sender_fields[].index` | integer | yes | The prefill key. At least 0 |
| `data.template.sender_fields[].label` | string \| null | yes |  |
| `data.template.sender_fields[].type` | string | yes | One of: text, checkbox, signature |
| `data.template.sender_fields[].semantic_type` | string | yes |  |
| `data.template.sender_fields[].group_key` | string \| null | yes | The choice question this box is an option of (answer with an option value) |
| `data.template.sender_fields[].option_value` | string \| null | yes |  |
| `data.template.sender_fields[].bulk` | boolean | yes | A plain text box a bulk row's prefill may set |
| `data.template.fixed_fields` | object[] | yes | The boxes the template fills itself (empty while draft) |
| `data.template.fixed_fields[].index` | integer | yes | The fixed_overrides key. At least 0 |
| `data.template.fixed_fields[].label` | string \| null | yes |  |
| `data.template.fixed_fields[].type` | string | yes | One of: text, checkbox, signature |
| `data.template.fixed_fields[].locked` | boolean | yes | True: set by the template, an override is 422 locked_field |
| `data.template.fixed_fields[].bulk` | boolean | yes | A Default text box a bulk row's prefill may set (its value becomes that row's override) |
| `data.template.source` | string | no | doc: saved from a Docs doc (no PDF; send it to many, or use it from Docs). One of: document, official, upload, doc |
| `data.template.official_form_slug` | string \| null | yes |  |
| `data.template.created_at` | string | no | Format: date-time |
| `data.template.updated_at` | string | no | Format: date-time |
| `data.template.summary` | string \| null | yes |  |
| `data.template.category` | string \| null | yes |  |
| `data.template.country` | string \| null | yes | An official form's country (or a saved copy of one). One of: US, AU, null |
| `data.template.official_form` | object \| null | yes |  |
| `data.template.official_form.slug` | string | yes |  |
| `data.template.official_form.code` | string | yes | As printed: "956", "W-9" |
| `data.template.official_form.label` | string | yes | "Form 956" for Home Affairs, else the code |
| `data.template.official_form.title` | string | yes |  |
| `data.template.official_form.agency` | string | yes |  |
| `data.template.official_form.agency_name` | string | yes |  |
| `data.template.esign` | object \| null | yes | The agency's e-sign rule. block: fill and print only (every send is refused with 422 esign_not_allowed). warn: send with esign_risk_acknowledged: true |
| `data.template.esign.mode` | string | yes | One of: block, warn |
| `data.template.esign.notice` | string | yes |  |
| `data.template.recipients_required` | integer | no | kind contract: how many parties (recipients, in order) a draft needs. At least 0 |
| `data.template.required_values` | object[] | no | kind contract: one value per key, required by create-document |
| `data.template.party_fields` | object[] | no | kind contract: the signature/name/date blocks bound to each party |
| `data.template.lawyer_reviewed` | boolean | no | kind contract: whether the base text has been through legal review |
| `data.template.own_risk` | boolean | yes | An AppliFlo contract no lawyer has reviewed: sent or drafted only with risk_accepted: true (Terms 8A) unless the person already accepted that version |
| `data.template.setup_required` | boolean | yes | The app asks this workspace's one-time set-up of the form (business details, who sends it) before the first use. Without it, a box the set-up answers is refused with 422 unanswered_ask or missing_detail: give it in fixed_overrides, or have an owner or admin set the form up in the app |

See also: [Errors](https://dev.appliflo.com/guides/errors), [Rate limits](https://dev.appliflo.com/guides/rate-limits), [Idempotency](https://dev.appliflo.com/guides/idempotency).
