Create a subscription plan in the Webapp (no code)
- Go to the Subscriptions app and select New subscription.
- Select a Customer (or create a new one). Defaults like billing entity and currency can come from your Billing or Customer settings.
- Add line items:
- Choose the Product, Price, and Quantity per item.
- You can add multiple items (multi‑item) and even different billing frequencies (multi‑frequency) in one subscription. Frequencies must be compatible so billing dates align on a consistent cycle.
- Configure tax and free trials:
- Apply a custom tax rate to subscription items, if needed.
- Add a free trial; trials are in addition to the paid billing duration.
- Choose a payment collection method:
- Automatically charge an existing saved method.
- Collect via digital invoice for the first payment to save a method for future cycles.
- Collect out‑of‑band and mark invoices paid manually.
- Add any additional info (e.g., invoice memo, metadata) and Create subscription. You can view and manage it from the subscriptions list and details drawer.
Refer details in Product Documentation:https://www.airwallex.com/docs/billing/subscriptions/get-started-with-subscription-management
Create a subscription plan via API
- Create or identify required objects:
- Billing Customer (stores contact and billing preferences).
- Product and Price (amount, currency, frequency; reuse Price IDs).
- Payment Source (if using AUTO_CHARGE). You can generate this from a verified Payment Consent collected at checkout; see “Other checkout options” for how to convert a Payment Consent into a Billing Payment Source.
- Create the Subscription:
- Set billing_customer_id.
- Choose collection_method: AUTO_CHARGE, CHARGE_ON_CHECKOUT, or OUT_OF_BAND.
- If AUTO_CHARGE, provide both linked_payment_account_id and payment_source_id
- If CHARGE_ON_CHECKOUT, provide linked_payment_account_id.
- Add items with items.price_id and quantity. You can include multiple items; ensure frequencies are compatible.
- Set duration.period_unit (DAY, WEEK, MONTH, YEAR) and optionally duration.period (e.g., bi‑monthly with period=2). The smallest frequency among item Prices governs the cycle.
- (Optional) Set default_invoice_template.invoice_memo and default_tax_percent.
- Trials and timing (optional):
- Trials are exclusive of billing duration; set starts_at (defaults to creation time) and trial_ends_at.
- Manage the lifecycle:
- Update (fields depend on status; customer, entity, currency, line items, and tax rate are not editable).
- Cancel with proration behavior: ALL, PRORATED, or NONE.
- Retrieve a subscription, list subscriptions, and retrieve subscription items
For details, prefer to API reference: https://www.airwallex.com/docs/api#/Billing/Subscriptions/
A sample API integration: https://www.airwallex.com/docs/billing/subscriptions/subscriptions-via-api/sample-integration