When a recurring payment fails in your billing system, notify Churn Buster so that a recovery campaign can be started.
curl -X "POST" "https://api.churnbuster.io/v1/failed_payments" \
-H "Content-Type: application/json" \
-u "ACCOUNT_ID:API_KEY" \
-d $'{
"payment": {
"source": "in_house",
"source_id": "ch_abc123",
"amount_in_cents": 2900,
"currency": "USD",
"properties": {
"failure_message": "insufficient_funds",
}
},
"subscription": {
"source": "in_house",
"source_id": "sub_abc123",
"properties": {
"product_name": "productA",
}
},
"customer": {
"source": "in_house",
"source_id": "cus_abc123",
"email": "sarah@example.com",
"properties": {
"first_name": "Sarah",
"last_name": "Doe",
"phone_number": "+1111111111",
"country_code": "US",
}
}
}
During development, view test API requests here.
When using the live API you can view recent requests here.
---