Profile & tracker endpoints
Read your account details, rotate your API key, configure global postback templates, set the interface language, and connect your tracker.
Profile info
GET /api/profile/info.json
Returns current account details, tariff, usage, and the five global postback URL templates.
{
"status": "ok",
"data": {
"id": 42,
"name": "John Doe",
"login": "johndoe",
"lang": "en",
"tariff": "cat",
"tariff_name": "Kitty",
"tariff_campaigns": 15,
"paid_until": "2026-07-01 00:00:00",
"campaigns": 3,
"pb_wait": "",
"pb_hold": "",
"pb_approve": "https://track.example.com/postbacks/abc?click={click}&status=approve",
"pb_cancel": "https://track.example.com/postbacks/abc?click={click}&status=cancel",
"pb_trash": "https://track.example.com/postbacks/abc?click={click}&status=trash",
"notify": {
"tariff": true,
"leads": true
}
}
}tariff_campaigns is -1 for the Tiger (unlimited) plan.
paid_until is "0000-00-00 00:00:00" for accounts that have never paid.
campaigns is the count of your non-deleted campaigns.
Empty pb_* fields mean that event’s postback is currently disabled globally.
notify.tariff — whether expiry-warning messages are enabled (default true).
notify.leads — global switch for lead-event notifications (default true).
See Tracker integration for how global vs. per-campaign templates
work.
Regenerate API key
POST /api/profile/apikey.json
Generates a new API key. The old key stops working immediately.
{ "status": "ok", "data": { "key": "42-new_key_value…" } }Set global postbacks
POST /api/profile/postbacks.json
Sets the five global postback URL templates. Partial update — only the fields you supply are written; omit a field to leave it unchanged. Pass an empty string to clear a template.
| Parameter | Description |
|---|---|
pb_wait | URL template for the wait event (bot link opened) |
pb_hold | URL template for the hold event (join request submitted) |
pb_approve | URL template for the approve event (joined or request approved) |
pb_cancel | URL template for the cancel event (left voluntarily, within window) |
pb_trash | URL template for the trash event (kicked or banned, within window) |
See Tracker integration → Macros for the {macro}
placeholders available in templates.
{ "status": "ok" }Set notification preferences
POST /api/profile/notify.json
Sets your notification preferences. Partial update — omit a field to leave it unchanged.
| Parameter | Type | Description |
|---|---|---|
tariff | bool | true = receive expiry-warning messages (default). Payment confirmation always fires. |
leads | bool | true = global enable for lead-event notifications from all campaigns (default). |
{ "status": "ok" }Set language
POST /api/profile/lang.json
| Parameter | Description |
|---|---|
lang | en or ru |
{ "status": "ok" }Resolve current session
GET /api/profile/login.json
Returns the user associated with the current session token. Requires a session token (not an API key) — the dashboard uses this to confirm the session is still valid.
{ "status": "ok", "data": { "id": 42, "name": "John Doe" } }Telegram login bridge
GET /api/auth/poll.json — unauthenticated
This is how the dashboard obtains a session after Telegram login. You won’t need to call this when scripting with an API key.
The flow: the dashboard mints a random nonce and shows the user a deep link to
the service bot (@altercpatopbot?start=login-{nonce}). It then polls this
endpoint until the user has opened the bot link.
| Parameter | Description |
|---|---|
nonce | The random nonce generated by the client |
While the user hasn’t yet opened the bot link:
{ "status": "ok", "pending": true }Once the user has opened the bot link:
{ "status": "ok", "pending": false, "token": "sess_token_value…" }The nonce is single-use — it is deleted the moment it is redeemed.
Tracker integration status
GET /api/profile/tracker.json
Returns the current tracker connection status. The API key is never returned.
{ "status": "ok", "data": { "connected": true, "domain": "www.altercpa.red" } }Connect / disconnect AlterCPA Lite tracker
POST /api/profile/tracker.json
Connect: pass domain + key. Probes GET /api/tracker/status.json on the
tracker domain to validate the credentials, then automatically writes all five
global postback templates. See
AlterCPA Lite integration for the full setup guide.
| Parameter | Description |
|---|---|
domain | Tracker hostname, e.g. www.altercpa.red. Pass empty string to disconnect. |
key | Your tracker API key (format {user_id}-{user_api} on the tracker). Required when connecting. |
{ "status": "ok", "data": { "connected": true, "domain": "www.altercpa.red" } }| Error | Meaning |
|---|---|
connect | The tracker domain could not be reached or returned an error |
Disconnect: pass domain="". Clears the saved tracker domain and key. Your postback templates are kept — they continue to fire as-is until you edit or clear them manually.