> Portal Navigation: > > - Append `.md` to any URL under `https://dev.wix.com/docs/` to get its markdown version. > - Pages are either content pages (article or reference text) or menu pages (a list of links to child pages). > - To get a menu page, truncate any URL to a parent path and append `.md` (e.g. `https://dev.wix.com/docs/sdk.md`, `https://dev.wix.com/docs/sdk/core-modules.md`). > - Top-level index of all portals: https://dev.wix.com/docs/llms.txt > - Full concatenated docs: https://dev.wix.com/docs/llms-full.txt ## Resource: Introduction ## Article: Public Introduction ## Article Link: https://dev.wix.com/docs/api-reference/business-solutions/pricing-plans/introduction.md ## Article Content: # About the Pricing Plans APIs [Wix Pricing Plans](https://support.wix.com/en/article/about-pricing-plans) includes Plans and Orders, and allows Wix users to build a customized membership plan experiences and sell them to their customers. - With [Plans](https://dev.wix.com/docs/api-reference/business-solutions/pricing-plans/plans/introduction.md), a Wix user can create different types of plans, such as, free, one-time or recurring subscriptions. - With [Orders](https://dev.wix.com/docs/api-reference/business-solutions/pricing-plans/orders/introduction.md), a Wix user can create and manage the purchases of these plans. ## Integrations Wix users can use Wix Pricing Plans together with other Wix business solutions. Pricing Plans can be used together with the following Wix business solutions: - *Wix Bookings* - services from Wix Bookings (classes, treatments, workshops, etc.) can be included as a part of a plan (e.g. a plan for 10 private yoga classes). - *Wix Blog* - blog (list of posts or a single complete post) can be limited to paying members who purchase a particular membership. - *Wix Forum* - allow some forum categories to be accessible only for paying members. - *Wix Events* - offer discounts on event tickets to paying members who purchase a particular membership. - *Wix File Share* - access to files in your shared library can be limited to paying members. - *Wix Online Programs* - access to an online program can be accessible only to paying members who purchase a particular membership. - *Wix Video* - video channel access can be limited to paying members. - *Wix Groups* - group membership can be accessible only to paying members who purchase a particular membership. Learn more about [connecting Pricing Plans to other Wix business solutions](https://support.wix.com/en/article/pricing-plans-an-overview#connect-your-plans-to-your-content-and-services). ## Plans and subscriptions Every purchase of a pricing plan creates a new "subscription" to that plan for that buyer. Plans can be 1 of 3 different pricing models, `subscription`, `singlePaymentForDuration`, or `singlePaymentUnlimited`. > **Note:** All orders are called subscriptions, not just the ones that use the `subscription` pricing model. ## Pricing models Pricing models contain the [pricing and duration options](https://support.wix.com/en/article/pricing-plans-creating-a-one-time-payment-plan#step-3-set-the-price-and-duration-of-your-plan) for a plan. Plans are based on a pricing model, which is defined with the plan's `pricing` property. A pricing model can be one of the following: + **A subscription:** A plan with recurring payment cycles. *Example:* A 1-year subscription with monthly, recurring payments. Each payment is $25, so the total price for the plan is $300. ```javascript "pricing": { "subscription": { "cycleDuration": { // Payment recurs every month "count": 1, "unit": "MONTH" }, // for 12 times "cycleCount": 12 }, "price": { "value": "25", "currency": "USD" } } ``` `cycleDuration` is the length of 1 payment cycle. Multiply `cycleDuration`'s `count` by `cycleCount` to get the subscription duration. For specific orders of this plan, the `index` of `currentCycle` is the current payment cycle for the subscription. `index` is `0` when the order is in a free trial period. In all other cases, the `index` starts with `1` for the first payment cycle in the subscription. For orders with a single payment, the `index` will remain `1` throughout the duration. In this example, the subscription of the plan is now in the 3rd month and the order looks like this: ```javascript "pricing": { "subscription": { "cycleDuration": { // Payment recurs every month "count": 1, "unit": "MONTH" }, // for 12 times "cycleCount": 12 }, "prices": [{ "duration": { "cycleFrom": 1, "numberOfCycles": 12 }, "price": { "subtotal": "25", "discount": "0", "total": "25", "currency": "USD" } }] }, ... "currentCycle": { "index": 3, "startedDate": "2025-03-01T13:45:53.129Z", "endedDate": "2025-04-01T13:45:53.129Z" }, ``` + **A Single Payment for Duration plan:** A plan paid for with a single payment. The plan doesn't renew after the duration. *Example:* A plan with a single payment of $35 for 3 months. ```javascript "pricing": { "singlePaymentForDuration": { // Single payment covers 3 months period "count": 3, "unit": "MONTH" }, "price": { "value": "35", "currency": "USD" } } ``` For specific orders of this plan, the `duration` `cycleFrom` and `numberOfCycles` will both be `1`, as the single price applies to the entirety of the subscription. Also, the `index` of `currentCycle` will remain `1` throughout the duration. ```javascript "pricing": { "singlePaymentForDuration": { // Plan duration is 3 months "count": 3, "unit": "MONTH" }, "prices": [{ "duration": { "cycleFrom": 1, "numberOfCycles": 1 }, "price": { "subtotal": "35", "discount": "0", "total": "35", "currency": "USD" } }] }, ... "currentCycle": { "index": 1, "startedDate": "2025-01-01T13:45:53.129Z", "endedDate": "2025-04-01T13:45:53.129Z" }, ``` + **A Single Payment Unlimited plan:** A plan paid for with a single payment. The plan doesn't expire and remains valid until canceled. *Example:* An unlimited plan that's paid for in advance with a single payment of $200. ```javascript "pricing": { "singlePaymentForDuration": true, "price": { "value": "200", "currency": "USD" } } ``` `singlePaymentUnlimited` is `true`. For specific orders of this plan, the `duration` `cycleFrom` and `numberOfCycles` will remain `1` throughout the duration of the plan. Also, the `index` of `currentCycle` will remain `1` throughout the duration. `singlePaymentUnlimitedPlans` don't return an `endedDate` in `currentCycle`. ```javascript "pricing": { "singlePaymentUnlimited": true, "prices": [{ "duration": { "cycleFrom": 1, "numberOfCycles": 1 }, "price": { "subtotal": "200", "discount": "0", "total": "200", "currency": "USD" } }] }, ... "currentCycle": { "index": 1, "startedDate": "2025-01-015T13:45:53.129Z" } ``` ## Free plans and free trial periods A free plan that's valid until canceled is a `singlePaymentUnlimited` pricing model. A free plan with a limited duration is treated as a `singlePaymentForDuration` pricing model. A Wix user can also add a free trial period, in days, to a `subscription` pricing model. When the free trial is over, the first payment cycle begins and the buyer is billed. During the free trial period, the `index` of `currentCycle` is `0`. A buyer only receives the free trial period for the first time they purchase a plan. For example, a buyer purchases a monthly plan for 3 months that includes a 7-day free trial period. The buyer may purchase the same plan again, for another 3 months, but won't receive the 7-day free trial period. When a buyer cancels their order during the free trial period, their subscription expires at the end of the free trial period and they won't be billed. A Wix user can [cancel an ordered plan](https://dev.wix.com/docs/api-reference/business-solutions/pricing-plans/orders/cancel-order.md) during the free trial period and choose to apply the cancellation `IMMEDIATELY` or at the `NEXT_PAYMENT_DATE`. Canceling at the `NEXT_PAYMENT_DATE` allows the buyer to continue using the benefits of the subscription until the end of the free trial period. Then, the subscription ends and the buyer isn't billed. ## Extend Pricing Plans with the Benefit Programs API Pricing plans are built on top of Wix's benefit programs infrastructure. This allows you to manage credit-based features, such as loyalty points, within your pricing plans using the [Benefit Programs API](https://dev.wix.com/docs/rest/business-solutions/benefit-programs/introduction.md). ### When to use the Benefit Programs API Use the Benefit Programs API when you need to make changes to [credits](https://dev.wix.com/docs/api-reference/business-solutions/benefit-programs/introduction.md) associated with your pricing plans. Credits are units that can be consumed by plan members to access services or features. To modify credit balances for pricing plan members, call [Change Balance](https://dev.wix.com/docs/rest/business-solutions/benefit-programs/balances/change-balance.md) from the Benefit Programs API. ### How pricing plans connect to benefit programs Pricing Plans entities are linked to specific Benefit Programs entities: - **Plans**: Linked to [program definitions](https://dev.wix.com/docs/rest/business-solutions/benefit-programs/program-definitions/program-definition-object.md). The plan's `id` matches the linked program definition's `externalId`. - **Orders**: Linked to [programs](https://dev.wix.com/docs/rest/business-solutions/benefit-programs/programs/program-object.md). The order's `id` matches the linked program's `externalId`. This connection allows you to use the order ID or plan ID to identify the corresponding benefit program when making credit-related changes. If you work with pricing plan-related benefit programs, you need to specify `@wix/pricing-plans` as the namespace when calling Benefit Programs API methods. For example, specify it in [Get Program By External Id And Namespace](https://dev.wix.com/docs/rest/business-solutions/benefit-programs/programs/get-program-by-external-id-and-namespace.md) and inside the `filter` for [Query Pools](https://dev.wix.com/docs/rest/business-solutions/benefit-programs/pools/query-pools.md).