Xtream-Masters Admin API

Full administrative control over your Xtream-Masters panel. Manage lines, devices, resellers, streams, servers, security, and system configuration through a comprehensive REST-style API.

Admin API - Full Access This API provides unrestricted administrative access. Keep your API key secure and never expose it in client-side code or public repositories.

Authentication

All API requests require your api_key parameter. Include it as a query parameter or POST field on every request.

Where do I find my API key? Your admin API key is available in the admin panel under Menu > Admin API page. This key grants full administrative privileges.

Base URL

All requests are made to the following base URL format:

http://{server-dns}:{stream-port}/{api-access-code}/admin/index.php

Replace {server-dns}, {stream-port}, and {api-access-code} with your server details.

Quick Start

Get up and running in minutes 1. Obtain your admin API key from the admin panel.
2. Note your server DNS, streaming port, and API access code.
3. Make your first request to user_info to verify connectivity.
Quick Test
curl "http://your-server:port/access-code/admin/index.php?api_key=YOUR_KEY&action=user_info"

Global Parameters

These parameters are available on all or most endpoints.

ParameterTypeRequiredDescription
api_keystringRequiredYour unique admin API key for authentication
actionstringRequiredThe API action to perform
startintOptionalPagination offset for list endpoints (default: 0)
limitintOptionalNumber of records to return (default: 50)
show_columnsstringOptionalComma-separated list of column names to include in the response
hide_columnsstringOptionalComma-separated list of column names to exclude from the response

Warnings

A call that cannot do everything you asked still succeeds, and says what it skipped. Nothing is dropped in silence. Each entry names the parameter, why it was ignored, and — where a panel setting is the cause — the exact path that would make it work.

Response
{
  "status": "STATUS_SUCCESS",
  "ticket_status": "closed",
  "changed": 1,
  "ids": [4],
  "warnings": [
    { "code": "ticket_not_found", "field": "id", "message": "No ticket with id 999999999." }
  ]
}

Failures carry error_code, and where one field is at fault, field and a one-sentence hint. The status string is unchanged, so existing clients keep working.

What’s New

Everything additive. A request that sends none of the new parameters behaves exactly as it always did.

New endpoint families
  • Support tickets — the whole queue: list, read with its conversation, open, reply, close, reopen, edit and delete. The panel has had Tickets for years and no API touched it.
  • Activation codes on the admin API — all eight actions. They existed on the reseller API only, so an operator could give a reseller code management and have none themselves. An admin sees every code.
  • ASN blockingget_blocked_asns, add_blocked_asn, edit_blocked_asn, delete_blocked_asn. Usually the largest security table on an install; page it with limit.
  • MAG claims — the viewer reports raised from a set-top box.
  • Content and catalogue writes — create, edit and delete for live channels, movies, series, episodes, radio stations, categories, bouquets, packages, groups and servers.
  • Connection control — kill a live connection; list servers.
Fixed — actions that never worked
  • get_providers / create_provider / edit_provider / delete_provider. They read and wrote a table called providers, which does not exist — the query failed and the action answered with an empty body. The panel keeps providers in streams_providers. They now serve the table the panel uses. Note provider_id is the key, not id.
  • get_blocked_uas / add_blocked_ua / delete_blocked_ua. Same fault: the table is blocked_user_agents, not blocked_uas. get_blocked_uas returned the ISP list, and every block silently blocked nothing. The parameter is user_agent; the documented ua is still accepted.
  • edit_settings. Every call that named a real settings column failed outright. A call naming no real column appeared to succeed, which made it look intermittent.
  • create_mag / create_enigma / create_line / create_activecode. Refused with STATUS_INSUFFICIENT_CREDITS against an admin key. The admin was being priced with the reseller’s rules — but an admin has no credit balance: the panel routes them to a different page that has no pricing at all. An admin is no longer charged, and cannot be refused for a balance. Resellers are charged exactly as before.
  • create_user / edit_user. Refused with “Sub-reseller creation is not enabled for your group” against an admin key. That is the reseller’s rule (create_sub_resellers plus Sub-Reseller Setup); the admin’s own page requires neither and offers every group. An admin may now create a reseller in any group, seed it with credits, and name any owner.
  • adjust_credits. An admin’s adjustment was debited from the admin’s own reg_users balance — a number the panel never shows and never refills, so the action worked until that hidden balance hit zero and then refused. An admin now grants: the reseller is credited, nobody is debited, and the movement is recorded in credits_log against the admin.
  • Bouquets, categories and episodes were written without the rows that make them mean something. A bouquet had no categories blob, so it produced no catalogue; a new category was never counted, so player_api hid it; an episode was never filed into series_episodes, so its series reported no seasons; and movies and radio went into columns get.php does not read. Content created through the API now reaches customers — verified end to end against player_api.php and get.php with a real line.
  • Category item counts are maintained again. The count that decides whether a category is visible at all had not been recomputed since this core took over the panel’s cron work, so any category created since — in the panel as much as through the API — was invisible to every client. It is recomputed whenever content changes.
  • A stream can no longer be created with no server behind it. The panel refuses that save (“Select at least one server.”) and writes the binding; the API did not, so a stream created without the panel’s server_tree_data was listed in every playlist and in player_api with nothing to play. Send server_id=3, server_ids=3,4,5, or the panel’s server_tree_data; parent_id names the server the others take their feed from and on_demand marks the on-demand ones. An edit that does not mention servers keeps the ones the stream has — but no save may leave a stream with none.
  • Deleting a stream now removes its server binding. It did not, so every deleted stream left rows behind — and stream ids are reused, so a later stream could inherit a dead binding nobody gave it. Deleting a series now removes its episodes too, instead of leaving them as orphaned rows playable through no series. A series with a locked episode is refused rather than silently skipped.
  • Reseller actions are logged the way the panel logs them. Every purchase, extension and deletion now writes the reseller’s history row (Reg User Log) as well as the credit row, in the panel’s own wording — New M3U User: <user> - LineID: <id> - Pack-ID: <pkg> and its balance line. Sales made through the API used to be missing from that screen entirely while the credits still left the balance. A deletion by a reseller whose group has refunds switched off is now logged too; it used to leave no trace at all.
  • Audit rows say when the API did it. Every credit line the API writes ends with Via api, so the ledger distinguishes a charge made in the panel from one made by an integration. The amount cell is also signed correctly now — a top-up read --1 instead of +1.
  • close_ticket reply shape. Its reply carried status twice — once for the request outcome and once for the ticket — and a JSON parser keeps the last. The ticket’s state is ticket_status.
