List the template library available to this workspace
`items` is one list of everything the workspace can start a document from (as the app's Templates page and the MCP list_templates tool): its saved templates first, then AppliFlo's contract templates (kind library), then the official government forms (kind official), filtered by kind, q, country and category and paged with limit/offset (`total` counts every match). `templates` (the old contract-template model, superseded by the library's lib_ items) and `saved_templates` are unchanged for existing integrations.
items is one list of everything the workspace can start a document from (as the app's Templates page and the MCP list_templates tool): its saved templates first, then AppliFlo's contract templates (kind library), then the official government forms (kind official), filtered by kind, q, country and category and paged with limit/offset (total counts every match). templates (the old contract-template model, superseded by the library's lib_ items) and saved_templates are unchanged for existing integrations.
bearerAuthAuthorizationBearer <token>Workspace API key, e.g. "Authorization: Bearer aflo_live_<64 hex chars>". Keys are hashed at rest and shown only once at creation. A key has scopes: read (GET routes), draft (create or change documents, fields and templates) and send (send, void, remind and bulk send); a call outside them gets 403 insufficient_scope. A key may expire (401 api_key_expired). Keys made before scopes existed have full access.
category?stringFilter to one category.
kind?stringitems[] of this kind only.
"saved""contract""library""official"q?stringWords in the name, or an official form's code ("956", "W-9").
length <= 100country?stringitems[] for this country only (official forms and saved copies of them).
"US""AU"limit?integer1 <= value <= 10020offset?integer0 <= value0The one list (items, total, limit, offset); the workspace's own contract templates plus the curated system ones (templates, deprecated); and its saved templates with recipient roles (saved_templates: status, current version, roles, sender boxes; empty when a category is given).
application/json- response
success*booleandata*curl -X GET 'https://appliflo.com/api/v1/templates'{ "success": true, "data": { "templates": [ { "template_id": "string", "name": "string", "category": "string", "version": 0, "status": "draft", "lawyer_reviewed": true, "scope": "system", "recipients_required": 0, "required_values": [ { "key": "string", "label": "string", "semantic_type": "string" } ], "party_fields": [ { "slot_id": "string", "label": "string", "semantic_type": "string", "party": "string" } ] } ], "saved_templates": [ { "template_id": "string", "kind": "saved", "name": "string", "status": "draft", "version": 0, "field_count": 0, "pages": 1, "roles": [ { "key": "string", "label": "string", "kind": "signer", "order": 1 } ], "sender_fields": [ { "index": 0, "label": "string", "type": "text", "semantic_type": "string", "group_key": "string", "option_value": "string", "bulk": true } ], "fixed_fields": [ { "index": 0, "label": "string", "type": "text", "locked": true, "bulk": true } ], "source": "document", "official_form_slug": "string", "created_at": "2019-08-24T14:15:22Z", "updated_at": "2019-08-24T14:15:22Z" } ], "items": [ { "template_id": "string", "kind": "saved", "name": "string", "status": "draft", "version": 0, "field_count": 0, "pages": 1, "roles": [ { "key": "string", "label": "string", "kind": "signer", "order": 1 } ], "sender_fields": [ { "index": 0, "label": "string", "type": "text", "semantic_type": "string", "group_key": "string", "option_value": "string", "bulk": true } ], "fixed_fields": [ { "index": 0, "label": "string", "type": "text", "locked": true, "bulk": true } ], "source": "document", "official_form_slug": "string", "created_at": "2019-08-24T14:15:22Z", "updated_at": "2019-08-24T14:15:22Z", "summary": "string", "category": "string", "country": "US", "official_form": { "slug": "string", "code": "string", "label": "string", "title": "string", "agency": "string", "agency_name": "string" }, "esign": { "mode": "block", "notice": "string" }, "recipients_required": 0, "required_values": [ {} ], "party_fields": [ {} ], "lawyer_reviewed": true, "own_risk": true, "setup_required": true } ], "total": 0, "limit": 1, "offset": 0 }}Draft a document from a template POST
An AppliFlo library item or official form (a lib_ id from items[]) is the app's Use: a ready item drafts with each role's person bound (an unreviewed contract needs risk_accepted: true unless the person already accepted that version); a form AppliFlo hasn't set up is imported as a new document and its fields are read, and recipients are added when you send. The e-sign rule applies at send (a fill-and-print-only form drafts, but every send refuses it). Any other id is the older contract-template model (values + recipients in party order). Saved templates: POST /saved-templates/{id}/create-document.
Cancel a batch POST
Every row not sent yet is cancelled; envelopes already sent are untouched (void them one by one if needed). A batch that already finished is refused.