API Documentation

Integrate WisPanel with your applications using our comprehensive REST API.

Base URL

https://your-server-ip:2083/api/v1

All API endpoints are relative to this base URL.

Services

Services

Control system services. Role: admin. Base: /api/v1/services. Auth: Authorization: Bearer wsp_…


List β€” GET /api/v1/services/

Response 200 (verified live):

[
  { "name": "nginx", "display_name": "Nginx", "status": "running",
    "enabled": true, "description": "Web server" },
  { "name": "mysql", "display_name": "MySQL", "status": "running",
    "enabled": true, "description": "Database server" }
]

GET /api/v1/services/:name β†’ one service object (same shape).

Control β€” POST /api/v1/services/:name/{start,stop,restart}

Request: no body.

Response 200: { "success": true, "status": "running" }

Response 403 (verified live β€” service not whitelisted):

{ "success": false, "code": "FORBIDDEN",
  "error": "Service not allowed",
  "message": "Service not allowed", "status": 403 }

:name = a whitelisted unit (nginx, mysql, php-fpm, …).


Conventions β†’ Authentication, Error Handling.

Rate Limiting

API requests are limited to 60 requests per minute per API token.

  • X-RateLimit-Limit: Maximum requests per minute
  • X-RateLimit-Remaining: Remaining requests
  • X-RateLimit-Reset: Unix timestamp when limit resets