Across every endpoint
  • Dry runs. dry_run=1 on any write validates it and answers with the record it would have created — without writing.
  • Idempotent creates. request_id=<your id> makes a retried create safe.
  • Bulk. ids=1,2,3 on delete / disable / enable / close, with a per-item result.
  • Pagination and filters on every listtotal, start, limit, returned, has_more, plus search, order_by, order_dir and column filters.
  • Delta sync. since / until, so a client can poll for what changed.
  • Machine-readable errorserror_code, field, hint.
  • Refusals name the setting. A refusal caused by a permission carries the exact panel path and the permission key, in the reply and in the log, so the operator can fix it without guessing.
  • Every action is permission-checked. The published API declared its permission list empty, so every check inside it passed and any valid key could do anything. All 182 actions now map to the Manage Groups permission the equivalent panel page requires.

General

Retrieve admin account information and package details.

GET user_info Get Admin Account Info

Returns your admin account details including server info and account settings.

Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=user_info"
Response
{
  "status": "STATUS_SUCCESS",
  "data": {
    "id": 1,
    "username": "admin",
    "email": "admin@example.com",
    "status": 1,
    "server_name": "Main Server",
    "total_lines": 1250,
    "total_resellers": 34,
    "created_at": "2024-01-01 00:00:00"
  }
}
GET get_packages List All Packages

Returns all packages configured in the system.

Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_packages"
Response
{
  "status": "STATUS_SUCCESS",
  "data": [
    {
      "id": 1,
      "package_name": "1 Month",
      "credits": 5.00,
      "duration_months": 1,
      "is_trial": 0,
      "is_official": 1,
      "groups": [1, 3, 5]
    }
  ]
}
GET get_package Get Single Package

Retrieve details of a single package by its ID.

ParameterTypeRequiredDescription
idintRequiredPackage ID
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_package&id=1"

Line Management

Create, manage, and control M3U lines. Admin creates lines with direct parameters (exp_date, bouquets, max_connections) rather than packages.

POST create_line Create Line

Creates a new M3U line with direct parameter control. Username and password are auto-generated if not provided.

ParameterTypeRequiredDescription
exp_datestringRequiredExpiration date (YYYY-MM-DD format)
usernamestringOptionalCustom username (auto-generated if empty)
passwordstringOptionalCustom password (auto-generated if empty)
bouquets_selectedjsonOptionalJSON array of bouquet IDs, e.g. [1,2,3]
max_connectionsintOptionalMaximum simultaneous connections (default: 1)
member_idintOptionalAssign to a specific reseller by ID
is_restreamerintOptional0 = normal, 1 = restreamer account
is_trialintOptional0 = regular, 1 = trial
is_isplockintOptional0 = disabled, 1 = enable ISP lock
allowed_ips[]arrayOptionalArray of allowed IP addresses
allowed_ua[]arrayOptionalArray of allowed User-Agent strings
admin_notesstringOptionalAdmin-only notes
reseller_notesstringOptionalNotes visible to reseller
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=create_line" \
  -d "exp_date=2026-12-31" \
  -d "username=customer1" \
  -d "password=securepass" \
  -d "max_connections=2" \
  -d "bouquets_selected=[1,2,5]" \
  -d "admin_notes=VIP customer"
Response
{
  "status": "STATUS_SUCCESS",
  "data": {
    "id": 4521,
    "username": "customer1",
    "password": "securepass",
    "exp_date": "2026-12-31",
    "max_connections": 2,
    "is_trial": 0,
    "status": 1,
    "admin_notes": "VIP customer",
    "created_at": "2026-03-15 14:30:00"
  }
}
POST edit_line Edit Line

Edit an existing line's properties. Only provided parameters are updated.

ParameterTypeRequiredDescription
idintRequiredLine ID to edit
exp_datestringOptionalNew expiration date (YYYY-MM-DD)
usernamestringOptionalNew username
passwordstringOptionalNew password
bouquets_selectedjsonOptionalJSON array of bouquet IDs
max_connectionsintOptionalMax simultaneous connections
member_idintOptionalReassign to a reseller
is_restreamerintOptional0 or 1
is_trialintOptional0 or 1
is_isplockintOptional0 or 1
allowed_ips[]arrayOptionalAllowed IPs
allowed_ua[]arrayOptionalAllowed User-Agents
admin_notesstringOptionalAdmin notes
reseller_notesstringOptionalReseller notes
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=edit_line" \
  -d "id=4521" \
  -d "exp_date=2027-06-30" \
  -d "max_connections=3"
POST extend_line Extend Line

Extend a line's expiry only — all other properties (bouquets, max connections, username, password) are preserved. The duration is added to the line's current expiry, or from now if already expired. Provide exactly ONE of: package, months, days, or an absolute exp_date. No credits are charged (admin action).

ParameterTypeRequiredDescription
idintRequiredLine ID to extend
packageintOptionalPackage ID — adds its official duration
monthsintOptionalNumber of months to add
daysintOptionalNumber of days to add
exp_datestringOptionalAbsolute new expiry (YYYY-MM-DD)
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=extend_line" \
  -d "id=4521" \
  -d "package=2"
Response
{
  "status": "STATUS_SUCCESS",
  "data": {
    "id": 4521,
    "exp_date": "2028-01-31 00:00:00"
  }
}
GET get_line Get Single Line

Retrieve details of a single M3U line by its ID.

ParameterTypeRequiredDescription
idintRequiredLine ID
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_line&id=4521"
Response
{
  "status": "STATUS_SUCCESS",
  "data": {
    "id": 4521,
    "username": "customer1",
    "password": "securepass",
    "exp_date": "2026-12-31",
    "max_connections": 2,
    "is_trial": 0,
    "is_isplock": 0,
    "is_restreamer": 0,
    "enabled": 1,
    "admin_enabled": 1,
    "allowed_ips": [],
    "allowed_ua": [],
    "admin_notes": "VIP customer",
    "reseller_notes": "",
    "bouquets": [1, 2, 5],
    "member_id": 0,
    "created_at": "2026-03-15 14:30:00"
  }
}
GET get_lines List All Lines

Retrieve a paginated list of all M3U lines. Supports search and status filtering.

ParameterTypeRequiredDescription
startintOptionalPagination offset (default: 0)
limitintOptionalRecords per page (default: 50)
search[value]stringOptionalSearch by username or other fields
filterintOptional1=Active, 2=Disabled, 3=Banned, 4=Expired, 5=Trial
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_lines&start=0&limit=25&filter=1"
POST delete_line Delete Line

Permanently delete a line. This action cannot be undone.

ParameterTypeRequiredDescription
idintRequiredLine ID to delete
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=delete_line" \
  -d "id=4521"
POST disable_line Disable Line

Temporarily disable a line (sets enabled=0). The line can be re-enabled later.

