A guide on how to create a new template via API
/createNewTemplate
recipients
to immediately instantiate a document and send notifications.
POST
/createNewTemplate
x-api-key: YOUR_API_KEY
multipart/form-data
document
(file, binary): The template PDF or DOCX file to upload (Note: You can upload a DOCX file, it will be converted to a PDF).templateName
(string): A human-readable name for the template.fields
(JSON string): Array of arrays representing fields grouped by recipient index.
id
(string): Stable ID for the field (e.g., sig-1
).x
(number), y
(number): Position on the page.page
(integer): 1-based page index.type
(string): e.g., Signature
, Text
.recipient
(integer): Group index this field belongs to.recipients
(JSON string): If provided, the server immediately creates a document instance from the template and notifies these recipients.
{ name: string, email: string, phone?: string }
autoReleaseSignatures
(boolean): Defaults to true
if omitted; auto-finalize when all signatures are collected.Content-Type
header for multipart; let your HTTP client set the boundary.fields
and recipients
must be JSON-encoded strings in the form data.(x, y)
and page
should match your PDF’s coordinate system (page is 1-based).{ "message": "No file uploaded." }
{ "message": "Template name is required." }
{ "message": "Invalid fields data." }
{ "message": "Recipients must be an array." }
{ "message": "API key is required." }
{ "message": "Invalid or expired API key." }
{ "message": "Internal Server Error" }