DNS
Base path: /api/cloud/dns
Protected endpoints:
POST /api/cloud/dns/create
- Auth: Bearer (Keycloak)
- Description: Creates a new DNS/proxy host entry for an instance port.
- Body (JSON):
instanceId(string, required)forwardPort(number, required, target port on instance)domain(string, optional; if omitted, auto-generates like<uuid>.redu.cloud)
- Responses:
201 Createdwith created entry;400/401/403/500 - Example:
curl -X POST https://your-host/api/cloud/dns/create \
-H "Authorization: Bearer $TOKEN" -H 'Content-Type: application/json' \
-d '{"instanceId":"INSTANCE_ID","forwardPort":3000,"domain":"app.redu.cloud"}'POST /api/cloud/dns/update-dns
- Auth: Bearer (Keycloak)
- Description: Updates instance DNS-related metadata.
- Body (JSON):
instanceId(string, required)metadata(object, required)
- Responses:
200 OKwith result;400/401/500 - Example:
curl -X POST https://your-host/api/cloud/dns/update-dns \
-H "Authorization: Bearer $TOKEN" -H 'Content-Type: application/json' \
-d '{"instanceId":"INSTANCE_ID","metadata":{"dns":"app.redu.cloud"}}'Public endpoints:
GET /api/cloud/dns/list
- Auth: None
- Description: Lists all proxy hosts (DNS entries).
- Example:
curl https://your-host/api/cloud/dns/listGET /api/cloud/dns/proxy-hosts/:proxyHostId
- Auth: None
- Params:
proxyHostId(string)
- Responses:
200 OKwith proxy host;400/500 - Example:
curl https://your-host/api/cloud/dns/proxy-hosts/PROXY_IDDELETE /api/cloud/dns/proxy-hosts/:proxyHostId
- Auth: None
- Params:
proxyHostId(string)
- Responses:
200 OKwith message;400/500 - Example:
curl -X DELETE https://your-host/api/cloud/dns/proxy-hosts/PROXY_IDPUT /api/cloud/dns/proxy-hosts/:proxyHostId
- Auth: None
- Params:
proxyHostId(string)
- Body:
updateData(object) fields to update - Responses:
200 OKwith updated host;400/500 - Example:
curl -X PUT https://your-host/api/cloud/dns/proxy-hosts/PROXY_ID \
-H 'Content-Type: application/json' \
-d '{"forwardPort":8080}'