ParameterTypeRequiredDescription
idintRequiredLine ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=disable_line" \
  -d "id=4521"
POST enable_line Enable Line

Re-enable a previously disabled line (sets enabled=1).

ParameterTypeRequiredDescription
idintRequiredLine ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=enable_line" \
  -d "id=4521"
POST ban_line Ban Line

Admin-ban a line (sets admin_enabled=0). Unlike disable, banned lines cannot be re-enabled by resellers.

ParameterTypeRequiredDescription
idintRequiredLine ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=ban_line" \
  -d "id=4521"
POST unban_line Unban Line

Remove admin ban from a line (sets admin_enabled=1).

ParameterTypeRequiredDescription
idintRequiredLine ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=unban_line" \
  -d "id=4521"

MAG Device Management

Create and manage MAG device subscriptions with direct parameter control.

POST create_mag Create MAG Device

Register a new MAG device with its MAC address.

ParameterTypeRequiredDescription
macstringRequiredMAC address (format: 00:1A:79:XX:XX:XX)
exp_datestringOptionalExpiration date (YYYY-MM-DD)
bouquets_selectedjsonOptionalJSON array of bouquet IDs
max_connectionsintOptionalMax connections (default: 1)
member_idintOptionalAssign to reseller by ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=create_mag" \
  -d "mac=00:1A:79:AB:CD:EF" \
  -d "exp_date=2026-12-31" \
  -d "bouquets_selected=[1,2,5]"
POST edit_mag Edit MAG Device

Edit a MAG device's properties.

ParameterTypeRequiredDescription
idintRequiredMAG device ID
macstringOptionalNew MAC address
exp_datestringOptionalNew expiration date
bouquets_selectedjsonOptionalJSON array of bouquet IDs
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=edit_mag" \
  -d "id=301" \
  -d "exp_date=2027-06-30"
GETget_magGet Single MAG

Retrieve details of a single MAG device.

ParameterTypeRequiredDescription
idintRequiredMAG device ID
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_mag&id=301"
GETget_magsList MAG Devices

Retrieve a paginated list of all MAG devices.

ParameterTypeRequiredDescription
startintOptionalPagination offset
limitintOptionalRecords per page
search[value]stringOptionalSearch term
filterintOptional1=Active, 2=Disabled, 3=Banned, 4=Expired
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_mags&start=0&limit=25"
POSTdelete_magDelete MAG

Permanently delete a MAG device entry.

ParameterTypeRequiredDescription
idintRequiredMAG device ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=delete_mag" \
  -d "id=301"
POSTdisable_magDisable MAG

Temporarily disable a MAG device (sets enabled=0).

ParameterTypeRequiredDescription
idintRequiredMAG device ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=disable_mag" \
  -d "id=301"
POSTenable_magEnable MAG

Re-enable a previously disabled MAG device (sets enabled=1).

ParameterTypeRequiredDescription
idintRequiredMAG device ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=enable_mag" \
  -d "id=301"
POSTban_magBan MAG

Admin-ban a MAG device (sets admin_enabled=0).

ParameterTypeRequiredDescription
idintRequiredMAG device ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=ban_mag" \
  -d "id=301"
POSTunban_magUnban MAG

Remove admin ban from a MAG device (sets admin_enabled=1).

ParameterTypeRequiredDescription
idintRequiredMAG device ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=unban_mag" \
  -d "id=301"
POSTconvert_magConvert MAG to M3U

Convert a MAG device subscription to an M3U line. Returns the newly created line with username and password.

ParameterTypeRequiredDescription
idintRequiredMAG device ID to convert
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=convert_mag" \
  -d "id=301"

MAG Claims

Viewer reports raised from a MAG box — Panel → MAG Claims. A claim names the stream, the device and when it was reported, and is how a set-top user tells you a channel is down. New in this core: previously panel-only.

POSTget_mag_claimsList MAG Claims

Page the claim list, newest ids last.

ParameterTypeRequiredDescription
limitintOptionalRows to return
startintOptionalOffset
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=get_mag_claims" \
  -d "limit=50"
POSTget_mag_claimGet MAG Claim

One claim.

ParameterTypeRequiredDescription
idintRequiredClaim ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=get_mag_claim" \
  -d "id=1"
POSTdelete_mag_claimClear MAG Claim

Remove a claim once it has been dealt with.

ParameterTypeRequiredDescription
idintRequiredClaim ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=delete_mag_claim" \
  -d "id=1"

Enigma2 Device Management

Create and manage Enigma2 device subscriptions.

POSTcreate_enigmaCreate Enigma2 Device

Register a new Enigma2 device with its MAC address.

ParameterTypeRequiredDescription
macstringRequiredDevice MAC address
exp_datestringOptionalExpiration date (YYYY-MM-DD)
bouquets_selectedjsonOptionalJSON array of bouquet IDs
max_connectionsintOptionalMax connections
member_idintOptionalAssign to reseller
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=create_enigma" \
  -d "mac=AA:BB:CC:DD:EE:FF" \
  -d "exp_date=2026-12-31"
POSTedit_enigmaEdit Enigma2

Edit an Enigma2 device's properties.

ParameterTypeRequiredDescription
idintRequiredEnigma2 device ID
macstringOptionalNew MAC address
exp_datestringOptionalNew expiration date
bouquets_selectedjsonOptionalJSON array of bouquet IDs
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=edit_enigma" \
  -d "id=501" \
  -d "exp_date=2027-06-30"
GETget_enigmaGet Single Enigma2

Retrieve details of a single Enigma2 device.

ParameterTypeRequiredDescription
idintRequiredEnigma2 device ID
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_enigma&id=501"
GETget_enigmasList Enigma2 Devices

Retrieve a paginated list of all Enigma2 devices.

ParameterTypeRequiredDescription
startintOptionalPagination offset
limitintOptionalRecords per page
search[value]stringOptionalSearch term
filterintOptional1=Active, 2=Disabled, 3=Banned, 4=Expired
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_enigmas&start=0&limit=25"
POSTdelete_enigmaDelete Enigma2

Permanently delete an Enigma2 device.

ParameterTypeRequiredDescription
idintRequiredEnigma2 device ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=delete_enigma" \
  -d "id=501"
POSTdisable_enigmaDisable Enigma2

Temporarily disable an Enigma2 device.

ParameterTypeRequiredDescription
idintRequiredEnigma2 device ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=disable_enigma" \
  -d "id=501"
POSTenable_enigmaEnable Enigma2

Re-enable a previously disabled Enigma2 device.

ParameterTypeRequiredDescription
idintRequiredEnigma2 device ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=enable_enigma" \
  -d "id=501"
POSTban_enigmaBan Enigma2

Admin-ban an Enigma2 device (sets admin_enabled=0).

