What you’ll need
- Your secret key. Every call in this guide authenticates with it.
- A currency you are set up to collect in. Your regions determine this.
The shape of the flow
1
Create the plan
What you charge, in what currency, how often.
2
Read the plan back
Confirm the pricing and the region it resolved to.
3
See who is subscribed
List subscriptions on the plan, or count them by status.
4
Read one subscription
The billing dates and the card behind it.
5
Stop the billing
Cancel the plan, or cancel one customer’s subscription.
Step 1: Create the plan
- This returns
200, not201, even though it creates the plan. regionsis derived, not sent. Spotflow worked out["Ghana"]from theGHScurrency and theGHcountry code. You cannot set it directly.subscribersandsubscriptionsare separate counts. One customer who resubscribes is one subscriber and two subscriptions.
The plan is already active
Your internal reference is the uniqueness key
Reusing aninternalReference is rejected:
Step 2: Read the plan back
createdAt.
For a portfolio view across all plans:
Those counts are strings, not numbers. Parse them before doing arithmetic.
GET /plans lists them all and accepts size and status filters.
Step 3: See who is subscribed
nextPaymentDate is when this customer gets charged again. A brand new plan returns
"content": [] with totalElements: 0.
For a status breakdown rather than the rows:
completed means the
cycleCount ran out; expired means the plan’s endDate passed.
GET /subscriptions lists across all plans and accepts status and size.
Step 4: Read one subscription
PUT on the same path to change it.
Step 5: Stop the billing
To stop the whole plan:activate is the
right call:
status returns to active.
To stop one customer instead of the whole plan, cancel their subscription:
We did not run the subscription cancel or activate calls, so their exact response bodies
are not shown here. Cancelling a live subscription is destructive and there was no
disposable one to use. The plan-level cancel and activate above are verified.
When things go wrong
What to do next
- Charge tax on a collection — add VAT to what you bill
- Give a Customer a Virtual Account — where the collected money lands
- Pay one person out — move it back out

