mirror of
https://github.com/coder/coder.git
synced 2025-07-23 21:32:07 +00:00
chore: accept payload on workspace usage route (#13544)
This commit is contained in:
17
docs/api/workspaces.md
generated
17
docs/api/workspaces.md
generated
@ -1397,16 +1397,27 @@ To perform this operation, you must be authenticated. [Learn more](authenticatio
|
||||
```shell
|
||||
# Example request using curl
|
||||
curl -X POST http://coder-server:8080/api/v2/workspaces/{workspace}/usage \
|
||||
-H 'Content-Type: application/json' \
|
||||
-H 'Coder-Session-Token: API_KEY'
|
||||
```
|
||||
|
||||
`POST /workspaces/{workspace}/usage`
|
||||
|
||||
> Body parameter
|
||||
|
||||
```json
|
||||
{
|
||||
"agent_id": "2b1e3b65-2c04-4fa2-a2d7-467901e98978",
|
||||
"app_name": "vscode"
|
||||
}
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
| Name | In | Type | Required | Description |
|
||||
| ----------- | ---- | ------------ | -------- | ------------ |
|
||||
| `workspace` | path | string(uuid) | true | Workspace ID |
|
||||
| Name | In | Type | Required | Description |
|
||||
| ----------- | ---- | ---------------------------------------------------------------------------------- | -------- | ---------------------------- |
|
||||
| `workspace` | path | string(uuid) | true | Workspace ID |
|
||||
| `body` | body | [codersdk.PostWorkspaceUsageRequest](schemas.md#codersdkpostworkspaceusagerequest) | false | Post workspace usage request |
|
||||
|
||||
### Responses
|
||||
|
||||
|
Reference in New Issue
Block a user