Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.tesouro.com/llms.txt

Use this file to discover all available pages before exploring further.

Webhooks let your system receive real-time notifications when events occur on the Tesouro platform. Tesouro delivers these as HTTP POST requests to an endpoint you register. Unlike polling the API, webhooks push data to you when an event occurs reducing latency and API load.
Your endpoint must return a 2xx status code to acknowledge receipt. Process payloads asynchronously. Heavy processing in the request handler risks timeouts and failed deliveries.

How it works

Embedded banking webhooks use a subscription model. You explicitly subscribe to the event types you want to receive, and Tesouro delivers matching events to your registered endpoint. Each subscription is created and managed through the managing subscriptions guide.

Supported events

Event typeDescription
LEDGER_TRANSACTIONA monetary transaction was posted to the ledger
LEDGER_POSTING_EXCEPTIONAn exception occurred while posting a transaction
LEDGER_ACCOUNT_EXCEPTIONAn exception occurred on a ledger account
ACCOUNT_STATUS_CHANGEDA ledger account’s status changed
ACCOUNT_RESTRICTION_CHANGEDA ledger account’s restrictions changed
See Event types for the attributes and example payload for each event.

Payload structure

Every webhook delivery shares the same envelope. Only the eventType value and the contents of attributes differ between events.
FieldTypeDescription
versionstringPayload schema version. Currently "1".
deliveryIdstring (UUID)Identifier for this delivery. Stable across retry attempts of the same event - use it to deduplicate on your end.
webhookUrlstringThe endpoint URL Tesouro is delivering to.
deliveryDateTimeUtcstring (ISO 8601, UTC)Server timestamp of the delivery attempt.
attemptCountstringDelivery attempt number - "1" on first attempt, higher on retries.
eventTypestringThe event type. See Event types.
attributesobjectEvent-specific fields. See Event types for the shape of each event’s attributes.

Next steps