API Integration / Default Payment Method API Endpoint (always optional)
Dunning
Adaptive Campaigns
Emails
SMS Nudge
Last Chance Offers
Retries
Card Updates
Alerts
Data & Testing
Cancel Flows
Overview
Getting Started
Deflections
Cancel Reasons
Targeted Offers
Custom Branding
Segmentation
Analytics & Insights
Integrations
Stripe
Loop
Inveterate
Ordergroove
Rivo
Checkout Champ
Skio
Stay AI
Seal Subscriptions
Awtomic
Recharge
Smartrr
PayPal
Braintree
Orb
API
Getting Started with the Churn Buster API
Successful Payments API Endpoint
Failed Payments API Endpoint
Cancellations API Endpoint
Default Payment Method API Endpoint (always optional)
Customer Endpoint
Upcoming Annual Renewals API Endpoint
Webhook Data Reference
Other
FAQ
Default Payment Method API Endpoint (always optional)
Notify Churn Buster when a customer's default payment method is updated so that analytics can be tracked.
When a customer's default payment method is updated in your billing system, notify Churn Buster so analytics can be tracked correctly.
This endpoint is optional, but it adds useful depth to campaign reporting: it shows which campaigns were recovered via retry vs. via card update.
Two-step setup
- Add a trigger in your in-house logic, or subscribe to a webhook from your payment processor or subscription management tool, that fires when a customer's default payment method is updated.
- When the trigger fires, send this request:
curl -X "POST" "https://api.churnbuster.io/v1/payment_methods" \
-H "Content-Type: application/json" \
-u "ACCOUNT_ID:API_KEY" \
-d '{
"payment_method": {
"source": "in_house",
"source_id": "card_abc123",
"type": "card",
"properties": {
"brand": "visa",
"funding": "debit",
"last4": "1234",
"exp_month": 9,
"exp_year": 2028
}
},
"customer": {
"source": "in_house",
"source_id": "cus_abc123",
"email": "sarah@example.com",
"properties": {
"first_name": "Sarah",
"last_name": "Doe"
}
}
}'
Verify your requests
- Test mode: view requests in the test debugger.
- Live mode: view recent requests in the live debugger.
About source and source_id
-
source: set it to"in_house", or another consistent name that identifies your subscription management system. Use the same value in every request. -
source_id: the record's ID in your system. Use unique IDs for each customer, subscription, payment method, and payment.