InAppPurchasesManager.BeginPurchasing

Syntax:

BeginPurchasing(<NotifyDescriptionOnCompletion>, <Purchase>)

Parameters:

<NotifyDescriptionOnCompletion> (required)

Type: NotifyDescription.
Contains a link to the procedure which will be called after purchase process is complete. The procedure should have the following parameters:
  • Purchase: type InAppPurchase/String – Purchase, acquisition of which was requested. This field could be useful if one handler function is used for several different purchases.
  • Successful: type Boolean – The result of the completed acquisition operation. True, if the purchase has been successfully acquired, False – if acquisition has not been executed (the user canceled a purchase in the application store interface, no connection with the service store, the receipt's digital signature has not been verified).
  • Receipt: type InAppPurchaseReceipt – Purchase receipt. It can be additionally verified later: independently or with the help of object InAppPurchasesValidationManager (in this case the receipt should be transferred to the server).
  • Additionally - Value that was specified when creating object NotifyDescription.

<Purchase> (required)

Type: InAppPurchase; String.
Acquired purchase.

Returned value:

Type: Boolean.

Description:

Sends a request to pay for a purchase. Control is transferred to the payment interface provided by the operating system. Return to the mobile platform application will be performed in one of the following cases:
  • acquiring of the purchase is complete,
  • the user refused the purchase,
  • purchase is not possible (due to no connection with the service store, not sufficient amount of cash on the user balance).
The method is asynchronous.

Availability:

Mobile application (client).

    

1C:Enterprise Developer's Community