How to create subscription plans?

Create a subscription plan in the Webapp (no code)

  1. Go to the Subscriptions app and select New subscription.
  2. Select a Customer (or create a new one). Defaults like billing entity and currency can come from your Billing or Customer settings.
  3. 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.
  4. 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.
  5. 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.
  6. 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

  1. 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.
  2. Create the Subscription:
    • Set billing_customer_id.
    • Choose collection_method: AUTO_CHARGE, CHARGE_ON_CHECKOUT, or OUT_OF_BAND.
      1. If AUTO_CHARGE, provide both linked_payment_account_id and payment_source_id
      2. 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.
  3. Trials and timing (optional):
    • Trials are exclusive of billing duration; set starts_at (defaults to creation time) and trial_ends_at.
  4. 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

Was this article helpful?

0 out of 0 found this helpful

Have more questions? Submit a request