NGINX
Base path: /api/cloud/nginx
Protected endpoints:
GET /api/cloud/nginx/available-port
- Auth: Bearer (Keycloak)
- Description: Returns a free TCP port available for routing.
- Example:
curl -H "Authorization: Bearer $TOKEN" \
https://your-host/api/cloud/nginx/available-portGET /api/cloud/nginx/used-ports
- Auth: Bearer (Keycloak)
- Description: Lists used TCP ports managed by the service.
- Example:
curl -H "Authorization: Bearer $TOKEN" \
https://your-host/api/cloud/nginx/used-portsGET /api/cloud/nginx/health
- Auth: Bearer (Keycloak)
- Description: Health check for NGINX management subsystem.
- Example:
curl -H "Authorization: Bearer $TOKEN" \
https://your-host/api/cloud/nginx/healthPOST /api/cloud/nginx/create
- Auth: Bearer (Keycloak)
- Description: Creates a new NGINX TCP route mapping.
- Body (JSON):
targetIp(string, required)targetPort(number, required)protocol(string, required, onlytcpsupported)port(number, required, incoming/listening port)certificate_id(number, optional)
- Responses:
200 OKwith created route;400/500 - Example:
curl -X POST https://your-host/api/cloud/nginx/create \
-H "Authorization: Bearer $TOKEN" -H 'Content-Type: application/json' \
-d '{"targetIp":"203.0.113.10","targetPort":3000,"protocol":"tcp","port":22005}'Public endpoint:
DELETE /api/cloud/nginx/routes/:port
- Auth: None
- Params:
port(number)
- Responses:
200 OKwith message;404if not found;500on error - Example:
curl -X DELETE https://your-host/api/cloud/nginx/routes/22005