Owners and managers add endpoints under Dashboard → Webhooks: up to 10 per organisation, each an HTTPS address on a public network. When you add one, you get its signing secret. It is shown once.
Events
deposit.registered,deposit.updated,deposit.failedanddeposit.tombstoned, with the record'staxonmark_id,id,status,object_type,titleandlanding_page;job.completedwhen a batch job finishes, withjob_id,accepted,rejectedandtotal;ping, sent when you press Test on the Webhooks page.
Each delivery
Taxonmark sends a POST request with a JSON body containing id, event, created, registry and data, and these headers:
X-TM-Event: the event name;X-TM-Timestamp: the time of sending, in Unix seconds;X-TM-Signature:sha256=followed by the HMAC-SHA256 of the timestamp, a full stop and the raw body, keyed with your signing secret.
$ok = hash_equals('sha256=' . hash_hmac('sha256', $ts . '.' . $raw, $secret), $sig) && abs(time() - (int)$ts) < 300;Answer within 5 seconds; slower answers are recorded as failed. Redirects are not followed and failed deliveries are not retried, so watch your endpoint's history: each webhook's page lists its last 100 deliveries with the status code, payload and response. You can pause, test or delete a webhook at any time.
Was this helpful? Send feedback