Test Your App’s Upgrade Process

Your app can include multiple pricing plans for your users to purchase. Each plan can offer different features and tiers of access to your app.
This article explains how to test your app's upgrade process to ensure that your app responds as expected when an upgrade occurs. Testing helps you verify:

  • That your app provides all advertised features for each pricing plan.
  • That your app responds as expected to events relevant to the app upgrade flow, such as Paid Plan Changed and Paid Plan Purchased.
  • That your app correctly detects upgrades if it uses polling.

Simulate the app purchase flow

To ensure that the upgrade process for your app's paid plans behaves as expected, simulate the user experience by installing and upgrading your app from a test site.

  1. Before you begin, make sure that:

  2. Select your app in the app dashboard.

  3. Hover over Test App at the top of the page, and then select Dashboard and a site for testing the upgrade flow.

    App Market opens, prompting you to upgrade the app on your test site.

  4. Select Upgrade on your app to proceed to the Wix pricing page. If you are using an external pricing page, complete the checkout flow according to your site's configuration.

    Note: For external pricing pages, ensure users cannot downgrade through your external pricing page. Downgrades or switches to monthly pricing require subscription cancellation and repurchase of the cheaper plan.

  5. Select a paid plan to start the purchase flow.

  6. Enter your payment information.

    Important: If you are upgrading to a plan with a free trial, you must make a real transaction with a valid credit card. This transaction is a nominal amount for validation purposes only and you will be refunded immediately.

    Payment depends on your app's status.

    • Unpublished apps: The total charge is $0. Use test credit card details to complete the purchase.
    • Published apps: Enter the coupon code you created earlier into the Enter promo code section of the Complete Your Purchase page to complete the purchase.
  7. Select Submit Purchase to complete your app upgrade.

  8. Confirm that your upgraded app instance's functionality operates as expected.

  9. To verify the upgrade for troubleshooting purposes, check that the upgrade is reflected in the app instance information. Call the following Wix APIs depending on the billing model of the upgraded plan:

    • Single: Call the Get Purchase History method and ensure that the recent upgrade is included in the purchases array.
    • Recurring: Call the Get App Instance method using REST or SDK and verify that the isFree field in the response object is false.

    Note: By default, apps built using Blocks only support plans with recurring billing models. Verify the upgrade by calling getDecodedAppInstance(). The response object includes a vendorProductId field only if the app was upgraded to a paid plan or free trial on that app instance. See this code example and learn more about setting Blocks app pricing plans.

See also

Did this help?