Adyen-for-platform icon

Example use cases

See examples of how you can configure the balance webhook for specific use cases.

On this page, you can see examples of how you can configure the balance webhook for specific use cases, complete with example API requests and the triggered webhook event.

Any current balance drops below a limit

Use case

I want to get notified if the balance drops below USD 5000 in any of the balance accounts in my balance platform.

Create webhook setting and define conditions

Using the Configuration API, create a webhook setting for the specific currency and value limit. In your API request, specify the following parameters and values:

Parameter Required Value
type -white_check_mark- balance
target.type -white_check_mark- balancePlatform
target.id -white_check_mark- The id of your balance platform, for example, YOUR_BALANCE_PLATFORM.
currency -white_check_mark- USD
status -white_check_mark- active
conditions.balanceType -white_check_mark- balance
conditions.conditionType -white_check_mark- lessThan
conditions.value -white_check_mark- 500000
Get notified when the balance drops below USD 5000
Expand view
Copy link to code block
Copy code
Copy code
curl https://balanceplatform-api-test.adyen.com/balancePlatforms/YourBalancePlatform/webhooks/WBHK00000000000000000000000001/settings \
-H 'x-api-key: ADYEN_BALANCE_PLATFORM_API_KEY' \
-H 'content-type: application/json' \
-X POST \
-d '{
"type": "balance",
"target" : {
"type": "balancePlatform",
"id": "YOUR_BALANCE_PLATFORM"
},
"currency": "USD",
"status": "active",
"conditions": [
{
"balanceType": "balance",
"conditionType": "lessThan",
"value": 500000
}
]
}'

Webhook

The following example shows the webhook event you receive when the balance matches the condition.

Current balance below USD 5000
Expand view
Copy link to code block
Copy code
Copy code
{
"data": {
"settingIds": "BWHS00000000000000000000000001",
"creationDate": "2025-01-19T13:37:38+02:00",
"balancePlatform": "YOUR_BALANCE_PLATFORM",
"currency": "USD",
"balances": {
"available": 499900,
"pending": 350000,
"reserved": 120000,
"balance": 470000
}
},
"environment": "test",
"type": "balancePlatform.balanceAccount.balance.updated"
}

Current balance of a specific user drops below a limit

Use case

I want to be notified if the current balance reaches or drops below USD 5000 in any of my user's balance accounts.

Create webhook setting and define conditions

Using the Configuration API, create a webhook setting and specify the following parameters and values:

Parameter Required Value
type -white_check_mark- balance
target.type -white_check_mark- accountHolder
target.id -white_check_mark- The accountHolderId of your user, for example, AH00000000000000000000001.
currency -white_check_mark- USD
status -white_check_mark- active
conditions.balanceType -white_check_mark- balance
conditions.conditionType -white_check_mark- lessThanOrEqual
conditions.value -white_check_mark- 500000
Get notified about a specific user's balance changes
Expand view
Copy link to code block
Copy code
Copy code
curl https://balanceplatform-api-test.adyen.com/balancePlatforms/YourBalancePlatform/webhooks/WBHK00000000000000000000000001/settings \
-H 'x-api-key: ADYEN_BALANCE_PLATFORM_API_KEY' \
-H 'content-type: application/json' \
-X POST \
-d '{
"type": "balance",
"target" : {
"type": "accountHolder",
"id": "AH00000000000000000000001"
},
"currency": "USD",
"status": "active",
"conditions": [
{
"balanceType": "balance",
"conditionType": "lessThanOrEqual",
"value": 500000
}
]
}'

Webhook

The following example shows the webhook event you receive when the balance matches the condition.

Current balance reached USD 5000
Expand view
Copy link to code block
Copy code
Copy code
{
"data": {
"settingIds": "BWHS00000000000000000000000001",
"creationDate": "2025-01-19T13:37:38+02:00",
"balancePlatform": "YOUR_BALANCE_PLATFORM",
"accountHolderId": "AH00000000000000000000001",
"currency": "USD",
"balances": {
"available": 440000,
"pending": 350000,
"reserved": 120000,
"balance": 500000
}
},
"environment": "test",
"type": "balancePlatform.balanceAccount.balance.updated"
}

Available balance of a specific balance account drops below a limit

Use case

I want to get notified when the available balance on six of my users' balance accounts, which hold foreign currencies, drop below 1000 in their respective currencies.

Create webhook setting and define conditions

Using the Configuration API, create a webhook setting for each of the balance accounts, specifying the following parameters and values:

Parameter Required Value
type -white_check_mark- balance
target.type -white_check_mark- balanceAccount
target.id -white_check_mark- The id of the specific balance account, for example, BA00000000000000000000001.
currency -white_check_mark- The currency of the balance for which you want to receive notifications. For example, JPY.
status -white_check_mark- active
conditions.balanceType -white_check_mark- available
conditions.conditionType -white_check_mark- lessThan
conditions.value -white_check_mark- 100000
Get notified about specific balance accounts
Expand view
Copy link to code block
Copy code
Copy code
curl https://balanceplatform-api-test.adyen.com/balancePlatforms/YourBalancePlatform/webhooks/WBHK00000000000000000000000001/settings \
-H 'x-api-key: ADYEN_BALANCE_PLATFORM_API_KEY' \
-H 'content-type: application/json' \
-X POST \
-d '{
"type": "balance",
"target" : {
"type": "balanceAccount",
"id": "BA00000000000000000000001"
},
"currency": "JPY",
"status": "active",
"conditions": [
{
"balanceType": "available",
"conditionType": "lessThan",
"value": 100000
}
]
}'

Webhook

The following example shows the webhook event you receive when the balance matches the condition.

Available balance below JPY 1000
Expand view
Copy link to code block
Copy code
Copy code
{
"data": {
"settingIds": "BWHS00000000000000000000000001",
"creationDate": "2025-01-19T13:37:38+02:00",
"balancePlatform": "YOUR_BALANCE_PLATFORM",
"accountHolderId": "AH00000000000000000000001",
"currency": "JPY",
"balances": {
"available": 95000,
"pending": 0,
"reserved": 120000,
"balance": 70000
}
},
"environment": "test",
"type": "balancePlatform.balanceAccount.balance.updated"
}