Register Webhook
Use this endpoint to register the URL that will receive webhook callbacks. The webhook will notify your server when deposit or conversion events occur. POST/webhook/register
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
clientId | string | Yes | Your Onion Finance client ID. |
webhookUrl | string | Yes | HTTPS endpoint that will accept POST events. |
Response (200 OK)
Response (4xx/5xx)
Event Types
| Event | Description |
|---|---|
deposit.completed | New deposit has been confirmed |
conversion.completed | FX conversion has been completed |

