Ratgeber

DocuSeal webhook: print signed documents automatically

Print documents signed in DocuSeal automatically with the submission.completed webhook, the DocuSeal API and Sealed Print. Setups for n8n, Zapier, Make or your server.

Aktualisiert am 21. Oktober 2026

DocuSeal collects signatures, but many signed documents still end up on paper: a contract for the client file, a delivery note for the warehouse, a handover report for the caretaker or a consent form that has to be filed. DocuSeal itself does not print. This article shows how to print every document signed in DocuSeal automatically on an office printer, using the DocuSeal webhook submission.completed and Sealed Print. It works with DocuSeal Cloud and with self-hosted DocuSeal, and nothing has to be opened on the office router.

How it works

  1. When the last signer has signed, DocuSeal sends a webhook with the event submission.completed to a URL you choose. The webhook contains JSON, not the PDF: the signed documents are download links.
  2. An automation downloads the signed PDF from that link: an n8n workflow, a Zap, a Make scenario or a few lines of code on your own server.
  3. The automation sends the PDF to a secret Sealed Print URL, an API endpoint. Sealed Print turns it into a print job and delivers it to the printer: through the relay client on a computer or NAS in the office, directly to printers with IPP INFRA support, or over IPP to a printer reachable from the internet.

The relay client and INFRA printers only open outgoing connections. DocuSeal, the automation and the printer do not have to be on the same network.

Prerequisites

  • DocuSeal with webhooks: DocuSeal Cloud on the Pro plan or self-hosted DocuSeal. According to DocuSeal's pricing page, the free Cloud Basic plan has no webhooks; the open-source version has them.
  • A Sealed Print account with at least one destination, that is, a printer. How to connect an office printer is explained in Install the relay client.
  • The inbound channel REST API is switched on under Settings → Inbound channels. It is on for organizations created since 21 October 2026; in older ones an admin switches it on.
  • An automation that receives the webhook: n8n, Zapier (a paid plan for webhooks), Make, or your own small server.

Which DocuSeal webhook event to use

DocuSeal sends these events, and you choose them per webhook URL:

EventWhen it firesGood for printing?
submission.completedeveryone has signedyes, fires once per submission
form.completedone signer has finishedonly if every signature should be printed separately
form.viewed, form.started, form.declineda signer opened, started or declined the formno
submission.created, submission.expired, submission.archivedthe request was created, expired or archivedno

The payload looks like this (shortened). DocuSeal posts it as JSON with the header Content-Type: application/json:

{
  "event_type": "submission.completed",
  "timestamp": "2026-10-21T09:41:12Z",
  "data": {
    "id": 4711,
    "status": "completed",
    "template": { "id": 12, "name": "Service agreement" },
    "documents": [
      { "name": "service-agreement", "url": "https://…/file/…" }
    ],
    "combined_document_url": "https://…/file/…",
    "audit_log_url": "https://…/file/…"
  }
}
  • documents lists the signed PDFs with name and a download url. Usually you print documents[0].url; with several documents, loop over the list.
  • combined_document_url is one PDF with all documents of the submission.
  • audit_log_url is DocuSeal's audit log, if you also want it on paper.

The download links expire. By default they are valid for 40 minutes. Download the PDF right away in the same automation, not in a job that runs hours later. On self-hosted DocuSeal the environment variable FILE_URLS_EXPIRE_MINUTES sets the lifetime.

Step 1: Create an API endpoint in Sealed Print

  1. Go to Sources → API endpoints and select New API endpoint.
  2. Enter a name, for example "DocuSeal contracts".
  3. Under Target, choose the printer, destination group or workflow for the signed documents.
  4. Select Create and copy the Endpoint URL: https://www.sealedprint.com/api/print/sp_ep_…

The URL is the access key: anyone who knows it can send documents to your printer. Keep it in the automation's credentials, not in a shared document. More in the guide API endpoints.

Step 2: Build the automation

