## Summary - Updates the Spaces API documentation to reflect new "disabledFeatures" property - Introduces Features API documentation to assist the Spaces API docs Related: https://github.com/elastic/kibana/issues/31053
55 lines
2 KiB
Text
55 lines
2 KiB
Text
[[spaces-api-put]]
|
|
=== Update Space
|
|
|
|
experimental[This API is *experimental* and may be changed or removed completely in a future release. The underlying Spaces concepts are stable, but the APIs for managing Spaces are currently experimental.]
|
|
|
|
Updates an existing {kib} space. To create a new space, use the POST command.
|
|
|
|
Note: You cannot access this endpoint via the Console in Kibana.
|
|
|
|
==== Request
|
|
|
|
To update a space, issue a PUT request to the
|
|
`/api/spaces/space/<space_id>` endpoint.
|
|
|
|
[source,js]
|
|
--------------------------------------------------
|
|
PUT /api/spaces/space/<space_id>
|
|
--------------------------------------------------
|
|
|
|
==== Request Body
|
|
|
|
The following parameters can be specified in the body of a PUT request to update a space:
|
|
|
|
`id`:: (string) Required identifier for the space. This identifier becomes part of Kibana's URL when inside the space. This cannot be changed by the update operation.
|
|
|
|
`name`:: (string) Required display name for the space.
|
|
|
|
`description`:: (string) Optional description for the space.
|
|
|
|
`disabledFeatures`:: (string array) Optional list of features that are disabled for the space. Use the <<features-api-get, Features API>> to get a list of available features IDs.
|
|
|
|
`initials`:: (string) Optionally specify the initials shown in the Space Avatar for this space. By default, the initials will be automatically generated from the space name.
|
|
If specified, initials should be either 1 or 2 characters.
|
|
|
|
`color`:: (string) Optioanlly specify the hex color code used in the Space Avatar for this space. By default, the color will be automatically generated from the space name.
|
|
|
|
===== Example
|
|
|
|
[source,js]
|
|
--------------------------------------------------
|
|
PUT /api/spaces/space/marketing
|
|
{
|
|
"id": "marketing",
|
|
"name": "Marketing",
|
|
"description" : "This is the Marketing Space",
|
|
"color": "#aabbcc",
|
|
"initials": "MK",
|
|
"disabledFeatures": []
|
|
}
|
|
--------------------------------------------------
|
|
// KIBANA
|
|
|
|
==== Response
|
|
|
|
A successful call returns a response code of `200` with the updated Space.
|