Skip to main content
POST
/
createNewTemplate
Create a template (API key auth). Optionally instantiate and send to recipients.
curl --request POST \
  --url https://api.useinkless.com/createNewTemplate \
  --header 'Content-Type: multipart/form-data' \
  --header 'x-api-key: <api-key>' \
  --form 'templateName=<string>' \
  --form 'fields=[
  {
    "id": "sig-1",
    "x": 144,
    "y": 418,
    "page": 1,
    "type": "Signature",
    "recipient": 1
  }
]' \
  --form document='@example-file' \
  --form 'emailSubject=<string>' \
  --form 'recipients={
  "name": "<string>",
  "email": "[email protected]",
  "phone": "<string>"
}' \
  --form autoReleaseSignatures=true
{
  "message": "Template created successfully",
  "template_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "s3_url": "<string>",
  "fields": [
    [
      {
        "id": "sig-1",
        "x": 144,
        "y": 418,
        "page": 1,
        "type": "Signature",
        "recipient": 1
      }
    ]
  ]
}

Authorizations

x-api-key
string
header
required

Body

multipart/form-data
templateName
string
required

Name for the template.

fields
object[][]
required

Template fields grouped by recipient index. Each inner array corresponds to the fields for a recipient. Sent as JSON within multipart.

document
file

The template PDF file to upload. Note that you can also upload a DOCX file here but will be converted to a PDF.

emailSubject
string

Optional custom subject for the email sent to recipients.

recipients
object[]

Optional. If provided, immediately creates a document instance and notifies recipients.

autoReleaseSignatures
boolean

Optional. Default false if omitted.

Response

Success

message
string
required
Example:

"Template created successfully"

template_id
string<uuid>
required
s3_url
string
required

S3 key/path for the uploaded template PDF.

fields
object[][]
required