Inkless Digital Signing • API v1

Introduction

The Inkless API lets you programmatically create and send signing links (“envelopes”) based on your email templates and document templates, with signing order, merge fields, auditing, and expiry.

Tip: Tokens are company-scoped. The email_template_id and all document_template_id values must belong to the same company as the token.

Base URL

POST https://inkless.uk/api/service.php

Authentication

Include your API token in the Authorization header:

Header
Authorization: Bearer YOUR_API_TOKEN
Missing/invalid token
401 Unauthorized
Revoked token
401 Unauthorized

Credits

Each successful send (one API call that creates an envelope) consumes 1 company credit.

No credits left
402 insufficient_credits
Response
Successful responses include remaining_credits.
curl -sS -X POST "https://inkless.uk/api/service.php" \
 -H "Authorization: Bearer YOUR_API_TOKEN" \
 -H "Content-Type: application/json" \
 -d '{"type":"get_credits"}'

Payload & schema

Top-level

FieldDescription
typeMust be send_link.
email_template_idCompany-owned email template; its subject is used.
documentsArray of document requests (see right).

documents[]

FieldDescription
document_template_idCompany-owned document template.
mergeObject of merge fields for the template (optional).
recipients[]Per-document signer mapping. Each item has:
- recipient_number (int ≥ 1): signing order bucket
- name (required)
- email (required)
- phone (optional)
Legacy shape is supported: documents[].doc_id, documents[].recipient_numbers, and a top-level recipients map.

Responses

200 OK

Example
{
  "ok": true,
  "links": [
    {
      "secure_link_id": 271,
      "token": "2c0c...e2f1",
      "recipient": { "name": "Shane Lowe", "email": "shane@example.com" },
      "expires_at": "2025-09-05 10:14:00",
      "status": "sent",
      "verify_url": "https://sign.inkless.uk/verify/2c0c...e2f1"
    }
  ],
  "docs": [
    { "doc_id": 5, "doc_token": "a1b2...c3d4", "name": "NDA", "version": 1, "pages": 3 }
  ],
  "remaining_credits": 42
}

Common errors

HTTPErrorMeaning
400documents is requiredProvide a non-empty documents array.
400email_template_id is requiredProvide a valid template id.
400no valid documents or recipientsCheck doc IDs and recipients (name, email, and numbers).
401Missing or invalid token.
402insufficient_creditsBuy credits or top up.
403email template not found for this companyTemplate ownership mismatch.
403invalid_document_idsOne or more documents aren’t owned by your company.
500server errorUnexpected failure (conversion, I/O). Retry or contact support.

Error handling

We return a non-2xx HTTP status and a JSON body with ok: false and an error key. Your client should check response.ok and handle these values.

Webhooks (optional)

Inkless can POST JSON to your webhook endpoint for events such as:

  • document_signing_link_sent
  • document_signed
  • archive_ready
  • link_resent
Example payload
{
  "event": "document_signed",
  "company_id": 16,
  "doc_token": "a1b2...c3d4",
  "secure_link_id": 271,
  "recipient": { "name": "Shane Lowe", "email": "shane@example.com" },
  "signed_at": "2025-09-04T10:25:31Z",
  "metadata": { "ip": "203.0.113.5", "user_agent": "..." }
}

Ask support to enable & configure your webhook URL. Use HTTPS. We can sign payloads and retry deliveries if needed.

List email templates

Returns active email templates (ID & name) for your company.

POST /api/service.php with {"type":"list_email_templates"}
curl -sS -X POST "https://inkless.uk/api/service.php" \
 -H "Authorization: Bearer YOUR_API_TOKEN" \
 -H "Content-Type: application/json" \
 -d '{"type":"list_email_templates"}'

Response: {"ok":true,"templates":[{"id":21,"name":"Default Signing Invite"},...]}

List document templates

Returns active non one-off document templates (ID & name) for your company.

POST /api/service.php with {"type":"list_document_templates"}
curl -sS -X POST "https://inkless.uk/api/service.php" \
 -H "Authorization: Bearer YOUR_API_TOKEN" \
 -H "Content-Type: application/json" \
 -d '{"type":"list_document_templates"}'

Response: {"ok":true,"templates":[{"id":5,"name":"Contract v1"},...]}

Get artifact (signed PDF / audit log / archive)

Returns the requested artifact for a document instance identified by doc_token. File is base64 in JSON.

POST /api/service.php with {"type":"get_artifact","doc_token":"...","artifact":"signed|audit|archive"}
curl -sS -X POST "https://inkless.uk/api/service.php" \
 -H "Authorization: Bearer YOUR_API_TOKEN" \
 -H "Content-Type: application/json" \
 -d '{"type":"get_artifact","doc_token":"DOC_TOKEN","artifact":"signed"}'
Not ready? You’ll receive 409 with {"ok":false,"error":"not ready"} until the artifact exists (e.g. signed PDF after all parties sign).

Changelog

  • 2025-09-04 — Added docs for get_credits, list_email_templates, list_document_templates, and get_artifact. Kept layout, added PHP/Python examples, generic tab & copy handling.
  • 2025-09-04 — Initial docs for send_link. Credits check & debit, ownership checks, audit logging, first-batch mailing.