Updated deprecated endpoint references with new endpoint (#24723)
[#23880](https://github.com/fleetdm/fleet/issues/23880) --------- Co-authored-by: Rachael Shaw <r@rachael.wtf>
This commit is contained in:
co-authored by
Rachael Shaw
parent
669e944f50
commit
abeb16c087
@@ -2410,7 +2410,7 @@ One of `query` and `query_id` must be specified.
|
||||
|
||||
#### Example with one host targeted by hostname
|
||||
|
||||
`POST /api/v1/fleet/queries/run_by_names`
|
||||
`POST /api/v1/fleet/queries/run_by_identifiers`
|
||||
|
||||
##### Request body
|
||||
|
||||
@@ -2449,7 +2449,7 @@ One of `query` and `query_id` must be specified.
|
||||
|
||||
#### Example with multiple hosts targeted by label name
|
||||
|
||||
`POST /api/v1/fleet/queries/run_by_names`
|
||||
`POST /api/v1/fleet/queries/run_by_identifiers`
|
||||
|
||||
##### Request body
|
||||
|
||||
@@ -2486,6 +2486,39 @@ One of `query` and `query_id` must be specified.
|
||||
}
|
||||
```
|
||||
|
||||
#### Example with invalid label
|
||||
|
||||
`POST /api/v1/fleet/queries/run_by_identifiers`
|
||||
|
||||
##### Request body
|
||||
|
||||
```json
|
||||
{
|
||||
"query": "SELECT instance_id FROM system_info",
|
||||
"selected": {
|
||||
"labels": ["Windows", "Banana", "Apple"]
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
##### Default response
|
||||
|
||||
`Status: 400`
|
||||
|
||||
```json
|
||||
{
|
||||
"message": "Bad request",
|
||||
"errors": [
|
||||
{
|
||||
"name": "base",
|
||||
"reason": "Invalid label name(s): Banana, Apple."
|
||||
}
|
||||
],
|
||||
"uuid": "303649f4-5e45-4379-bae9-64ec0ef56287"
|
||||
}
|
||||
```
|
||||
|
||||
|
||||
### Retrieve live query results (standard WebSocket API)
|
||||
|
||||
You can retrieve the results of a live query using the [standard WebSocket API](#https://developer.mozilla.org/en-US/docs/Web/API/WebSockets_API/Writing_WebSocket_client_applications).
|
||||
|
||||
Reference in New Issue
Block a user