ParameterTypeRequiredDescription
idintRequiredEnigma2 device ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=ban_enigma" \
  -d "id=501"
POSTunban_enigmaUnban Enigma2

Remove admin ban from an Enigma2 device (sets admin_enabled=1).

ParameterTypeRequiredDescription
idintRequiredEnigma2 device ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=unban_enigma" \
  -d "id=501"
POSTconvert_enigmaConvert Enigma2 to M3U

Convert an Enigma2 device subscription to an M3U line.

ParameterTypeRequiredDescription
idintRequiredEnigma2 device ID to convert
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=convert_enigma" \
  -d "id=501"

Sub-Reseller Management

Create and manage reseller accounts and their credits.

POSTcreate_userCreate Sub-Reseller

Create a new reseller account.

ParameterTypeRequiredDescription
usernamestringOptionalUsername (auto-generated if empty)
passwordstringOptionalPassword (auto-generated if empty)
emailstringOptionalEmail address
member_group_idintOptionalMember group to assign
notesstringOptionalInternal notes
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=create_user" \
  -d "username=reseller1" \
  -d "password=strongpass123" \
  -d "email=reseller@example.com" \
  -d "member_group_id=3"
Response
{
  "status": "STATUS_SUCCESS",
  "data": {
    "id": 88,
    "username": "reseller1",
    "email": "reseller@example.com",
    "member_group_id": 3,
    "credits": 0,
    "status": 1,
    "created_at": "2026-03-15 14:30:00"
  }
}
POSTedit_userEdit Sub-Reseller

Edit a reseller account's properties.

ParameterTypeRequiredDescription
idintRequiredReseller ID
usernamestringOptionalNew username
passwordstringOptionalNew password
emailstringOptionalNew email
member_group_idintOptionalNew group ID
notesstringOptionalInternal notes
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=edit_user" \
  -d "id=88" \
  -d "email=new@example.com"
GETget_userGet Single Reseller

Retrieve details of a single reseller account.

ParameterTypeRequiredDescription
idintRequiredReseller ID
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_user&id=88"
GETget_usersList Resellers

Retrieve a paginated list of all reseller accounts.

ParameterTypeRequiredDescription
startintOptionalPagination offset
limitintOptionalRecords per page
search[value]stringOptionalSearch term
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_users&start=0&limit=25"
POSTdelete_userDelete Reseller

Permanently delete a reseller account.

ParameterTypeRequiredDescription
idintRequiredReseller ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=delete_user" \
  -d "id=88"
POSTdisable_userDisable Reseller

Temporarily disable a reseller account.

ParameterTypeRequiredDescription
idintRequiredReseller ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=disable_user" \
  -d "id=88"
POSTenable_userEnable Reseller

Re-enable a previously disabled reseller account.

ParameterTypeRequiredDescription
idintRequiredReseller ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=enable_user" \
  -d "id=88"
POSTadjust_creditsAdjust Credits

Add or subtract credits from a reseller account. Use positive values to add and negative values to subtract.

ParameterTypeRequiredDescription
idintRequiredReseller ID
creditsfloatRequiredCredits to adjust (positive = add, negative = subtract)
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=adjust_credits" \
  -d "id=88" \
  -d "credits=100"
Response
{
  "status": "STATUS_SUCCESS",
  "data": {
    "id": 88,
    "credits_before": 50.00,
    "credits_after": 150.00,
    "adjusted": 100
  }
}

Streams & Content

Manage live streams, channels, movies, series, and radio stations.

GETget_streamsList Live Streams

Retrieve list of all live streams.

Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_streams"
GETget_streamGet Single Stream

Retrieve details of a single stream by ID.

ParameterTypeRequiredDescription
idintRequiredStream ID
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_stream&id=10"
GETget_channelsList Channels

Retrieve list of all created channels.

Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_channels"
GETget_channelGet Single Channel

Retrieve details of a single channel.

ParameterTypeRequiredDescription
idintRequiredChannel ID
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_channel&id=5"
GETget_stationsList Radio Stations

Retrieve list of all radio stations.

Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_stations"
GETget_moviesList Movies

Retrieve list of all movies.

Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_movies"
GETget_movieGet Single Movie

Retrieve details of a single movie.

ParameterTypeRequiredDescription
idintRequiredMovie ID
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_movie&id=100"
GETget_series_listList Series

Retrieve list of all TV series.

Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_series_list"
GETget_seriesGet Single Series

Retrieve details of a single series.

ParameterTypeRequiredDescription
idintRequiredSeries ID
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_series&id=50"
GETget_episodesList Episodes

Retrieve list of all episodes.

Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_episodes"
GETget_episodeGet Single Episode

Retrieve details of a single episode.

ParameterTypeRequiredDescription
idintRequiredEpisode ID
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_episode&id=200"
POSTstart_streamStart Stream

Start a live stream.

ParameterTypeRequiredDescription
idintRequiredStream ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=start_stream" \
  -d "id=10"
POSTstop_streamStop Stream

Stop a live stream.

ParameterTypeRequiredDescription
idintRequiredStream ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=stop_stream" \
  -d "id=10"
POSTstart_channelStart Channel

Start a channel.

ParameterTypeRequiredDescription
idintRequiredChannel ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=start_channel" \
  -d "id=5"
POSTstop_channelStop Channel

Stop a channel.

ParameterTypeRequiredDescription
idintRequiredChannel ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=stop_channel" \
  -d "id=5"
POSTstart_movieStart Movie

Start a movie stream.

ParameterTypeRequiredDescription
idintRequiredMovie ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=start_movie" \
  -d "id=100"
POSTstop_movieStop Movie

Stop a movie stream.

ParameterTypeRequiredDescription
idintRequiredMovie ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=stop_movie" \
  -d "id=100"

Configuration

Manage bouquets, groups, categories, access codes, EPGs, and transcode profiles.

Bouquets

CRUD operations for bouquet management.

Fixed — bouquets the API made were invisible

A bouquet carries a categories blob (the four category lists and their counts) and a type, and the catalogue builder takes each bouquet’s category order from that blob. The API wrote neither, so every bouquet it created or edited produced no catalogue at all — the line authenticated and the customer saw an empty app, whatever the id lists said. Both are now written, and recomputed from the final lists on every save.

Two ways to say what a bouquet holds, and you may use either:

  • By categorylive_categories, vod_categories, series_categories, radio_categories, each a JSON array or comma-separated list of category ids. The channel and series lists are DERIVED from them, which is what the panel’s own screen does. This wins if both forms are sent.
  • By idbouquet_data, a JSON object with stream, movies, radios and series arrays. Unchanged, and still supported.

