Spaces method and path for this operation:
put /s/{space_id}/api/fleet/fleet_server_hosts/{itemId}
Refer to Spaces for more information.
Update a Fleet Server host by ID.
[Required authorization] Route required privileges: fleet-settings-all.
PUT
/api/fleet/fleet_server_hosts/{itemId}
curl \
--request PUT 'https://localhost:5601/api/fleet/fleet_server_hosts/{itemId}' \
--header "Authorization: $API_KEY" \
--header "Content-Type: application/json" \
--header "kbn-xsrf: true" \
--data '{"host_urls":["https://updated-fleet-server.example.com:8220"],"is_default":false,"name":"Updated Fleet Server"}'
Request example
Update a Fleet Server host
{
"host_urls": [
"https://updated-fleet-server.example.com:8220"
],
"is_default": false,
"name": "Updated Fleet Server"
}
Response examples (200)
The updated Fleet Server host
{
"item": {
"host_urls": [
"https://updated-fleet-server.example.com:8220"
],
"id": "fleet-server-host-id-1",
"is_default": false,
"is_preconfigured": false,
"name": "Updated Fleet Server"
}
}
Response examples (400)
Example of a generic error response
{
"error": "Bad Request",
"message": "An error message describing what went wrong",
"statusCode": 400
}
Response examples (404)
No Fleet Server host was found with the given ID
{
"error": "Not Found",
"message": "Fleet server fleet-server-host-id-1 not found",
"statusCode": 404
}