Skip to content

Quickstart

In this guide you connect a script to your MyCLM provider, send a PDF for signature and get notified when it is signed. It takes about ten minutes.

You need: an account with the Integrations permission (integrations.manage, owners and administrators have it) on your organization, a PDF file, and curl, Node.js 20+, Python 3 or PHP 8.

  1. In the app, open Settings → Integrations → API keys and click New API key.

    • Name: what the key is for, e.g. CRM sync.
    • Scope: the entity (or group) the key works in. It sees what a member attached there would see.
    • Role: the rights of the key, e.g. Member (can send signature requests). A key never gets more rights than yours.
    • Expiry and Allowed IP addresses are optional but recommended in production.

    Copy the Client ID, Client secret, Token URL and Scope. The secret is shown once: store it in your secrets manager.

    Terminal window
    export MLT_API_URL=http://localhost:3100
    export MLT_TOKEN_URL='<Token URL>'
    export MLT_CLIENT_ID='<Client ID>'
    export MLT_CLIENT_SECRET='<Client secret>'
    export MLT_SCOPE='<Scope>'
  2. API keys use the OAuth 2 client_credentials grant on the identity provider of your MyCLM provider.

    Terminal window
    export MLT_TOKEN=$(curl -s -X POST "$MLT_TOKEN_URL" \
    -u "$MLT_CLIENT_ID:$MLT_CLIENT_SECRET" \
    -d grant_type=client_credentials \
    --data-urlencode "scope=$MLT_SCOPE" | jq -r .access_token)

    The token is valid for 10 minutes (expires_in, in seconds): cache it and reuse it until it expires.

  3. Resources belong to an entity. GET /v1/me tells you where your key can work: take scopes[].entityId.

    Terminal window
    curl -s "$MLT_API_URL/v1/me" -H "Authorization: Bearer $MLT_TOKEN" | jq '.scopes[] | {entityId, entityName, permissions}'
  4. The request is multipart/form-data: a file part with the PDF and a data part with the options as a JSON string.

    Terminal window
    curl -s -X POST "$MLT_API_URL/v1/signature-requests" \
    -H "Authorization: Bearer $MLT_TOKEN" \
    -F 'data={"entityId":"<entityId>","title":"Bail - Lot 12","signers":[{"firstName":"Marie","lastName":"Durand","email":"marie.durand@example.fr"}]}' \
    -F 'file=@bail-lot-12.pdf;type=application/pdf'

    The response is the signature request with status: "sent". Marie receives an email with a signing link.

  5. In Settings → Integrations → Webhooks, click New subscription, enter your HTTPS endpoint and select signature.signed and signature.completed. Copy the signing secret (shown once) and click Send a test event to check your endpoint.

    When Marie signs, your endpoint receives:

    {
    "id": "0192f3b0-12c4-7e8a-b3d1-5f6a7b8c9d0e",
    "type": "signature.completed",
    "apiVersion": "1",
    "createdAt": "2026-10-01T10:12:45.000Z",
    "providerId": "0192f3a1-7c2e-7b4d-9a61-100000000001",
    "orgId": "0192f3a1-7c2e-7b4d-9a61-200000000001",
    "data": { "requestId": "0192f3a1-7c2e-7b4d-9a61-400000000001", "title": "Bail - Lot 12" }
    }

    Always verify the X-MLT-Signature header before trusting a payload, and answer 2xx within 10 seconds.

  6. Terminal window
    curl -s "$MLT_API_URL/v1/signature-requests/<id>/document?variant=signed" \
    -H "Authorization: Bearer $MLT_TOKEN" -o bail-lot-12-signed.pdf