The translation was generated automatically and may contain mistakes

Module: 7. Monetization

Lesson 5. Sale of virtual values: one-time payment and subscriptions

The main thing in the lesson

  • To add a one-time payment:

    1. 1.
      In the client side of the mini-app, call the event VKWebAppShowOrderBox .
    2. 2.
      In the server mini-application part, return the product information.
    3. 3.
      Give the user the product.
    4. 4.
      In the server side of the mini-app, in response to the payment notification, transmit the status that the goods have been issued. VKontakte will automatically transfer votes from the user account to your application account.
  • To add a subscription:

    1. 1.
      In the client side of the mini-app, call the event VKWebAppShowSubscriptionBox .
    2. 2.
      In the server part, return the subscription information.
    3. 3.
      In response to a payment notification, communicate the status that the subscription has been created, canceled, or renewed.

Useful links

:::