Option A: n8n

  1. Add a Webhook node with HTTP Method POST. Copy its Production URL.

  2. Add an If node with the condition {{ $json.body.event_type }} is equal to submission.completed. This ignores other events if you subscribe to more.

  3. Add an HTTP Request node that downloads the PDF:

    SettingValue
    MethodGET
    URL{{ $json.body.data.documents[0].url }}
    Options → Response → Response FormatFile
  4. Add a second HTTP Request node that sends the PDF to Sealed Print:

    SettingValue
    MethodPOST
    URLyour endpoint URL https://www.sealedprint.com/api/print/sp_ep_…
    Send Query Parameterson, name = {{ $('Webhook').item.json.body.data.template.name }}
    Send Bodyon
    Body Content Typen8n Binary File
    Input Data Field Namedata
  5. Activate the workflow. In DocuSeal, add the n8n Production URL as webhook (step 3).

Further print options and the parameter targets for other printers are described in Print from n8n.

Option B: Zapier

  1. Trigger: Webhooks by Zapier with the event Catch Hook. Copy the webhook URL.
  2. Filter: continue only if event_type is submission.completed.
  3. Action: Code by Zapier with Run Javascript. Input data: file = the field data documents url from the trigger, name = data template name, endpoint = your endpoint URL. Then use this code:
const source = await fetch(inputData.file)
if (!source.ok) {
    throw new Error(`Download from DocuSeal failed: HTTP ${source.status}`)
}
const url = new URL(inputData.endpoint)
url.searchParams.set("name", inputData.name || "DocuSeal")
const response = await fetch(url, {
    method: "POST",
    headers: { "Content-Type": "application/pdf" },
    body: Buffer.from(await source.arrayBuffer()),
})
const text = await response.text()
if (!response.ok) {
    throw new Error(`Sealed Print: HTTP ${response.status} ${text}`)
}
const job = JSON.parse(text)
output = { id: job.id, number: job.number, state: job.state }

If the submission has several documents, Zapier passes the URLs as a comma-separated list; print the first one or split the list in the code. More about Zapier in Print from Zapier.

Option C: Make

  1. Webhooks > Custom webhook as the trigger; copy the address.
  2. A filter on event_type = submission.completed.
  3. HTTP > Download a file with the URL data.documents[1].url (Make counts arrays from 1).
  4. HTTP > Make a request, method POST, your endpoint URL, body type multipart with a field of type File named file that takes the downloaded file.

Details on the Make request are in Print from Make.

Option D: your own server

If DocuSeal runs on your own server anyway, a small service can receive the webhook. This example for Node.js 20 or newer checks DocuSeal's signature, downloads the signed PDF and sends it to Sealed Print:

import { createHmac, timingSafeEqual } from "node:crypto"
import { createServer } from "node:http"

const SECRET = process.env.DOCUSEAL_WEBHOOK_SECRET // signing secret from DocuSeal's webhook settings
const ENDPOINT = process.env.SEALEDPRINT_ENDPOINT // https://www.sealedprint.com/api/print/sp_ep_…

function signatureValid(header, body) {
    const [timestamp, signature] = String(header ?? "").split(".")
    if (!timestamp || !signature || Math.abs(Date.now() / 1000 - Number(timestamp)) > 300) {
        return false
    }
    const expected = createHmac("sha256", SECRET).update(`${timestamp}.${body}`).digest("hex")
    return expected.length === signature.length && timingSafeEqual(Buffer.from(expected), Buffer.from(signature))
}

createServer(async (request, response) => {
    let body = ""
    for await (const chunk of request) {
        body += chunk
    }
    if (!signatureValid(request.headers["x-docuseal-signature"], body)) {
        response.writeHead(401).end()
        return
    }
    const event = JSON.parse(body)
    if (event.event_type === "submission.completed") {
        for (const document of event.data.documents) {
            const pdf = await fetch(document.url)
            const url = new URL(ENDPOINT)
            url.searchParams.set("name", `${event.data.template.name} – ${document.name}`)
            await fetch(url, {
                method: "POST",
                headers: { "Content-Type": "application/pdf" },
                body: Buffer.from(await pdf.arrayBuffer()),
            })
        }
    }
    response.writeHead(200).end()
}).listen(3000)

