mirror of
https://github.com/elastic/kibana.git
synced 2025-06-28 11:05:39 -04:00
## Summary Passing default solution from cloud onboarding process. 1. Renaming. Solution changes are not released yet, would be shipped with `8.15`, so it's fine to do it. - `search` -> `es` - `observability` -> `oblt` - Adjusted telemetry accordingly 2. Added `cloud` as optional dependency to `spaces` plugin to use `onboarding.defaultSolution` passed through setup contract. ### How to test 1. Set `xpack.cloud.onboarding.default_solution` to `es | oblt | security` 2. Check that default space was created with provided solution `GET kbn:/api/spaces/space/default` ### Checklist - [x] [Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html) was added for features that require explanation or tutorials - [x] [Unit or functional tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html) were updated or added to match the most common scenarios ### For maintainers - [x] This was checked for breaking API changes and was [labeled appropriately](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process) __Fixes: https://github.com/elastic/kibana/issues/184999__ --------- Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
138 lines
3.7 KiB
Text
138 lines
3.7 KiB
Text
[[spaces-api-get-all]]
|
|
=== Get all {kib} spaces API
|
|
++++
|
|
<titleabbrev>Get all spaces</titleabbrev>
|
|
++++
|
|
|
|
experimental[] Retrieve all {kib} spaces.
|
|
|
|
[[spaces-api-get-all-request]]
|
|
==== Request
|
|
|
|
`GET <kibana host>:<port>/api/spaces/space`
|
|
|
|
[[spaces-api-get-all-query-params]]
|
|
==== Query parameters
|
|
|
|
`purpose`::
|
|
(Optional, string) Valid options include `any`, `copySavedObjectsIntoSpace`, and `shareSavedObjectsIntoSpace`. This determines what
|
|
authorization checks are applied to the API call. If `purpose` is not provided in the URL, the `any` purpose is used.
|
|
|
|
`include_authorized_purposes`::
|
|
(Optional, boolean) When enabled, the API will return any spaces that the user is authorized to access in any capacity, and each space
|
|
will contain the purpose(s) for which the user is authorized. This can be useful to determine which spaces a user can read but not take a
|
|
specific action in. If the Security plugin is not enabled, this will have no effect, as no authorization checks would take place.
|
|
+
|
|
NOTE: This option cannot be used in conjunction with `purpose`.
|
|
|
|
[[spaces-api-get-all-response-codes]]
|
|
==== Response code
|
|
|
|
`200`::
|
|
Indicates a successful call.
|
|
|
|
[[spaces-api-get-all-example]]
|
|
==== Examples
|
|
|
|
[[spaces-api-get-all-example-1]]
|
|
===== Default options
|
|
|
|
Retrieve all spaces without specifying any options:
|
|
|
|
[source,sh]
|
|
--------------------------------------------------
|
|
$ curl -X GET api/spaces/space
|
|
--------------------------------------------------
|
|
|
|
The API returns the following:
|
|
|
|
[source,sh]
|
|
--------------------------------------------------
|
|
[
|
|
{
|
|
"id": "default",
|
|
"name": "Default",
|
|
"description" : "This is the Default Space",
|
|
"disabledFeatures": [],
|
|
"imageUrl": "",
|
|
"_reserved": true
|
|
},
|
|
{
|
|
"id": "marketing",
|
|
"name": "Marketing",
|
|
"description" : "This is the Marketing Space",
|
|
"color": "#aabbcc",
|
|
"disabledFeatures": ["apm"],
|
|
"initials": "MK",
|
|
"imageUrl": "data:image/png;base64,iVBORw0KGgoAAAANSU"
|
|
},
|
|
{
|
|
"id": "sales",
|
|
"name": "Sales",
|
|
"initials": "MK",
|
|
"disabledFeatures": ["discover"],
|
|
"imageUrl": "",
|
|
"solution": "oblt"
|
|
}
|
|
]
|
|
--------------------------------------------------
|
|
|
|
[[spaces-api-get-all-example-2]]
|
|
===== Custom options
|
|
|
|
The user has read-only access to the Sales space. Retrieve all spaces and specify options:
|
|
|
|
[source,sh]
|
|
--------------------------------------------------
|
|
$ curl -X GET api/spaces/space?purpose=shareSavedObjectsIntoSpace&include_authorized_purposes=true
|
|
--------------------------------------------------
|
|
|
|
The API returns the following:
|
|
|
|
[source,sh]
|
|
--------------------------------------------------
|
|
[
|
|
{
|
|
"id": "default",
|
|
"name": "Default",
|
|
"description" : "This is the Default Space",
|
|
"disabledFeatures": [],
|
|
"imageUrl": "",
|
|
"_reserved": true,
|
|
"authorizedPurposes": {
|
|
"any": true,
|
|
"copySavedObjectsIntoSpace": true,
|
|
"findSavedObjects": true,
|
|
"shareSavedObjectsIntoSpace": true,
|
|
}
|
|
},
|
|
{
|
|
"id": "marketing",
|
|
"name": "Marketing",
|
|
"description" : "This is the Marketing Space",
|
|
"color": "#aabbcc",
|
|
"disabledFeatures": ["apm"],
|
|
"initials": "MK",
|
|
"imageUrl": "data:image/png;base64,iVBORw0KGgoAAAANSU",
|
|
"authorizedPurposes": {
|
|
"any": true,
|
|
"copySavedObjectsIntoSpace": true,
|
|
"findSavedObjects": true,
|
|
"shareSavedObjectsIntoSpace": true,
|
|
}
|
|
},
|
|
{
|
|
"id": "sales",
|
|
"name": "Sales",
|
|
"initials": "MK",
|
|
"disabledFeatures": ["discover"],
|
|
"imageUrl": "",
|
|
"authorizedPurposes": {
|
|
"any": true,
|
|
"copySavedObjectsIntoSpace": false,
|
|
"findSavedObjects": true,
|
|
"shareSavedObjectsIntoSpace": false,
|
|
}
|
|
}
|
|
]
|
|
--------------------------------------------------
|