tario.

Creating webhooks and verifying deliveries

A webhook sends a signed POST to your URL when Hacienda accepts or rejects an invoice or a purchase arrives; you create it under Company settings → Integrations, copy the secret once, test it and follow each delivery.

If you are not signed in, Tario asks you to log in and opens your current company.

Steps

  1. Open Company settings → Integrations → Webhooks and click New webhook (you need the Settings → manage permission).

  2. Type the Endpoint URL (HTTPS recommended), choose the Events you want (Invoice accepted, Invoice rejected, Bill received) and an optional Description. Confirm with Create.

  3. Copy the signing secret now: it is shown once. Every delivery carries X-Tario-Event, X-Tario-Delivery and X-Tario-Signature = HMAC-SHA256 of the raw body with that secret, in hex; verify it against the raw body before parsing.

  4. Click Send test event to queue a signed ping: the Last delivery column shows Queued, Delivered (with the HTTP code), Retrying or Failed with the last error. Tario retries failed deliveries up to 5 times (1 min, 5 min, 30 min, 2 h).

  5. Use the Status switch to pause a webhook without deleting it; Delete removes it and drops queued deliveries.

  6. Delivery history is kept for 30 days. The same subscriptions are available over the API (GET/POST/PATCH/DELETE /api/v1/webhooks) with the update ability.

Tips

  • Answer 2xx quickly and process the event afterwards: a slow endpoint counts as a failure after 10 seconds.
  • Use X-Tario-Delivery as an idempotency key: a retry repeats the same delivery id.
  • Invoice events carry numero_hacienda (the consecutivo), email_delivery (which e-mail Tario sends, if any), hacienda_responded_at and the xml_download_path / xml_response_download_path routes to fetch the signed XML and Hacienda's response with your token, for example to build your own PDF.

Common errors

Code or messageWhat it meansHow to fix it
Turn the webhook on before sending a test event.The webhook is paused, so nothing is delivered to it.Turn the Status switch on and send the test again.

Ask Tario AI

Opens the assistant inside Tario with the question typed, ready to send.

Ask Tario AI