Services
Endpoints for managing system services.
Services include web servers, database engines, PHP-FPM pools, and other systemd units managed by the panel.
List Services
GET /api/v1/services
Scope: read:services
Response
{
"data": [
{
"name": "nginx",
"status": "running",
"version": ""
},
{
"name": "mariadb",
"status": "running",
"version": "mariadb from 11.8.6-MariaDB, client 15.2 for debian-linux-gnu (x86_64) using EditLine wrapper"
},
{
"name": "php8.4-fpm",
"status": "running",
"version": "PHP 8.4.24 (cli) (built: Jul 30 2026 15:35:42) (NTS)"
},
{
"name": "postgresql",
"status": "not installed",
"version": ""
}
]
}
| Field | Type | Description |
|---|---|---|
name |
string | Service identifier |
status |
string | Current state (see below) |
version |
string | Detected version, or empty if not installed |
Status Values
| Value | Meaning |
|---|---|
running |
Service is active |
stopped |
Service is installed but not running |
not installed |
Service is not present on the server |
installed |
Runtime-only service that is installed but not managed as a daemon |
Example
curl -H "Authorization: Bearer $TOKEN" \
https://panel.example.com/api/v1/services
Get Service
GET /api/v1/services/{name}
Scope: read:services
Path Parameters
| Parameter | Type | Description |
|---|---|---|
name |
string | Service name, for example nginx |
Response
Same shape as a single item in the list response, wrapped in data:
{
"data": {
"name": "php8.4-fpm",
"status": "running",
"version": "PHP 8.4.24 (cli) (built: Jul 30 2026 15:35:42) (NTS)"
}
}
Errors
| Code | Status | Condition |
|---|---|---|
not_found |
404 | Service is not installed on the server |
Example
curl -H "Authorization: Bearer $TOKEN" \
https://panel.example.com/api/v1/services/nginx
Run Action
PATCH /api/v1/services/actions
Scope: write:services
Start, stop, restart, or reload a service.
Request Body
The body maps one service name to one action:
{
"nginx": "restart"
}
| Field | Type | Required | Description |
|---|---|---|---|
<service-name> |
string | Yes | Action to run. Exactly one service per request |
Valid actions:
| Action | Effect |
|---|---|
start |
Start the service if stopped |
stop |
Stop the service |
restart |
Full stop then start |
reload |
Re-read configuration without restarting the process |
Response
Returns the updated service status:
{
"data": {
"name": "nginx",
"status": "running",
"version": ""
}
}
Errors
| Code | Status | Condition |
|---|---|---|
invalid_request |
400 | Body has zero or more than one service |
invalid_request |
400 | Action is not one of start, stop, restart, reload |
not_found |
404 | Service is not installed on the server |
Example
Restart nginx:
curl -X PATCH \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{"nginx": "restart"}' \
https://panel.example.com/api/v1/services/actions
Reload nginx without dropping connections:
curl -X PATCH \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{"nginx": "reload"}' \
https://panel.example.com/api/v1/services/actions
Related
- Authentication - token format and auth failures
- Responses - success response shape
- Errors - error codes