Create a subscription for the current customer
const url = 'https://api.example.com/cms/customer/payment/subscribe';const options = { method: 'POST', headers: { 'API-Key': '<API-Key>', Authorization: 'Bearer <token>', Token: '<Token>', 'Content-Type': 'application/json' }, body: '{"cartId":"example","productId":1,"id":1,"articleId":1,"price":1,"quantity":1,"currency":"example","payment_method":"example","address":{},"shipping_address":{},"shipping_provider":"example","vat_country":"NL","ip_address":"example","country":"example","source":"example","page":"example","button":"example","properties":{},"custom_price":1,"receipt":"example","use_saved_card":false}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.example.com/cms/customer/payment/subscribe \ --header 'API-Key: <API-Key>' \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --header 'Token: <Token>' \ --data '{ "cartId": "example", "productId": 1, "id": 1, "articleId": 1, "price": 1, "quantity": 1, "currency": "example", "payment_method": "example", "address": {}, "shipping_address": {}, "shipping_provider": "example", "vat_country": "NL", "ip_address": "example", "country": "example", "source": "example", "page": "example", "button": "example", "properties": {}, "custom_price": 1, "receipt": "example", "use_saved_card": false }'Initiates a recurring subscription for the current customer. Only supported by payment methods that implement createSubscription() (e.g. stripe, google, itunes). For stripe, use_saved_card (default false) picks the flow: false returns a hosted Checkout Session url to redirect the customer to, for entering a new card; true confirms on-site against the customer’s already-saved payment method (see acquireToken()), returning requires_action/client_secret for SCA/3DS if needed. For google/itunes, it validates a receipt from that gateway entirely on-site with no redirect. The request can specify a cart, product, product item, or article to purchase.
Authorizations
Section titled “Authorizations”Request Bodyrequired
Section titled “Request Bodyrequired”object
Cart ID for existing cart
Product ID for direct purchase
Product item ID for direct purchase
Article ID or array of article IDs
Custom price for product
Quantity for product item
Payment currency
Payment method, must support on-site subscription creation
Billing address
object
Shipping address
object
Shipping provider
2-letter ISO code of the country the customer pays VAT in, as listed under Countries (e.g. NL). Required for VAT calculation: without it the tax in the price matrix is 0. Prices already include VAT, so this sets how much of the total is VAT; it does not change the total.
Example
NLCustomer IP address. Do not send this if the client is directly communicating with the API, such as from your mobile app.
2-letter ISO code of the country (only send when ip_address is filled)
Source (web, app, etc.)
Source page URL
Source button
Additional properties to save for this payment, such as UTM parameters, coupon code, affiliate info, etc.
object
Custom price for article
Payment receipt for off-system payments (e.g. Apple or Google payments)
Stripe only. False (default) returns a hosted Checkout Session url to redirect to for entering a new card; true confirms on-site against the customer’s already-saved payment method.
Responses
Section titled “Responses”Subscription created successfully. If the response object has requires_action = true, the frontend must call stripe.confirmCardPayment(client_secret) to complete SCA/3DS authentication. If the response object has a url instead, redirect the customer there (hosted Checkout Session).
object
API representation of a payment
object
Payment ID
Order amount (DB decimal serialized as a string)
Order currency
Order amount in base currency (DB decimal serialized as a string)
Payment status
Response message
Last update timestamp, MySQL datetime (Y-m-d H:i:s)
Payment timestamp, MySQL datetime (Y-m-d H:i:s)
User ID
Payment method
Renewal ID
Cart items
object
Purchased product item. Currently serialized as a string reference of the form “WhiteBeard\ECommerce\ProductItems:
API representation of an ecommerce pricing tier (product item)
object
Item ID
Description
Product ID
Product name
Price
The price it sells at today: its timed offer’s price while one runs, otherwise price
Currency
Available
Item order
Shippable
Weight
Installments
Once per user
Is upgrade
Upgrade type
Upgrade from
Upgrade exclude items
Upgrade price web
Upgrade price mobile
Field values, keyed by field key (each {name, value, type}), e.g. {“size”: {“name”: “Size”, “value”: “large”, “type”: “list”}}: the same keys the product search takes in settings; an empty array when there are none
object
object
Has image
Additional label 1
Additional label 2
Additional label 3
Diameter
Length
Depth
Width
Recurrent
Recurrent price
Recurrent start
Recurrent schedule
SKU
Stock enabled
Stock available
Whether orders are accepted when out of stock
Package quantity
Related items
object
Images (attachments)
object
High resolution URL
Video (only for video attachments)
object
Duration (only when present in metadata)
Files (attachments)
object
Duration (only when present in metadata)
Product details. Deprecated to avoid circular references. Use productId instead.
object
Translations
Action data to be executed when a pricing tier is bought
object
Action data to be executed when a pricing tier is bought as a renewal
object
Price matrix
object
Subtotal amount
Shipping amount
Tax amount
Discount amount
Total amount
Shipping status. “delivered” means digitally delivered (no physical product); “shipped_delivered” is a physical shipment that arrived.
Shipment tracking number: from the shipping provider when it created the shipment, or set by hand on the order. Null when there is none.
Authorization
Shipping price
Tax price
Reference order ID
Source of the payment (such as website or mobile app store)
Payment properties: those sent when the payment was created (such as UTM parameters, coupon code, affiliate info, stripe_mode), and those the system keeps on it (such as renewal_id, or payment method and CRM sync details)
object
Subscription creation response: either {subscription_id, status, requires_action, client_secret} for on-site confirmation, or a Stripe Checkout Session (including url) when redirecting
object
Example
{ "payment": { "price": "12", "price_baseCurrency": "12", "lastUpdate": "2026-09-29 13:22:40", "timestamp": "2026-09-18 14:46:39", "cart": [ { "item": "WhiteBeard\\ECommerce\\ProductItems:133", "price": 12 } ], "shippingStatus": "waiting", "shippingTrackingNumber": "1Z999AA10123456784", "address": "[]", "shipping_address": "[]", "properties": { "utm_source": "newsletter", "renewal_id": 3 } }}Bad Request
Unauthorized
Forbidden