Working with API
1. Query syntax
In order to use API method you need to execute
POST query via
HTTP-protocol:
http://api-telegram-proxy.efficrm3.ru/api/
{METHOD_NAME}
Query consists of several parts:
{METHOD_NAME} (required) — name of API method, you want to refer to. Full list of methods is available
here.
For instance, to use ApiAuthUser method you need to execute POST query via the following address:
http://api-telegram-proxy.efficrm3.ru/api/ApiAuthUser
Query content is in JSON format:
{
"login": "string",
"password": "string"
}
Upon this request you will get a response in JSON format:
{
"access_token": "string",
"status": {
"STAT": "string",
"MSG": "string"
}
}
2. Getting access key
In order to work with API method you need to transmit in
access_token — query a special access key. It constitutes a string from Latin characters and numbers and can comply with single user API.
In order to get access key in API you need to execute ApiAuthUser method and pass two parameters –
login and
password.
As a result of executing this method access_token would be generated – access key with 30 minutes validity from the last referring to any API method.
3. API Test console (sandbox)
Test console provides an ability to call any API method without building own infrastructure.
Test console is available
here.