Harthelm Docs

Wake targets of a workspace

Needs `workspace.view`. Wakes the named targets, or without a body the IDE and every service whose run switch is on. Returns at once: a target that can wake is `waking` (the IDE first in `rwo-colocated` mode, then the services on its node), one that cannot says why in `wake.state` (`no-capacity`, `sleeps-until`, `paused`, `stopped`, `busy`). An awake target stays as it is. The shell calls it when the workspace page opens (pre-wake) with `{"targets": ["ide"]}`.

Generated from openapi/harthelm.yaml at v1.5.0
POST
/workspaces/{ws}/wake

Authorization

cookie__Host-harthelm_session<token>

Browser session of the UI (12 h idle, 7 days absolute). State-changing requests also need the header Harthelm-CSRF: 1 and a matching Origin.

Path Parameters

ws*integer

Numeric resource id.

Formatint64
Range1 <= value

Request Body

application/json
  1. body
targets?array<>

The targets; absent for the default of the operation.

Items1 <= items <= 64

Response Body

Accepted; the power state after the request.

application/json
  1. response
workspace_id*ID

Numeric resource id.

Formatint64
Range1 <= value
targets*array<>

The IDE first, then the services by name.

curl -X POST 'https://console.example.com/api/v1/workspaces/1/wake' \  -H 'Content-Type: application/json' \  -d '{}'
{  "workspace_id": 1,  "targets": [    {      "target": "string",      "availability": "always",      "asleep": true,      "ready_replicas": 0,      "sleep_reason": "idle",      "slept_at": "2019-08-24T14:15:22Z",      "woke_at": "2019-08-24T14:15:22Z",      "idle_timeout_minutes": 1,      "last_active_at": "2019-08-24T14:15:22Z",      "sleeps_at": "2019-08-24T14:15:22Z",      "busy": [        "ide"      ],      "busy_at": "2019-08-24T14:15:22Z",      "wake": {        "state": "awake",        "requested_at": "2019-08-24T14:15:22Z",        "finished_at": "2019-08-24T14:15:22Z",        "detail": "string",        "retry_after_seconds": 0,        "until": "2019-08-24T14:15:22Z"      }    }  ]}