mirror of
https://github.com/elastic/kibana.git
synced 2025-04-24 17:59:23 -04:00
Merge remote-tracking branch 'upstream/7.x' into 7.x
This commit is contained in:
commit
bf7ca4df10
1919 changed files with 60190 additions and 26875 deletions
|
@ -5,6 +5,7 @@ set -e
|
|||
# move to Kibana root
|
||||
cd "$(dirname "$0")/.."
|
||||
|
||||
source src/dev/ci_setup/load_env_keys.sh
|
||||
source src/dev/ci_setup/extract_bootstrap_cache.sh
|
||||
source src/dev/ci_setup/setup.sh
|
||||
source src/dev/ci_setup/checkout_sibling_es.sh
|
||||
|
|
|
@ -25,6 +25,8 @@ bower_components
|
|||
/packages/kbn-ui-framework/dist
|
||||
/packages/kbn-ui-framework/doc_site/build
|
||||
/packages/kbn-ui-framework/generator-kui/*/templates/
|
||||
/packages/kbn-test/src/functional_test_runner/__tests__/fixtures/
|
||||
/packages/kbn-test/src/functional_test_runner/lib/config/__tests__/fixtures/
|
||||
/x-pack/legacy/plugins/maps/public/vendor/**
|
||||
/x-pack/coverage
|
||||
/x-pack/build
|
||||
|
|
|
@ -186,8 +186,10 @@ module.exports = {
|
|||
'x-pack/legacy/plugins/apm/**/*.js',
|
||||
'test/*/config.ts',
|
||||
'test/visual_regression/tests/**/*',
|
||||
'x-pack/test/visual_regression/tests/**/*',
|
||||
'x-pack/test/*/config.ts',
|
||||
'x-pack/test/*/{tests,test_suites,apis,apps}/**/*',
|
||||
'x-pack/test/*/*config.*ts',
|
||||
'x-pack/test/saved_object_api_integration/*/apis/**/*',
|
||||
'x-pack/test/ui_capabilities/*/tests/**/*',
|
||||
],
|
||||
rules: {
|
||||
'import/no-default-export': 'off',
|
||||
|
|
|
@ -15,14 +15,14 @@
|
|||
"embeddableApi": "src/legacy/core_plugins/embeddable_api",
|
||||
"kbnVislibVisTypes": "src/legacy/core_plugins/kbn_vislib_vis_types",
|
||||
"visTypeMarkdown": "src/legacy/core_plugins/vis_type_markdown",
|
||||
"metricVis": "src/legacy/core_plugins/metric_vis",
|
||||
"visTypeMetric": "src/legacy/core_plugins/vis_type_metric",
|
||||
"visTypeVega": "src/legacy/core_plugins/vis_type_vega",
|
||||
"visTypeTable": "src/legacy/core_plugins/vis_type_table",
|
||||
"regionMap": "src/legacy/core_plugins/region_map",
|
||||
"statusPage": "src/legacy/core_plugins/status_page",
|
||||
"tileMap": "src/legacy/core_plugins/tile_map",
|
||||
"timelion": "src/legacy/core_plugins/timelion",
|
||||
"tagCloud": "src/legacy/core_plugins/tagcloud",
|
||||
"visTypeTagCloud": "src/legacy/core_plugins/vis_type_tagcloud",
|
||||
"tsvb": "src/legacy/core_plugins/metrics",
|
||||
"kbnESQuery": "packages/kbn-es-query",
|
||||
"xpack.actions": "x-pack/legacy/plugins/actions",
|
||||
|
@ -58,7 +58,8 @@
|
|||
"xpack.spaces": "x-pack/legacy/plugins/spaces",
|
||||
"xpack.upgradeAssistant": "x-pack/legacy/plugins/upgrade_assistant",
|
||||
"xpack.uptime": "x-pack/legacy/plugins/uptime",
|
||||
"xpack.watcher": "x-pack/legacy/plugins/watcher"
|
||||
"xpack.watcher": "x-pack/legacy/plugins/watcher",
|
||||
"inspector": "src/plugins/inspector"
|
||||
},
|
||||
"exclude": ["src/legacy/ui/ui_render/ui_render_mixin.js"],
|
||||
"translations": [
|
||||
|
|
33
NOTICE.txt
33
NOTICE.txt
|
@ -107,6 +107,39 @@ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
THE SOFTWARE.
|
||||
|
||||
---
|
||||
This product includes code that is adapted from mapbox-gl-js, which is
|
||||
available under a "BSD-3-Clause" license.
|
||||
https://github.com/mapbox/mapbox-gl-js/blob/master/src/util/image.js
|
||||
|
||||
Copyright (c) 2016, Mapbox
|
||||
|
||||
All rights reserved.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without modification,
|
||||
are permitted provided that the following conditions are met:
|
||||
|
||||
* Redistributions of source code must retain the above copyright notice,
|
||||
this list of conditions and the following disclaimer.
|
||||
* Redistributions in binary form must reproduce the above copyright notice,
|
||||
this list of conditions and the following disclaimer in the documentation
|
||||
and/or other materials provided with the distribution.
|
||||
* Neither the name of Mapbox GL JS nor the names of its contributors
|
||||
may be used to endorse or promote products derived from this software
|
||||
without specific prior written permission.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
|
||||
CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
|
||||
EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
||||
PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
|
||||
PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
|
||||
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
|
||||
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
---
|
||||
This product includes code that is based on facebookincubator/idx, which was
|
||||
available under a "MIT" license.
|
||||
|
|
|
@ -1209,17 +1209,23 @@ Aliases: `label`, `text`, `description`
|
|||
|
||||
Default: `""`
|
||||
|
||||
|`labelFont`
|
||||
|`style`
|
||||
|The CSS font properties for the label. For example, `font-family` or `font-weight`.
|
||||
|
||||
Default: `{font size=14 family="'Open Sans', Helvetica, Arial, sans-serif" color="#000000" align=center}`.
|
||||
|
||||
|`metricFont`
|
||||
|`style`
|
||||
|The CSS font properties for the metric. For example, `font-family` or `font-weight`.
|
||||
|
||||
Default: `{font size=48 family="'Open Sans', Helvetica, Arial, sans-serif" color="#000000" align=center lHeight=48}`.
|
||||
|
||||
|`labelFont`
|
||||
|`style`
|
||||
|The CSS font properties for the label. For example, `font-family` or `font-weight`.
|
||||
|`metricFormat`
|
||||
|
||||
Default: `{font size=14 family="'Open Sans', Helvetica, Arial, sans-serif" color="#000000" align=center}`.
|
||||
Alias: `format`
|
||||
|`string`
|
||||
|A NumeralJS format string. For example, `"0.0a"` or `"0%"`. See http://numeraljs.com/#format.
|
||||
|===
|
||||
|
||||
*Returns:* `render`
|
||||
|
|
|
@ -3,66 +3,84 @@
|
|||
|
||||
[partintro]
|
||||
--
|
||||
A Kibana _dashboard_ displays a collection of visualizations, searches, and {kibana-ref}/maps.html[maps].
|
||||
You can arrange, resize, and edit the dashboard content and then save the dashboard
|
||||
so you can share it.
|
||||
|
||||
A {kib} _dashboard_ is a collection of visualizations, searches, and
|
||||
maps, typically in real-time. Dashboards provide
|
||||
at-a-glance insights into your data and enable you to drill down into details.
|
||||
|
||||
To start working with dashboards, click *Dashboard* in the side navigation.
|
||||
With *Dashboard*, you can:
|
||||
|
||||
* <<dashboard-create-new-dashboard, Create a dashboard>>
|
||||
* <<customizing-your-dashboard, Arrange dashboard elements>>
|
||||
* <<sharing-dashboards, Share a dashboard>>
|
||||
* <<import-dashboards, Import and export dashboards>>
|
||||
* <<viewing-detailed-information, Inspect and edit dashboard elements>>
|
||||
|
||||
|
||||
[role="screenshot"]
|
||||
image:images/Dashboard_example.png[Example dashboard]
|
||||
|
||||
--
|
||||
|
||||
[[dashboard-getting-started]]
|
||||
== Building a Dashboard
|
||||
|
||||
If you haven't yet indexed data into {es} or created an index pattern,
|
||||
you'll be prompted to do so as you follow the steps for creating a dashboard.
|
||||
Or, you can use one of the prebuilt sample data sets, available from the
|
||||
Kibana home page.
|
||||
|
||||
[float]
|
||||
[[dashboard-read-only-access]]
|
||||
=== [xpack]#Read only access#
|
||||
When you have insufficient privileges to create or save dashboards, the following
|
||||
indicator in Kibana will be displayed. The buttons to create new dashboards or edit
|
||||
existing dashboard won't be visible. For more information on granting access to
|
||||
Kibana see <<xpack-security-authorization>>.
|
||||
If you see
|
||||
the read-only icon in the application header,
|
||||
then you don't have sufficient privileges to create and save dashboards. The buttons to create and edit
|
||||
dashboards are not visible. For more information, see <<xpack-security-authorization>>.
|
||||
|
||||
[role="screenshot"]
|
||||
image::images/dashboard-read-only-badge.png[Example of Dashboard's read only access indicator in Kibana's header]
|
||||
|
||||
[float]
|
||||
[[dashboard-create-new-dashboard]]
|
||||
=== Creating a new Dashboard
|
||||
[[dashboard-getting-started]]
|
||||
=== Interact with dashboards
|
||||
|
||||
. In the side navigation, click *Dashboard*.
|
||||
When you open *Dashhboard*, you're presented an overview of your dashboards.
|
||||
If you don't have any dashboards, you can add
|
||||
<<add-sample-data, sample data sets>>,
|
||||
which include pre-built dashboards.
|
||||
|
||||
Once you open a dashboard, you can filter the data
|
||||
by entering a search query, changing the time filter, or clicking
|
||||
in the visualizations, searches, and maps. If a dashboard element has a stored query,
|
||||
both queries are applied.
|
||||
|
||||
--
|
||||
|
||||
[[dashboard-create-new-dashboard]]
|
||||
== Create a dashboard
|
||||
|
||||
To create a dashboard, you must have data indexed into {es}, an index pattern
|
||||
to retrieve the data from {es}, and
|
||||
visualizations, saved searches, or maps. If these don't exist, you're prompted to
|
||||
add them as you create the dashboard.
|
||||
|
||||
For an end-to-end example, see <<tutorial-build-dashboard, Building your own dashboard>>.
|
||||
|
||||
. Open *Dashboard.*
|
||||
. Click *Create new dashboard.*
|
||||
. Click *Add*.
|
||||
. [[adding-visualizations-to-a-dashboard]]Use *Add Panels* to add visualizations
|
||||
and saved searches to the dashboard. If you have a large number of
|
||||
visualizations, you can filter the lists.
|
||||
. Use *Add panels* to add elements to the dashboard.
|
||||
+
|
||||
The visualizations, saved searches, and maps
|
||||
are stored in panels that you can move and resize. A
|
||||
menu in the upper right of the panel has options for customizing
|
||||
the panel. You can add elements from
|
||||
multiple indices, and the same element can appear in multiple dashboards.
|
||||
+
|
||||
[role="screenshot"]
|
||||
image:images/Dashboard_add_visualization.png[Example add visualization to dashboard]
|
||||
|
||||
. [[saving-dashboards]]When you're finished adding and arranging the panels,
|
||||
go to the menu bar and click *Save*.
|
||||
|
||||
. In *Save Dashboard*, enter a dashboard title and optionally a description.
|
||||
|
||||
. To store the time period specified in the time filter, enable *Store time
|
||||
with dashboard*.
|
||||
|
||||
. Click *Save*.
|
||||
|
||||
[[loading-a-saved-dashboard]]
|
||||
To import, export, and delete dashboards, see <<managing-saved-objects>>.
|
||||
. When you're finished adding and arranging the panels,
|
||||
*Save* the dashboard.
|
||||
|
||||
[float]
|
||||
[[customizing-your-dashboard]]
|
||||
== Arranging Dashboard Elements
|
||||
=== Arrange dashboard elements
|
||||
|
||||
The visualizations and searches in a dashboard are stored in panels that you can move,
|
||||
resize, edit, and delete. To start editing, click *Edit* in the menu bar.
|
||||
In *Edit* mode, you can move, resize, customize, and delete panels to suit your needs.
|
||||
|
||||
[[moving-containers]]
|
||||
* To move a panel, click and hold the panel header and drag to the new location.
|
||||
|
@ -71,53 +89,60 @@ resize, edit, and delete. To start editing, click *Edit* in the menu bar.
|
|||
* To resize a panel, click the resize control on the lower right and drag
|
||||
to the new dimensions.
|
||||
|
||||
[[removing-containers]]
|
||||
Additional commands for managing the panel and its contents
|
||||
are in the gear menu in the upper right.
|
||||
* To toggle the use of margins and panel titles, use the *Options* menu in the upper left.
|
||||
|
||||
[role="screenshot"]
|
||||
image:images/Dashboard_Resize_Menu.png[Example dashboard]
|
||||
|
||||
NOTE: Deleting a panel from a
|
||||
* To delete a panel, open the panel menu and select *Delete from dashboard.* Deleting a panel from a
|
||||
dashboard does *not* delete the saved visualization or search.
|
||||
|
||||
[[viewing-detailed-information]]
|
||||
== Inspecting a Visualization from the Dashboard
|
||||
|
||||
Many visualizations allow you to inspect the data and requests behind the
|
||||
visualization.
|
||||
|
||||
In the dashboard, expand the visualization's panel menu (or gear menu if in
|
||||
*Edit* mode) and select *Inspect*.
|
||||
|
||||
The initial view shows the underlying data for the visualization. To view the
|
||||
requests that were made for the visualization, choose *Requests* from the *View*
|
||||
menu.
|
||||
|
||||
The views you'll see depend on the element that you inspect.
|
||||
|
||||
[role="screenshot"]
|
||||
image:images/Dashboard_visualization_data.png[Example of visualization data]
|
||||
|
||||
|
||||
|
||||
[float]
|
||||
[[sharing-dashboards]]
|
||||
== Sharing a Dashboard
|
||||
|
||||
You can either share a direct link to a Kibana dashboard,
|
||||
or embed the dashboard in a web page. Users must have Kibana access
|
||||
to view an embedded dashboard.
|
||||
=== Share a dashboard
|
||||
|
||||
[[embedding-dashboards]]
|
||||
When you've finished your dashboard, you can share it with your teammates.
|
||||
From the *Share* menu, you can:
|
||||
|
||||
. Open the dashboard you want to share.
|
||||
. In the menu bar, click *Share*.
|
||||
. Copy the link you want to share or the iframe you want to embed. You can
|
||||
share the live dashboard or a static snapshot of the current point in time.
|
||||
* Embed the code in a web page. Users must have Kibana access
|
||||
to view an embedded dashboard.
|
||||
* Share a direct link to a {kib} dashboard
|
||||
* Generate a PDF report
|
||||
* Generate a PNG report
|
||||
|
||||
TIP: You can create a link to a dashboard by title by doing this: +
|
||||
`${domain}/${basepath?}/app/kibana#/dashboards?title=${yourdashboardtitle}`
|
||||
|
||||
TIP: When sharing a link to a dashboard snapshot, use the *Short URL*. Snapshot
|
||||
URLs are long and can be problematic for Internet Explorer and other
|
||||
tools. To create a short URL, you must have write access to {kib}.
|
||||
tools. To create a short URL, you must have write access to {kib}.
|
||||
|
||||
[float]
|
||||
[[import-dashboards]]
|
||||
=== Import and export dashboards
|
||||
|
||||
To import and export dashboards, go to *Management > Saved Objects*. For details,
|
||||
see <<managing-saved-objects, Managing saved objects>>.
|
||||
|
||||
[float]
|
||||
[[viewing-detailed-information]]
|
||||
=== Inspect and edit elements
|
||||
|
||||
Many dashboard elements allow you to drill down into the data and requests
|
||||
behind the element. Open the menu in the upper right of the panel and select *Inspect*.
|
||||
The views you see depend on the element that you inspect.
|
||||
|
||||
[role="screenshot"]
|
||||
image:images/Dashboard_inspect.png[Inspect in dashboard]
|
||||
|
||||
To open an element for editing, put the dashboard in *Edit* mode,
|
||||
and then select *Edit* from the panel menu. The changes you make appear in
|
||||
every dashboard that uses the element.
|
||||
|
||||
include::management/dashboard_only_mode/index.asciidoc[]
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -66,6 +66,15 @@ To accomplish this the `serve` task does a few things:
|
|||
- redirects from `/{any}/app/{appName}` to `/{randomBasePath}/app/{appName}` so that refreshes should work
|
||||
- proxies all requests starting with `/{randomBasePath}/` to the Kibana server
|
||||
|
||||
If you're writing scripts that interact with the Kibana API, the base path proxy will likely
|
||||
make this difficult. To bypass the base path proxy for a single request, prefix urls with
|
||||
`__UNSAFE_bypassBasePath` and the request will be routed to the development Kibana server.
|
||||
|
||||
["source","shell"]
|
||||
-----------
|
||||
curl "http://elastic:changeme@localhost:5601/__UNSAFE_bypassBasePath/api/status"
|
||||
-----------
|
||||
|
||||
This proxy can sometimes have unintended side effects in development, so when
|
||||
needed you can opt out by passing the `--no-base-path` flag to the `serve` task
|
||||
or `yarn start`.
|
||||
|
|
|
@ -95,8 +95,10 @@ export type VizRenderer = (context: VizRenderContext, domElement: HTMLElement) =
|
|||
class VizRenderingPlugin {
|
||||
private readonly vizRenderers = new Map<string, ((domElement: HTMLElement) => () => void)>();
|
||||
|
||||
constructor(private readonly initContext: PluginInitializerContext) {}
|
||||
|
||||
setup(core) {
|
||||
this.contextContainer = core.createContextContainer<
|
||||
this.contextContainer = core.context.createContextContainer<
|
||||
VizRenderContext,
|
||||
ReturnType<VizRenderer>,
|
||||
[HTMLElement]
|
||||
|
@ -110,8 +112,8 @@ class VizRenderingPlugin {
|
|||
}
|
||||
|
||||
start(core) {
|
||||
// Register the core context available to all renderers. Use the VizRendererContext's pluginId as the first arg.
|
||||
this.contextContainer.registerContext('viz_rendering', 'core', () => ({
|
||||
// Register the core context available to all renderers. Use the VizRendererContext's opaqueId as the first arg.
|
||||
this.contextContainer.registerContext(this.initContext.opaqueId, 'core', () => ({
|
||||
i18n: core.i18n,
|
||||
uiSettings: core.uiSettings
|
||||
}));
|
||||
|
|
|
@ -23,5 +23,6 @@ export interface CoreStart
|
|||
| [i18n](./kibana-plugin-public.corestart.i18n.md) | <code>I18nStart</code> | [I18nStart](./kibana-plugin-public.i18nstart.md) |
|
||||
| [notifications](./kibana-plugin-public.corestart.notifications.md) | <code>NotificationsStart</code> | [NotificationsStart](./kibana-plugin-public.notificationsstart.md) |
|
||||
| [overlays](./kibana-plugin-public.corestart.overlays.md) | <code>OverlayStart</code> | [OverlayStart](./kibana-plugin-public.overlaystart.md) |
|
||||
| [savedObjects](./kibana-plugin-public.corestart.savedobjects.md) | <code>SavedObjectsStart</code> | [SavedObjectsStart](./kibana-plugin-public.savedobjectsstart.md) |
|
||||
| [uiSettings](./kibana-plugin-public.corestart.uisettings.md) | <code>UiSettingsClientContract</code> | [UiSettingsClient](./kibana-plugin-public.uisettingsclient.md) |
|
||||
|
||||
|
|
|
@ -0,0 +1,13 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [CoreStart](./kibana-plugin-public.corestart.md) > [savedObjects](./kibana-plugin-public.corestart.savedobjects.md)
|
||||
|
||||
## CoreStart.savedObjects property
|
||||
|
||||
[SavedObjectsStart](./kibana-plugin-public.savedobjectsstart.md)
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
savedObjects: SavedObjectsStart;
|
||||
```
|
|
@ -14,6 +14,8 @@ The plugin integrates with the core system via lifecycle events: `setup`<!-- -->
|
|||
|
||||
| Class | Description |
|
||||
| --- | --- |
|
||||
| [SavedObjectsClient](./kibana-plugin-public.savedobjectsclient.md) | Saved Objects is Kibana's data persisentence mechanism allowing plugins to use Elasticsearch for storing plugin state. The client-side SavedObjectsClient is a thin convenience library around the SavedObjects HTTP API for interacting with Saved Objects. |
|
||||
| [SimpleSavedObject](./kibana-plugin-public.simplesavedobject.md) | This class is a very simple wrapper for SavedObjects loaded from the server with the [SavedObjectsClient](./kibana-plugin-public.savedobjectsclient.md)<!-- -->.<!-- -->It provides basic functionality for creating/saving/deleting saved objects, but doesn't include any type-specific implementations. |
|
||||
| [ToastsApi](./kibana-plugin-public.toastsapi.md) | |
|
||||
| [UiSettingsClient](./kibana-plugin-public.uisettingsclient.md) | |
|
||||
|
||||
|
@ -59,6 +61,19 @@ The plugin integrates with the core system via lifecycle events: `setup`<!-- -->
|
|||
| [OverlayStart](./kibana-plugin-public.overlaystart.md) | |
|
||||
| [Plugin](./kibana-plugin-public.plugin.md) | The interface that should be returned by a <code>PluginInitializer</code>. |
|
||||
| [PluginInitializerContext](./kibana-plugin-public.plugininitializercontext.md) | The available core services passed to a <code>PluginInitializer</code> |
|
||||
| [SavedObject](./kibana-plugin-public.savedobject.md) | |
|
||||
| [SavedObjectAttributes](./kibana-plugin-public.savedobjectattributes.md) | The data for a Saved Object is stored in the <code>attributes</code> key as either an object or an array of objects. |
|
||||
| [SavedObjectReference](./kibana-plugin-public.savedobjectreference.md) | A reference to another saved object. |
|
||||
| [SavedObjectsBaseOptions](./kibana-plugin-public.savedobjectsbaseoptions.md) | |
|
||||
| [SavedObjectsBatchResponse](./kibana-plugin-public.savedobjectsbatchresponse.md) | |
|
||||
| [SavedObjectsBulkCreateObject](./kibana-plugin-public.savedobjectsbulkcreateobject.md) | |
|
||||
| [SavedObjectsBulkCreateOptions](./kibana-plugin-public.savedobjectsbulkcreateoptions.md) | |
|
||||
| [SavedObjectsCreateOptions](./kibana-plugin-public.savedobjectscreateoptions.md) | |
|
||||
| [SavedObjectsFindOptions](./kibana-plugin-public.savedobjectsfindoptions.md) | |
|
||||
| [SavedObjectsFindResponsePublic](./kibana-plugin-public.savedobjectsfindresponsepublic.md) | Return type of the Saved Objects <code>find()</code> method.<!-- -->\*Note\*: this type is different between the Public and Server Saved Objects clients. |
|
||||
| [SavedObjectsMigrationVersion](./kibana-plugin-public.savedobjectsmigrationversion.md) | Information about the migrations that have been applied to this SavedObject. When Kibana starts up, KibanaMigrator detects outdated documents and migrates them based on this value. For each migration that has been applied, the plugin's name is used as a key and the latest migration version as the value. |
|
||||
| [SavedObjectsStart](./kibana-plugin-public.savedobjectsstart.md) | |
|
||||
| [SavedObjectsUpdateOptions](./kibana-plugin-public.savedobjectsupdateoptions.md) | |
|
||||
| [UiSettingsState](./kibana-plugin-public.uisettingsstate.md) | |
|
||||
|
||||
## Type Aliases
|
||||
|
@ -74,7 +89,10 @@ The plugin integrates with the core system via lifecycle events: `setup`<!-- -->
|
|||
| [IContextHandler](./kibana-plugin-public.icontexthandler.md) | A function registered by a plugin to perform some action. |
|
||||
| [IContextProvider](./kibana-plugin-public.icontextprovider.md) | A function that returns a context value for a specific key of given context type. |
|
||||
| [PluginInitializer](./kibana-plugin-public.plugininitializer.md) | The <code>plugin</code> export at the root of a plugin's <code>public</code> directory should conform to this interface. |
|
||||
| [PluginOpaqueId](./kibana-plugin-public.pluginopaqueid.md) | |
|
||||
| [RecursiveReadonly](./kibana-plugin-public.recursivereadonly.md) | |
|
||||
| [SavedObjectAttribute](./kibana-plugin-public.savedobjectattribute.md) | |
|
||||
| [SavedObjectsClientContract](./kibana-plugin-public.savedobjectsclientcontract.md) | SavedObjectsClientContract as implemented by the [SavedObjectsClient](./kibana-plugin-public.savedobjectsclient.md) |
|
||||
| [ToastInput](./kibana-plugin-public.toastinput.md) | |
|
||||
| [UiSettingsClientContract](./kibana-plugin-public.uisettingsclientcontract.md) | [UiSettingsClient](./kibana-plugin-public.uisettingsclient.md) |
|
||||
|
||||
|
|
|
@ -0,0 +1,12 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [PluginOpaqueId](./kibana-plugin-public.pluginopaqueid.md)
|
||||
|
||||
## PluginOpaqueId type
|
||||
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
export declare type PluginOpaqueId = symbol;
|
||||
```
|
|
@ -0,0 +1,13 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObject](./kibana-plugin-public.savedobject.md) > [attributes](./kibana-plugin-public.savedobject.attributes.md)
|
||||
|
||||
## SavedObject.attributes property
|
||||
|
||||
The data for a Saved Object is stored in the `attributes` key as either an object or an array of objects.
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
attributes: T;
|
||||
```
|
|
@ -0,0 +1,14 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObject](./kibana-plugin-public.savedobject.md) > [error](./kibana-plugin-public.savedobject.error.md)
|
||||
|
||||
## SavedObject.error property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
error?: {
|
||||
message: string;
|
||||
statusCode: number;
|
||||
};
|
||||
```
|
|
@ -0,0 +1,13 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObject](./kibana-plugin-public.savedobject.md) > [id](./kibana-plugin-public.savedobject.id.md)
|
||||
|
||||
## SavedObject.id property
|
||||
|
||||
The ID of this Saved Object, guaranteed to be unique for all objects of the same `type`
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
id: string;
|
||||
```
|
|
@ -0,0 +1,26 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObject](./kibana-plugin-public.savedobject.md)
|
||||
|
||||
## SavedObject interface
|
||||
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
export interface SavedObject<T extends SavedObjectAttributes = any>
|
||||
```
|
||||
|
||||
## Properties
|
||||
|
||||
| Property | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| [attributes](./kibana-plugin-public.savedobject.attributes.md) | <code>T</code> | The data for a Saved Object is stored in the <code>attributes</code> key as either an object or an array of objects. |
|
||||
| [error](./kibana-plugin-public.savedobject.error.md) | <code>{</code><br/><code> message: string;</code><br/><code> statusCode: number;</code><br/><code> }</code> | |
|
||||
| [id](./kibana-plugin-public.savedobject.id.md) | <code>string</code> | The ID of this Saved Object, guaranteed to be unique for all objects of the same <code>type</code> |
|
||||
| [migrationVersion](./kibana-plugin-public.savedobject.migrationversion.md) | <code>SavedObjectsMigrationVersion</code> | Information about the migrations that have been applied to this SavedObject. When Kibana starts up, KibanaMigrator detects outdated documents and migrates them based on this value. For each migration that has been applied, the plugin's name is used as a key and the latest migration version as the value. |
|
||||
| [references](./kibana-plugin-public.savedobject.references.md) | <code>SavedObjectReference[]</code> | A reference to another saved object. |
|
||||
| [type](./kibana-plugin-public.savedobject.type.md) | <code>string</code> | The type of Saved Object. Each plugin can define it's own custom Saved Object types. |
|
||||
| [updated\_at](./kibana-plugin-public.savedobject.updated_at.md) | <code>string</code> | Timestamp of the last time this document had been updated. |
|
||||
| [version](./kibana-plugin-public.savedobject.version.md) | <code>string</code> | An opaque version number which changes on each successful write operation. Can be used for implementing optimistic concurrency control. |
|
||||
|
|
@ -0,0 +1,13 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObject](./kibana-plugin-public.savedobject.md) > [migrationVersion](./kibana-plugin-public.savedobject.migrationversion.md)
|
||||
|
||||
## SavedObject.migrationVersion property
|
||||
|
||||
Information about the migrations that have been applied to this SavedObject. When Kibana starts up, KibanaMigrator detects outdated documents and migrates them based on this value. For each migration that has been applied, the plugin's name is used as a key and the latest migration version as the value.
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
migrationVersion?: SavedObjectsMigrationVersion;
|
||||
```
|
|
@ -0,0 +1,13 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObject](./kibana-plugin-public.savedobject.md) > [references](./kibana-plugin-public.savedobject.references.md)
|
||||
|
||||
## SavedObject.references property
|
||||
|
||||
A reference to another saved object.
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
references: SavedObjectReference[];
|
||||
```
|
|
@ -0,0 +1,13 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObject](./kibana-plugin-public.savedobject.md) > [type](./kibana-plugin-public.savedobject.type.md)
|
||||
|
||||
## SavedObject.type property
|
||||
|
||||
The type of Saved Object. Each plugin can define it's own custom Saved Object types.
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
type: string;
|
||||
```
|
|
@ -0,0 +1,13 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObject](./kibana-plugin-public.savedobject.md) > [updated\_at](./kibana-plugin-public.savedobject.updated_at.md)
|
||||
|
||||
## SavedObject.updated\_at property
|
||||
|
||||
Timestamp of the last time this document had been updated.
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
updated_at?: string;
|
||||
```
|
|
@ -0,0 +1,13 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObject](./kibana-plugin-public.savedobject.md) > [version](./kibana-plugin-public.savedobject.version.md)
|
||||
|
||||
## SavedObject.version property
|
||||
|
||||
An opaque version number which changes on each successful write operation. Can be used for implementing optimistic concurrency control.
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
version?: string;
|
||||
```
|
|
@ -0,0 +1,12 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectAttribute](./kibana-plugin-public.savedobjectattribute.md)
|
||||
|
||||
## SavedObjectAttribute type
|
||||
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
export declare type SavedObjectAttribute = string | number | boolean | null | undefined | SavedObjectAttributes | SavedObjectAttributes[];
|
||||
```
|
|
@ -0,0 +1,13 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectAttributes](./kibana-plugin-public.savedobjectattributes.md)
|
||||
|
||||
## SavedObjectAttributes interface
|
||||
|
||||
The data for a Saved Object is stored in the `attributes` key as either an object or an array of objects.
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
export interface SavedObjectAttributes
|
||||
```
|
|
@ -0,0 +1,11 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectReference](./kibana-plugin-public.savedobjectreference.md) > [id](./kibana-plugin-public.savedobjectreference.id.md)
|
||||
|
||||
## SavedObjectReference.id property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
id: string;
|
||||
```
|
|
@ -0,0 +1,22 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectReference](./kibana-plugin-public.savedobjectreference.md)
|
||||
|
||||
## SavedObjectReference interface
|
||||
|
||||
A reference to another saved object.
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
export interface SavedObjectReference
|
||||
```
|
||||
|
||||
## Properties
|
||||
|
||||
| Property | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| [id](./kibana-plugin-public.savedobjectreference.id.md) | <code>string</code> | |
|
||||
| [name](./kibana-plugin-public.savedobjectreference.name.md) | <code>string</code> | |
|
||||
| [type](./kibana-plugin-public.savedobjectreference.type.md) | <code>string</code> | |
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectReference](./kibana-plugin-public.savedobjectreference.md) > [name](./kibana-plugin-public.savedobjectreference.name.md)
|
||||
|
||||
## SavedObjectReference.name property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
name: string;
|
||||
```
|
|
@ -0,0 +1,11 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectReference](./kibana-plugin-public.savedobjectreference.md) > [type](./kibana-plugin-public.savedobjectreference.type.md)
|
||||
|
||||
## SavedObjectReference.type property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
type: string;
|
||||
```
|
|
@ -0,0 +1,19 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsBaseOptions](./kibana-plugin-public.savedobjectsbaseoptions.md)
|
||||
|
||||
## SavedObjectsBaseOptions interface
|
||||
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
export interface SavedObjectsBaseOptions
|
||||
```
|
||||
|
||||
## Properties
|
||||
|
||||
| Property | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| [namespace](./kibana-plugin-public.savedobjectsbaseoptions.namespace.md) | <code>string</code> | Specify the namespace for this operation |
|
||||
|
|
@ -0,0 +1,13 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsBaseOptions](./kibana-plugin-public.savedobjectsbaseoptions.md) > [namespace](./kibana-plugin-public.savedobjectsbaseoptions.namespace.md)
|
||||
|
||||
## SavedObjectsBaseOptions.namespace property
|
||||
|
||||
Specify the namespace for this operation
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
namespace?: string;
|
||||
```
|
|
@ -0,0 +1,19 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsBatchResponse](./kibana-plugin-public.savedobjectsbatchresponse.md)
|
||||
|
||||
## SavedObjectsBatchResponse interface
|
||||
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
export interface SavedObjectsBatchResponse<T extends SavedObjectAttributes = SavedObjectAttributes>
|
||||
```
|
||||
|
||||
## Properties
|
||||
|
||||
| Property | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| [savedObjects](./kibana-plugin-public.savedobjectsbatchresponse.savedobjects.md) | <code>Array<SimpleSavedObject<T>></code> | |
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsBatchResponse](./kibana-plugin-public.savedobjectsbatchresponse.md) > [savedObjects](./kibana-plugin-public.savedobjectsbatchresponse.savedobjects.md)
|
||||
|
||||
## SavedObjectsBatchResponse.savedObjects property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
savedObjects: Array<SimpleSavedObject<T>>;
|
||||
```
|
|
@ -0,0 +1,11 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsBulkCreateObject](./kibana-plugin-public.savedobjectsbulkcreateobject.md) > [attributes](./kibana-plugin-public.savedobjectsbulkcreateobject.attributes.md)
|
||||
|
||||
## SavedObjectsBulkCreateObject.attributes property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
attributes: T;
|
||||
```
|
|
@ -0,0 +1,19 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsBulkCreateObject](./kibana-plugin-public.savedobjectsbulkcreateobject.md)
|
||||
|
||||
## SavedObjectsBulkCreateObject interface
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
export interface SavedObjectsBulkCreateObject<T extends SavedObjectAttributes = SavedObjectAttributes> extends SavedObjectsCreateOptions
|
||||
```
|
||||
|
||||
## Properties
|
||||
|
||||
| Property | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| [attributes](./kibana-plugin-public.savedobjectsbulkcreateobject.attributes.md) | <code>T</code> | |
|
||||
| [type](./kibana-plugin-public.savedobjectsbulkcreateobject.type.md) | <code>string</code> | |
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsBulkCreateObject](./kibana-plugin-public.savedobjectsbulkcreateobject.md) > [type](./kibana-plugin-public.savedobjectsbulkcreateobject.type.md)
|
||||
|
||||
## SavedObjectsBulkCreateObject.type property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
type: string;
|
||||
```
|
|
@ -0,0 +1,19 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsBulkCreateOptions](./kibana-plugin-public.savedobjectsbulkcreateoptions.md)
|
||||
|
||||
## SavedObjectsBulkCreateOptions interface
|
||||
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
export interface SavedObjectsBulkCreateOptions
|
||||
```
|
||||
|
||||
## Properties
|
||||
|
||||
| Property | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| [overwrite](./kibana-plugin-public.savedobjectsbulkcreateoptions.overwrite.md) | <code>boolean</code> | If a document with the given <code>id</code> already exists, overwrite it's contents (default=false). |
|
||||
|
|
@ -0,0 +1,13 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsBulkCreateOptions](./kibana-plugin-public.savedobjectsbulkcreateoptions.md) > [overwrite](./kibana-plugin-public.savedobjectsbulkcreateoptions.overwrite.md)
|
||||
|
||||
## SavedObjectsBulkCreateOptions.overwrite property
|
||||
|
||||
If a document with the given `id` already exists, overwrite it's contents (default=false).
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
overwrite?: boolean;
|
||||
```
|
|
@ -0,0 +1,13 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsClient](./kibana-plugin-public.savedobjectsclient.md) > [bulkCreate](./kibana-plugin-public.savedobjectsclient.bulkcreate.md)
|
||||
|
||||
## SavedObjectsClient.bulkCreate property
|
||||
|
||||
Creates multiple documents at once
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
bulkCreate: (objects?: SavedObjectsBulkCreateObject<SavedObjectAttributes>[], options?: SavedObjectsBulkCreateOptions) => Promise<SavedObjectsBatchResponse<SavedObjectAttributes>>;
|
||||
```
|
|
@ -0,0 +1,21 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsClient](./kibana-plugin-public.savedobjectsclient.md) > [bulkGet](./kibana-plugin-public.savedobjectsclient.bulkget.md)
|
||||
|
||||
## SavedObjectsClient.bulkGet property
|
||||
|
||||
Returns an array of objects by id
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
bulkGet: (objects?: {
|
||||
id: string;
|
||||
type: string;
|
||||
}[]) => Promise<SavedObjectsBatchResponse<SavedObjectAttributes>>;
|
||||
```
|
||||
|
||||
## Example
|
||||
|
||||
bulkGet(\[ { id: 'one', type: 'config' }<!-- -->, { id: 'foo', type: 'index-pattern' } \])
|
||||
|
|
@ -0,0 +1,13 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsClient](./kibana-plugin-public.savedobjectsclient.md) > [create](./kibana-plugin-public.savedobjectsclient.create.md)
|
||||
|
||||
## SavedObjectsClient.create property
|
||||
|
||||
Persists an object
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
create: <T extends SavedObjectAttributes>(type: string, attributes: T, options?: SavedObjectsCreateOptions) => Promise<SimpleSavedObject<T>>;
|
||||
```
|
|
@ -0,0 +1,13 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsClient](./kibana-plugin-public.savedobjectsclient.md) > [delete](./kibana-plugin-public.savedobjectsclient.delete.md)
|
||||
|
||||
## SavedObjectsClient.delete property
|
||||
|
||||
Deletes an object
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
delete: (type: string, id: string) => Promise<{}>;
|
||||
```
|
|
@ -0,0 +1,13 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsClient](./kibana-plugin-public.savedobjectsclient.md) > [find](./kibana-plugin-public.savedobjectsclient.find.md)
|
||||
|
||||
## SavedObjectsClient.find property
|
||||
|
||||
Search for objects
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
find: <T extends SavedObjectAttributes>(options?: Pick<SavedObjectFindOptionsServer, "search" | "type" | "defaultSearchOperator" | "searchFields" | "sortField" | "hasReference" | "page" | "perPage" | "fields">) => Promise<SavedObjectsFindResponsePublic<T>>;
|
||||
```
|
|
@ -0,0 +1,13 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsClient](./kibana-plugin-public.savedobjectsclient.md) > [get](./kibana-plugin-public.savedobjectsclient.get.md)
|
||||
|
||||
## SavedObjectsClient.get property
|
||||
|
||||
Fetches a single object
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
get: <T extends SavedObjectAttributes>(type: string, id: string) => Promise<SimpleSavedObject<T>>;
|
||||
```
|
|
@ -0,0 +1,35 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsClient](./kibana-plugin-public.savedobjectsclient.md)
|
||||
|
||||
## SavedObjectsClient class
|
||||
|
||||
Saved Objects is Kibana's data persisentence mechanism allowing plugins to use Elasticsearch for storing plugin state. The client-side SavedObjectsClient is a thin convenience library around the SavedObjects HTTP API for interacting with Saved Objects.
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
export declare class SavedObjectsClient
|
||||
```
|
||||
|
||||
## Properties
|
||||
|
||||
| Property | Modifiers | Type | Description |
|
||||
| --- | --- | --- | --- |
|
||||
| [bulkCreate](./kibana-plugin-public.savedobjectsclient.bulkcreate.md) | | <code>(objects?: SavedObjectsBulkCreateObject<SavedObjectAttributes>[], options?: SavedObjectsBulkCreateOptions) => Promise<SavedObjectsBatchResponse<SavedObjectAttributes>></code> | Creates multiple documents at once |
|
||||
| [bulkGet](./kibana-plugin-public.savedobjectsclient.bulkget.md) | | <code>(objects?: {</code><br/><code> id: string;</code><br/><code> type: string;</code><br/><code> }[]) => Promise<SavedObjectsBatchResponse<SavedObjectAttributes>></code> | Returns an array of objects by id |
|
||||
| [create](./kibana-plugin-public.savedobjectsclient.create.md) | | <code><T extends SavedObjectAttributes>(type: string, attributes: T, options?: SavedObjectsCreateOptions) => Promise<SimpleSavedObject<T>></code> | Persists an object |
|
||||
| [delete](./kibana-plugin-public.savedobjectsclient.delete.md) | | <code>(type: string, id: string) => Promise<{}></code> | Deletes an object |
|
||||
| [find](./kibana-plugin-public.savedobjectsclient.find.md) | | <code><T extends SavedObjectAttributes>(options?: Pick<SavedObjectFindOptionsServer, "search" | "type" | "defaultSearchOperator" | "searchFields" | "sortField" | "hasReference" | "page" | "perPage" | "fields">) => Promise<SavedObjectsFindResponsePublic<T>></code> | Search for objects |
|
||||
| [get](./kibana-plugin-public.savedobjectsclient.get.md) | | <code><T extends SavedObjectAttributes>(type: string, id: string) => Promise<SimpleSavedObject<T>></code> | Fetches a single object |
|
||||
|
||||
## Methods
|
||||
|
||||
| Method | Modifiers | Description |
|
||||
| --- | --- | --- |
|
||||
| [update(type, id, attributes, { version, migrationVersion, references })](./kibana-plugin-public.savedobjectsclient.update.md) | | Updates an object |
|
||||
|
||||
## Remarks
|
||||
|
||||
The constructor for this class is marked as internal. Third-party code should not call the constructor directly or create subclasses that extend the `SavedObjectsClient` class.
|
||||
|
|
@ -0,0 +1,28 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsClient](./kibana-plugin-public.savedobjectsclient.md) > [update](./kibana-plugin-public.savedobjectsclient.update.md)
|
||||
|
||||
## SavedObjectsClient.update() method
|
||||
|
||||
Updates an object
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
update<T extends SavedObjectAttributes>(type: string, id: string, attributes: T, { version, migrationVersion, references }?: SavedObjectsUpdateOptions): Promise<SimpleSavedObject<T>>;
|
||||
```
|
||||
|
||||
## Parameters
|
||||
|
||||
| Parameter | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| type | <code>string</code> | |
|
||||
| id | <code>string</code> | |
|
||||
| attributes | <code>T</code> | |
|
||||
| { version, migrationVersion, references } | <code>SavedObjectsUpdateOptions</code> | |
|
||||
|
||||
<b>Returns:</b>
|
||||
|
||||
`Promise<SimpleSavedObject<T>>`
|
||||
|
||||
|
|
@ -0,0 +1,13 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsClientContract](./kibana-plugin-public.savedobjectsclientcontract.md)
|
||||
|
||||
## SavedObjectsClientContract type
|
||||
|
||||
SavedObjectsClientContract as implemented by the [SavedObjectsClient](./kibana-plugin-public.savedobjectsclient.md)
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
export declare type SavedObjectsClientContract = PublicMethodsOf<SavedObjectsClient>;
|
||||
```
|
|
@ -0,0 +1,13 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsCreateOptions](./kibana-plugin-public.savedobjectscreateoptions.md) > [id](./kibana-plugin-public.savedobjectscreateoptions.id.md)
|
||||
|
||||
## SavedObjectsCreateOptions.id property
|
||||
|
||||
(Not recommended) Specify an id instead of having the saved objects service generate one for you.
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
id?: string;
|
||||
```
|
|
@ -0,0 +1,22 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsCreateOptions](./kibana-plugin-public.savedobjectscreateoptions.md)
|
||||
|
||||
## SavedObjectsCreateOptions interface
|
||||
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
export interface SavedObjectsCreateOptions
|
||||
```
|
||||
|
||||
## Properties
|
||||
|
||||
| Property | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| [id](./kibana-plugin-public.savedobjectscreateoptions.id.md) | <code>string</code> | (Not recommended) Specify an id instead of having the saved objects service generate one for you. |
|
||||
| [migrationVersion](./kibana-plugin-public.savedobjectscreateoptions.migrationversion.md) | <code>SavedObjectsMigrationVersion</code> | Information about the migrations that have been applied to this SavedObject. When Kibana starts up, KibanaMigrator detects outdated documents and migrates them based on this value. For each migration that has been applied, the plugin's name is used as a key and the latest migration version as the value. |
|
||||
| [overwrite](./kibana-plugin-public.savedobjectscreateoptions.overwrite.md) | <code>boolean</code> | If a document with the given <code>id</code> already exists, overwrite it's contents (default=false). |
|
||||
| [references](./kibana-plugin-public.savedobjectscreateoptions.references.md) | <code>SavedObjectReference[]</code> | |
|
||||
|
|
@ -0,0 +1,13 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsCreateOptions](./kibana-plugin-public.savedobjectscreateoptions.md) > [migrationVersion](./kibana-plugin-public.savedobjectscreateoptions.migrationversion.md)
|
||||
|
||||
## SavedObjectsCreateOptions.migrationVersion property
|
||||
|
||||
Information about the migrations that have been applied to this SavedObject. When Kibana starts up, KibanaMigrator detects outdated documents and migrates them based on this value. For each migration that has been applied, the plugin's name is used as a key and the latest migration version as the value.
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
migrationVersion?: SavedObjectsMigrationVersion;
|
||||
```
|
|
@ -0,0 +1,13 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsCreateOptions](./kibana-plugin-public.savedobjectscreateoptions.md) > [overwrite](./kibana-plugin-public.savedobjectscreateoptions.overwrite.md)
|
||||
|
||||
## SavedObjectsCreateOptions.overwrite property
|
||||
|
||||
If a document with the given `id` already exists, overwrite it's contents (default=false).
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
overwrite?: boolean;
|
||||
```
|
|
@ -0,0 +1,11 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsCreateOptions](./kibana-plugin-public.savedobjectscreateoptions.md) > [references](./kibana-plugin-public.savedobjectscreateoptions.references.md)
|
||||
|
||||
## SavedObjectsCreateOptions.references property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
references?: SavedObjectReference[];
|
||||
```
|
|
@ -0,0 +1,11 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsFindOptions](./kibana-plugin-public.savedobjectsfindoptions.md) > [defaultSearchOperator](./kibana-plugin-public.savedobjectsfindoptions.defaultsearchoperator.md)
|
||||
|
||||
## SavedObjectsFindOptions.defaultSearchOperator property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
defaultSearchOperator?: 'AND' | 'OR';
|
||||
```
|
|
@ -0,0 +1,18 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsFindOptions](./kibana-plugin-public.savedobjectsfindoptions.md) > [fields](./kibana-plugin-public.savedobjectsfindoptions.fields.md)
|
||||
|
||||
## SavedObjectsFindOptions.fields property
|
||||
|
||||
An array of fields to include in the results
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
fields?: string[];
|
||||
```
|
||||
|
||||
## Example
|
||||
|
||||
SavedObjects.find(<!-- -->{<!-- -->type: 'dashboard', fields: \['attributes.name', 'attributes.location'\]<!-- -->}<!-- -->)
|
||||
|
|
@ -0,0 +1,14 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsFindOptions](./kibana-plugin-public.savedobjectsfindoptions.md) > [hasReference](./kibana-plugin-public.savedobjectsfindoptions.hasreference.md)
|
||||
|
||||
## SavedObjectsFindOptions.hasReference property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
hasReference?: {
|
||||
type: string;
|
||||
id: string;
|
||||
};
|
||||
```
|
|
@ -0,0 +1,28 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsFindOptions](./kibana-plugin-public.savedobjectsfindoptions.md)
|
||||
|
||||
## SavedObjectsFindOptions interface
|
||||
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
export interface SavedObjectsFindOptions extends SavedObjectsBaseOptions
|
||||
```
|
||||
|
||||
## Properties
|
||||
|
||||
| Property | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| [defaultSearchOperator](./kibana-plugin-public.savedobjectsfindoptions.defaultsearchoperator.md) | <code>'AND' | 'OR'</code> | |
|
||||
| [fields](./kibana-plugin-public.savedobjectsfindoptions.fields.md) | <code>string[]</code> | An array of fields to include in the results |
|
||||
| [hasReference](./kibana-plugin-public.savedobjectsfindoptions.hasreference.md) | <code>{</code><br/><code> type: string;</code><br/><code> id: string;</code><br/><code> }</code> | |
|
||||
| [page](./kibana-plugin-public.savedobjectsfindoptions.page.md) | <code>number</code> | |
|
||||
| [perPage](./kibana-plugin-public.savedobjectsfindoptions.perpage.md) | <code>number</code> | |
|
||||
| [search](./kibana-plugin-public.savedobjectsfindoptions.search.md) | <code>string</code> | Search documents using the Elasticsearch Simple Query String syntax. See Elasticsearch Simple Query String <code>query</code> argument for more information |
|
||||
| [searchFields](./kibana-plugin-public.savedobjectsfindoptions.searchfields.md) | <code>string[]</code> | The fields to perform the parsed query against. See Elasticsearch Simple Query String <code>fields</code> argument for more information |
|
||||
| [sortField](./kibana-plugin-public.savedobjectsfindoptions.sortfield.md) | <code>string</code> | |
|
||||
| [sortOrder](./kibana-plugin-public.savedobjectsfindoptions.sortorder.md) | <code>string</code> | |
|
||||
| [type](./kibana-plugin-public.savedobjectsfindoptions.type.md) | <code>string | string[]</code> | |
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsFindOptions](./kibana-plugin-public.savedobjectsfindoptions.md) > [page](./kibana-plugin-public.savedobjectsfindoptions.page.md)
|
||||
|
||||
## SavedObjectsFindOptions.page property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
page?: number;
|
||||
```
|
|
@ -0,0 +1,11 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsFindOptions](./kibana-plugin-public.savedobjectsfindoptions.md) > [perPage](./kibana-plugin-public.savedobjectsfindoptions.perpage.md)
|
||||
|
||||
## SavedObjectsFindOptions.perPage property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
perPage?: number;
|
||||
```
|
|
@ -0,0 +1,13 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsFindOptions](./kibana-plugin-public.savedobjectsfindoptions.md) > [search](./kibana-plugin-public.savedobjectsfindoptions.search.md)
|
||||
|
||||
## SavedObjectsFindOptions.search property
|
||||
|
||||
Search documents using the Elasticsearch Simple Query String syntax. See Elasticsearch Simple Query String `query` argument for more information
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
search?: string;
|
||||
```
|
|
@ -0,0 +1,13 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsFindOptions](./kibana-plugin-public.savedobjectsfindoptions.md) > [searchFields](./kibana-plugin-public.savedobjectsfindoptions.searchfields.md)
|
||||
|
||||
## SavedObjectsFindOptions.searchFields property
|
||||
|
||||
The fields to perform the parsed query against. See Elasticsearch Simple Query String `fields` argument for more information
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
searchFields?: string[];
|
||||
```
|
|
@ -0,0 +1,11 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsFindOptions](./kibana-plugin-public.savedobjectsfindoptions.md) > [sortField](./kibana-plugin-public.savedobjectsfindoptions.sortfield.md)
|
||||
|
||||
## SavedObjectsFindOptions.sortField property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
sortField?: string;
|
||||
```
|
|
@ -0,0 +1,11 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsFindOptions](./kibana-plugin-public.savedobjectsfindoptions.md) > [sortOrder](./kibana-plugin-public.savedobjectsfindoptions.sortorder.md)
|
||||
|
||||
## SavedObjectsFindOptions.sortOrder property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
sortOrder?: string;
|
||||
```
|
|
@ -0,0 +1,11 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsFindOptions](./kibana-plugin-public.savedobjectsfindoptions.md) > [type](./kibana-plugin-public.savedobjectsfindoptions.type.md)
|
||||
|
||||
## SavedObjectsFindOptions.type property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
type?: string | string[];
|
||||
```
|
|
@ -0,0 +1,24 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsFindResponsePublic](./kibana-plugin-public.savedobjectsfindresponsepublic.md)
|
||||
|
||||
## SavedObjectsFindResponsePublic interface
|
||||
|
||||
Return type of the Saved Objects `find()` method.
|
||||
|
||||
\*Note\*: this type is different between the Public and Server Saved Objects clients.
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
export interface SavedObjectsFindResponsePublic<T extends SavedObjectAttributes = SavedObjectAttributes> extends SavedObjectsBatchResponse<T>
|
||||
```
|
||||
|
||||
## Properties
|
||||
|
||||
| Property | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| [page](./kibana-plugin-public.savedobjectsfindresponsepublic.page.md) | <code>number</code> | |
|
||||
| [perPage](./kibana-plugin-public.savedobjectsfindresponsepublic.perpage.md) | <code>number</code> | |
|
||||
| [total](./kibana-plugin-public.savedobjectsfindresponsepublic.total.md) | <code>number</code> | |
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsFindResponsePublic](./kibana-plugin-public.savedobjectsfindresponsepublic.md) > [page](./kibana-plugin-public.savedobjectsfindresponsepublic.page.md)
|
||||
|
||||
## SavedObjectsFindResponsePublic.page property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
page: number;
|
||||
```
|
|
@ -0,0 +1,11 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsFindResponsePublic](./kibana-plugin-public.savedobjectsfindresponsepublic.md) > [perPage](./kibana-plugin-public.savedobjectsfindresponsepublic.perpage.md)
|
||||
|
||||
## SavedObjectsFindResponsePublic.perPage property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
perPage: number;
|
||||
```
|
|
@ -0,0 +1,11 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsFindResponsePublic](./kibana-plugin-public.savedobjectsfindresponsepublic.md) > [total](./kibana-plugin-public.savedobjectsfindresponsepublic.total.md)
|
||||
|
||||
## SavedObjectsFindResponsePublic.total property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
total: number;
|
||||
```
|
|
@ -0,0 +1,18 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsMigrationVersion](./kibana-plugin-public.savedobjectsmigrationversion.md)
|
||||
|
||||
## SavedObjectsMigrationVersion interface
|
||||
|
||||
Information about the migrations that have been applied to this SavedObject. When Kibana starts up, KibanaMigrator detects outdated documents and migrates them based on this value. For each migration that has been applied, the plugin's name is used as a key and the latest migration version as the value.
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
export interface SavedObjectsMigrationVersion
|
||||
```
|
||||
|
||||
## Example
|
||||
|
||||
migrationVersion: { dashboard: '7.1.1', space: '6.6.6', }
|
||||
|
|
@ -0,0 +1,13 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsStart](./kibana-plugin-public.savedobjectsstart.md) > [client](./kibana-plugin-public.savedobjectsstart.client.md)
|
||||
|
||||
## SavedObjectsStart.client property
|
||||
|
||||
[SavedObjectsClient](./kibana-plugin-public.savedobjectsclient.md)
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
client: SavedObjectsClientContract;
|
||||
```
|
|
@ -0,0 +1,19 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsStart](./kibana-plugin-public.savedobjectsstart.md)
|
||||
|
||||
## SavedObjectsStart interface
|
||||
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
export interface SavedObjectsStart
|
||||
```
|
||||
|
||||
## Properties
|
||||
|
||||
| Property | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| [client](./kibana-plugin-public.savedobjectsstart.client.md) | <code>SavedObjectsClientContract</code> | [SavedObjectsClient](./kibana-plugin-public.savedobjectsclient.md) |
|
||||
|
|
@ -0,0 +1,21 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsUpdateOptions](./kibana-plugin-public.savedobjectsupdateoptions.md)
|
||||
|
||||
## SavedObjectsUpdateOptions interface
|
||||
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
export interface SavedObjectsUpdateOptions
|
||||
```
|
||||
|
||||
## Properties
|
||||
|
||||
| Property | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| [migrationVersion](./kibana-plugin-public.savedobjectsupdateoptions.migrationversion.md) | <code>SavedObjectsMigrationVersion</code> | Information about the migrations that have been applied to this SavedObject. When Kibana starts up, KibanaMigrator detects outdated documents and migrates them based on this value. For each migration that has been applied, the plugin's name is used as a key and the latest migration version as the value. |
|
||||
| [references](./kibana-plugin-public.savedobjectsupdateoptions.references.md) | <code>SavedObjectReference[]</code> | |
|
||||
| [version](./kibana-plugin-public.savedobjectsupdateoptions.version.md) | <code>string</code> | |
|
||||
|
|
@ -0,0 +1,13 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsUpdateOptions](./kibana-plugin-public.savedobjectsupdateoptions.md) > [migrationVersion](./kibana-plugin-public.savedobjectsupdateoptions.migrationversion.md)
|
||||
|
||||
## SavedObjectsUpdateOptions.migrationVersion property
|
||||
|
||||
Information about the migrations that have been applied to this SavedObject. When Kibana starts up, KibanaMigrator detects outdated documents and migrates them based on this value. For each migration that has been applied, the plugin's name is used as a key and the latest migration version as the value.
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
migrationVersion?: SavedObjectsMigrationVersion;
|
||||
```
|
|
@ -0,0 +1,11 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsUpdateOptions](./kibana-plugin-public.savedobjectsupdateoptions.md) > [references](./kibana-plugin-public.savedobjectsupdateoptions.references.md)
|
||||
|
||||
## SavedObjectsUpdateOptions.references property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
references?: SavedObjectReference[];
|
||||
```
|
|
@ -0,0 +1,11 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SavedObjectsUpdateOptions](./kibana-plugin-public.savedobjectsupdateoptions.md) > [version](./kibana-plugin-public.savedobjectsupdateoptions.version.md)
|
||||
|
||||
## SavedObjectsUpdateOptions.version property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
version?: string;
|
||||
```
|
|
@ -0,0 +1,21 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SimpleSavedObject](./kibana-plugin-public.simplesavedobject.md) > [(constructor)](./kibana-plugin-public.simplesavedobject.(constructor).md)
|
||||
|
||||
## SimpleSavedObject.(constructor)
|
||||
|
||||
Constructs a new instance of the `SimpleSavedObject` class
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
constructor(client: SavedObjectsClient, { id, type, version, attributes, error, references, migrationVersion }: SavedObjectType<T>);
|
||||
```
|
||||
|
||||
## Parameters
|
||||
|
||||
| Parameter | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| client | <code>SavedObjectsClient</code> | |
|
||||
| { id, type, version, attributes, error, references, migrationVersion } | <code>SavedObjectType<T></code> | |
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SimpleSavedObject](./kibana-plugin-public.simplesavedobject.md) > [\_version](./kibana-plugin-public.simplesavedobject._version.md)
|
||||
|
||||
## SimpleSavedObject.\_version property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
_version?: SavedObjectType<T>['version'];
|
||||
```
|
|
@ -0,0 +1,11 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SimpleSavedObject](./kibana-plugin-public.simplesavedobject.md) > [attributes](./kibana-plugin-public.simplesavedobject.attributes.md)
|
||||
|
||||
## SimpleSavedObject.attributes property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
attributes: T;
|
||||
```
|
|
@ -0,0 +1,15 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SimpleSavedObject](./kibana-plugin-public.simplesavedobject.md) > [delete](./kibana-plugin-public.simplesavedobject.delete.md)
|
||||
|
||||
## SimpleSavedObject.delete() method
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
delete(): Promise<{}>;
|
||||
```
|
||||
<b>Returns:</b>
|
||||
|
||||
`Promise<{}>`
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SimpleSavedObject](./kibana-plugin-public.simplesavedobject.md) > [error](./kibana-plugin-public.simplesavedobject.error.md)
|
||||
|
||||
## SimpleSavedObject.error property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
error: SavedObjectType<T>['error'];
|
||||
```
|
|
@ -0,0 +1,22 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SimpleSavedObject](./kibana-plugin-public.simplesavedobject.md) > [get](./kibana-plugin-public.simplesavedobject.get.md)
|
||||
|
||||
## SimpleSavedObject.get() method
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
get(key: string): any;
|
||||
```
|
||||
|
||||
## Parameters
|
||||
|
||||
| Parameter | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| key | <code>string</code> | |
|
||||
|
||||
<b>Returns:</b>
|
||||
|
||||
`any`
|
||||
|
|
@ -0,0 +1,22 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SimpleSavedObject](./kibana-plugin-public.simplesavedobject.md) > [has](./kibana-plugin-public.simplesavedobject.has.md)
|
||||
|
||||
## SimpleSavedObject.has() method
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
has(key: string): boolean;
|
||||
```
|
||||
|
||||
## Parameters
|
||||
|
||||
| Parameter | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| key | <code>string</code> | |
|
||||
|
||||
<b>Returns:</b>
|
||||
|
||||
`boolean`
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SimpleSavedObject](./kibana-plugin-public.simplesavedobject.md) > [id](./kibana-plugin-public.simplesavedobject.id.md)
|
||||
|
||||
## SimpleSavedObject.id property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
id: SavedObjectType<T>['id'];
|
||||
```
|
|
@ -0,0 +1,44 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SimpleSavedObject](./kibana-plugin-public.simplesavedobject.md)
|
||||
|
||||
## SimpleSavedObject class
|
||||
|
||||
This class is a very simple wrapper for SavedObjects loaded from the server with the [SavedObjectsClient](./kibana-plugin-public.savedobjectsclient.md)<!-- -->.
|
||||
|
||||
It provides basic functionality for creating/saving/deleting saved objects, but doesn't include any type-specific implementations.
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
export declare class SimpleSavedObject<T extends SavedObjectAttributes>
|
||||
```
|
||||
|
||||
## Constructors
|
||||
|
||||
| Constructor | Modifiers | Description |
|
||||
| --- | --- | --- |
|
||||
| [(constructor)(client, { id, type, version, attributes, error, references, migrationVersion })](./kibana-plugin-public.simplesavedobject.(constructor).md) | | Constructs a new instance of the <code>SimpleSavedObject</code> class |
|
||||
|
||||
## Properties
|
||||
|
||||
| Property | Modifiers | Type | Description |
|
||||
| --- | --- | --- | --- |
|
||||
| [\_version](./kibana-plugin-public.simplesavedobject._version.md) | | <code>SavedObjectType<T>['version']</code> | |
|
||||
| [attributes](./kibana-plugin-public.simplesavedobject.attributes.md) | | <code>T</code> | |
|
||||
| [error](./kibana-plugin-public.simplesavedobject.error.md) | | <code>SavedObjectType<T>['error']</code> | |
|
||||
| [id](./kibana-plugin-public.simplesavedobject.id.md) | | <code>SavedObjectType<T>['id']</code> | |
|
||||
| [migrationVersion](./kibana-plugin-public.simplesavedobject.migrationversion.md) | | <code>SavedObjectType<T>['migrationVersion']</code> | |
|
||||
| [references](./kibana-plugin-public.simplesavedobject.references.md) | | <code>SavedObjectType<T>['references']</code> | |
|
||||
| [type](./kibana-plugin-public.simplesavedobject.type.md) | | <code>SavedObjectType<T>['type']</code> | |
|
||||
|
||||
## Methods
|
||||
|
||||
| Method | Modifiers | Description |
|
||||
| --- | --- | --- |
|
||||
| [delete()](./kibana-plugin-public.simplesavedobject.delete.md) | | |
|
||||
| [get(key)](./kibana-plugin-public.simplesavedobject.get.md) | | |
|
||||
| [has(key)](./kibana-plugin-public.simplesavedobject.has.md) | | |
|
||||
| [save()](./kibana-plugin-public.simplesavedobject.save.md) | | |
|
||||
| [set(key, value)](./kibana-plugin-public.simplesavedobject.set.md) | | |
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SimpleSavedObject](./kibana-plugin-public.simplesavedobject.md) > [migrationVersion](./kibana-plugin-public.simplesavedobject.migrationversion.md)
|
||||
|
||||
## SimpleSavedObject.migrationVersion property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
migrationVersion: SavedObjectType<T>['migrationVersion'];
|
||||
```
|
|
@ -0,0 +1,11 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SimpleSavedObject](./kibana-plugin-public.simplesavedobject.md) > [references](./kibana-plugin-public.simplesavedobject.references.md)
|
||||
|
||||
## SimpleSavedObject.references property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
references: SavedObjectType<T>['references'];
|
||||
```
|
|
@ -0,0 +1,15 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SimpleSavedObject](./kibana-plugin-public.simplesavedobject.md) > [save](./kibana-plugin-public.simplesavedobject.save.md)
|
||||
|
||||
## SimpleSavedObject.save() method
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
save(): Promise<SimpleSavedObject<T>>;
|
||||
```
|
||||
<b>Returns:</b>
|
||||
|
||||
`Promise<SimpleSavedObject<T>>`
|
||||
|
|
@ -0,0 +1,23 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SimpleSavedObject](./kibana-plugin-public.simplesavedobject.md) > [set](./kibana-plugin-public.simplesavedobject.set.md)
|
||||
|
||||
## SimpleSavedObject.set() method
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
set(key: string, value: any): T;
|
||||
```
|
||||
|
||||
## Parameters
|
||||
|
||||
| Parameter | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| key | <code>string</code> | |
|
||||
| value | <code>any</code> | |
|
||||
|
||||
<b>Returns:</b>
|
||||
|
||||
`T`
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [SimpleSavedObject](./kibana-plugin-public.simplesavedobject.md) > [type](./kibana-plugin-public.simplesavedobject.type.md)
|
||||
|
||||
## SimpleSavedObject.type property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
type: SavedObjectType<T>['type'];
|
||||
```
|
|
@ -8,5 +8,5 @@
|
|||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
export declare type AuthenticationHandler = (request: KibanaRequest, t: AuthToolkit) => AuthResult | Promise<AuthResult>;
|
||||
export declare type AuthenticationHandler = (request: KibanaRequest, response: LifecycleResponseFactory, toolkit: AuthToolkit) => AuthResult | KibanaResponse | Promise<AuthResult | KibanaResponse>;
|
||||
```
|
||||
|
|
|
@ -0,0 +1,22 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-server](./kibana-plugin-server.md) > [AuthStatus](./kibana-plugin-server.authstatus.md)
|
||||
|
||||
## AuthStatus enum
|
||||
|
||||
Status indicating an outcome of the authentication.
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
export declare enum AuthStatus
|
||||
```
|
||||
|
||||
## Enumeration Members
|
||||
|
||||
| Member | Value | Description |
|
||||
| --- | --- | --- |
|
||||
| authenticated | <code>"authenticated"</code> | <code>auth</code> interceptor successfully authenticated a user |
|
||||
| unauthenticated | <code>"unauthenticated"</code> | <code>auth</code> interceptor failed user authentication |
|
||||
| unknown | <code>"unknown"</code> | <code>auth</code> interceptor has not been registered |
|
||||
|
|
@ -17,6 +17,4 @@ export interface AuthToolkit
|
|||
| Property | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| [authenticated](./kibana-plugin-server.authtoolkit.authenticated.md) | <code>(data?: AuthResultParams) => AuthResult</code> | Authentication is successful with given credentials, allow request to pass through |
|
||||
| [redirected](./kibana-plugin-server.authtoolkit.redirected.md) | <code>(url: string) => AuthResult</code> | Authentication requires to interrupt request handling and redirect to a configured url |
|
||||
| [rejected](./kibana-plugin-server.authtoolkit.rejected.md) | <code>(error: Error, options?: {</code><br/><code> statusCode?: number;</code><br/><code> }) => AuthResult</code> | Authentication is unsuccessful, fail the request with specified error. |
|
||||
|
||||
|
|
|
@ -1,13 +0,0 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-server](./kibana-plugin-server.md) > [AuthToolkit](./kibana-plugin-server.authtoolkit.md) > [redirected](./kibana-plugin-server.authtoolkit.redirected.md)
|
||||
|
||||
## AuthToolkit.redirected property
|
||||
|
||||
Authentication requires to interrupt request handling and redirect to a configured url
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
redirected: (url: string) => AuthResult;
|
||||
```
|
|
@ -1,15 +0,0 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-server](./kibana-plugin-server.md) > [AuthToolkit](./kibana-plugin-server.authtoolkit.md) > [rejected](./kibana-plugin-server.authtoolkit.rejected.md)
|
||||
|
||||
## AuthToolkit.rejected property
|
||||
|
||||
Authentication is unsuccessful, fail the request with specified error.
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
rejected: (error: Error, options?: {
|
||||
statusCode?: number;
|
||||
}) => AuthResult;
|
||||
```
|
|
@ -0,0 +1,12 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-server](./kibana-plugin-server.md) > [ConfigPath](./kibana-plugin-server.configpath.md)
|
||||
|
||||
## ConfigPath type
|
||||
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
export declare type ConfigPath = string | string[];
|
||||
```
|
|
@ -0,0 +1,17 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-server](./kibana-plugin-server.md) > [ContextSetup](./kibana-plugin-server.contextsetup.md) > [createContextContainer](./kibana-plugin-server.contextsetup.createcontextcontainer.md)
|
||||
|
||||
## ContextSetup.createContextContainer() method
|
||||
|
||||
Creates a new for a service owner.
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
createContextContainer<TContext extends {}, THandlerReturn, THandlerParmaters extends any[] = []>(): IContextContainer<TContext, THandlerReturn, THandlerParmaters>;
|
||||
```
|
||||
<b>Returns:</b>
|
||||
|
||||
`IContextContainer<TContext, THandlerReturn, THandlerParmaters>`
|
||||
|
|
@ -0,0 +1,78 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-server](./kibana-plugin-server.md) > [ContextSetup](./kibana-plugin-server.contextsetup.md)
|
||||
|
||||
## ContextSetup interface
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
export interface ContextSetup
|
||||
```
|
||||
|
||||
## Methods
|
||||
|
||||
| Method | Description |
|
||||
| --- | --- |
|
||||
| [createContextContainer()](./kibana-plugin-server.contextsetup.createcontextcontainer.md) | Creates a new for a service owner. |
|
||||
|
||||
## Example
|
||||
|
||||
Say we're creating a plugin for rendering visualizations that allows new rendering methods to be registered. If we want to offer context to these rendering methods, we can leverage the ContextService to manage these contexts.
|
||||
|
||||
```ts
|
||||
export interface VizRenderContext {
|
||||
core: {
|
||||
i18n: I18nStart;
|
||||
uiSettings: UISettingsClientContract;
|
||||
}
|
||||
[contextName: string]: unknown;
|
||||
}
|
||||
|
||||
export type VizRenderer = (context: VizRenderContext, domElement: HTMLElement) => () => void;
|
||||
|
||||
class VizRenderingPlugin {
|
||||
private readonly vizRenderers = new Map<string, ((domElement: HTMLElement) => () => void)>();
|
||||
|
||||
constructor(private readonly initContext: PluginInitializerContext) {}
|
||||
|
||||
setup(core) {
|
||||
this.contextContainer = core.context.createContextContainer<
|
||||
VizRenderContext,
|
||||
ReturnType<VizRenderer>,
|
||||
[HTMLElement]
|
||||
>();
|
||||
|
||||
return {
|
||||
registerContext: this.contextContainer.registerContext,
|
||||
registerVizRenderer: (plugin: PluginOpaqueId, renderMethod: string, renderer: VizTypeRenderer) =>
|
||||
this.vizRenderers.set(renderMethod, this.contextContainer.createHandler(plugin, renderer)),
|
||||
};
|
||||
}
|
||||
|
||||
start(core) {
|
||||
// Register the core context available to all renderers. Use the VizRendererContext's opaqueId as the first arg.
|
||||
this.contextContainer.registerContext(this.initContext.opaqueId, 'core', () => ({
|
||||
i18n: core.i18n,
|
||||
uiSettings: core.uiSettings
|
||||
}));
|
||||
|
||||
return {
|
||||
registerContext: this.contextContainer.registerContext,
|
||||
|
||||
renderVizualization: (renderMethod: string, domElement: HTMLElement) => {
|
||||
if (!this.vizRenderer.has(renderMethod)) {
|
||||
throw new Error(`Render method '${renderMethod}' has not been registered`);
|
||||
}
|
||||
|
||||
// The handler can now be called directly with only an `HTMLElement` and will automatically
|
||||
// have a new `context` object created and populated by the context container.
|
||||
const handler = this.vizRenderers.get(renderMethod)
|
||||
return handler(domElement);
|
||||
}
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
```
|
||||
|
|
@ -0,0 +1,13 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-server](./kibana-plugin-server.md) > [CoreSetup](./kibana-plugin-server.coresetup.md) > [context](./kibana-plugin-server.coresetup.context.md)
|
||||
|
||||
## CoreSetup.context property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
context: {
|
||||
createContextContainer: ContextSetup['createContextContainer'];
|
||||
};
|
||||
```
|
|
@ -16,6 +16,7 @@ export interface CoreSetup
|
|||
|
||||
| Property | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| [context](./kibana-plugin-server.coresetup.context.md) | <code>{</code><br/><code> createContextContainer: ContextSetup['createContextContainer'];</code><br/><code> }</code> | |
|
||||
| [elasticsearch](./kibana-plugin-server.coresetup.elasticsearch.md) | <code>{</code><br/><code> adminClient$: Observable<ClusterClient>;</code><br/><code> dataClient$: Observable<ClusterClient>;</code><br/><code> createClient: (type: string, clientConfig?: Partial<ElasticsearchClientConfig>) => ClusterClient;</code><br/><code> }</code> | |
|
||||
| [http](./kibana-plugin-server.coresetup.http.md) | <code>{</code><br/><code> createCookieSessionStorageFactory: HttpServiceSetup['createCookieSessionStorageFactory'];</code><br/><code> registerOnPreAuth: HttpServiceSetup['registerOnPreAuth'];</code><br/><code> registerAuth: HttpServiceSetup['registerAuth'];</code><br/><code> registerOnPostAuth: HttpServiceSetup['registerOnPostAuth'];</code><br/><code> basePath: HttpServiceSetup['basePath'];</code><br/><code> isTlsEnabled: HttpServiceSetup['isTlsEnabled'];</code><br/><code> }</code> | |
|
||||
|
||||
|
|
|
@ -0,0 +1,20 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-server](./kibana-plugin-server.md) > [CustomHttpResponseOptions](./kibana-plugin-server.customhttpresponseoptions.md)
|
||||
|
||||
## CustomHttpResponseOptions interface
|
||||
|
||||
HTTP response parameters for a response with adjustable status code.
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
export interface CustomHttpResponseOptions extends HttpResponseOptions
|
||||
```
|
||||
|
||||
## Properties
|
||||
|
||||
| Property | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| [statusCode](./kibana-plugin-server.customhttpresponseoptions.statuscode.md) | <code>number</code> | |
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
||||
|
||||
[Home](./index.md) > [kibana-plugin-server](./kibana-plugin-server.md) > [CustomHttpResponseOptions](./kibana-plugin-server.customhttpresponseoptions.md) > [statusCode](./kibana-plugin-server.customhttpresponseoptions.statuscode.md)
|
||||
|
||||
## CustomHttpResponseOptions.statusCode property
|
||||
|
||||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
statusCode: number;
|
||||
```
|
|
@ -9,5 +9,5 @@ Get headers to authenticate a user against Elasticsearch.
|
|||
<b>Signature:</b>
|
||||
|
||||
```typescript
|
||||
export declare type GetAuthHeaders = (request: KibanaRequest | Request) => AuthHeaders | undefined;
|
||||
export declare type GetAuthHeaders = (request: KibanaRequest | LegacyRequest) => AuthHeaders | undefined;
|
||||
```
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue