Skip to content

Opensearch dashboards.savedobjectsservicestart.getscopedclient

Home > opensearch-dashboards > SavedObjectsServiceStart > getScopedClient

SavedObjectsServiceStart.getScopedClient property

Creates a Saved Objects client that uses the credentials from the passed in request to authenticate with OpenSearch. If other plugins have registered Saved Objects client wrappers, these will be applied to extend the functionality of the client.

A client that is already scoped to the incoming request is also exposed from the route handler context see RequestHandlerContext.

Signature:

getScopedClient: (req: OpenSearchDashboardsRequest, options?: SavedObjectsClientProviderOptions) => SavedObjectsClientContract;