Note the storage: live channels, created channels, radio AND movies all live in bouquet_channels; only series are separate. That is what the panel writes and what get.php reads — filing movies into bouquet_movies by name left them out of every playlist while they still showed in player_api.

GETget_bouquetsList All Bouquets

Retrieve all bouquets.

Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_bouquets"
GETget_bouquetGet Single Bouquet

Retrieve a single bouquet by ID.

ParameterTypeRequiredDescription
idintRequiredBouquet ID
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_bouquet&id=1"
POSTcreate_bouquetCreate Bouquet

Create a new bouquet.

Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=create_bouquet" \
  -d "bouquet_name=Premium Sports"
POSTedit_bouquetEdit Bouquet

Edit an existing bouquet.

ParameterTypeRequiredDescription
idintRequiredBouquet ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=edit_bouquet" \
  -d "id=1" \
  -d "bouquet_name=Premium Sports HD"
POSTdelete_bouquetDelete Bouquet

Delete a bouquet.

ParameterTypeRequiredDescription
idintRequiredBouquet ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=delete_bouquet" \
  -d "id=1"

Groups

CRUD operations for member group management.

GETget_groupsList Groups

List all member groups.

Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_groups"
GETget_groupGet Group

Get single group by ID.

ParameterTypeRequiredDescription
idintRequiredGroup ID
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_group&id=1"
POSTcreate_groupCreate Group

Create a new member group.

Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=create_group" \
  -d "group_name=Premium Resellers"
POSTedit_groupEdit Group

Edit a member group.

ParameterTypeRequiredDescription
idintRequiredGroup ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=edit_group" \
  -d "id=1"
POSTdelete_groupDelete Group

Delete a member group.

ParameterTypeRequiredDescription
idintRequiredGroup ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=delete_group" \
  -d "id=1"

Categories

CRUD operations for stream categories.

GETget_categoriesList Categories

List all categories.

Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_categories"
GETget_categoryGet Category

Get single category by ID.

ParameterTypeRequiredDescription
idintRequiredCategory ID
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_category&id=1"
POSTcreate_categoryCreate Category

Create a new category.

Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=create_category" \
  -d "category_name=Sports"
POSTedit_categoryEdit Category

Edit a category.

ParameterTypeRequiredDescription
idintRequiredCategory ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=edit_category" \
  -d "id=1"
POSTdelete_categoryDelete Category

Delete a category.

ParameterTypeRequiredDescription
idintRequiredCategory ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=delete_category" \
  -d "id=1"

Access Codes

CRUD operations for API access code management.

GETget_access_codesList Access Codes

List all access codes.

Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_access_codes"
GETget_access_codeGet Access Code

Get single access code.

ParameterTypeRequiredDescription
idintRequiredAccess Code ID
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_access_code&id=1"
POSTcreate_access_codeCreate Access Code

Create a new access code.

Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=create_access_code"
POSTedit_access_codeEdit Access Code

Edit an access code.

ParameterTypeRequiredDescription
idintRequiredAccess Code ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=edit_access_code" \
  -d "id=1"
POSTdelete_access_codeDelete Access Code

Delete an access code.

ParameterTypeRequiredDescription
idintRequiredAccess Code ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=delete_access_code" \
  -d "id=1"

EPG

Manage Electronic Program Guide sources.

GETget_epgsList EPGs

List all EPG sources.

Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_epgs"
GETget_epgGet EPG

Get single EPG source.

ParameterTypeRequiredDescription
idintRequiredEPG ID
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_epg&id=1"
POSTcreate_epgCreate EPG

Add a new EPG source.

Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=create_epg"
POSTedit_epgEdit EPG

Edit an EPG source.

ParameterTypeRequiredDescription
idintRequiredEPG ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=edit_epg" \
  -d "id=1"
POSTdelete_epgDelete EPG

Delete an EPG source.

ParameterTypeRequiredDescription
idintRequiredEPG ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=delete_epg" \
  -d "id=1"
POSTreload_epgReload EPG

Force reload EPG data from all sources.

Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=reload_epg"

Transcode Profiles

Manage transcoding profiles for streams.

GETget_transcode_profilesList Profiles

List all transcode profiles.

Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_transcode_profiles"
GETget_transcode_profileGet Profile

Get single transcode profile.

ParameterTypeRequiredDescription
idintRequiredProfile ID
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_transcode_profile&id=1"
POSTcreate_transcode_profileCreate Profile

Create a new transcode profile.

Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=create_transcode_profile"
POSTedit_transcode_profileEdit Profile

Edit a transcode profile.

ParameterTypeRequiredDescription
idintRequiredProfile ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=edit_transcode_profile" \
  -d "id=1"
POSTdelete_transcode_profileDelete Profile

Delete a transcode profile.

ParameterTypeRequiredDescription
idintRequiredProfile ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=delete_transcode_profile" \
  -d "id=1"

Security

Manage IP blocking, User-Agent blocking, ISP blocking, and RTMP IP management.

IP Blocking

Block and manage blocked IP addresses.

GETget_blocked_ipsList Blocked IPs

Retrieve all blocked IP addresses.

Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_blocked_ips"
POSTadd_blocked_ipBlock IP

Add an IP address to the blocklist.

ParameterTypeRequiredDescription
ipstringRequiredIP address to block
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=add_blocked_ip" \
  -d "ip=192.168.1.100"
POSTdelete_blocked_ipUnblock IP

Remove an IP address from the blocklist.

ParameterTypeRequiredDescription
idintRequiredBlocked IP entry ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=delete_blocked_ip" \
  -d "id=15"
POSTflush_blocked_ipsFlush All Blocked IPs

Remove all IP addresses from the blocklist.

WarningThis will unblock ALL blocked IPs. Use with caution.
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=flush_blocked_ips"

User-Agent Blocking

Block specific User-Agent strings — Panel → User Agents.

Fixed in this core

These three actions never worked. They read and wrote a table called blocked_uas, which does not exist on any install — the panel keeps blocked agents in blocked_user_agents. get_blocked_uas answered with the ISP list instead, and every add_blocked_ua silently blocked nothing. They now read and write the table the panel uses.

The parameter is user_agent, matching the column. ua, which the old documentation named, is still accepted.

GETget_blocked_uasList Blocked UAs

Retrieve all blocked User-Agent strings.

Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_blocked_uas"
POSTadd_blocked_uaBlock UA

Add a User-Agent string to the blocklist.

ParameterTypeRequiredDescription
user_agentstringRequiredUser-Agent string to block (ua also accepted)
exact_matchintOptional1 to match the whole string rather than a substring
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=add_blocked_ua" \
  -d "user_agent=BadBot/1.0"
POSTdelete_blocked_uaUnblock UA

Remove a User-Agent string from the blocklist.

ParameterTypeRequiredDescription
idintRequiredBlocked UA entry ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=delete_blocked_ua" \
  -d "id=5"

ASN Blocking

The autonomous-system blocklist behind Panel → Blocked ASNs, gated by the block_asns group permission. It is usually the largest security table on an install — tens of thousands of rows — so always page it with limit. New in this core: the panel has had this screen for years and the API had no action for it at all.

POSTget_blocked_asnsList Blocked ASNs

Page the ASN blocklist. Supports the standard start, limit, search, order_by and order_dir parameters.

ParameterTypeRequiredDescription
limitintOptionalRows to return — use it, the table is large
startintOptionalOffset
searchstringOptionalMatch against the ISP, domain or country
Request
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
c
m
d
"
>
c
u
r
l
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
f
l
a
g
"
>
-
X
 
P
O
S
T
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
s
t
r
"
>
"
h
t
t
p
:
/
/
d
n
s
:
p
o
r
t
/
a
c
c
e
s
s
/
a
d
m
i
n
/
i
n
d
e
x
.
p
h
p
"
<
/
s
p
a
n
>
 
\


 
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
f
l
a
g
"
>
-
d
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
s
t
r
"
>
"
a
p
i
_
k
e
y
=
Y
O
U
R
_
K
E
Y
"
<
/
s
p
a
n
>
 
\


 
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
f
l
a
g
"
>
-
d
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
s
t
r
"
>
"
a
c
t
i
o
n
=
g
e
t
_
b
l
o
c
k
e
d
_
a
s
n
s
"
<
/
s
p
a
n
>


 
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
f
l
a
g
"
>
-
d
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
s
t
r
"
>
"
l
i
m
i
t
=
5
0
"
<
/
s
p
a
n
>
POSTget_blocked_asnGet Blocked ASN

One ASN record.

ParameterTypeRequiredDescription
idintRequiredRow ID
Request
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
c
m
d
"
>
c
u
r
l
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
f
l
a
g
"
>
-
X
 
P
O
S
T
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
s
t
r
"
>
"
h
t
t
p
:
/
/
d
n
s
:
p
o
r
t
/
a
c
c
e
s
s
/
a
d
m
i
n
/
i
n
d
e
x
.
p
h
p
"
<
/
s
p
a
n
>
 
\


 
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
f
l
a
g
"
>
-
d
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
s
t
r
"
>
"
a
p
i
_
k
e
y
=
Y
O
U
R
_
K
E
Y
"
<
/
s
p
a
n
>
 
\


 
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
f
l
a
g
"
>
-
d
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
s
t
r
"
>
"
a
c
t
i
o
n
=
g
e
t
_
b
l
o
c
k
e
d
_
a
s
n
"
<
/
s
p
a
n
>


 
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
f
l
a
g
"
>
-
d
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
s
t
r
"
>
"
i
d
=
1
"
<
/
s
p
a
n
>
POSTadd_blocked_asnBlock ASN

Add an ASN to the blocklist. blocked=1 enforces it; exclude_restreamer=1 lets restreamer lines through it.

ParameterTypeRequiredDescription
asnintRequiredAutonomous system number
ispstringOptionalISP name, as shown in the panel
domainstringOptionalISP domain
countrystringOptionalISO country code
blockedintOptional1 to enforce the block
exclude_restreamerintOptional1 to exempt restreamer lines
Request
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
c
m
d
"
>
c
u
r
l
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
f
l
a
g
"
>
-
X
 
P
O
S
T
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
s
t
r
"
>
"
h
t
t
p
:
/
/
d
n
s
:
p
o
r
t
/
a
c
c
e
s
s
/
a
d
m
i
n
/
i
n
d
e
x
.
p
h
p
"
<
/
s
p
a
n
>
 
\


 
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
f
l
a
g
"
>
-
d
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
s
t
r
"
>
"
a
p
i
_
k
e
y
=
Y
O
U
R
_
K
E
Y
"
<
/
s
p
a
n
>
 
\


 
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
f
l
a
g
"
>
-
d
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
s
t
r
"
>
"
a
c
t
i
o
n
=
a
d
d
_
b
l
o
c
k
e
d
_
a
s
n
"
<
/
s
p
a
n
>


 
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
f
l
a
g
"
>
-
d
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
s
t
r
"
>
"
a
s
n
=
6
4
5
1
2
"
<
/
s
p
a
n
>


 
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
f
l
a
g
"
>
-
d
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
s
t
r
"
>
"
i
s
p
=
E
x
a
m
p
l
e
 
H
o
s
t
i
n
g
"
<
/
s
p
a
n
>


 
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
f
l
a
g
"
>
-
d
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
s
t
r
"
>
"
b
l
o
c
k
e
d
=
1
"
<
/
s
p
a
n
>
POSTedit_blocked_asnEdit Blocked ASN

Change an ASN record — typically to toggle blocked.

ParameterTypeRequiredDescription
idintRequiredRow ID
blockedintOptional1 or 0
Request
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
c
m
d
"
>
c
u
r
l
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
f
l
a
g
"
>
-
X
 
P
O
S
T
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
s
t
r
"
>
"
h
t
t
p
:
/
/
d
n
s
:
p
o
r
t
/
a
c
c
e
s
s
/
a
d
m
i
n
/
i
n
d
e
x
.
p
h
p
"
<
/
s
p
a
n
>
 
\


 
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
f
l
a
g
"
>
-
d
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
s
t
r
"
>
"
a
p
i
_
k
e
y
=
Y
O
U
R
_
K
E
Y
"
<
/
s
p
a
n
>
 
\


 
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
f
l
a
g
"
>
-
d
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
s
t
r
"
>
"
a
c
t
i
o
n
=
e
d
i
t
_
b
l
o
c
k
e
d
_
a
s
n
"
<
/
s
p
a
n
>


 
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
f
l
a
g
"
>
-
d
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
s
t
r
"
>
"
i
d
=
1
"
<
/
s
p
a
n
>


 
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
f
l
a
g
"
>
-
d
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
s
t
r
"
>
"
b
l
o
c
k
e
d
=
0
"
<
/
s
p
a
n
>
POSTdelete_blocked_asnUnblock ASN

Remove an ASN from the blocklist.

ParameterTypeRequiredDescription
idintRequiredRow ID
Request
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
c
m
d
"
>
c
u
r
l
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
f
l
a
g
"
>
-
X
 
P
O
S
T
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
s
t
r
"
>
"
h
t
t
p
:
/
/
d
n
s
:
p
o
r
t
/
a
c
c
e
s
s
/
a
d
m
i
n
/
i
n
d
e
x
.
p
h
p
"
<
/
s
p
a
n
>
 
