Reference
//
Get amount spent per subs...
Retrieves amount spent per subscription with period breakdown
Security
oauth2ClientCredentials(Required scopes: subscriptions:write)
- Mock serverhttps://developer.boyahq.com/_mock/v2/openapi/subscriptions/amount-spent
- Productionhttps://api.boyahq.com/v2/subscriptions/amount-spent
- Sandboxhttps://sandbox.api.boyahq.com/v2/subscriptions/amount-spent
curl -i -X POST \
https://developer.boyahq.com/_mock/v2/openapi/subscriptions/amount-spent \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'Content-Type: application/json' \
-H 'business_id: string' \
-H 'org_wallet_ref: string' \
-d '{
"from": "2025-12-31T21:00:00.000+00:00",
"to": "2026-01-30T21:00:00.000+00:00",
"currency": "KES",
"business_id": "4D7CA841437E366EB38C",
"period": "MONTHLY",
"subscriptionId": "67b44aea86c1ccabbe965827"
}'Response
{ "status": true, "message": "Fetch total amount per period", "data": { "amountSpent": [], "periodBreakdown": [ … ] } }