API Reference

ISPCore API

A REST API to automate your ISP — manage clients, subscriptions, RADIUS sessions, fiber devices, billing and support, all over HTTPS with JSON.

Live, always-current reference. Every ISPCore instance ships with interactive OpenAPI (Swagger) docs at https://your-server/docs and a machine-readable spec at /openapi.json. Those reflect your exact version. The examples below are illustrative of the resources available.

Introduction

The ISPCore API is organized around REST. It uses predictable resource-oriented URLs, accepts and returns JSON, and relies on standard HTTP verbs and status codes. The API runs on your own ISPCore server, so your data never leaves your infrastructure.

Base URL

All endpoints are served from your installation's domain, under the /api/v1 prefix:

# your own ISPCore server
https://your-server/api/v1

Authentication

Requests are authenticated with a bearer token issued from your panel (Settings → API). Send it in the Authorization header with every request.

curl https://your-server/api/v1/clients \
  -H "Authorization: Bearer <your_token>"
Keep tokens secret and server-side. Tokens scope access to a single tenant; revoke or rotate them anytime from the panel. The exact authentication scheme for your version is shown in the interactive docs.

Conventions

TopicBehavior
PaginationList endpoints accept ?page and ?per_page; responses include total counts.
SearchMost collections accept ?q= for free-text search (name, code, username…).
DatesISO-8601 (2026-06-04 or full timestamps in UTC).
IDsStable string identifiers; clients also carry a human code like C-2026-00009.

Errors

ISPCore uses conventional HTTP status codes. Errors return a JSON body with a detail message.

CodeMeaning
200 / 201Success
400Invalid request / validation error
401Missing or invalid token
403Not allowed for this token / tenant
404Resource not found
429Rate limit exceeded
{
  "detail": "Client not found"
}

Clients

Manage your subscribers (customers). Each client carries contact details, status, location and PPPoE state.

GET/api/v1/clients
List clients. Supports ?q=, ?status=, ?online= and pagination.
GET/api/v1/clients/{id}
Retrieve a single client with subscriptions, location and status.
POST/api/v1/clients
Create a client.
PUT/api/v1/clients/{id}
Update a client's details.
DELETE/api/v1/clients/{id}
Remove a client.

Example response

GET /api/v1/clients/C-2026-00009
{
  "code": "C-2026-00009",
  "name": "prova1234",
  "phone": "0697926666",
  "city": "Tirane",
  "status": "active",
  "online": true,
  "ip_pppoe": "10.99.99.247",
  "location": { "lat": 41.3277, "lng": 19.8220 }
}

Subscriptions

A subscription links a client to a service plan and tracks billing dates and connection state.

GET/api/v1/subscriptions
List subscriptions with plan, status and next billing date.
POST/api/v1/subscriptions
Create a subscription for a client (username, plan).
PUT/api/v1/subscriptions/{id}
Change plan, suspend or resume a subscription.

Plans

Read the service plans (speed/profile) available on your system.

GET/api/v1/plans
List plans with name, speed profile and price.

RADIUS sessions

Read live PPPoE / RADIUS sessions and disconnect them remotely (CoA).

GET/api/v1/sessions
List active sessions: username, IP, MAC, NAS, uptime and traffic.
POST/api/v1/sessions/{username}/disconnect
Disconnect a live session via Change-of-Authorization.
GET /api/v1/sessions?username=prova1234
{
  "username": "prova1234",
  "status": "online",
  "ip": "10.99.99.247",
  "mac": "D8:44:89:78:CF:29",
  "nas": "10.100.230.171",
  "uptime_s": 572700,
  "in_bytes": 7866941440,
  "out_bytes": 257698037
}

OLT / ONU

Inventory and control fiber equipment — GPON and EPON, across Huawei and ZTE.

GET/api/v1/olts
List configured OLTs.
GET/api/v1/onus
List ONUs with online status, signal (Rx/Tx), interface and VLAN.
GET/api/v1/onus/{id}/status
Detailed optical status: Rx/Tx power, distance, serial, mode.
POST/api/v1/onus/{id}/reboot
Reboot an ONU. Also: /resync, /disable, /delete.
GET /api/v1/onus/{id}/status
{
  "serial": "ZXICCCBA21AF",
  "type": "ZTE-F660",
  "interface": "gpon_onu-1/4/1:2",
  "rx_power_dbm": -16.47,
  "tx_power_dbm": 2.61,
  "distance_m": 393,
  "vlan": 824,
  "status": "working"
}

NAS & IP pools

Manage RADIUS NAS devices and IP address pools.

GET/api/v1/nas
List NAS devices (BNG/routers) and their status.
GET/api/v1/ip-pools
List IP pools and utilization.

TR-069 / CPE

Manage customer premises equipment through the integrated ACS.

GET/api/v1/cpe
List CPE devices with model, firmware and last inform.
POST/api/v1/cpe/{id}/reboot
Trigger a remote reboot or configuration task.

Billing & payments

Read invoices and record payments.

GET/api/v1/invoices
List invoices with amount, status and due date.
GET/api/v1/invoices/{id}
Retrieve a single invoice (with PDF link).
POST/api/v1/payments
Record a payment against a client or invoice.

Tickets

Programmatic access to the built-in support desk.

GET/api/v1/tickets
List tickets with status, priority and assignee.
POST/api/v1/tickets
Open a ticket (subject, category, priority, client).

Dashboard stats

Read the same metrics shown on your dashboard — useful for external monitoring.

GET/api/v1/stats
Active clients, active subscriptions, online clients, live traffic, revenue and outstanding debt.
GET /api/v1/stats
{
  "active_clients": 8,
  "active_subscriptions": 9,
  "online_clients": 3,
  "live_download_mb": 7506.4,
  "revenue_month": 18500,
  "outstanding_debt": 1500
}

Interactive docs

Your ISPCore instance exposes a fully interactive reference where you can browse every endpoint, see exact schemas and try calls live:

Because the interactive docs are generated from your running version, they are always accurate for your installation — the perfect companion to this overview.

← Back to ISPCore