\


 
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
f
l
a
g
"
>
-
d
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
s
t
r
"
>
"
a
p
i
_
k
e
y
=
Y
O
U
R
_
K
E
Y
"
<
/
s
p
a
n
>
 
\


 
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
f
l
a
g
"
>
-
d
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
s
t
r
"
>
"
a
c
t
i
o
n
=
d
e
l
e
t
e
_
b
l
o
c
k
e
d
_
a
s
n
"
<
/
s
p
a
n
>


 
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
f
l
a
g
"
>
-
d
<
/
s
p
a
n
>
 
<
s
p
a
n
 
c
l
a
s
s
=
"
h
l
-
s
t
r
"
>
"
i
d
=
1
"
<
/
s
p
a
n
>

ISP Blocking

Block connections from specific ISPs.

GETget_blocked_ispsList Blocked ISPs

Retrieve all blocked ISPs.

Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_blocked_isps"
POSTadd_blocked_ispBlock ISP

Add an ISP to the blocklist.

ParameterTypeRequiredDescription
ispstringRequiredISP name to block
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=add_blocked_isp" \
  -d "isp=SomeVPN Provider"
POSTdelete_blocked_ispUnblock ISP

Remove an ISP from the blocklist.

ParameterTypeRequiredDescription
idintRequiredBlocked ISP entry ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=delete_blocked_isp" \
  -d "id=3"

RTMP IP Management

Manage allowed RTMP IP addresses.

GETget_rtmp_ipsList RTMP IPs

List all allowed RTMP IPs.

Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_rtmp_ips"
POSTcreate_rtmp_ipAdd RTMP IP

Add a new allowed RTMP IP.

ParameterTypeRequiredDescription
ipstringRequiredRTMP IP address
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=create_rtmp_ip" \
  -d "ip=10.0.0.50"
POSTedit_rtmp_ipEdit RTMP IP

Edit an RTMP IP entry.

ParameterTypeRequiredDescription
idintRequiredRTMP IP entry ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=edit_rtmp_ip" \
  -d "id=1"
POSTdelete_rtmp_ipDelete RTMP IP

Delete an RTMP IP entry.

ParameterTypeRequiredDescription
idintRequiredRTMP IP entry ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=delete_rtmp_ip" \
  -d "id=1"

Support Tickets

The ticket queue behind Panel → Tickets. Two tables sit under it: the ticket itself (subject, member, state, unread flags) and its replies. New in this core — neither API exposed any of it before, so an integration could sell a customer a line and never see them ask for help.

How the panel behaves — reproduced exactly

status is 1 for open and 0 for closed. An admin reply reopens a closed ticket; a member’s reply does not. Every reply marks the ticket read for the side that wrote it and unread for the other. reply_ticket tells you when it has reopened one, in warnings.

POSTget_ticketsList Tickets

Page the queue. Filter on status for open or closed, or on admin_read=0 for the ones waiting on you.

ParameterTypeRequiredDescription
limitintOptionalRows to return
startintOptionalOffset
statusintOptional1 open, 0 closed
admin_readintOptional0 for tickets you have not read
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=get_tickets" \
  -d "status=1" \
  -d "admin_read=0"
POSTget_ticketGet Ticket + Conversation

The ticket row plus every reply, oldest first, in replies, with reply_count. Reading marks it read for the admin, exactly as opening the panel view does — pass keep_unread=1 to leave the flag alone.

ParameterTypeRequiredDescription
idintRequiredTicket ID
keep_unreadintOptional1 to leave the ticket unread
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=get_ticket" \
  -d "id=2"
POSTcreate_ticketOpen Ticket

Raise a ticket against a reseller account.

ParameterTypeRequiredDescription
member_idintRequiredreg_users id the ticket belongs to
titlestringRequiredSubject
statusintOptional1 open (default in the panel)
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=create_ticket" \
  -d "member_id=6" \
  -d "title=Payment not credited" \
  -d "status=1"
POSTreply_ticketReply to Ticket

Append an admin message. If the ticket was closed this reopens it, which is what the panel does; the reply carries reopened: true and a warning saying so.

ParameterTypeRequiredDescription
idintRequiredTicket ID
messagestringRequiredThe reply body
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=reply_ticket" \
  -d "id=2" \
  -d "message=Credited now, sorry for the wait."
POSTclose_ticketClose Ticket

Close one ticket with id, or many with ids. The reply reports ticket_status, changed and the ids it changed; ids that do not exist come back in warnings rather than failing the call.

ParameterTypeRequiredDescription
idintOptionalTicket ID
idsstringOptionalComma-separated ticket IDs
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=close_ticket" \
  -d "ids=2,3,4"
POSTopen_ticketReopen Ticket

The same, in the other direction.

ParameterTypeRequiredDescription
idintOptionalTicket ID
idsstringOptionalComma-separated ticket IDs
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=open_ticket" \
  -d "id=2"
POSTedit_ticketEdit Ticket

Change a ticket row — its title or the read flags.

ParameterTypeRequiredDescription
idintRequiredTicket ID
titlestringOptionalNew subject
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=edit_ticket" \
  -d "id=2" \
  -d "title=Billing query"
POSTdelete_ticketDelete Ticket

Remove a ticket. Its replies are left in place, as in the panel.

ParameterTypeRequiredDescription
idintRequiredTicket ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=delete_ticket" \
  -d "id=2"

Activation Codes

The activation-code screens — Panel → Activation Codes, gated by users to view and add_user / edit_user to change. New on the admin API: all eight actions existed on the reseller API and none on this one, so an operator could hand a reseller code management and have none themselves. An admin sees every code, not just their own, and is never charged for one.

POSTget_activecodesList Activation Codes

Every code on the install, paged.

ParameterTypeRequiredDescription
limitintOptionalRows to return
startintOptionalOffset
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=get_activecodes" \
  -d "limit=50"
POSTget_activecodeGet Activation Code

One code.

ParameterTypeRequiredDescription
idintRequiredCode ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=get_activecode" \
  -d "id=1"
POSTcreate_activecodeCreate Activation Code

Generate one or more codes against a package. count=N generates N.

ParameterTypeRequiredDescription
packageintRequiredPackage ID the code activates
countintOptionalHow many to generate
notesstringOptionalFree-text note
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=create_activecode" \
  -d "package=1" \
  -d "count=5"
POSTedit_activecodeEdit Activation Code

Change a code row.

ParameterTypeRequiredDescription
idintRequiredCode ID
notesstringOptionalFree-text note
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=edit_activecode" \
  -d "id=1" \
  -d "notes=reissued"
POSTenable_activecodeEnable Activation Code

Allow a code to be redeemed.

ParameterTypeRequiredDescription
idintRequiredCode ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=enable_activecode" \
  -d "id=1"