DocuSeal signs every webhook with the header X-Docuseal-Signature in the form timestamp.signature: an HMAC-SHA256 of timestamp.body with the webhook's signing secret. The check above also rejects requests older than five minutes. Put the service behind HTTPS; DocuSeal Cloud only sends webhooks to HTTPS addresses.

Step 3: Add the webhook in DocuSeal

  1. In DocuSeal, open Settings → Webhooks.
  2. Add the URL from step 2 (n8n production URL, Zapier or Make webhook address, or your server).
  3. Select the event submission.completed.
  4. Optionally note the signing secret, or add a secret header of your own that your automation checks.
  5. Send a test request, then sign a test document. The signed PDF appears in the Sealed Print Queue and is printed.

DocuSeal retries a webhook that fails or answers with an error, with growing pauses. Answer quickly with HTTP 200 and do slow work afterwards, otherwise a retry can print the document a second time.

The API endpoint accepts the same query parameters as every other Sealed Print endpoint, for example:

ParameterExampleEffect
nameService agreement – Millername of the job in the queue
copies2one copy for the file, one for the client
sidestwo-sided-long-edgedouble-sided
targetsofficeprint on the destination with the identifier office instead of the endpoint's target
noTargettruekeep the job in Sealed Print until someone checks and sends it

The full list is in Print from n8n. If the endpoint's target is a workflow, the document can wait in Sealed Print first, for example to be checked before it is printed.

Errors and what they mean

  • HTTP 401 or 403 from DocuSeal's download link: the link has expired. Download the PDF in the same run as the webhook.
  • HTTP 403 from Sealed Print: the inbound channel REST API is switched off, or the person who owns the endpoint has left the organization.
  • HTTP 404 from Sealed Print: the endpoint URL is wrong or was replaced with Generate new URL, or an identifier in targets does not exist.
  • HTTP 413: the PDF is larger than 50 MB or larger than your plan allows.
  • HTTP 415: the request has no Content-Type of application/pdf. Set it as in the examples.

Signing and printing in one place

If the documents are signed only to be printed afterwards, Sealed Print can also collect the signatures itself: the signed PDF gets a verification code and a QR code on every page and goes to the printer without an automation in between. See Electronic signatures. For anyone who already works with DocuSeal templates and its API, the webhook described here is the shorter way.

Frequently asked questions

Can DocuSeal print documents?

No. DocuSeal has no print function and no printer connection. You can download the signed PDF and print it by hand, or, as described here, let a webhook send it to a cloud print service that delivers it to the printer.

Which DocuSeal webhook event fires when all parties have signed?

submission.completed. The event form.completed fires for every single signer, so a submission with three signers would be printed three times.

Does this work with self-hosted DocuSeal?

Yes. The open-source version sends the same webhooks. The automation only has to reach the internet, and the printer stays in the office behind the relay client.

Can I also print the audit log?

Yes. The webhook contains audit_log_url. Download it like the document and send it to the same API endpoint, or use combined_document_url if you want everything as one PDF.

DocuSeal's file links are valid for 40 minutes by default. If your automation waits longer, request the submission again through the DocuSeal API (GET /submissions/{id}) to get fresh links.

What does it cost?

Sealed Print bills per delivery, that is, per job to one printer; the plans are on the pricing page. DocuSeal webhooks need DocuSeal Cloud Pro or the self-hosted version, and Zapier needs a paid plan for webhooks.

Print and sign from anywhere

Unterzeichner unterschreiben per E-Mail-Link ohne Konto; alle erhalten das gesiegelte PDF. Im Tarif Free zahlen Sie nur pro Unterschrift.

Weitere Ratgeber und Vorlagen