Event After Successful Application Installation OnAppInstall
Choose a tool for developing with an AI agent:
- use Alaio Vibecode to build an app for Bitrix24 from a task description without knowing any programming language. The agent writes the code and deploys the app to a server, with no manual hosting setup
- use the MCP server to develop a REST API integration in your own project. The agent refers to the official REST documentation
Scope:
basicWho can subscribe: any user
The ONAPPINSTALL event is triggered immediately after the successful installation of an application on Bitrix24. The application_token is passed to the handler, which is important to save. For more details, refer to the article Security in Handlers.
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": "ONAPPINSTALL",
"data": {
"VERSION": "1.0.0",
"ACTIVE": "Y",
"INSTALLED": "Y",
"LANGUAGE_ID": "de"
},
"ts": "1696527000",
"auth": {
"domain": "some-domain.bitrix24.com",
"scope": "imbot",
"access_token": "s6p6eclrvim6da22ft9ch94ekreb52lv",
"refresh_token": "4s386p3q0tr8dy89xvmt96234v3dljg8",
"expires_in": 3600,
"server_endpoint": "https://oauth.bitrix.info/rest/",
"status": "F",
"client_endpoint": "https://some-domain.bitrix24.com/rest/",
"member_id": "a223c6b3710f85df22e9377d6c4f7553",
"application_token": "51856fefc120afa4b628cc82d3935cce"
}
}
Request Parameters
Required parameters are marked with *
|
Name |
Description |
|
event* |
Symbolic event code. In this case — |
|
data* |
Data about the installed application. The structure is described below |
|
ts* |
Date and time of the event sent from the queue |
|
auth* |
Object containing authorization parameters and information about the account where the event occurred. The structure is described below |
Parameter data
|
Name |
Description |
|
VERSION* |
Version of the installed application |
|
ACTIVE* |
Application activity status. Possible values: |
|
INSTALLED* |
Whether the application is ready for use. Possible values: |
|
LANGUAGE_ID* |
Installed language: |
Parameter auth
|
Name |
Description |
|
domain* |
Address of the Bitrix24 account where the event occurred |
|
scope* |
List of permissions granted to the application, separated by spaces |
|
access_token* |
OAuth 2.0 authorization token |
|
refresh_token* |
Token for extending OAuth 2.0 authorization |
|
expires_in* |
Access token lifetime in seconds |
|
server_endpoint* |
Authorization server address for token renewal |
|
status* |
Status of the application that subscribed to this event:
|
|
client_endpoint* |
Common path for API method calls to the account |
|
member_id* |
Unique identifier of the account |
|
application_token* |
Token for secure event handling |
The handler for this event can be set in the installation script of the application, which is specified in the version card in a separate field.