Skip to main content

Automate a process

What you get

A process runs your paperwork end to end: documents come in from a source or a mailbox, Talonic reads and checks them, the right person signs off, and the result goes out by mail, to a system or to a destination, with every step recorded. It is for operations teams who own a workflow such as invoice approval or contract intake, and for developers who start and watch those runs from their own systems.

Before you start

  • Processes use six permissions: view, build, publish, run, sign and govern (process_view, process_build, process_publish, process_run, process_sign, process_govern). Admins hold them by default and grant them to others in Team & Roles. Signers need only process_sign.
  • For the API: a key that belongs to a person (the actions are theirs), with read for reads and write for every change, run and signature. A key with no person behind it is refused.
  • To send or read mail, a connected Gmail or Outlook mailbox. Connecting is a consent screen in the browser.

Do it in the app

  1. Open Processes and click New process. Describe it in one sentence ("Read supplier invoices from the AP mailbox, check totals against the PO, finance signs above 10,000, then send to the ERP"), or import an exported n8n workflow. You get a draft; nothing runs yet.
  2. Adjust the steps: who signs (people, roles or groups from Team & Roles, with Four eyes so nobody signs the same document twice), which mailbox mail goes out from, what is sent where. Open points are listed as plain questions.
  3. Click Test run and pick some documents. The draft runs in a test copy: emails and calls are only recorded and nothing is delivered. The test stops at any step not yet set up.
  4. Click Publish. You see what changes against the live version; the process then runs for real, starting on whatever its first step says (new mail, a source, a form or a call from another system).
  5. Signers find waiting documents under Sign-offs and either sign or Send back with a reason. Open a run to follow each document step by step; use Try again on a failed step.
  6. Every publish is a new version. Roll back to an earlier one from Versions.

Changes that weaken control, such as removing a sign-off or a check, dropping a signer or letting a step act on its own, are saved only after a person confirms them.

Do it with the API

Create a draft with POST /v1/processes, sending exactly one of description (10 to 2,000 characters), workflow (an exported n8n workflow) or name with draft. Change it in words with POST /v1/processes/{id}/change, see what is still missing with GET /v1/processes/{id}/check, test with POST /v1/processes/{id}/test-run, and go live with POST /v1/processes/{id}/publish. Run it on documents with POST /v1/processes/{id}/run, or post one item by field name with POST /v1/processes/{id}/items.

curl: draft, check, test, publish
curl -s -X POST https://api.talonic.com/v1/processes \
  -H "Authorization: Bearer $TALONIC_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "description": "Read supplier invoices from the AP mailbox, check totals against the PO, finance signs above 10000, then send to the ERP." }'
# -> 201 { "id": "...", "name": "...", "steps": [...], "explanation": "...", "questions": [...], "stillOpen": [...], "notes": [...] }

curl -s https://api.talonic.com/v1/processes/$PROCESS_ID/check \
  -H "Authorization: Bearer $TALONIC_API_KEY"

curl -s -X POST https://api.talonic.com/v1/processes/$PROCESS_ID/test-run \
  -H "Authorization: Bearer $TALONIC_API_KEY" -H "Content-Type: application/json" \
  -d '{ "documentIds": ["c3d4e5f6-a7b8-9012-cdef-123456789012"] }'

curl -s -X POST https://api.talonic.com/v1/processes/$PROCESS_ID/publish \
  -H "Authorization: Bearer $TALONIC_API_KEY" -H "Content-Type: application/json" \
  -d '{ "reason": "First live version" }'
# -> 201 { "version": 1, "changed": true }
Node: sign what waits for you
const base = 'https://api.talonic.com/v1/processes';
const headers = {
  Authorization: `Bearer ${process.env.TALONIC_API_KEY}`,
  'Content-Type': 'application/json',
};

const runs = await (await fetch(`${base}/runs?waitingForMe=1`, { headers })).json();
for (const run of runs.runs) {
  // stepId comes from GET /v1/processes/waiting
  await fetch(`${base}/${run.processId}/runs/${run.id}/holds/${stepId}/release`, {
    method: 'POST', headers, body: JSON.stringify({}), // all waiting items
  });
}
Response: GET /v1/processes/{id}/check
{
  "canPublish": false,
  "stillNeeded": [
    { "stepId": "s_mail", "key": "mailFromId", "message": "Which mailbox should this process send from?" }
  ],
  "problems": []
}

Other routes: GET /v1/processes/{id}/changes (what publishing would change), /versions and /versions/{n}/rollback, GET /v1/processes/runs (filter by state: running, completed, failed, stuck), GET /v1/processes/{id}/status, POST /v1/processes/runs/{runId}/retry (failed steps again), .../holds/{stepId}/send-back (with items and reason), GET /v1/processes/mailboxes and PUT /v1/processes/mailboxes/{mailboxId}/ownership (individual or company), and PUT /v1/processes/{id}/address for an address other systems post items to (shown once; require a signature with /address/signing).

Do it with an agent

Build with talonic_process_create, talonic_process_change, talonic_process_check, talonic_process_test_run and talonic_process_publish; operate with talonic_process_run, talonic_process_item, talonic_process_status, talonic_process_runs and talonic_process_retry; sign with talonic_process_waiting_for_me, talonic_process_sign and talonic_process_send_back; manage with talonic_process_versions, talonic_process_rollback, talonic_process_mailbox_ownership, talonic_process_address and talonic_process_setup. Ask, for example: "Draft a Talonic process that reads invoices from the AP mailbox and needs finance sign-off above 10,000, then test it on last week's invoices."

Limits and costs

  • Descriptions and change instructions: up to 2,000 characters. Secrets: names of up to 60 letters, digits, _ or -, values up to 4,000 characters; a value is never returned.
  • Steps that call another system or look up data retry twice by default, either at once or after a set number of minutes. Sign-offs can have a deadline after which the item moves on.
  • Runs list 50 a page, newest first. A process with an open run cannot be deleted.
  • No separate price per process is published. The documents a process reads are charged as in any Run. See Billing, credits and usage.

Errors

ParameterTypeDescription
400bad_requestInvalid body, or publish refused because the draft still needs something; the answer lists what.
403forbiddenThe key has no person behind it, the person lacks the process permission, or the key lacks the scope.
404not_foundNo process, run or mailbox with this ID in your workspace.
409conflictThe draft changed since you read it (send the latest `expectedUpdatedAt`), or an address exists and `replace` was not sent.
422unprocessableA posted item names a field the process does not have; the answer lists its fields.

A change that reduces control answers { "status": "needs_confirmation", "reductions": [...] } and saves nothing. Show those points to a person, and resend with confirmed: true only after they agree.

Next

Frequently asked questions

Can I bring an existing n8n workflow?+
Yes. Export it from n8n and import it when you create a process, or send it as workflow to POST /v1/processes. You get a draft to check, test and publish; nothing runs before you publish.
Does a test run send anything?+
No. A test run works on a test copy: emails and calls are only recorded and nothing is delivered. It stops at the first step that is not set up yet, and everything before it runs.
Who can sign a step?+
Only the people, roles or groups the step names. With four eyes on, whoever signed the same document earlier cannot sign again. Over the API the person behind the key signs, under the same rules as on screen.