Agent
The endpoints a cluster's agent and the install scripts call. They authenticate with agent and enrollment tokens, not with API tokens. Each operation lists its method and path, parameters, request body, responses and an example call.
curl -X GET "https://example.com/agent/v1/access-state"{ "$schema": "https://example.com/AccessState.json", "buildRegistry": true, "desiredAgentImage": "string", "environments": [ { "id": "string", "namespace": "string", "podSecurityBaseline": true } ], "revision": 0}curl -X GET "https://example.com/agent/v1/broker-commands"{ "$schema": "https://example.com/BrokerCommands.json", "commands": [ { "expiresAt": "2019-08-24T14:15:22Z", "id": "string", "kind": "string", "node": "string" } ]}/agent/v1/broker-eventsHeader Parameters
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/problem+json
curl -X POST "https://example.com/agent/v1/broker-events" \ -H "Content-Type: application/json" \ -d '{ "id": "string" }'/agent/v1/build-logsHeader Parameters
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/problem+json
curl -X POST "https://example.com/agent/v1/build-logs" \ -H "Content-Type: application/json" \ -d '{ "buildId": "string", "lines": [ { "at": "2019-08-24T14:15:22Z", "text": "string" } ] }'/agent/v1/cnpg.shRequest Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/problem+json
curl -X POST "https://example.com/agent/v1/cnpg.sh" \ -H "Content-Type: application/json" \ -d '{ "token": "string" }'"string"/agent/v1/enable-ha.shRequest Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/problem+json
curl -X POST "https://example.com/agent/v1/enable-ha.sh" \ -H "Content-Type: application/json" \ -d '{ "token": "string" }'"string"/agent/v1/enrollRequest Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/problem+json
curl -X POST "https://example.com/agent/v1/enroll" \ -H "Content-Type: application/json" \ -d '{ "enrollmentToken": "string", "hello": { "agentVersion": "string", "capabilities": { "metricsServer": true, "tailscale": true, "traefik": true }, "k3sVersion": "string", "nodes": [ { "allocatable": { "cpuMilli": 0, "ephemeralBytes": 0, "memoryBytes": 0, "pods": 0 }, "allocated": { "cpuMilli": 0, "ephemeralBytes": 0, "memoryBytes": 0, "pods": 0 }, "k3sVersion": "string", "name": "string", "ready": true, "unschedulable": true } ] } }'{ "$schema": "https://example.com/EnrollResponse.json", "agentToken": "string", "clusterId": "string"}/agent/v1/eventsHeader Parameters
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/problem+json
curl -X POST "https://example.com/agent/v1/events" \ -H "Content-Type: application/json" \ -d '[ { "at": "2019-08-24T14:15:22Z", "kind": "string" } ]'/agent/v1/heartbeatHeader Parameters
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/problem+json
curl -X POST "https://example.com/agent/v1/heartbeat" \ -H "Content-Type: application/json" \ -d '{ "appliedRevision": 0, "at": "2019-08-24T14:15:22Z", "capabilities": { "metricsServer": true, "tailscale": true, "traefik": true }, "nodes": [ { "allocatable": { "cpuMilli": 0, "ephemeralBytes": 0, "memoryBytes": 0, "pods": 0 }, "allocated": { "cpuMilli": 0, "ephemeralBytes": 0, "memoryBytes": 0, "pods": 0 }, "k3sVersion": "string", "name": "string", "ready": true, "unschedulable": true } ], "workloads": [ { "environmentId": "string", "pods": [ { "cpuMilli": 0, "memoryBytes": 0, "name": "string", "node": "string", "phase": "string", "ready": true, "restarts": 0 } ], "releaseId": "string", "serviceId": "string" } ] }'/agent/v1/helloHeader Parameters
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/problem+json
curl -X POST "https://example.com/agent/v1/hello" \ -H "Content-Type: application/json" \ -d '{ "agentVersion": "string", "capabilities": { "metricsServer": true, "tailscale": true, "traefik": true }, "k3sVersion": "string", "nodes": [ { "allocatable": { "cpuMilli": 0, "ephemeralBytes": 0, "memoryBytes": 0, "pods": 0 }, "allocated": { "cpuMilli": 0, "ephemeralBytes": 0, "memoryBytes": 0, "pods": 0 }, "k3sVersion": "string", "name": "string", "ready": true, "unschedulable": true } ] }'/agent/v1/install.shRequest Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/problem+json
curl -X POST "https://example.com/agent/v1/install.sh" \ -H "Content-Type: application/json" \ -d '{ "token": "string" }'"string"/agent/v1/install/join-configRequest Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/problem+json
curl -X POST "https://example.com/agent/v1/install/join-config" \ -H "Content-Type: application/json" \ -d '{ "token": "string" }'{ "$schema": "https://example.com/JoinConfigBody.json", "k3sVersion": "string", "serverUrl": "string", "token": "string"}/agent/v1/install/manifestRequest Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/problem+json
curl -X POST "https://example.com/agent/v1/install/manifest" \ -H "Content-Type: application/json" \ -d '{ "token": "string" }'"string"/agent/v1/install/progressRequest Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/problem+json
curl -X POST "https://example.com/agent/v1/install/progress" \ -H "Content-Type: application/json" \ -d '{ "nodeName": "string", "status": "running", "step": "preflight", "token": "string" }'/agent/v1/logsHeader Parameters
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/problem+json
curl -X POST "https://example.com/agent/v1/logs" \ -H "Content-Type: application/json" \ -d '{ "lines": [ { "at": "2019-08-24T14:15:22Z", "environmentId": "string", "podName": "string", "processName": "string", "serviceId": "string", "text": "string" } ] }'curl -X GET "https://example.com/agent/v1/ping"curl -X GET "https://example.com/agent/v1/stream"[ { "data": { "$schema": "https://example.com/Command.json", "buildId": "string", "database": { "maxRows": 0, "query": "string", "target": { "database": "string", "engine": "string", "image": "string", "namespace": "string", "password": "string", "port": 0, "runAsUser": 0, "serviceSlug": "string", "username": "string" }, "timeoutMillis": 0 }, "environmentId": "string", "id": "string", "image": "string", "kind": "string", "node": "string", "pod": "string", "process": "string", "releaseId": "string", "role": "string", "serviceId": "string", "volume": { "database": { "database": "string", "engine": "string", "image": "string", "namespace": "string", "password": "string", "port": 0, "runAsUser": 0, "serviceSlug": "string", "username": "string" }, "environmentId": "string", "expectedSha256": "string", "jobId": "string", "method": "string", "namespace": "string", "objectKey": "string", "quiesce": true, "serviceId": "string", "serviceSlug": "string", "store": { "accessKeyId": "string", "bucket": "string", "endpoint": "string", "forcePathStyle": true, "region": "string", "secretAccessKey": "string" }, "volume": { "mountPath": "string", "name": "string", "sizeBytes": 0, "storageClass": "string" } } }, "event": "command", "id": 0, "retry": 0 }]/agent/v1/tailscale.shRequest Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/problem+json
curl -X POST "https://example.com/agent/v1/tailscale.sh" \ -H "Content-Type: application/json" \ -d '{ "token": "string" }'"string"