Send a template, or save it as a draft
Makes a document from a template, with one person for each role, and sends
it. With send: false it is saved as a draft instead; a draft may leave
roles empty, and is sent later with
Send a draft.
In signing order, only the first group is invited now. The next group is
invited when the group before them has finished. Every person still gets a
link now: the people in later turns are in laterLinks, and their message
carries the same link when their turn comes.
The response carries each invited person's signing link in invites, and
each later person's link in laterLinks. A link is a secret: anyone
holding it can sign as that person.
Permission: signing:send @ workspace/{workspaceId}, plus
contact:read @ workspace/{workspaceId} when any signer is a CRM contact.
When sending now, also email:send @ workspace/{workspaceId} (or email:me:use with the
address assigned to you) to send from a workspace email address, and
phone:send @ workspace/{workspaceId} to send text messages. The HumaDocs
address ([email protected]) needs nothing more.
Get the template ID first
curl "$HOS_API/signing/templates?workspaceId=ws_a1b2c3" \ -H "Authorization: Bearer $HOS_KEY"Request
curl -X POST "$HOS_API/signing/requests?workspaceId=ws_a1b2c3" \ -H "Authorization: Bearer $HOS_KEY" \ -H "Content-Type: application/json" \ -d '{ "templateId": "RVeFlYdDGgoESUXespsR", "name": "Service agreement, Acme", "signers": [{ "roleId": "client", "name": "Ana Silva", "email": "[email protected]" }] }'Authorization
ServiceAccountKey A service account API key, sent whole as a bearer token:
hsk_<40 hex>.hss_<64 hex>.
In: header
Query Parameters
The workspace the template or document belongs to. Send it in the query string on every call, including the PDF upload. IDs come from List workspaces.
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/signing/requests?workspaceId=ws_a1b2c3" \ -H "Content-Type: application/json" \ -d '{ "templateId": "string" }'{ "success": true, "request": { "id": "string", "templateId": "string", "templateName": "string", "name": "string", "message": "string", "status": "draft", "order": "parallel", "delivery": "email", "sendFrom": { "email": "[email protected]", "phone": "string" }, "layoutVersion": 0, "layoutChangedBy": null, "previousPdfs": [ { "sha256": "string", "fileName": "string", "pageCount": 0, "replacedAt": "2019-08-24T14:15:22Z", "replacedBy": "string" } ], "snapshot": { "pdf": { "fileName": "string", "pageCount": 0, "pageSizes": [ { "w": 0, "h": 0 } ], "sha256": "string", "md5": "string", "bytes": 0 }, "roles": [ { "roleId": "client", "label": "Client", "order": 1 } ], "fields": [ { "fieldId": "client_sig", "roleId": "client", "type": "signature", "label": "string", "required": true, "page": 0, "x": 0, "y": 0, "w": 0, "h": 0 } ] }, "signerSummary": { "total": 0, "completed": 0 }, "prefills": { "property1": "string", "property2": "string" }, "prefillEditable": [ "string" ], "expiresAt": "2019-08-24T14:15:22Z", "remindEveryDays": 2, "createdAt": "2019-08-24T14:15:22Z", "sentAt": "2019-08-24T14:15:22Z", "allSignedAt": "2019-08-24T14:15:22Z", "completedAt": "2019-08-24T14:15:22Z", "declinedAt": "2019-08-24T14:15:22Z", "voidedAt": "2019-08-24T14:15:22Z", "expiredAt": "2019-08-24T14:15:22Z", "result": null, "finalizeError": "string" }, "signers": [ { "id": "string", "roleId": "string", "name": "string", "email": "string", "contactId": "string", "phone": "string", "order": 0, "status": "pending", "consentAt": "2019-08-24T14:15:22Z", "openedAt": "2019-08-24T14:15:22Z", "lastEmailAt": "2019-08-24T14:15:22Z", "lastSmsAt": "2019-08-24T14:15:22Z", "lastLinkAt": "2019-08-24T14:15:22Z", "completedAt": "2019-08-24T14:15:22Z", "declinedAt": "2019-08-24T14:15:22Z", "declineReason": "string", "ip": "string", "userAgent": "string", "timezone": "string", "remindersSent": 0, "nextReminderAt": "2019-08-24T14:15:22Z" } ], "invites": [ { "signerId": "string", "ok": true, "error": "string", "channels": { "email": { "ok": true, "error": "string" }, "sms": { "ok": true, "error": "string" } }, "url": "string" } ], "laterLinks": [ { "signerId": "string", "order": 0, "url": "string" } ]}List documents GET
Documents in the workspace, newest first, at most 200. There is no paging yet. **Permission:** `signing:read` @ `workspace/{workspaceId}`
Count documents by stage GET
Counts for the HumaDocs home page: drafts, documents waiting for others, finished documents, and `actionsRequired`, the number of items [List what needs you](/docs/api-reference/signing/documents/listSigningActions) returns for the caller. **Permission:** `signing:read` @ `workspace/{workspaceId}`