> ## Documentation Index
> Fetch the complete documentation index at: https://tetrafi.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Webhook events

> Every event a webhook can subscribe to, by area, with what it means.

Choose events when you add a webhook. Every event arrives in the same envelope, `{id, type, apiVersion, createdAt, data}`, signed with Standard Webhooks: [Webhooks](https://tetrafi.mintlify.site/trade/webhooks.md) shows how to verify and handle it. More events can be added: answer one you do not handle with a `2xx`.

## Payouts

| Event | What it means |
| :- | :- |
| `treasury.payout.awaiting_approval` | A person must approve this payout before anything is sent. |
| `treasury.payout.completed` | The payout settled; its transaction hash and explorer link are included when known. |
| `treasury.payout.failed` | The payout stopped as failed; read its outcome before trying again. |
| `treasury.payout.cancelled` | The payout was cancelled before anything was sent. |

## Fiat

| Event | What it means |
| :- | :- |
| `treasury.fiat_leg.planned` | A bank payout is planned; nothing has been sent yet. |
| `treasury.fiat_leg.awaiting_approval` | The bank payout waits for your workspace's approval before it is sent. |
| `treasury.fiat_leg.payout_held` | The bank payout waits before sending, for the reason its code names; it is asked again. |
| `treasury.fiat_leg.dispatching` | The venue was asked to send the bank payout; it has not reported it sent yet. |
| `treasury.fiat_leg.uncertain` | Whether the venue took the request is not known yet; it is checked, never sent again. |
| `treasury.fiat_leg.in_transit` | Reported sent by the venue; it has not been reported arrived. |
| `treasury.fiat_leg.held_by_provider` | The provider reports it is holding the bank payout. |
| `treasury.fiat_leg.overdue` | The bank payout passed its expected arrival time and is still being followed. |
| `treasury.fiat_leg.manual_review` | Support must look at this bank payout; it will not fail on its own. |
| `treasury.fiat_leg.settled` | Reported arrived by the venue, not independently verified. |
| `treasury.fiat_leg.returned` | Reported returned by the venue: the money came back to the account. |
| `treasury.fiat_leg.returned_after_settlement` | A bank payout reported arrived was later reported returned. |
| `treasury.fiat_leg.refunding` | The money is being returned to where it came from. |
| `treasury.fiat_leg.refunded` | The money was returned to where it came from. |
| `treasury.fiat_leg.cancelled` | A bank payout or deposit-first pay-in ended before anything moved; its outcome code says why. |
| `treasury.fiat_leg.refused` | The bank payout was refused before anything was sent; its code says why. |
| `treasury.bank_deposit.declared` | A member said they sent a bank deposit to a venue account; nothing is credited until it is confirmed. |
| `treasury.bank_deposit.overdue` | The declared deposit passed its expected arrival time; it is still credited when it lands. |
| `treasury.bank_deposit.manual_review` | The deposit could not be matched on its own; support must look at it. |
| `treasury.bank_deposit.credited` | The venue's record, or the LP's own report, credited the deposit; creditSource says which. |
| `treasury.bank_deposit.withdrawn_by_user` | The workspace said the deposit was not sent; nothing moved. |
| `treasury.bank_deposit.history_unreadable` | The venue's deposit history can't be read, so the deposit can't be matched yet; nothing is lost. |
| `treasury.bank_deposit.history_recovered` | The venue's deposit history can be read again and matching resumed. |
| `treasury.fiat_leg.awaiting_funds` | A deposit-first trade waits for its bank deposit; nothing converts before it lands. |
| `treasury.fiat_leg.funds_received` | The deposit landed; the trade runs only at the consented worst price or better. |
| `treasury.fiat_leg.price_beyond_bound` | The price moved or the worst price lapsed; confirmAgainReason says which. Nothing converted. |
| `treasury.fiat_leg.expired_unfunded` | The pay-by deadline passed before the deposit arrived. |
| `treasury.fiat_leg.late_funds` | The deposit arrived after its pay-by deadline. |

## Transfers

| Event | What it means |
| :- | :- |
| `treasury.transfer.submitted` | The custodian accepted the transfer; it has not settled yet. |
| `treasury.transfer.awaiting_approval` | The transfer is waiting for your workspace's approvers. |
| `treasury.transfer.rejected` | An approver rejected the transfer; nothing was sent. |
| `treasury.transfer.completed` | The custodian reports the transfer complete. |
| `treasury.transfer.failed` | The transfer failed; read its outcome before sending again. |
| `treasury.transfer.cancelled` | The transfer was cancelled. |
| `treasury.transfer.custodian_approval_relayed` | Your approval reached the custodian, which still decides the outcome. |
| `treasury.transfer.expired` | The approval window closed before the transfer was released. |
| `treasury.transfer.replaced` | A replacement transaction was recorded for the original transfer. |
| `treasury.transfer.confirmation_threshold_set` | A person changed how many confirmations this transfer waits for. |

## Runs

| Event | What it means |
| :- | :- |
| `treasury.run.draft` | A plan was saved for review; nothing has been sent. |
| `treasury.run.waiting_for_funds` | Its sources cannot pay it yet; nobody is asked to approve it until they can. |
| `treasury.run.awaiting_approval` | The Run is waiting for a person to approve it. |
| `treasury.run.ready` | The Run is approved and about to start. |
| `treasury.run.running` | The Run is carrying out its plan. |
| `treasury.run.waiting` | The Run is waiting on something outside it, such as a confirmation. |
| `treasury.run.reconciling` | The original operation is being checked, not sent again. |
| `treasury.run.needs_review` | A person needs to look at the reason the Run stopped. |
| `treasury.run.paused` | The Run is paused; its reason says what resumes it. |
| `treasury.run.succeeded` | The Run finished its whole plan. |
| `treasury.run.partially_succeeded` | Part of the plan finished; check each step before acting. |
| `treasury.run.failed` | The Run failed; nothing more is sent without a person. |
| `treasury.run.recovering` | The Run is following its recorded recovery plan. |
| `treasury.run.recovered` | The recovery finished. |
| `treasury.run.cancelled` | The Run was cancelled before anything more was sent. |

## Run steps

| Event | What it means |
| :- | :- |
| `treasury.step.pending` | The step has not started. |
| `treasury.step.ready` | The step is about to start. |
| `treasury.step.dispatching` | The step is sending its one operation. |
| `treasury.step.waiting` | The step is waiting for its operation to confirm. |
| `treasury.step.reconciling` | The original operation is being checked, not sent again. |
| `treasury.step.needs_review` | A person needs to look at the reason the step stopped. |
| `treasury.step.paused` | The step cannot continue until its pause is resolved. |
| `treasury.step.succeeded` | The step's operation is confirmed. |
| `treasury.step.partially_succeeded` | Part of the step finished and needs reconciling. |
| `treasury.step.failed` | The step failed; check its outcome before retrying. |
| `treasury.step.cancelled` | The step was cancelled. |
| `treasury.step.custodian_cancel_requested` | The custodian accepted a person's cancel of the step's payment; the step settles from the custodian's own record. |
| `treasury.step.confirmation_threshold_set` | A person changed how many confirmations the step's custody payment waits for. |
| `treasury.step.custodian_approval_relayed` | A person's approval of the step's payment reached the custodian, which still decides the outcome. |
| `treasury.step.custodian_cancel_overridden` | The custodian completed the step's payment after accepting its cancel; the step settles as sent at the custodian's actual fee. |

## Approvals

| Event | What it means |
| :- | :- |
| `treasury.approval.requested` | A treasury decision is waiting for an eligible member of the workspace. |
| `treasury.approval.expiring` | A treasury decision is still waiting and its approval window closes soon. |
| `treasury.approval.approved` | A member approved the request. Approval is not execution: nothing is implied about sending. |
| `treasury.approval.denied` | A member declined the request, so it will not go ahead. |
| `treasury.approval.expired` | Nobody decided before the approval window closed, so the request will not go ahead. |

## Destinations

| Event | What it means |
| :- | :- |
| `treasury.destination.retired` | A person retired the Destination; it cannot receive new payouts. |

## Workspace

| Event | What it means |
| :- | :- |
| `treasury.workspace.frozen` | Someone froze Treasury for the workspace; no money moves until it is unfrozen. |

## Balances

| Event | What it means |
| :- | :- |
| `treasury.balance.low` | A balance fell below its alert threshold. |
| `treasury.balance.recovered` | A balance is back above its alert threshold. |
| `treasury.statement.ready` | A monthly statement for the previous month was generated and can be downloaded under current reporting access. |

## Automations

| Event | What it means |
| :- | :- |
| `treasury.automation.created` | A person saved a new automation. |
| `treasury.automation.updated` | A person changed an automation's definition. |
| `treasury.automation.activated` | The automation was approved and will start Runs on its schedule. |
| `treasury.automation.returned_to_review` | The automation needs approval again before it runs. |
| `treasury.automation.paused` | The automation will not start Runs until it is resumed. |
| `treasury.automation.resumed` | The automation starts Runs again. |
| `treasury.automation.archived` | The automation was archived and will not run again. |

## Agents

| Event | What it means |
| :- | :- |
| `treasury.agent.envelope.created` | Spending limits were recorded for an agent. |
| `treasury.agent.envelope.updated` | An agent's spending limits changed. |
| `treasury.agent.kill_switch.activated` | A person stopped the agent; it cannot move money until restarted. |
| `treasury.agent.session_signer.granted` | An agent was given a signer for its wallet. |
| `treasury.agent.session_signer.revoked` | An agent's signer was taken away. |
| `treasury.agent.sponsor.changed` | A different member is now accountable for the agent. |

## Agent payments

| Event | What it means |
| :- | :- |
| `treasury.agent.payment.authorized` | An agent's payment was authorized; it has not settled yet. |
| `treasury.agent.payment.settled` | An agent's payment settled. |
| `treasury.agent.payment.refused` | An agent's payment was refused; its reason is recorded. |
| `treasury.agent.payment.received` | An agent received a payment. |

## Orders

| Event | What it means |
| :- | :- |
| `order.updated` | An order or venue trade changed status; carries its id, new status and where to read it. |

## Settlement

| Event | What it means |
| :- | :- |
| `settlement.failed` | A settlement attempt failed. |
| `settlement.retried` | A failed settlement is being attempted again. |
| `settlement.disputed` | A counterparty disputed a settlement. |

## Members

| Event | What it means |
| :- | :- |
| `member.invited` | Someone was invited to the workspace. |
| `member.joined` | An invited person joined the workspace. |
| `member.added` | A member was added to the workspace. |
| `member.removed` | A member was removed from the workspace. |

## API keys

| Event | What it means |
| :- | :- |
| `api_key.rotated` | An API key was replaced with a new secret. |
| `api_key.revoked` | An API key was revoked and no longer works. |
| `api_key.expiring_soon` | An API key will expire soon; rotate it to keep access. |

## Liquidity provision

| Event | What it means |
| :- | :- |
| `lp.enabled` | A liquidity provider was enabled for the workspace. |
| `lp.disabled` | A liquidity provider was disabled for the workspace. |
| `lp.sla_breach` | A liquidity provider missed its service level. |

## Compliance

| Event | What it means |
| :- | :- |
| `kyb.expiring` | The workspace's business verification expires soon. |
| `kyb.expired` | The workspace's business verification expired. |
| `kyb.renewed` | The workspace's business verification was renewed. |
| `kyc.expiring` | A member's identity verification expires soon. |
| `compliance.sanctions.flag_added` | A sanctions screening flag was added. |
| `compliance.event` | A compliance event without its own name was recorded. |

## Credit

| Event | What it means |
| :- | :- |
| `credit.updated` | A credit line or limit changed. |

## Affiliation

| Event | What it means |
| :- | :- |
| `affiliation.invited` | Another workspace was invited to affiliate. |
| `affiliation.accepted` | An affiliation invitation was accepted. |
| `affiliation.revoked` | An affiliation was ended. |

## Bilateral

| Event | What it means |
| :- | :- |
| `bilateral.requested` | A counterparty asked to trade bilaterally. |
| `bilateral.accepted` | A bilateral trading request was accepted. |

## Direct users

| Event | What it means |
| :- | :- |
| `direct_user.created` | A direct user was created under this broker. |
| `direct_user.updated` | A direct user's details changed. |
| `direct_user.invited` | A direct user was invited. |
| `direct_user.suspended` | A direct user was suspended. |
| `direct_user.verification.pending` | A direct user's verification is in progress. |
| `direct_user.verification.verified` | A direct user passed verification. |
| `direct_user.verification.rejected` | A direct user's verification was rejected. |

## Wallets

| Event | What it means |
| :- | :- |
| `wallet.session_signer.granted` | A session signer was granted on a workspace wallet. |
| `wallet.session_signer.revoked` | A session signer was revoked from a workspace wallet. |

## Webhooks

| Event | What it means |
| :- | :- |
| `webhook.subscription.paused` | Another webhook in this workspace paused after repeated failed deliveries. |


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.