Event on Application Payment onAppPayment

Scope: basic

Who can subscribe: any user

The onAppPayment event is triggered when an application is paid for.

Events will not be sent to the application until the installation is complete. Check the application installation

What the handler receives

Data is transmitted as a POST request

{
            "event": "ONAPPPAYMENT",
            "data": {
                "CODE": "bitrix.gds_company",
                "VERSION": 1,
                "STATUS": "S",
                "PAYMENT_EXPIRED": "N",
                "DAYS": 28,
                "LANGUAGE_ID": "en"
            },
            "ts": "1466439714",
            "auth": {
                "domain": "some-domain.bitrix24.com",
                "server_endpoint": "https://oauth.bitrix.info/rest/",
                "client_endpoint": "https://some-domain.bitrix24.com/rest/"
            }
        }
        

Request Parameters

Required parameters are marked with *

Name
type

Description

event*
string

Symbolic event code — ONAPPPAYMENT

data*
object

Payment data.

The structure is described below

ts*
timestamp

Date and time of event dispatch from the queue

auth*
object

Authorization and account data.

The structure is described below

Parameter data

Required parameters are marked with *

Name
type

Description

CODE*
string

Application code

VERSION*
integer

Installed application version

STATUS*
string

Application status. Possible values:

  • F (Free) — free
  • D (Demo) — demo version
  • T (Trial) — time-limited trial version
  • P (Paid) — paid application

PAYMENT_EXPIRED*
string

[Y

N] Flag indicating whether the paid period or trial period has expired

DAYS*
integer

Number of days remaining until the end of the paid period or trial period

LANGUAGE_ID*
string

Installed language: en, de, and others

Parameter auth

Required parameters are marked with *

Name
type

Description

domain*
string

Bitrix24 account address

server_endpoint*
string

Authorization server address for token refresh

client_endpoint*
string

Common path for API method calls to the account

member_id*
string

Unique account identifier

Continue Learning