POSTdisable_activecodeDisable Activation Code

Stop a code being redeemed.

ParameterTypeRequiredDescription
idintRequiredCode ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=disable_activecode" \
  -d "id=1"
POSTreset_activecodeReset Activation Code

Return a redeemed code to unused.

ParameterTypeRequiredDescription
idintRequiredCode ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=reset_activecode" \
  -d "id=1"
POSTdelete_activecodeDelete Activation Code

Remove a code.

ParameterTypeRequiredDescription
idintRequiredCode ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=delete_activecode" \
  -d "id=1"

Server Management

Manage servers, view statistics, and perform system operations.

GETget_serversList Servers

Retrieve a list of all configured servers.

Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_servers"
GETget_serverGet Single Server

Retrieve details of a single server.

ParameterTypeRequiredDescription
idintRequiredServer ID
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_server&id=1"
POSTedit_serverEdit Server

Edit server settings and configuration.

ParameterTypeRequiredDescription
idintRequiredServer ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=edit_server" \
  -d "id=1"
POSTedit_proxyEdit Proxy Settings

Edit proxy server settings.

ParameterTypeRequiredDescription
idintRequiredProxy server ID
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=edit_proxy" \
  -d "id=1"
GETget_server_statsServer Statistics

Retrieve server statistics including CPU, memory, disk usage, and connection counts.

ParameterTypeRequiredDescription
server_idintOptionalSpecific server ID (returns all if omitted)
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=get_server_stats&server_id=1"
Response
{
  "status": "STATUS_SUCCESS",
  "data": {
    "server_id": 1,
    "cpu_usage": 23.5,
    "mem_usage": 62.1,
    "disk_usage": 45.8,
    "uptime": "45 days",
    "active_connections": 342,
    "total_streams": 128
  }
}
POSTreload_nginxReload Nginx

Reload the nginx configuration on the server.

Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=reload_nginx"
POSTreload_cacheReload Cache

Reload the system cache.

Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=reload_cache"
POSTclear_tempClear Temp Files

Clear temporary files from the server.

Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=clear_temp"
POSTclear_streamsClear Stream Cache

Clear the stream cache on the server.

Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=clear_streams"
POSTkill_connectionKill Active Connection

Terminate an active user connection by its activity ID. Use live_connections to get active activity IDs.

ParameterTypeRequiredDescription
activity_idintRequiredThe activity ID of the connection to terminate
server_idintOptionalServer ID (defaults to main server)
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=kill_connection" \
  -d "activity_id=12345"
Response
{
  "status": "STATUS_SUCCESS"
}
POSTkill_pidKill Process by PID

Terminate a running process on the server by its PID. Useful for killing stuck stream processes.

ParameterTypeRequiredDescription
pidintRequiredThe process ID to terminate
server_idintOptionalServer ID (defaults to main server)
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=kill_pid" \
  -d "pid=54321"
Response
{
  "status": "STATUS_SUCCESS"
}

Logs & Monitoring

Monitor activity, connections, credits, and system events.

GETactivity_logsActivity Logs

Retrieve user activity logs with pagination support.

ParameterTypeRequiredDescription
startintOptionalPagination offset
limitintOptionalRecords per page
search[value]stringOptionalSearch term
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=activity_logs&start=0&limit=50"
GETlive_connectionsLive Connections

View currently active/live connections across all lines and devices.

ParameterTypeRequiredDescription
startintOptionalPagination offset
limitintOptionalRecords per page
search[value]stringOptionalSearch term
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=live_connections&start=0&limit=50"
GETcredit_logsCredit Logs

Retrieve credit transaction logs across all resellers.

ParameterTypeRequiredDescription
startintOptionalPagination offset
limitintOptionalRecords per page
search[value]stringOptionalSearch term
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=credit_logs&start=0&limit=50"
GETuser_logsReseller Action Logs

Retrieve reseller action logs and audit trail.

ParameterTypeRequiredDescription
startintOptionalPagination offset
limitintOptionalRecords per page
search[value]stringOptionalSearch term
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=user_logs&start=0&limit=50"
GETlogin_logsLogin History

Retrieve login history for all users.

ParameterTypeRequiredDescription
startintOptionalPagination offset
limitintOptionalRecords per page
search[value]stringOptionalSearch term
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=login_logs&start=0&limit=50"
GETclient_logsClient Connection Logs

Retrieve client connection logs and history.

ParameterTypeRequiredDescription
startintOptionalPagination offset
limitintOptionalRecords per page
search[value]stringOptionalSearch term
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=client_logs&start=0&limit=50"
GETmag_eventsMAG Device Events

Retrieve MAG device event logs.

ParameterTypeRequiredDescription
startintOptionalPagination offset
limitintOptionalRecords per page
search[value]stringOptionalSearch term
Request
curl -X GET "http://dns:port/access_code/admin/index.php?api_key=YOUR_KEY&action=mag_events&start=0&limit=50"

Response Format

All API responses follow a consistent JSON structure.

Standard Response
{
  "status": "STATUS_SUCCESS" | "STATUS_FAILURE",
  "data": { // Object or Array depending on the endpoint }
}
Important Always check the status field before processing the data field. On failure, the data field may contain an error message or be empty.

Status Codes

All possible status values returned by the API.

STATUS_SUCCESS
STATUS_FAILURE
STATUS_EXISTS_USERNAME
STATUS_EXISTS_MAC
STATUS_INVALID_MAC
STATUS_INVALID_DATE
STATUS_INVALID_INPUT
STATUS_INSUFFICIENT_CREDITS
STATUS_INVALID_PACKAGE
STATUS_NO_PERMISSIONS

Advanced

Advanced administrative operations. Use with extreme caution.

POST mysql_query Execute SQL Query
DANGER: Raw SQL Execution This endpoint executes raw SQL queries directly against the database. Incorrect queries can permanently corrupt or destroy data. Only use this if you fully understand the database schema and the consequences of your query. This endpoint is restricted to admin API keys only.

Execute a raw SQL query against the database. Returns the query result set for SELECT queries, or affected row count for INSERT/UPDATE/DELETE.

ParameterTypeRequiredDescription
querystringRequiredThe SQL query to execute
Request
curl -X POST "http://dns:port/access_code/admin/index.php" \
  -d "api_key=YOUR_KEY" \
  -d "action=mysql_query" \
  --data-urlencode "query=SELECT id, username, exp_date FROM lines WHERE member_id = 88 LIMIT 10"
Response
{
  "status": "STATUS_SUCCESS",
  "data": [
    {
      "id": 4521,
      "username": "customer1",
      "exp_date": "2026-12-31"
    },
    {
      "id": 4522,
      "username": "customer2",
      "exp_date": "2027-03-15"
    }
  ]
}