Interactive API Reference (Swagger)¶
Interactive, always-in-sync Swagger UI for every XC_VM API, generated from OpenAPI 3.1 specifications traced from the source: each operation cites the file and line it was read from (src/...:line). Use the API tabs at the top of the page to switch between APIs, or open one directly via the links below.
| API | Description | Auth | Open |
|---|---|---|---|
| Player API | player_api.php sign-in, live TV, VOD, series and EPG; legacy panel_api.php; xmltv.php guide (15 operations) |
username + password, token or activation code |
Open ↗ |
| Playlist API | get.php playlists — M3U, M3U Plus, Enigma2 bouquets, set-top box formats; also /playlist |
username + password or token |
Open ↗ |
| Streaming | Live, VOD, series, catch-up, HLS segments and keys, thumbnails, subtitles (36 operations) | Line credentials in the path, or a line / play token | Open ↗ |
| MAG Portal | Stalker/Ministra portal for MAG and compatible set-top boxes (91 operations) | MAC handshake + bearer token | Open ↗ |
| Enigma2 | enigma2.php XML playlists and the xplugin.php companion API (13 operations) |
username + password; device MAC + token |
Open ↗ |
| Activation | active_code.php activation and code management, and the /portal self-activation page (15 operations) |
Activation code, or admin / reseller api_key |
Open ↗ |
| Admin API | Administration — lines, devices, users, groups, packages, streams, VOD, series, servers, settings, logs (187 actions) | api_key + Admin API access code |
Open ↗ |
| Reseller API | A reseller's lines, devices, sub-accounts, activation codes and credits (49 actions) | api_key + Reseller API access code |
Open ↗ |
| System API | Node actions of /api.php (now run over the cluster bus; HTTP answers 404) and the /admin/* stream endpoints (37 operations) |
Signed node.rpc; relay ticket or live_streaming_pass |
Open ↗ |
| Cluster API | MAIN-only node-to-MAIN control plane /cluster/v1/<op> (22 operations) |
Signed X-XCVM-* headers |
Open ↗ |
| Monitoring | /metrics (Prometheus), /healthz, /progress (3 operations) |
metrics_token bearer for /metrics |
Open ↗ |
Using "Try it out"¶
- Open a spec, then use the API tabs to switch APIs, and the Documentation / Interactive (Swagger) tabs for each API.
- Expand any endpoint → Try it out → fill parameters → Execute to see the real request URL, cURL command and live response.
- For the Admin, Reseller and Monitoring APIs, click Authorize 🔓 and paste your API key or metrics token — it is then attached to every request automatically.
CORS note: direct "Try it out" calls from the browser to your server may be blocked by CORS. This is expected — use the generated cURL command, Postman or Insomnia instead. The error does not mean the API is broken.
Notes on answers¶
Admin API
api_keytakes an account's API key or one of its API tokens, which can be limited to reading, or to lines, devices and activation codes.- An API key acts with the permissions its holder's group lists. The table under Admin API keys names the permission each action asks for; an action the group has no permission for answers
STATUS_NO_PERMISSIONS. The active-code API answers the same when it is called with an Admin API key. delete_user,disable_user,enable_userandadjust_creditsanswerSTATUS_FAILUREfor an administrator's account unless the key belongs to a full administrator.get_user,create_userandedit_useranswer the account without itspassword, and with itsapi_keyonly when it is the account the calling key belongs to.create_line,edit_line,create_mag,edit_mag,create_enigmaandedit_enigmaanswerSTATUS_INVALID_USERNAMEorSTATUS_INVALID_PASSWORDwhen the username or password contains/. A line or device that already has such a value keeps it and stays editable while that value is sent unchanged or left out. The reseller API answers the same for lines; see Reseller System.edit_linekeeps the line's username and password when the request does not send them. An empty value asks for a generated one.- Every
edit_*action keeps each field the request leaves out, as the record has it stored, so a request may send only the fields it changes. Send a field to change it; send it empty to clear it (a list sent empty is an empty list, a date sent empty is none). A switch (a checkbox of the panel's form) is on at1and off at0or empty. The fields are named as the panel's form posts them: lists as arrays (bouquets[],category_id[],domain_name[],http_broadcast_ports[]), or as a JSON array where the form posts one (bouquets_selected,groups_selected,permissions_selected,packages_selected,server_tree_data). An HMAC key is kept unlesskeygenis sent; an RTMP address keeps its password unless one is sent.edit_settingschanges only the settings the request names, the stream argument defaults (user_agent,http_proxy,cookie,headers) and the genre mapping included. - For
edit_line:exp_dateempty, orno_expireon, removes the expiry (ano_expireof0or empty is off);isp_clearclears the stored ISP.exp_datetakes a date string, not the timestampget_lineanswers.bouquets_selectedis a JSON array, outputs areaccess_output[].is_stalker,is_restreamer,is_trial,is_isplockandbypass_uaare off at0or empty.enabledandadmin_enabledare kept: sendenabled=1/admin_enabled=1to switch a disabled or banned line back on (an edit used to do that whatever it sent). edit_user:creditssets the balance to that value; leave it out to keep the balance. A value equal to the balance asget_useranswers it (six significant digits) keeps the balance too.create_groupandedit_group:group_idin the body is ignored. A new group gets the next id, and an edit changes the group named byid.create_transcode_profileandedit_transcode_profileanswerSTATUS_INVALID_INPUTwhenvideo_codec_cpu,video_codec_gpu,audio_codecor apreset_*field is not a single name, or avideo_profile_*field is not a name with an optional-level N.install_serverinstalls a load balancer andinstall_proxya proxy. Both needssh_port,root_usernameandroot_password, and answerSTATUS_INVALID_INPUTwithout one of them.activity_logsrows (player) andlive_connectionsrows (user_agent) carry the device's name as it is stored, with HTML entities encoded (&,"). The panel's tables show the decoded name.
Player API
- Signing in with an activation code as username or token answers
user_info.statusExpired("Account has expired.") when the code's subscription has run out, andDisabled("Account has been disabled.") when the code is suspended or revoked. Other refused codes answer "Username or password is invalid.".
Raw specifications¶
Every spec can be imported into Postman, Insomnia or any OpenAPI 3.1 tooling: