---
swagger: '2.0'
info:
  version: '1'
  title: Elastic Cloud API
  termsOfService: ''
  x-doc-license:
    name: Attribution-NonCommercial-NoDerivatives 4.0 International
    url: https://creativecommons.org/licenses/by-nc-nd/4.0/
  x-feedbackLink:
    label: Feedback
    url: https://github.com/elastic/docs-content/issues/new?assignees=&labels=feedback%2Ccommunity&projects=&template=api-feedback.yaml&title=%5BFeedback%5D%3A+
  description: |
    This RESTful API enables you to perform most of the operations available in the UI console through API calls.

    You can [create an API key](https://www.elastic.co/guide/en/cloud/current/ec-api-authentication.html) to quickly and easily authenticate, then use the API to create and manage deployments, configure remote clusters, set up traffic filters, manage extensions, and much more.
    Access the API from its base URL at `api.elastic-cloud.com`.

    To manage your serverless projects, use the [Elastic Cloud Serverless API](https://www.elastic.co/docs/api/doc/elastic-cloud-serverless).

    ## Documentation source and versions

    This documentation is derived from https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json.
    It is provided under license [Attribution-NonCommercial-NoDerivatives 4.0 International](https://creativecommons.org/licenses/by-nc-nd/4.0/).
host: api.elastic-cloud.com
basePath: "/api/v1"
schemes:
- https
security: []
paths:
  "/account":
    get:
      tags:
      - Accounts
      summary: Fetch current account information
      description: Fetch current account information.
      operationId: get-current-account
      produces:
      - application/json
      parameters: []
      responses:
        '200':
          description: Account fetched successfully
          schema:
            "$ref": "#/definitions/AccountResponse"
        '404':
          description: 'Account not found. (code: `accounts.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - accounts.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Accounts
    put:
      tags:
      - Accounts
      summary: Updates the current account
      description: Updates the current account.
      operationId: update-current-account
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - in: body
        name: body
        description: the current account
        required: true
        schema:
          "$ref": "#/definitions/AccountUpdateRequest"
      responses:
        '200':
          description: Account updated successfully
          schema:
            "$ref": "#/definitions/AccountResponse"
        '404':
          description: 'Account not found. (code: `accounts.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - accounts.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Accounts
    patch:
      tags:
      - Accounts
      summary: Updates the current account
      description: Updates the current account.
      operationId: patch-current-account
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - in: body
        name: body
        description: All changes in the specified object are applied to the current
          account according to the JSON Merge Patch processing rules. Omitting existing
          fields causes the same values to be reapplied. Specifying a `null` value
          reverts the field to the default value, or removes the field when no default
          value exists.
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Account updated successfully
          schema:
            "$ref": "#/definitions/AccountResponse"
        '404':
          description: 'Account not found. (code: `accounts.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - accounts.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Accounts
  "/billing/costs/{organization_id}":
    get:
      tags:
      - BillingCostsAnalysis
      summary: Get costs overview for the organization. Currently unavailable in self-hosted
        ECE.
      description: Retrieves an overview of the costs by organization ID.
      operationId: get-costs-overview
      produces:
      - application/json
      parameters:
      - name: organization_id
        in: path
        description: Identifier for the organization
        required: true
        type: string
      - name: from
        in: query
        description: A datetime for the beginning of the desired range for which to
          fetch costs. Defaults to start of current month.
        required: false
        type: string
      - name: to
        in: query
        description: A datetime for the end of the desired range for which to fetch
          costs. Defaults to the current date.
        required: false
        type: string
      deprecated: true
      responses:
        '200':
          description: Top-level cost overview for the organization
          schema:
            "$ref": "#/definitions/CostsOverview"
        '400':
          description: 'The specified date range is invalid. (code: `costs.invalid_date_range`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - costs.invalid_date_range
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '403':
          description: 'The current user does not have access to the requested organization.
            (code: `organization.invalid_access`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.invalid_access
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: 'Organization not found. (code: `organization.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'An error occurred when fetching an overview of the costs for
            the organization. (code: `billing_service.failed_request`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - billing_service.failed_request
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Billing Costs Analysis
  "/billing/costs/{organization_id}/charts":
    get:
      tags:
      - BillingCostsAnalysis
      summary: Get charts for the organization. Currently unavailable in self-hosted
        ECE.
      description: Retrieves the usage charts for the organization.
      operationId: get-costs-charts
      produces:
      - application/json
      parameters:
      - name: organization_id
        in: path
        description: Identifier for the organization
        required: true
        type: string
      - name: from
        in: query
        description: A datetime for the beginning of the desired range for which to
          fetch costs. Defaults to start of current month.
        required: false
        type: string
      - name: to
        in: query
        description: A datetime for the end of the desired range for which to fetch
          costs. Defaults to the current date.
        required: false
        type: string
      - name: bucketing_strategy
        in: query
        description: The desired bucketing strategy for the charts. Defaults to `daily`.
        required: false
        type: string
        default: daily
        enum:
        - daily
        - monthly
      deprecated: true
      responses:
        '200':
          description: The usage charts of an organization.
          schema:
            "$ref": "#/definitions/ChartItems"
        '400':
          description: 'The specified date range is invalid. (code: `costs.invalid_date_range`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - costs.invalid_date_range
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '403':
          description: 'The current user does not have access to the requested organization.
            (code: `organization.invalid_access`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.invalid_access
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: 'Organization not found. (code: `organization.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '429':
          description: 'Too many requests. (code: `billing_service.rate_limited`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - billing_service.rate_limited
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'Error fetching the itemized costs for the organization. (code:
            `billing_service.failed_request`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - billing_service.failed_request
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Billing Costs Analysis
  "/billing/costs/{organization_id}/deployments":
    get:
      tags:
      - BillingCostsAnalysis
      summary: Get deployments costs for the organization. Currently unavailable in
        self-hosted ECE.
      description: Retrieves the costs associated with all deployments for the organization.
      operationId: get-costs-deployments
      produces:
      - application/json
      parameters:
      - name: organization_id
        in: path
        description: Identifier for the organization
        required: true
        type: string
      - name: from
        in: query
        description: A datetime for the beginning of the desired range for which to
          fetch activity. Defaults to start of current month.
        required: false
        type: string
      - name: to
        in: query
        description: A datetime for the end of the desired range for which to fetch
          activity. Defaults to the current date.
        required: false
        type: string
      - name: Accept
        in: header
        description: Accept header containing the content preference.
        required: false
        type: string
      deprecated: true
      responses:
        '200':
          description: The costs associated to a set of products
          schema:
            "$ref": "#/definitions/DeploymentsCosts"
        '400':
          description: 'Invalid date range specified. (code: `costs.invalid_date_range`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - costs.invalid_date_range
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '403':
          description: 'The current user does not have access to the requested organization.
            (code: `organization.invalid_access`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.invalid_access
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: 'Organization not found. (code: `organization.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'An error occurred when fetching the costs associated with
            all deployments for the organization. (code: `billing_service.failed_request`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - billing_service.failed_request
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Billing Costs Analysis
  "/billing/costs/{organization_id}/deployments/{deployment_id}/charts":
    get:
      tags:
      - BillingCostsAnalysis
      summary: Get charts by deployment. Currently unavailable in self-hosted ECE.
      description: Retrieves the usage charts for the given  deployment.
      operationId: get-costs-charts-by-deployment
      produces:
      - application/json
      parameters:
      - name: organization_id
        in: path
        description: Identifier for the organization
        required: true
        type: string
      - name: deployment_id
        in: path
        description: Id of a Deployment
        required: true
        type: string
      - name: from
        in: query
        description: A datetime for the beginning of the desired range for which to
          fetch costs. Defaults to start of current month.
        required: false
        type: string
      - name: to
        in: query
        description: A datetime for the end of the desired range for which to fetch
          costs. Defaults to the current date.
        required: false
        type: string
      - name: bucketing_strategy
        in: query
        description: The desired bucketing strategy for the charts. Defaults to `daily`.
        required: false
        type: string
        default: daily
        enum:
        - daily
        - monthly
      deprecated: true
      responses:
        '200':
          description: The usage charts of a deployment.
          schema:
            "$ref": "#/definitions/ChartItems"
        '400':
          description: 'The specified date range is invalid. (code: `costs.invalid_date_range`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - costs.invalid_date_range
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '403':
          description: 'The current user does not have access to the requested organization.
            (code: `organization.invalid_access`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.invalid_access
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: 'Organization not found. (code: `organization.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '429':
          description: 'Too many requests. (code: `billing_service.rate_limited`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - billing_service.rate_limited
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'Error fetching the itemized costs for the organization. (code:
            `billing_service.failed_request`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - billing_service.failed_request
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Billing Costs Analysis
  "/billing/costs/{organization_id}/deployments/{deployment_id}/items":
    get:
      tags:
      - BillingCostsAnalysis
      summary: Get itemized costs by deployments. Currently unavailable in self-hosted
        ECE.
      description: Retrieves the itemized costs for the given deployment.
      operationId: get-costs-items-by-deployment
      produces:
      - application/json
      parameters:
      - name: organization_id
        in: path
        description: Identifier for the organization
        required: true
        type: string
      - name: deployment_id
        in: path
        description: Id of a Deployment
        required: true
        type: string
      - name: from
        in: query
        description: A datetime for the beginning of the desired range for which to
          fetch costs. Defaults to start of current month.
        required: false
        type: string
      - name: to
        in: query
        description: A datetime for the end of the desired range for which to fetch
          costs. Defaults to the current date.
        required: false
        type: string
      - name: Accept
        in: header
        description: Determines the response body format. Can be either application/json
          or text/csv.
        required: false
        type: string
      deprecated: true
      responses:
        '200':
          description: The costs associated to a set items billed for a single deployment.
          schema:
            "$ref": "#/definitions/ItemsCosts"
        '400':
          description: 'The specified date range is invalid. (code: `costs.invalid_date_range`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - costs.invalid_date_range
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '403':
          description: 'The current user does not have access to the requested organization.
            (code: `organization.invalid_access`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.invalid_access
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: |-
            * The organization was not found. (code: `organization.not_found`)
            * The Elasticsearch cluster was not found. (code: `billing_service.es_cluster_id_not_found`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.not_found
              - billing_service.es_cluster_id_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'An error occurred when fetching the itemized costs for the
            given deployment of the organization. (code: `billing_service.failed_request`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - billing_service.failed_request
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Billing Costs Analysis
  "/billing/costs/{organization_id}/items":
    get:
      tags:
      - BillingCostsAnalysis
      summary: Get itemized costs for the organization. Currently unavailable in self-hosted
        ECE.
      description: Retrieves the itemized costs for the organization.
      operationId: get-costs-items
      produces:
      - application/json
      parameters:
      - name: organization_id
        in: path
        description: Identifier for the organization
        required: true
        type: string
      - name: from
        in: query
        description: A datetime for the beginning of the desired range for which to
          fetch costs. Defaults to start of current month.
        required: false
        type: string
      - name: to
        in: query
        description: A datetime for the end of the desired range for which to fetch
          costs. Defaults to the current date.
        required: false
        type: string
      deprecated: true
      responses:
        '200':
          description: The costs associated to a set of items
          schema:
            "$ref": "#/definitions/ItemsCosts"
        '400':
          description: 'The specified date range is invalid. (code: `costs.invalid_date_range`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - costs.invalid_date_range
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '403':
          description: 'The current user does not have access to the requested organization.
            (code: `organization.invalid_access`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.invalid_access
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: 'Organization not found. (code: `organization.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'Error fetching the itemized costs for the organization. (code:
            `billing_service.failed_request`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - billing_service.failed_request
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Billing Costs Analysis
  "/deployments":
    get:
      tags:
      - Deployments
      summary: List Deployments
      description: List Deployments.
      operationId: list-deployments
      produces:
      - application/json
      parameters: []
      responses:
        '200':
          description: The list of deployments that belong to the authenticated user.
          schema:
            "$ref": "#/definitions/DeploymentsListResponse"
        '401':
          description: You are not authorized to perform this action.
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - CRUD
    post:
      tags:
      - Deployments
      summary: Create Deployment
      description: Creates a Deployment.
      operationId: create-deployment
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - name: request_id
        in: query
        description: An optional idempotency token - if two create requests share
          the same request_id token (min size 32 characters, max 128) then only one
          deployment will be created, the second request will return the info of that
          deployment (in the same format described below, but with blanks for auth-related
          fields)
        required: false
        type: string
      - name: validate_only
        in: query
        description: If true, will just validate the Deployment definition but will
          not perform the creation
        required: false
        type: boolean
        default: false
      - name: template_id
        in: query
        description: An optional template id - if present, the referenced template
          will be used to fill in the resources field of the deployment creation request.
          If any resources are present in the request together with the template,
          the ones coming in the request will prevail and no merging with the template
          will be performed.
        required: false
        type: string
      - in: body
        name: body
        description: The deployment definition
        required: true
        schema:
          "$ref": "#/definitions/DeploymentCreateRequest"
      responses:
        '200':
          description: The request was valid (used when validate_only is true).
          schema:
            "$ref": "#/definitions/DeploymentCreateResponse"
        '201':
          description: The request was valid and a new deployment was created
          headers:
            x-cloud-resource-version:
              type: string
              description: The resource version, which is used to avoid update conflicts
                with concurrent operations
            x-cloud-resource-created:
              type: string
              description: The date-time when the resource was created (ISO format
                relative to UTC)
            x-cloud-resource-last-modified:
              type: string
              description: The date-time when the resource was last modified (ISO
                format relative to UTC)
          schema:
            "$ref": "#/definitions/DeploymentCreateResponse"
        '202':
          description: The request was valid and deployment creation had already been
            started.
          schema:
            "$ref": "#/definitions/DeploymentCreateResponse"
        '400':
          description: The deployment request had errors.
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '401':
          description: You are not authorized to perform this action.
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - CRUD
  "/deployments/_search":
    post:
      tags:
      - Deployments
      summary: Search Deployments
      description: Retrieves the information for all of the deployments that match
        the specified query.
      operationId: search-deployments
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - name: minimal_metadata
        in: query
        description: Comma separated list of attributes to include in response for
          deployments found. Useful for reducing response size when retrieving many
          deployments. Use of this parameter moves the result to the minimal_metadata
          section of the response.
        required: false
        type: string
      - in: body
        name: body
        description: "(Optional) The search query to run. When not specified, all
          of the deployments are matched."
        required: false
        schema:
          "$ref": "#/definitions/SearchRequest"
      responses:
        '200':
          description: The list of deployments that match the specified query and
            belong to the authenticated user.
          headers:
            x-cloud-resource-version:
              type: string
              description: The resource version, which is used to avoid update conflicts
                with concurrent operations
            x-cloud-resource-created:
              type: string
              description: The date-time when the resource was created (ISO format
                relative to UTC)
            x-cloud-resource-last-modified:
              type: string
              description: The date-time when the resource was last modified (ISO
                format relative to UTC)
          schema:
            "$ref": "#/definitions/DeploymentsSearchResponse"
      x-doc:
        tag: Deployment - Commands
  "/deployments/eligible-remote-clusters":
    post:
      tags:
      - Deployments
      summary: Get eligible remote clusters
      description: Returns the list of deployments which contain eligible remote clusters
        for a specific version.
      operationId: search-eligible-remote-clusters
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - name: version
        in: query
        description: The version of the Elasticsearch cluster cluster that will potentially
          be configured to have remote clusters.
        required: true
        type: string
      - in: body
        name: body
        description: "(Optional) The search query to run against all deployments containing
          eligible remote clusters. When not specified, all the eligible deployments
          are matched."
        required: false
        schema:
          "$ref": "#/definitions/SearchRequest"
      responses:
        '200':
          description: List of deployments which contains eligible remote clusters
            for a specific version
          schema:
            "$ref": "#/definitions/DeploymentsSearchResponse"
        '400':
          description: 'The provided version is invalid. (code: `stackpack.invalid_version`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - stackpack.invalid_version
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Remote Clusters
  "/deployments/extensions":
    get:
      tags:
      - Extensions
      summary: List Extensions
      description: Retrieves all of the available extensions.
      operationId: list-extensions
      produces:
      - application/json
      parameters: []
      responses:
        '200':
          description: The extensions that are available
          schema:
            "$ref": "#/definitions/Extensions"
      x-doc:
        tag: Deployments - Extensions
    post:
      tags:
      - Extensions
      summary: Create an extension
      description: |
        Creates the extension.
         The extensions API supports two types of usage patterns.
         A). Specify a `download_url`, http or https URL,  where the extension is currently hosted. This will result in extension being copied to elastic repository.
         B). Create only the extension metadata using the `POST` endpoint and then use `PUT` to upload the extension file. Leave the `download_url` unspecified in this case.
      operationId: create-extension
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - in: body
        name: body
        description: the data that creates the extension
        required: true
        schema:
          "$ref": "#/definitions/CreateExtensionRequest"
      responses:
        '201':
          description: The extension that was just created.
          headers:
            x-cloud-resource-version:
              type: string
              description: The resource version, which is used to avoid update conflicts
                with concurrent operations
            x-cloud-resource-created:
              type: string
              description: The date-time when the resource was created (ISO format
                relative to UTC)
            x-cloud-resource-last-modified:
              type: string
              description: The date-time when the resource was last modified (ISO
                format relative to UTC)
          schema:
            "$ref": "#/definitions/Extension"
        '400':
          description: 'Could not download the extension from the specified URL. (code:
            `extensions.request_execution_failed`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - extensions.request_execution_failed
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: 'Your current session does not have a user id associated with
            it. (code: `extensions.no_user_id`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - extensions.no_user_id
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '409':
          description: 'An extension already exists with the generated id. Please
            try again. (code: `extensions.id_already_exists`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - extensions.id_already_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployments - Extensions
  "/deployments/extensions/{extension_id}":
    get:
      tags:
      - Extensions
      summary: Get Extension
      description: Retrieves an extension.
      operationId: get-extension
      produces:
      - application/json
      parameters:
      - name: extension_id
        in: path
        description: Id of an extension
        required: true
        type: string
      - name: include_deployments
        in: query
        description: Include deployments referencing this extension. Up to only 10000
          deployments will be included.
        required: false
        type: boolean
        default: false
      responses:
        '200':
          description: The Extension
          headers:
            x-cloud-resource-version:
              type: string
              description: The resource version, which is used to avoid update conflicts
                with concurrent operations
            x-cloud-resource-created:
              type: string
              description: The date-time when the resource was created (ISO format
                relative to UTC)
            x-cloud-resource-last-modified:
              type: string
              description: The date-time when the resource was last modified (ISO
                format relative to UTC)
          schema:
            "$ref": "#/definitions/Extension"
        '404':
          description: 'The extension requested does not exist. (code: `extensions.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - extensions.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployments - Extensions
    post:
      tags:
      - Extensions
      summary: Update Extension
      description: Updates an extension.
      operationId: update-extension
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - name: extension_id
        in: path
        description: Id of an extension
        required: true
        type: string
      - in: body
        name: body
        description: The extension update data.
        required: true
        schema:
          "$ref": "#/definitions/UpdateExtensionRequest"
      responses:
        '200':
          description: Extension updated successfully.
          headers:
            x-cloud-resource-version:
              type: string
              description: The resource version, which is used to avoid update conflicts
                with concurrent operations
            x-cloud-resource-created:
              type: string
              description: The date-time when the resource was created (ISO format
                relative to UTC)
            x-cloud-resource-last-modified:
              type: string
              description: The date-time when the resource was last modified (ISO
                format relative to UTC)
          schema:
            "$ref": "#/definitions/Extension"
        '400':
          description: 'Could not download the extension from the specified URL. (code:
            `extensions.request_execution_failed`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - extensions.request_execution_failed
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '401':
          description: |-
            * The extension does not belong to you. (code: `extensions.unauthorised`)
            * Your current session does not have a user id associated with it. (code: `extensions.no_user_id`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - extensions.unauthorised
              - extensions.no_user_id
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: 'The extension you want does not exist. (code: `extensions.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - extensions.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '409':
          description: 'The version you sent does not match the persisted version.
            (code: `extensions.version_conflict`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - extensions.version_conflict
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployments - Extensions
    put:
      tags:
      - Extensions
      summary: Uploads the Extension
      description: Uploads archive for an extension.
      operationId: upload-extension
      consumes:
      - multipart/form-data
      produces:
      - application/json
      parameters:
      - name: extension_id
        in: path
        description: Id of an extension
        required: true
        type: string
      - name: file
        in: formData
        description: Zip file that contains the extension
        required: true
        type: file
      responses:
        '200':
          description: Archive uploaded successfully.
          headers:
            x-cloud-resource-version:
              type: string
              description: The resource version, which is used to avoid update conflicts
                with concurrent operations
            x-cloud-resource-created:
              type: string
              description: The date-time when the resource was created (ISO format
                relative to UTC)
            x-cloud-resource-last-modified:
              type: string
              description: The date-time when the resource was last modified (ISO
                format relative to UTC)
          schema:
            "$ref": "#/definitions/Extension"
        '400':
          description: 'Could not accept the extensions file. (code: `extensions.request_execution_failed`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - extensions.request_execution_failed
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '401':
          description: |-
            * The extension does not belong to you. (code: `extensions.unauthorised`)
            * Your current session does not have a user id associated with it. (code: `extensions.no_user_id`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - extensions.unauthorised
              - extensions.no_user_id
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: 'The extension you want does not exist. (code: `extensions.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - extensions.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployments - Extensions
    delete:
      tags:
      - Extensions
      summary: Delete Extension
      description: Deletes a Extension.
      operationId: delete-extension
      produces:
      - application/json
      parameters:
      - name: extension_id
        in: path
        description: Id of an extension
        required: true
        type: string
      responses:
        '200':
          description: Extension deleted successfully.
          headers:
            x-cloud-resource-version:
              type: string
              description: The resource version, which is used to avoid update conflicts
                with concurrent operations
            x-cloud-resource-created:
              type: string
              description: The date-time when the resource was created (ISO format
                relative to UTC)
            x-cloud-resource-last-modified:
              type: string
              description: The date-time when the resource was last modified (ISO
                format relative to UTC)
          schema:
            "$ref": "#/definitions/EmptyResponse"
        '401':
          description: |-
            * The extension does not belong to you. (code: `extensions.unauthorised`)
            * Your current session does not have a user id associated with it. (code: `extensions.no_user_id`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - extensions.unauthorised
              - extensions.no_user_id
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: 'The extension requested does not exist. (code: `extensions.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - extensions.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '409':
          description: 'The version you sent does not match the persisted version.
            (code: `extensions.version_conflict`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - extensions.version_conflict
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployments - Extensions
  "/deployments/templates":
    get:
      tags:
      - DeploymentTemplates
      summary: Get deployment templates
      description: Retrieves all deployment templates.
      operationId: get-deployment-templates-v2
      produces:
      - application/json
      parameters:
      - name: metadata
        in: query
        description: An optional key/value pair in the form of (key:value) that will
          act as a filter and exclude any templates that do not have a matching metadata
          item associated.
        required: false
        type: string
      - name: show_instance_configurations
        in: query
        description: If true, will return details for each instance configuration
          referenced by the template.
        required: false
        type: boolean
        default: true
      - name: show_max_zones
        in: query
        description: If true, will populate the max_zones field in the instance configurations.
          Only relevant if show_instance_configurations=true.
        required: false
        type: boolean
        default: false
      - name: stack_version
        in: query
        description: If present, it will cause the returned deployment templates to
          be adapted to return only the elements allowed in that version.
        required: false
        type: string
      - name: hide_deprecated
        in: query
        description: If true, templates flagged as deprecated will NOT be returned.
        required: false
        type: boolean
        default: false
      - name: region
        in: query
        description: Region of the deployment templates
        required: true
        type: string
      responses:
        '200':
          description: The deployment templates were returned successfully.
          schema:
            type: array
            items:
              "$ref": "#/definitions/DeploymentTemplateInfoV2"
        '400':
          description: 'The requested region was not found. (code: `templates.region_not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - templates.region_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '401':
          description: 'The user is not authorized to access requested region. (code:
            `templates.region_not_allowed`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - templates.region_not_allowed
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployments - Templates
  "/deployments/templates/{template_id}":
    get:
      tags:
      - DeploymentTemplates
      summary: Get deployment template
      description: Retrieves a deployment template by id.
      operationId: get-deployment-template-v2
      produces:
      - application/json
      parameters:
      - name: template_id
        in: path
        description: The identifier for the deployment template.
        required: true
        type: string
      - name: show_instance_configurations
        in: query
        description: If true, will return details for each instance configuration
          referenced by the template.
        required: false
        type: boolean
        default: true
      - name: show_max_zones
        in: query
        description: If true, will populate the max_zones field in the instance configurations.
          Only relevant if show_instance_configurations=true.
        required: false
        type: boolean
        default: false
      - name: stack_version
        in: query
        description: If present, it will cause the returned deployment template to
          be adapted to return only the elements allowed in that version.
        required: false
        type: string
      - name: region
        in: query
        description: Region of the deployment template
        required: true
        type: string
      responses:
        '200':
          description: The deployment template was found and returned successfully.
          schema:
            "$ref": "#/definitions/DeploymentTemplateInfoV2"
        '400':
          description: 'The requested region is not supported. (code: `templates.region_not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - templates.region_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '401':
          description: 'The user is not authorized to access requested region. (code:
            `templates.region_not_allowed`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - templates.region_not_allowed
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: 'The deployment template specified by {template_id} cannot
            be found. (code: `templates.template_not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - templates.template_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployments - Templates
  "/deployments/traffic-filter/associations/{association_type}/{associated_entity_id}/rulesets":
    get:
      tags:
      - DeploymentsTrafficFilter
      summary: Get associated rulesets
      description: Retrieves the rulesets associated with a deployment.
      operationId: get-traffic-filter-deployment-ruleset-associations
      produces:
      - application/json
      parameters:
      - name: association_type
        in: path
        description: Association type
        required: true
        type: string
      - name: associated_entity_id
        in: path
        description: Associated entity ID
        required: true
        type: string
      responses:
        '200':
          description: Rulesets in the deployment were successfully returned
          schema:
            "$ref": "#/definitions/TrafficFilterSettings"
        '400':
          description: 'Invalid association type. (code: `traffic_filter.invalid_association_type`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - traffic_filter.invalid_association_type
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'Error fetching traffic filter rulesets. (code: `traffic_filter.request_execution_failed`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - traffic_filter.request_execution_failed
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployments - Traffic Filter - Associations
  "/deployments/traffic-filter/link-ids":
    get:
      tags:
      - DeploymentsTrafficFilter
      summary: List traffic filter claimed link id
      description: List all of the traffic filter claimed link id.
      operationId: get-traffic-filter-claimed-link-ids
      produces:
      - application/json
      parameters:
      - name: region
        in: query
        description: If provided limits the claimed id to that region only.
        required: false
        type: string
      - name: organization_id
        in: query
        description: Retrieves a list of resources that are associated to the specified
          organization ID. It only takes effect if the user is an admin.
        required: false
        type: string
      responses:
        '200':
          description: The collection of traffic filter claimed link id
          schema:
            "$ref": "#/definitions/TrafficFilterClaimedLinkIds"
        '500':
          description: 'Error fetching traffic filter claimed link ids. (code: `traffic_filter_claimed_link_id.request_execution_failed`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - traffic_filter_claimed_link_id.request_execution_failed
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployments - Traffic Filter Claimed Link Id
  "/deployments/traffic-filter/link-ids/_claim":
    post:
      tags:
      - DeploymentsTrafficFilter
      summary: Claim a link id
      description: Claim the ownership of a link id.
      operationId: claim-traffic-filter-link-id
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - in: body
        name: body
        description: The specification for traffic filter claimed link id.
        required: true
        schema:
          "$ref": "#/definitions/TrafficFilterClaimedLinkIdRequest"
      responses:
        '201':
          description: The ruleset definition is valid and the creation has started.
          schema:
            "$ref": "#/definitions/TrafficFilterClaimedLinkIdInfo"
        '500':
          description: 'Error creating the traffic filter ruleset. (code: `traffic_filter_claimed_link_id.request_execution_failed`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - traffic_filter_claimed_link_id.request_execution_failed
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployments - Traffic Filter Claimed Link Id
  "/deployments/traffic-filter/link-ids/_unclaim":
    post:
      tags:
      - DeploymentsTrafficFilter
      summary: Unclaims a link id
      description: Unclaims the ownership of a link id.
      operationId: unclaim-traffic-filter-link-id
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - in: body
        name: body
        description: The specification for traffic filter claimed link id.
        required: true
        schema:
          "$ref": "#/definitions/TrafficFilterClaimedLinkIdRequest"
      responses:
        '200':
          description: The claimed link id was successfully deleted.
          schema:
            "$ref": "#/definitions/EmptyResponse"
        '400':
          description: 'Error validating the request. (code: `traffic_filter_claimed_link_id.invalid_input`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - traffic_filter_claimed_link_id.invalid_input
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'Error deleting the traffic filter claimed link id. (code:
            `traffic_filter_claimed_link_id.request_execution_failed`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - traffic_filter_claimed_link_id.request_execution_failed
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployments - Traffic Filter Claimed Link Id
  "/deployments/traffic-filter/rulesets":
    get:
      tags:
      - DeploymentsTrafficFilter
      summary: List traffic filter rulesets
      description: List all of the traffic filter rulesets.
      operationId: get-traffic-filter-rulesets
      produces:
      - application/json
      parameters:
      - name: include_associations
        in: query
        description: Retrieves a list of resources that are associated to the specified
          ruleset.
        required: false
        type: boolean
        default: false
      - name: region
        in: query
        description: If provided limits the rulesets to that region only.
        required: false
        type: string
      - name: organization_id
        in: query
        description: Retrieves a list of resources that are associated to the specified
          organization ID. It only takes effect if the user is an admin.
        required: false
        type: string
      responses:
        '200':
          description: The collection of traffic filter routes
          schema:
            "$ref": "#/definitions/TrafficFilterRulesets"
        '500':
          description: 'Error fetching traffic filter rulesets. (code: `traffic_filter.request_execution_failed`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - traffic_filter.request_execution_failed
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployments - Traffic Filter - CRUD
    post:
      tags:
      - DeploymentsTrafficFilter
      summary: Create a ruleset
      description: Creates a ruleset that consists of a set of rules.
      operationId: create-traffic-filter-ruleset
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - in: body
        name: body
        description: The specification for traffic filter ruleset.
        required: true
        schema:
          "$ref": "#/definitions/TrafficFilterRulesetRequest"
      responses:
        '201':
          description: The ruleset definition is valid and the creation has started.
          schema:
            "$ref": "#/definitions/TrafficFilterRulesetResponse"
        '500':
          description: 'Error creating the traffic filter ruleset. (code: `traffic_filter.request_execution_failed`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - traffic_filter.request_execution_failed
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployments - Traffic Filter - CRUD
  "/deployments/traffic-filter/rulesets/{ruleset_id}":
    get:
      tags:
      - DeploymentsTrafficFilter
      summary: Retrieves the ruleset by ID.
      description: Retrieves a list of resources that are associated to the specified
        ruleset.
      operationId: get-traffic-filter-ruleset
      produces:
      - application/json
      parameters:
      - name: ruleset_id
        in: path
        description: The mandatory ruleset ID.
        required: true
        type: string
      - name: include_associations
        in: query
        description: Retrieves a list of resources that are associated to the specified
          ruleset.
        required: false
        type: boolean
        default: false
      responses:
        '200':
          description: The container for a set of traffic filter rules.
          schema:
            "$ref": "#/definitions/TrafficFilterRulesetInfo"
        '404':
          description: 'The traffic filter ruleset specified by {ruleset_id} cannot
            be found. (code: `traffic_filter.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - traffic_filter.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'Error reading the traffic filter ruleset. (code: `traffic_filter.request_execution_failed`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - traffic_filter.request_execution_failed
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployments - Traffic Filter - CRUD
    put:
      tags:
      - DeploymentsTrafficFilter
      summary: Updates a ruleset
      description: Updates the ruleset with the definition.
      operationId: update-traffic-filter-ruleset
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - name: ruleset_id
        in: path
        description: The mandatory ruleset ID.
        required: true
        type: string
      - in: body
        name: body
        description: The specification for traffic filter ruleset.
        required: true
        schema:
          "$ref": "#/definitions/TrafficFilterRulesetRequest"
      responses:
        '200':
          description: The ruleset definition was valid and the update has started.
          schema:
            "$ref": "#/definitions/TrafficFilterRulesetResponse"
        '404':
          description: 'The traffic filter ruleset specified by {ruleset_id} cannot
            be found. (code: `traffic_filter.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - traffic_filter.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'Error reading the traffic filter ruleset. (code: `traffic_filter.request_execution_failed`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - traffic_filter.request_execution_failed
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployments - Traffic Filter - CRUD
    delete:
      tags:
      - DeploymentsTrafficFilter
      summary: Delete a ruleset
      description: Deletes the ruleset by ID.
      operationId: delete-traffic-filter-ruleset
      produces:
      - application/json
      parameters:
      - name: ruleset_id
        in: path
        description: The mandatory ruleset ID.
        required: true
        type: string
      - name: ignore_associations
        in: query
        description: When true, ignores the associations and deletes the ruleset.
          When false, recognizes the associations, which prevents the deletion of
          the rule set.
        required: false
        type: boolean
        default: false
      responses:
        '200':
          description: The traffic filter ruleset was successfully deleted.
          schema:
            "$ref": "#/definitions/EmptyResponse"
        '404':
          description: 'The traffic filter ruleset specified by {ruleset_id} cannot
            be found. (code: `traffic_filter.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - traffic_filter.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'Error deleting the traffic filter ruleset. (code: `traffic_filter.request_execution_failed`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - traffic_filter.request_execution_failed
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployments - Traffic Filter - CRUD
  "/deployments/traffic-filter/rulesets/{ruleset_id}/associations":
    get:
      tags:
      - DeploymentsTrafficFilter
      summary: Get associated deployments
      description: Retrieves a list of deployments that are associated to the specified
        ruleset.
      operationId: get-traffic-filter-ruleset-deployment-associations
      produces:
      - application/json
      parameters:
      - name: ruleset_id
        in: path
        description: The mandatory ruleset ID.
        required: true
        type: string
      responses:
        '200':
          description: Associations referred by traffic filter rulesets were successfully
            returned
          schema:
            "$ref": "#/definitions/RulesetAssociations"
        '500':
          description: 'Error fetching deployments. (code: `traffic_filter.request_execution_failed`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - traffic_filter.request_execution_failed
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployments - Traffic Filter - Associations
    post:
      tags:
      - DeploymentsTrafficFilter
      summary: Create ruleset association
      description: Applies the ruleset to the specified deployment.
      operationId: create-traffic-filter-ruleset-association
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - name: ruleset_id
        in: path
        description: The mandatory ruleset ID.
        required: true
        type: string
      - in: body
        name: body
        description: Mandatory ruleset association description
        required: true
        schema:
          "$ref": "#/definitions/FilterAssociation"
      responses:
        '200':
          description: Create association request was valid and the association already
            exists
          schema:
            "$ref": "#/definitions/EmptyResponse"
        '201':
          description: Create association request was valid and the association has
            been created
          schema:
            "$ref": "#/definitions/EmptyResponse"
        '404':
          description: 'The traffic filter ruleset specified by {ruleset_id} cannot
            be found. (code: `traffic_filter.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - traffic_filter.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'Creation failed. (code: `traffic_filter.request_execution_failed`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - traffic_filter.request_execution_failed
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployments - Traffic Filter - Associations
  "/deployments/traffic-filter/rulesets/{ruleset_id}/associations/{association_type}/{associated_entity_id}":
    delete:
      tags:
      - DeploymentsTrafficFilter
      summary: Delete ruleset association
      description: Deletes the traffic rules in the ruleset from the deployment.
      operationId: delete-traffic-filter-ruleset-association
      produces:
      - application/json
      parameters:
      - name: ruleset_id
        in: path
        description: The mandatory ruleset ID.
        required: true
        type: string
      - name: association_type
        in: path
        description: Association type
        required: true
        type: string
      - name: associated_entity_id
        in: path
        description: Associated entity ID
        required: true
        type: string
      responses:
        '200':
          description: Delete association request was valid and the association has
            been deleted
          schema:
            "$ref": "#/definitions/EmptyResponse"
        '404':
          description: 'The traffic filter ruleset association cannot be found. (code:
            `traffic_filter.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - traffic_filter.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'Deletion failed. (code: `traffic_filter.request_execution_failed`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - traffic_filter.request_execution_failed
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployments - Traffic Filter - Associations
  "/deployments/{deployment_id}":
    get:
      tags:
      - Deployments
      summary: Get Deployment
      description: Retrieves information about a Deployment.
      operationId: get-deployment
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment
        required: true
        type: string
      - name: show_security
        in: query
        description: Whether to include the Elasticsearch 2.x security information
          in the response - can be large per cluster and also include credentials
        required: false
        type: boolean
        default: false
      - name: show_metadata
        in: query
        description: Whether to include the full cluster metadata in the response
          - can be large per cluster and also include credentials
        required: false
        type: boolean
        default: false
      - name: show_plans
        in: query
        description: Whether to include the full current and pending plan information
          in the response - can be large per cluster
        required: false
        type: boolean
        default: true
      - name: show_plan_logs
        in: query
        description: Whether to include with the current and pending plan information
          the attempt log - can be very large per cluster
        required: false
        type: boolean
        default: false
      - name: show_plan_history
        in: query
        description: |
          Whether to include the plan history with the current and pending plan information. The results can be very large per cluster.
           By default, if a given resource kind (e.g. Elasticsearch, Kibana, etc.) has more than 100 plans
           (which should be very rare, most likely caused by a bug) only 100 plans are returned for the given resource type:
           The first 10 plans, and the last 90 plans for that resource type.
           If ALL of the plans are desired, pass the `force_all_plan_history` parameter with a value of `true`.
        required: false
        type: boolean
        default: false
      - name: show_plan_defaults
        in: query
        description: If showing plans, whether to show values that are left at their
          default value (less readable but more informative)
        required: false
        type: boolean
        default: false
      - name: convert_legacy_plans
        in: query
        description: If showing plans, whether to leave pre-2.0.0 plans in their legacy
          format (the default), or whether to update them to 2.0.x+ format (if 'true')
        required: false
        type: boolean
        default: false
      - name: show_system_alerts
        in: query
        description: Number of system alerts (such as forced restarts due to memory
          limits) to be included in the response - can be large per cluster. Negative
          numbers or 0 will not return field.
        required: false
        type: integer
        default: 0
      - name: show_settings
        in: query
        description: Whether to show cluster settings in the response.
        required: false
        type: boolean
        default: false
      - name: show_instance_metrics
        in: query
        description: Whether to show resources instance metrics in the response.
        required: false
        type: boolean
        default: true
      - name: show_instance_configurations
        in: query
        description: If true, will return details for each instance configuration
          referenced by the deployment.
        required: false
        type: boolean
        default: true
      - name: enrich_with_template
        in: query
        description: If showing plans, whether to enrich the plan by including the
          missing elements from the deployment template it is based on
        required: false
        type: boolean
        default: true
      - name: force_all_plan_history
        in: query
        description: "Force show the entire plan history no matter how long.\n As
          noted in the `show_plan_history` parameter description, by default, a maximum
          of 100 plans are shown per resource. \n If `true`, this parameter overrides
          the default, and ALL plans are returned.\n Use with care as the plan history
          can be VERY large. Consider pairing with `show_plan_logs=false`.\n "
        required: false
        type: boolean
        default: false
      - name: clear_transient
        in: query
        description: If set (defaults to false) then removes the transient section
          from all child resources, making it safe to reapply via an update
        required: false
        type: boolean
        default: false
      responses:
        '200':
          description: The Deployment info response
          headers:
            x-cloud-resource-version:
              type: string
              description: The resource version, which is used to avoid update conflicts
                with concurrent operations
            x-cloud-resource-created:
              type: string
              description: The date-time when the resource was created (ISO format
                relative to UTC)
            x-cloud-resource-last-modified:
              type: string
              description: The date-time when the resource was last modified (ISO
                format relative to UTC)
          schema:
            "$ref": "#/definitions/DeploymentGetResponse"
        '401':
          description: You are not authorized to perform this action.
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: 'The Deployment specified by {deployment_id} cannot be found.
            (code: `deployments.deployment_not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - CRUD
    put:
      tags:
      - Deployments
      summary: Update Deployment
      description: Updates a Deployment.
      operationId: update-deployment
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment
        required: true
        type: string
      - name: hide_pruned_orphans
        in: query
        description: Whether or not to hide orphaned resources that were shut down
          (relevant if prune on the request is true)
        required: false
        type: boolean
        default: false
      - name: skip_snapshot
        in: query
        description: Whether or not to skip snapshots before shutting down orphaned
          resources (relevant if prune on the request is true)
        required: false
        type: boolean
        default: false
      - name: validate_only
        in: query
        description: If true, will just validate the Deployment definition but will
          not perform the update
        required: false
        type: boolean
        default: false
      - name: version
        in: query
        description: If specified then checks for conflicts against the version stored
          in the persistent store (returned in 'x-cloud-resource-version' of the GET
          request)
        required: false
        type: string
      - in: body
        name: body
        description: The deployment definition
        required: true
        schema:
          "$ref": "#/definitions/DeploymentUpdateRequest"
      responses:
        '200':
          description: The request was valid and the deployment was updated.
          headers:
            x-cloud-resource-version:
              type: string
              description: The resource version, which is used to avoid update conflicts
                with concurrent operations
            x-cloud-resource-created:
              type: string
              description: The date-time when the resource was created (ISO format
                relative to UTC)
            x-cloud-resource-last-modified:
              type: string
              description: The date-time when the resource was last modified (ISO
                format relative to UTC)
          schema:
            "$ref": "#/definitions/DeploymentUpdateResponse"
        '400':
          description: The deployment request had errors.
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '401':
          description: You are not authorized to perform this action.
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: 'The Deployment specified by {deployment_id} cannot be found.
            (code: `deployments.deployment_not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - CRUD
  "/deployments/{deployment_id}/_restore":
    post:
      tags:
      - Deployments
      summary: Restores a shutdown Deployment
      description: Restores all resources in a Deployment.
      operationId: restore-deployment
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment
        required: true
        type: string
      - name: restore_snapshot
        in: query
        description: Whether or not to restore a snapshot for those resources that
          allow it.
        required: false
        type: boolean
        default: false
      responses:
        '200':
          description: The request was valid and the resources of the deployment were
            restored.
          schema:
            "$ref": "#/definitions/DeploymentRestoreResponse"
        '400':
          description: There are Elasticsearch resources in the deployment which are
            not shut down.
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '401':
          description: You are not authorized to perform this action.
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: 'The Deployment specified by {deployment_id} cannot be found.
            (code: `deployments.deployment_not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - CRUD
  "/deployments/{deployment_id}/_shutdown":
    post:
      tags:
      - Deployments
      summary: Shuts down Deployment
      description: Shuts down all resources in a Deployment.
      operationId: shutdown-deployment
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment
        required: true
        type: string
      - name: hide
        in: query
        description: Whether or not to hide the deployment and its resources.Only
          applicable for Platform administrators.
        required: false
        type: boolean
      - name: skip_snapshot
        in: query
        description: Whether or not to skip snapshots before shutting down the resources
        required: false
        type: boolean
        default: false
      responses:
        '200':
          description: The request was valid and the resources of the deployment were
            shutdown.
          schema:
            "$ref": "#/definitions/DeploymentShutdownResponse"
        '400':
          description: 'Parameter is restricted and can only be set by a Platform
            administrator. (code: `deployments.restricted_parameter`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.restricted_parameter
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '401':
          description: You are not authorized to perform this action.
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: 'The Deployment specified by {deployment_id} cannot be found.
            (code: `deployments.deployment_not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - CRUD
  "/deployments/{deployment_id}/apm/{ref_id}":
    get:
      tags:
      - Deployments
      summary: Get Deployment APM Resource Info
      description: Get info about an APM Resource belonging to a given Deployment.
      operationId: get-deployment-apm-resource-info
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      - name: show_metadata
        in: query
        description: Whether to include the full cluster metadata in the response
          - can be large per cluster and also include credentials.
        required: false
        type: boolean
        default: false
      - name: show_plans
        in: query
        description: Whether to include the full current and pending plan information
          in the response - can be large per cluster.
        required: false
        type: boolean
        default: true
      - name: show_plan_logs
        in: query
        description: Whether to include with the current and pending plan information
          the attempt log - can be very large per cluster.
        required: false
        type: boolean
        default: false
      - name: show_plan_history
        in: query
        description: Whether to include with the current and pending plan information
          the plan history- can be very large per cluster.
        required: false
        type: boolean
        default: false
      - name: show_plan_defaults
        in: query
        description: If showing plans, whether to show values that are left at their
          default value (less readable but more informative).
        required: false
        type: boolean
        default: false
      - name: show_settings
        in: query
        description: Whether to show cluster settings in the response.
        required: false
        type: boolean
        default: false
      - name: clear_transient
        in: query
        description: If set (defaults to false) then removes the transient section
          from all child resources, making it safe to reapply via an update
        required: false
        type: boolean
        default: false
      responses:
        '200':
          description: Standard response.
          schema:
            "$ref": "#/definitions/ApmResourceInfo"
        '404':
          description: 'The Deployment specified by {deployment_id} cannot be found.
            (code: `deployments.deployment_not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'We have failed you. (code: `deployments.deployment_resource_no_longer_exists`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_no_longer_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Info
  "/deployments/{deployment_id}/apm/{ref_id}/_reset-token":
    post:
      tags:
      - Deployments
      summary: Reset the secret token for an APM resource.
      description: Reset the token of an APM resource.
      operationId: deployment-apm-reset-secret-token
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment.
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      responses:
        '202':
          description: Response containing the new secret token, plan to apply it
            starts
          schema:
            "$ref": "#/definitions/ApmCrudResponse"
        '400':
          description: 'Reset token is not supported when APM is managed by Elastic
            Agent. (code: `clusters.cluster_plan_state_error`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - clusters.cluster_plan_state_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'We have failed you. (code: `deployments.deployment_resource_no_longer_exists`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_no_longer_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: APM routes
  "/deployments/{deployment_id}/appsearch/{ref_id}":
    get:
      tags:
      - Deployments
      summary: Get Deployment App Search Resource Info
      description: Get info about an App Search Resource belonging to a given Deployment.
      operationId: get-deployment-appsearch-resource-info
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      - name: show_metadata
        in: query
        description: Whether to include the full cluster metadata in the response
          - can be large per cluster and also include credentials.
        required: false
        type: boolean
        default: false
      - name: show_plans
        in: query
        description: Whether to include the full current and pending plan information
          in the response - can be large per cluster.
        required: false
        type: boolean
        default: true
      - name: show_plan_logs
        in: query
        description: Whether to include with the current and pending plan information
          the attempt log - can be very large per cluster.
        required: false
        type: boolean
        default: false
      - name: show_plan_history
        in: query
        description: Whether to include with the current and pending plan information
          the plan history- can be very large per cluster.
        required: false
        type: boolean
        default: false
      - name: show_plan_defaults
        in: query
        description: If showing plans, whether to show values that are left at their
          default value (less readable but more informative).
        required: false
        type: boolean
        default: false
      - name: show_settings
        in: query
        description: Whether to show cluster settings in the response.
        required: false
        type: boolean
        default: false
      - name: clear_transient
        in: query
        description: If set (defaults to false) then removes the transient section
          from all child resources, making it safe to reapply via an update
        required: false
        type: boolean
        default: false
      responses:
        '200':
          description: Standard response.
          schema:
            "$ref": "#/definitions/AppSearchResourceInfo"
        '404':
          description: 'The Deployment specified by {deployment_id} cannot be found.
            (code: `deployments.deployment_not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'We have failed you. (code: `deployments.deployment_resource_no_longer_exists`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_no_longer_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Info
  "/deployments/{deployment_id}/appsearch/{ref_id}/read_only_mode":
    get:
      tags:
      - Deployments
      summary: Set AppSearch read-only status
      description: Enable/Disable read-only mode on the given App Search resource.
      operationId: get-appsearch-read-only-mode
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment.
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      responses:
        '200':
          description: Standard response
          schema:
            "$ref": "#/definitions/ReadOnlyResponse"
        '404':
          description: 'The Resource specified by ref_id cannot be found. (code: `deployments.deployment_resource_not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'We have failed you. (code: `deployments.deployment_resource_no_longer_exists`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_no_longer_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: App Search - Read-only
    put:
      tags:
      - Deployments
      summary: Set AppSearch read-only status
      description: Enable/Disable read-only mode on the given App Search resource.
      operationId: set-appsearch-read-only-mode
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment.
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      - in: body
        name: body
        description: read-only request body
        required: true
        schema:
          "$ref": "#/definitions/ReadOnlyRequest"
      responses:
        '200':
          description: Standard response
          schema:
            "$ref": "#/definitions/ReadOnlyResponse"
        '404':
          description: 'The Resource specified by ref_id cannot be found. (code: `deployments.deployment_resource_not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'We have failed you. (code: `deployments.deployment_resource_no_longer_exists`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_no_longer_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: App Search - Read-only
  "/deployments/{deployment_id}/certificate-authority":
    get:
      tags:
      - Deployments
      summary: Get certificate authority
      description: Returns the certificate authority used to sign the certificates
        of this deployment.
      operationId: get-deployment-certificate-authority
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment.
        required: true
        type: string
      responses:
        '200':
          description: The certificate authority used to sign the certificates of
            this deployment
          schema:
            "$ref": "#/definitions/CertificateAuthority"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Elasticsearch Resource cannot be found. (code: `deployments.deployment_resource_not_found`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Trust
  "/deployments/{deployment_id}/elasticsearch/{ref_id}":
    get:
      tags:
      - Deployments
      summary: Get Deployment Elasticsearch Resource Info
      description: Get info about an Elasticsearch Resource belonging to a given Deployment.
      operationId: get-deployment-es-resource-info
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      - name: show_security
        in: query
        description: Whether to include the Elasticsearch 2.x security information
          in the response - can be large per cluster and also include credentials.
        required: false
        type: boolean
        default: false
      - name: show_metadata
        in: query
        description: Whether to include the full cluster metadata in the response
          - can be large per cluster and also include credentials.
        required: false
        type: boolean
        default: false
      - name: show_plans
        in: query
        description: Whether to include the full current and pending plan information
          in the response - can be large per cluster.
        required: false
        type: boolean
        default: true
      - name: show_plan_logs
        in: query
        description: Whether to include with the current and pending plan information
          the attempt log - can be very large per cluster.
        required: false
        type: boolean
        default: false
      - name: show_plan_history
        in: query
        description: Whether to include with the current and pending plan information
          the plan history- can be very large per cluster.
        required: false
        type: boolean
        default: false
      - name: show_plan_defaults
        in: query
        description: If showing plans, whether to show values that are left at their
          default value (less readable but more informative).
        required: false
        type: boolean
        default: false
      - name: convert_legacy_plans
        in: query
        description: If showing plans, whether to leave pre-2.0.0 plans in their legacy
          format (the default), or whether to update them to 2.0.x+ format (if 'true').
        required: false
        type: boolean
        default: false
      - name: show_system_alerts
        in: query
        description: Number of system alerts (such as forced restarts due to memory
          limits) to be included in the response - can be large per cluster. Negative
          numbers or 0 will not return field.
        required: false
        type: integer
        default: 0
      - name: show_settings
        in: query
        description: Whether to show cluster settings in the response.
        required: false
        type: boolean
        default: false
      - name: enrich_with_template
        in: query
        description: If showing plans, whether to enrich the plan by including the
          missing elements from the deployment template it is based on.
        required: false
        type: boolean
        default: true
      - name: clear_transient
        in: query
        description: If set (defaults to false) then removes the transient section
          from all child resources, making it safe to reapply via an update
        required: false
        type: boolean
        default: false
      responses:
        '200':
          description: Standard response.
          schema:
            "$ref": "#/definitions/ElasticsearchResourceInfo"
        '404':
          description: 'The Deployment specified by {deployment_id} cannot be found.
            (code: `deployments.deployment_not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'We have failed you. (code: `deployments.deployment_resource_no_longer_exists`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_no_longer_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Info
  "/deployments/{deployment_id}/elasticsearch/{ref_id}/_enable-ccr":
    post:
      tags:
      - Deployments
      summary: Migrate Elasticsearch and associated Kibana resources to enable CCR
      description: Migrates the specified Elasticsearch resource and its associated
        Kibana to enable CCR (if supported).
      operationId: enable-deployment-resource-ccr
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment.
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      - name: validate_only
        in: query
        description: When `true`, will not enable CCR but returns warnings if any
          elements may lose availability during CCR enablement
        required: false
        type: boolean
        default: false
      responses:
        '200':
          description: Standard response
          schema:
            "$ref": "#/definitions/DeploymentResourceCommandResponse"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Commands
  "/deployments/{deployment_id}/elasticsearch/{ref_id}/_enable-ilm":
    post:
      tags:
      - Deployments
      summary: Migrate Elasticsearch resource to use ILM
      description: Migrates the specified Elasticsearch resource to use ILM.
      operationId: enable-deployment-resource-ilm
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment.
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      - name: validate_only
        in: query
        description: When `true`, does not enable ILM but returns warnings if any
          applications may lose availability during ILM migration.
        required: false
        type: boolean
        default: false
      - in: body
        name: body
        description: Information to build the ILM policies that will be created
        required: true
        schema:
          "$ref": "#/definitions/EnableIlmRequest"
      responses:
        '200':
          description: Standard response
          schema:
            "$ref": "#/definitions/DeploymentResourceCommandResponse"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'We have failed you. (code: `deployments.deployment_resource_no_longer_exists`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_no_longer_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Commands
  "/deployments/{deployment_id}/elasticsearch/{ref_id}/_enable-slm":
    post:
      tags:
      - Deployments
      summary: Migrate Elasticsearch resource to use SLM
      description: Migrates the specified Elasticsearch resource to use SLM.
      operationId: enable-deployment-resource-slm
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment.
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      - name: validate_only
        in: query
        description: When `true`, does not enable SLM but returns warnings if any
          applications may lose availability during SLM migration.
        required: false
        type: boolean
        default: false
      responses:
        '200':
          description: Standard response
          schema:
            "$ref": "#/definitions/DeploymentResourceCommandResponse"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'We have failed you. (code: `deployments.deployment_resource_no_longer_exists`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_no_longer_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Commands
  "/deployments/{deployment_id}/elasticsearch/{ref_id}/_reset-password":
    post:
      tags:
      - Deployments
      summary: Reset 'elastic' user password
      description: Resets the password of the 'elastic' user.
      operationId: reset-elasticsearch-user-password
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment.
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      - name: check_completion
        in: query
        description: If true, will not reset elastic user password and instead will
          return a status code signaling whether or not the current credentials are
          ready to use (eg from creation or the last call to _reset_password)
        required: false
        type: boolean
        default: false
      responses:
        '200':
          description: The password reset was out carried successfully
          schema:
            "$ref": "#/definitions/ElasticsearchElasticUserPasswordResetResponse"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'Failed to reset the ''elastic'' user''s password. (code: `deployments.elasticsearch.password_reset_error`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.elasticsearch.password_reset_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Commands
  "/deployments/{deployment_id}/elasticsearch/{ref_id}/_restart":
    post:
      tags:
      - Deployments
      summary: Restart Deployment Elasticsearch Resource
      description: 'Restarts an Elasticsearch Resource. If a Resource is active: this
        command re-applies the existing plan but applies a "cluster_reboot", which
        issues a restart command and waits for it to complete. If a Resource is inactive:
        this command starts it up with the most recent successful plan.'
      operationId: restart-deployment-es-resource
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment.
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      - name: restore_snapshot
        in: query
        description: When set to true and restoring from shutdown, then will restore
          the cluster from the last snapshot (if available).
        required: false
        type: boolean
        default: true
      - name: skip_snapshot
        in: query
        description: If true, will not take a snapshot of the cluster before restarting.
        required: false
        type: boolean
        default: true
      - name: cancel_pending
        in: query
        description: If true, cancels any pending plans before restarting. If false
          and there are pending plans, returns an error.
        required: false
        type: boolean
        default: false
      - name: group_attribute
        in: query
        description: 'Indicates the property or properties used to divide the list
          of instances to restart in groups. Valid options are: ''\_\_all\_\_'' (restart
          all at once), ''\_\_zone\_\_'' by logical zone, ''\_\_name\_\_'' one instance
          at a time, or a comma-separated list of attributes of the instances'
        required: false
        type: string
        default: __zone__
      - name: shard_init_wait_time
        in: query
        description: 'The time, in seconds, to wait for shards that show no progress
          of initializing, before rolling the next group (default: 10 minutes)'
        required: false
        type: integer
        default: 600
      responses:
        '202':
          description: The restart command was issued successfully.
          schema:
            "$ref": "#/definitions/DeploymentResourceCommandResponse"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '422':
          description: 'The command sent to a Resource found the Resource in an illegal
            state, the error message gives more details. (code: `deployments.deployment_resource_plan_change_error`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_plan_change_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'A Resource that was previously stored no longer exists. (code:
            `deployments.deployment_resource_no_longer_exists`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_no_longer_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Commands
  "/deployments/{deployment_id}/elasticsearch/{ref_id}/_shutdown":
    post:
      tags:
      - Deployments
      summary: Shutdown Deployment Elasticsearch Resource
      description: Shutdown Elasticsearch Resource belonging to a given Deployment.
      operationId: shutdown-deployment-es-resource
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment.
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      - name: hide
        in: query
        description: Hide cluster on shutdown. Hidden clusters are not listed by default.
          Only applicable for Platform administrators.
        required: false
        type: boolean
      - name: skip_snapshot
        in: query
        description: If true, will skip taking a snapshot of the cluster before shutting
          the cluster down (if even possible).
        required: false
        type: boolean
        default: false
      responses:
        '200':
          description: Standard response.
          schema:
            "$ref": "#/definitions/DeploymentResourceCommandResponse"
        '400':
          description: 'Parameter is restricted and can only be set by a Platform
            administrator. (code: `deployments.restricted_parameter`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.restricted_parameter
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'A Resource that was previously stored no longer exists. (code:
            `deployments.deployment_resource_no_longer_exists`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_no_longer_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Commands
  "/deployments/{deployment_id}/elasticsearch/{ref_id}/eligible-remote-clusters":
    post:
      tags:
      - Deployments
      summary: Get eligible remote clusters
      description: Returns the list of deployments which contain eligible remote clusters
        for the elasticsearch resource.
      operationId: get-deployment-es-resource-eligible-remote-clusters
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment.
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      - in: body
        name: body
        description: "(Optional) The search query to run against all deployments containing
          eligible remote clusters. When not specified, all the eligible deployments
          are matched."
        required: false
        schema:
          "$ref": "#/definitions/SearchRequest"
      responses:
        '200':
          description: List of deployments which contains eligible remote clusters
            for the resource
          schema:
            "$ref": "#/definitions/DeploymentsSearchResponse"
        '400':
          description: 'The resource specified doesn''t yet have a valid version for
            the current plan or the pending plan. (code: `deployments.resource_does_not_have_a_valid_version`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.resource_does_not_have_a_valid_version
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Remote Clusters
  "/deployments/{deployment_id}/elasticsearch/{ref_id}/keystore":
    get:
      tags:
      - Deployments
      summary: Get the items in the Elasticsearch resource keystore
      description: Fetches the current fields and metadata (but not the values) of
        the keystore for the Elasticsearch resource.
      operationId: get-deployment-es-resource-keystore
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one)
        required: true
        type: string
      responses:
        '200':
          description: The contents of the Elasticsearch keystore, with values redacted
          schema:
            "$ref": "#/definitions/KeystoreContents"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'We have failed you. (code: `deployments.metadata_internal_error`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.metadata_internal_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment Resources - CRUD
    patch:
      tags:
      - Deployments
      summary: Add or remove items from the Elasticsearch resource keystore
      description: Adds the specified values to the Elasticsearch keystore, or removes
        the keys for the unspecified values.
      operationId: set-deployment-es-resource-keystore
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one)
        required: true
        type: string
      - name: validate_only
        in: query
        description: When `true`, does nothing except return the entries' allowlist
          and reloadability statuses.
        required: false
        type: boolean
        default: false
      - in: body
        name: body
        description: The new settings that will be applied to the keystore of the
          Elasticsearch resource.
        required: true
        schema:
          "$ref": "#/definitions/KeystoreContents"
      responses:
        '200':
          description: The new contents of the Elasticsearch keystore (or the proposed
            contents if validate_only is true)
          schema:
            "$ref": "#/definitions/KeystoreContents"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'We have failed you. (code: `deployments.metadata_internal_error`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.metadata_internal_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment Resources - CRUD
  "/deployments/{deployment_id}/elasticsearch/{ref_id}/remote-clusters":
    get:
      tags:
      - Deployments
      summary: Get certificate based remote clusters
      description: Returns the list of certificate based remote clusters for the elasticsearch
        resource.
      operationId: get-deployment-es-resource-remote-clusters
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment.
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      responses:
        '200':
          description: List of certificate based remote clusters for the resource
          schema:
            "$ref": "#/definitions/RemoteResources"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Remote Clusters
    put:
      tags:
      - Deployments
      summary: Set certificate based remote clusters
      description: Overwrites or creates the list of certificate based remote clusters
        for the elasticsearch resource.
      operationId: set-deployment-es-resource-remote-clusters
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment.
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      - in: body
        name: body
        description: List of certificate based remote clusters for the resource
        required: true
        schema:
          "$ref": "#/definitions/RemoteResources"
      responses:
        '202':
          description: The Remote Clusters were updated
          schema:
            "$ref": "#/definitions/EmptyResponse"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Remote Clusters
  "/deployments/{deployment_id}/elasticsearch/{ref_id}/snapshot/repository":
    get:
      tags:
      - Deployments
      summary: List the attached snapshot repositories
      description: Lists all the snapshot repositories this deployment has access
        to. These are snapshot repositories of other deployments that have been linked
        to this deployment.
      operationId: get-deployment-es-resource-snapshot-repository
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one)
        required: true
        type: string
      responses:
        '200':
          description: List of snapshot repositories for this deployment
          schema:
            "$ref": "#/definitions/SnapshotRepositories"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'We have failed you. (code: `deployments.metadata_internal_error`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.metadata_internal_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment Resources - CRUD
    post:
      tags:
      - Deployments
      summary: Create a snapshot repository for Elasticsearch resource
      description: 'Important: This API is currently in Tech Preview. While available
        for use, it is subject to change. Creates a snapshot dependency, allowing
        this cluster to access snapshots from the source deployment.'
      operationId: create-deployment-es-resource-snapshot-repository
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one)
        required: true
        type: string
      - in: body
        name: body
        description: The source deployment to link snapshots from
        required: true
        schema:
          "$ref": "#/definitions/CreateSnapshotDependencyRequest"
      responses:
        '202':
          description: The request was accepted and the configuration change will
            be processed asynchronously
          schema:
            "$ref": "#/definitions/CreateSnapshotDependencyResponse"
        '400':
          description: |-
            * Cannot create a snapshot dependency from a deployment to itself. (code: `deployments.snapshot_dependency_cannot_link_to_self`)
            * The request failed validation. (code: `clusters.cluster_invalid_plan`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.snapshot_dependency_cannot_link_to_self
              - clusters.cluster_invalid_plan
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: |-
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
            * The source deployment cannot be found. (code: `deployments.snapshot_dependency_source_not_found`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_not_found
              - deployments.snapshot_dependency_source_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'Failed to create snapshot dependency. (code: `deployments.snapshot_dependency_internal_error`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.snapshot_dependency_internal_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment Resources - CRUD
      x-state: Technical preview
  "/deployments/{deployment_id}/elasticsearch/{ref_id}/snapshot/repository/{repository_name}":
    delete:
      tags:
      - Deployments
      summary: Remove the attached snapshot repository
      description: Removes the attached snapshot repository. This is only possible
        if the repository is not in use anymore by any searchable snapshots.
      operationId: delete-deployment-es-resource-snapshot-repository
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one)
        required: true
        type: string
      - name: repository_name
        in: path
        description: The name of the snapshot repository to remove (e.g. _clone_abcd1234)
        required: true
        type: string
      responses:
        '200':
          description: ''
          schema:
            "$ref": "#/definitions/EmptyResponse"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
            * The snapshot repository specified by {repository_name} cannot be found. (code: `deployments.snapshot_dependency_not_found`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
              - deployments.snapshot_dependency_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'We have failed you. (code: `deployments.metadata_internal_error`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.metadata_internal_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment Resources - CRUD
  "/deployments/{deployment_id}/elasticsearch/{ref_id}/tiers":
    patch:
      tags:
      - Deployments
      summary: Update Elasticsearch tiers
      description: Updates the size and/or zone count of one or more Elasticsearch
        topology elements (tiers) within a Deployment.
      operationId: update-deployment-es-resource-tier
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one)
        required: true
        type: string
      - in: body
        name: body
        description: A map of tier IDs to their desired configuration
        required: true
        schema:
          "$ref": "#/definitions/TiersUpdateRequest"
      responses:
        '200':
          description: The tier configuration was updated and a plan change was initiated.
          schema:
            "$ref": "#/definitions/DeploymentUpdateResponse"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
            * One or more tier IDs in the request body are not valid for this deployment. (code: `deployments.tier_not_found`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
              - deployments.tier_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'We have failed you. (code: `deployments.metadata_internal_error`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.metadata_internal_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment Resources - CRUD
  "/deployments/{deployment_id}/enterprise_search/{ref_id}":
    get:
      tags:
      - Deployments
      summary: Get Deployment Enterprise Search Resource Info
      description: Get info about an Enterprise Search Resource belonging to a given
        Deployment.
      operationId: get-deployment-enterprise-search-resource-info
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      - name: show_metadata
        in: query
        description: Whether to include the full cluster metadata in the response
          - can be large per cluster and also include credentials.
        required: false
        type: boolean
        default: false
      - name: show_plans
        in: query
        description: Whether to include the full current and pending plan information
          in the response - can be large per cluster.
        required: false
        type: boolean
        default: true
      - name: show_plan_logs
        in: query
        description: Whether to include with the current and pending plan information
          the attempt log - can be very large per cluster.
        required: false
        type: boolean
        default: false
      - name: show_plan_history
        in: query
        description: Whether to include with the current and pending plan information
          the plan history- can be very large per cluster.
        required: false
        type: boolean
        default: false
      - name: show_plan_defaults
        in: query
        description: If showing plans, whether to show values that are left at their
          default value (less readable but more informative).
        required: false
        type: boolean
        default: false
      - name: show_settings
        in: query
        description: Whether to show cluster settings in the response.
        required: false
        type: boolean
        default: false
      - name: clear_transient
        in: query
        description: If set (defaults to false) then removes the transient section
          from all child resources, making it safe to reapply via an update
        required: false
        type: boolean
        default: false
      responses:
        '200':
          description: Standard response.
          schema:
            "$ref": "#/definitions/EnterpriseSearchResourceInfo"
        '404':
          description: 'The Deployment specified by {deployment_id} cannot be found.
            (code: `deployments.deployment_not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'We have failed you. (code: `deployments.deployment_resource_no_longer_exists`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_no_longer_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Info
  "/deployments/{deployment_id}/integrations_server/{ref_id}":
    get:
      tags:
      - Deployments
      summary: Get Deployment Integrations Server Resource Info
      description: Get info about an Integrations Server Resource belonging to a given
        Deployment.
      operationId: get-deployment-integrations-server-resource-info
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      - name: show_metadata
        in: query
        description: Whether to include the full cluster metadata in the response
          - can be large per cluster and also include credentials.
        required: false
        type: boolean
        default: false
      - name: show_plans
        in: query
        description: Whether to include the full current and pending plan information
          in the response - can be large per cluster.
        required: false
        type: boolean
        default: true
      - name: show_plan_logs
        in: query
        description: Whether to include with the current and pending plan information
          the attempt log - can be very large per cluster.
        required: false
        type: boolean
        default: false
      - name: show_plan_history
        in: query
        description: Whether to include with the current and pending plan information
          the plan history- can be very large per cluster.
        required: false
        type: boolean
        default: false
      - name: show_plan_defaults
        in: query
        description: If showing plans, whether to show values that are left at their
          default value (less readable but more informative).
        required: false
        type: boolean
        default: false
      - name: show_settings
        in: query
        description: Whether to show cluster settings in the response.
        required: false
        type: boolean
        default: false
      - name: clear_transient
        in: query
        description: If set (defaults to false) then removes the transient section
          from all child resources, making it safe to reapply via an update
        required: false
        type: boolean
        default: false
      responses:
        '200':
          description: Standard response.
          schema:
            "$ref": "#/definitions/IntegrationsServerResourceInfo"
        '404':
          description: 'The Deployment specified by {deployment_id} cannot be found.
            (code: `deployments.deployment_not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'We have failed you. (code: `deployments.deployment_resource_no_longer_exists`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_no_longer_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Info
  "/deployments/{deployment_id}/kibana/{ref_id}":
    get:
      tags:
      - Deployments
      summary: Get Deployment Kibana Resource Info
      description: Get info about a Kibana Resource belonging to a given Deployment.
      operationId: get-deployment-kib-resource-info
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      - name: show_metadata
        in: query
        description: Whether to include the full cluster metadata in the response
          - can be large per cluster and also include credentials.
        required: false
        type: boolean
        default: false
      - name: show_plans
        in: query
        description: Whether to include the full current and pending plan information
          in the response - can be large per cluster.
        required: false
        type: boolean
        default: true
      - name: show_plan_logs
        in: query
        description: Whether to include with the current and pending plan information
          the attempt log - can be very large per cluster.
        required: false
        type: boolean
        default: false
      - name: show_plan_history
        in: query
        description: Whether to include with the current and pending plan information
          the plan history- can be very large per cluster.
        required: false
        type: boolean
        default: false
      - name: show_plan_defaults
        in: query
        description: If showing plans, whether to show values that are left at their
          default value (less readable but more informative).
        required: false
        type: boolean
        default: false
      - name: convert_legacy_plans
        in: query
        description: If showing plans, whether to leave pre-2.0.0 plans in their legacy
          format (the default), or whether to update them to 2.0.x+ format (if 'true').
        required: false
        type: boolean
        default: false
      - name: show_settings
        in: query
        description: Whether to show cluster settings in the response.
        required: false
        type: boolean
        default: false
      - name: clear_transient
        in: query
        description: If set (defaults to false) then removes the transient section
          from all child resources, making it safe to reapply via an update
        required: false
        type: boolean
        default: false
      responses:
        '200':
          description: Standard response.
          schema:
            "$ref": "#/definitions/KibanaResourceInfo"
        '404':
          description: 'The Deployment specified by {deployment_id} cannot be found.
            (code: `deployments.deployment_not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'We have failed you. (code: `deployments.deployment_resource_no_longer_exists`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_no_longer_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Info
  "/deployments/{deployment_id}/migrate_template":
    get:
      tags:
      - Deployments
      summary: Build request to migrate deployment to a different template
      description: Returns a deployment update request that would migrate this deployment
        to a different template.
      operationId: migrate-deployment-template
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment
        required: true
        type: string
      - name: template_id
        in: query
        description: The ID of the deployment template to migrate to
        required: true
        type: string
      - name: skip_instance_metrics_check
        in: query
        description: If true, will skip the instance metrics check for memory and
          disk usage calculations
        required: false
        type: boolean
        default: false
      responses:
        '200':
          description: The request was valid and the deployment can be migrated to
            the template with the provided ID.
          schema:
            "$ref": "#/definitions/DeploymentUpdateRequest"
        '400':
          description: The deployment cannot be successfully migrated to the template
            with the provided ID.
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '401':
          description: You are not authorized to perform this action.
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: 'The Deployment specified by {deployment_id} cannot be found.
            (code: `deployments.deployment_not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - CRUD
  "/deployments/{deployment_id}/tags":
    get:
      tags:
      - Deployments
      summary: Get the tags for a Deployment
      description: Returns the tags for a Deployment.
      operationId: get-deployment-tags
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment
        required: true
        type: string
      responses:
        '200':
          description: The deployment tags were successfully returned
          schema:
            "$ref": "#/definitions/DeploymentTagsResponse"
        '404':
          description: 'The Deployment specified by {deployment_id} cannot be found.
            (code: `deployments.deployment_not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - CRUD
    put:
      tags:
      - Deployments
      summary: Set the tags for a Deployment
      description: Sets the tags for a Deployment, replacing any existing tags.
      operationId: set-deployment-tags
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment
        required: true
        type: string
      - in: body
        name: body
        description: The tags to set on the deployment.
        required: true
        schema:
          "$ref": "#/definitions/DeploymentTagsResponse"
      responses:
        '200':
          description: The deployment tags were successfully updated
          schema:
            "$ref": "#/definitions/DeploymentTagsResponse"
        '400':
          description: |-
            * The number of tags exceeds the maximum of 64 allowed per deployment. (code: `deployments.too_many_tags`)
            * A tag key exceeds the maximum of 32 characters or a tag value exceeds the maximum of 128 characters. (code: `deployments.lengthy_key_or_value`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.too_many_tags
              - deployments.lengthy_key_or_value
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: 'The Deployment specified by {deployment_id} cannot be found.
            (code: `deployments.deployment_not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - CRUD
  "/deployments/{deployment_id}/upgrade_assistant/status":
    get:
      tags:
      - Deployments
      summary: Get Deployment upgrade assistant status
      description: Get details about an Elasticsearch resource belonging to a given
        deployment.
      operationId: get-deployment-upgrade-assistant-status
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment
        required: true
        type: string
      - name: target_version
        in: query
        description: If present, value is included in resource request to provide
          additional context (only supported for Kibana)
        required: false
        type: string
      responses:
        '200':
          description: The Upgrade Assistant returned the status successfully
          schema:
            "$ref": "#/definitions/DeploymentUpgradeAssistantStatusResponse"
        '404':
          description: 'The Deployment specified by {deployment_id} cannot be found.
            (code: `deployments.deployment_not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Upgrade Assistant
  "/deployments/{deployment_id}/{resource_kind}/{ref_id}/_restore":
    post:
      tags:
      - Deployments
      summary: Restores a shutdown resource
      description: Restores a shutdown resource belonging to a given Deployment.
      operationId: restore-deployment-resource
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment
        required: true
        type: string
      - name: resource_kind
        in: path
        description: The kind of resource
        required: true
        type: string
        enum:
        - elasticsearch
        - kibana
        - apm
        - appsearch
        - enterprise_search
        - integrations_server
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one)
        required: true
        type: string
      - name: restore_snapshot
        in: query
        description: Whether or not to restore a snapshot for those resources that
          allow it.
        required: false
        type: boolean
        default: false
      responses:
        '200':
          description: Standard Deployment Resource Crud Response
          schema:
            "$ref": "#/definitions/DeploymentResourceCrudResponse"
        '400':
          description: |-
            * The Resource does not have a pending plan. (code: `deployments.resource_does_not_have_a_pending_plan`)
            * The resource is not shut down. (code: `deployments.resource_not_shutdown`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.resource_does_not_have_a_pending_plan
              - deployments.resource_not_shutdown
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: 'The Deployment specified by {deployment_id} cannot be found.
            (code: `deployments.deployment_not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment Resources - CRUD
  "/deployments/{deployment_id}/{resource_kind}/{ref_id}/instances/_start":
    post:
      tags:
      - Deployments
      summary: Start all instances
      description: Starts all instances belonging to a Deployment Resource.
      operationId: start-deployment-resource-instances-all
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment.
        required: true
        type: string
      - name: resource_kind
        in: path
        description: The kind of resource (one of elasticsearch, kibana, apm, or integrations_server).
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      responses:
        '202':
          description: The start command was issued successfully.
          schema:
            "$ref": "#/definitions/DeploymentResourceCommandResponse"
        '403':
          description: 'The start maintenance mode command was prohibited for the
            given Resource. (code: `deployments.instance_update_prohibited_error`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.instance_update_prohibited_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
            * One or more instances of the given resource type are missing. (code: `deployments.instances_missing_on_update_error`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
              - deployments.instances_missing_on_update_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'A Resource that was previously stored no longer exists. (code:
            `deployments.deployment_resource_no_longer_exists`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_no_longer_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Commands
  "/deployments/{deployment_id}/{resource_kind}/{ref_id}/instances/_stop":
    post:
      tags:
      - Deployments
      summary: Stop all instances
      description: Stops all instances belonging to a Deployment Resource.
      operationId: stop-deployment-resource-instances-all
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment.
        required: true
        type: string
      - name: resource_kind
        in: path
        description: The kind of resource (one of elasticsearch, kibana, apm, or integrations_server).
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      responses:
        '202':
          description: The stop command was issued successfully.
          schema:
            "$ref": "#/definitions/DeploymentResourceCommandResponse"
        '403':
          description: 'The stop maintenance mode command was prohibited for the given
            Resource. (code: `deployments.instance_update_prohibited_error`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.instance_update_prohibited_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
            * One or more instances of the given resource type are missing. (code: `deployments.instances_missing_on_update_error`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
              - deployments.instances_missing_on_update_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'A Resource that was previously stored no longer exists. (code:
            `deployments.deployment_resource_no_longer_exists`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_no_longer_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Commands
  "/deployments/{deployment_id}/{resource_kind}/{ref_id}/instances/maintenance-mode/_start":
    post:
      tags:
      - Deployments
      summary: Start maintenance mode (all instances)
      description: Starts maintenance mode of all instances belonging to a Deployment
        Resource.
      operationId: start-deployment-resource-instances-all-maintenance-mode
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment.
        required: true
        type: string
      - name: resource_kind
        in: path
        description: The kind of resource (one of elasticsearch, kibana, apm, or integrations_server).
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      responses:
        '202':
          description: The start maintenance command was issued successfully.
          schema:
            "$ref": "#/definitions/DeploymentResourceCommandResponse"
        '403':
          description: 'The start maintenance mode command was prohibited for the
            given Resource. (code: `deployments.instance_update_prohibited_error`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.instance_update_prohibited_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
            * One or more instances of the given resource type are missing. (code: `deployments.instances_missing_on_update_error`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
              - deployments.instances_missing_on_update_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'A Resource that was previously stored no longer exists. (code:
            `deployments.deployment_resource_no_longer_exists`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_no_longer_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Commands
  "/deployments/{deployment_id}/{resource_kind}/{ref_id}/instances/maintenance-mode/_stop":
    post:
      tags:
      - Deployments
      summary: Stop maintenance mode (all instances)
      description: Stops maintenance mode of all instances belonging to a Deployment
        Resource.
      operationId: stop-deployment-resource-instances-all-maintenance-mode
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment.
        required: true
        type: string
      - name: resource_kind
        in: path
        description: The kind of resource (one of elasticsearch, kibana, apm, or integrations_server).
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      responses:
        '202':
          description: The stop maintenance mode command was issued successfully.
          schema:
            "$ref": "#/definitions/DeploymentResourceCommandResponse"
        '403':
          description: 'The stop maintenance mode command was prohibited for the given
            Resource. (code: `deployments.instance_update_prohibited_error`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.instance_update_prohibited_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
            * One or more instances of the given resource type are missing. (code: `deployments.instances_missing_on_update_error`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
              - deployments.instances_missing_on_update_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'A Resource that was previously stored no longer exists. (code:
            `deployments.deployment_resource_no_longer_exists`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_no_longer_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Commands
  "/deployments/{deployment_id}/{resource_kind}/{ref_id}/instances/{instance_ids}/_start":
    post:
      tags:
      - Deployments
      summary: Start instances
      description: Starts instances belonging to a Deployment Resource.
      operationId: start-deployment-resource-instances
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment.
        required: true
        type: string
      - name: resource_kind
        in: path
        description: The kind of resource (one of elasticsearch, kibana, apm, or integrations_server).
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      - name: instance_ids
        in: path
        description: A comma-separated list of instance identifiers.
        required: true
        type: array
        items:
          type: string
        collectionFormat: csv
      - name: ignore_missing
        in: query
        description: If true and the instance does not exist then quietly proceed
          to the next instance, otherwise treated as an error
        required: false
        type: boolean
        default: false
      responses:
        '202':
          description: The start command was issued successfully.
          schema:
            "$ref": "#/definitions/DeploymentResourceCommandResponse"
        '403':
          description: 'The start maintenance mode command was prohibited for the
            given Resource. (code: `deployments.instance_update_prohibited_error`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.instance_update_prohibited_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
            * One or more instances of the given resource type are missing. (code: `deployments.instances_missing_on_update_error`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
              - deployments.instances_missing_on_update_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'A Resource that was previously stored no longer exists. (code:
            `deployments.deployment_resource_no_longer_exists`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_no_longer_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Commands
  "/deployments/{deployment_id}/{resource_kind}/{ref_id}/instances/{instance_ids}/_stop":
    post:
      tags:
      - Deployments
      summary: Stop instances
      description: Stops instances belonging to a Deployment Resource.
      operationId: stop-deployment-resource-instances
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment.
        required: true
        type: string
      - name: resource_kind
        in: path
        description: The kind of resource (one of elasticsearch, kibana, apm, or integrations_server).
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      - name: instance_ids
        in: path
        description: A comma-separated list of instance identifiers.
        required: true
        type: array
        items:
          type: string
        collectionFormat: csv
      - name: ignore_missing
        in: query
        description: If true and the instance does not exist then quietly proceed
          to the next instance, otherwise treated as an error.
        required: false
        type: boolean
        default: false
      responses:
        '202':
          description: The stop command was issued successfully.
          schema:
            "$ref": "#/definitions/DeploymentResourceCommandResponse"
        '403':
          description: 'The start maintenance mode command was prohibited for the
            given Resource. (code: `deployments.instance_update_prohibited_error`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.instance_update_prohibited_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
            * One or more instances of the given resource type are missing. (code: `deployments.instances_missing_on_update_error`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
              - deployments.instances_missing_on_update_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'A Resource that was previously stored no longer exists. (code:
            `deployments.deployment_resource_no_longer_exists`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_no_longer_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Commands
  "/deployments/{deployment_id}/{resource_kind}/{ref_id}/instances/{instance_ids}/maintenance-mode/_start":
    post:
      tags:
      - Deployments
      summary: Start maintenance mode
      description: Starts maintenance mode of instances belonging to a Deployment
        Resource.
      operationId: start-deployment-resource-maintenance-mode
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment.
        required: true
        type: string
      - name: resource_kind
        in: path
        description: The kind of resource (one of elasticsearch, kibana, apm, or integrations_server).
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      - name: instance_ids
        in: path
        description: A comma-separated list of instance identifiers.
        required: true
        type: array
        items:
          type: string
        collectionFormat: csv
      - name: ignore_missing
        in: query
        description: If true and the instance does not exist then quietly proceed
          to the next instance, otherwise treated as an error.
        required: false
        type: boolean
        default: false
      responses:
        '202':
          description: The start maintenance command was issued successfully.
          schema:
            "$ref": "#/definitions/DeploymentResourceCommandResponse"
        '403':
          description: 'The start maintenance mode command was prohibited for the
            given Resource. (code: `deployments.instance_update_prohibited_error`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.instance_update_prohibited_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
            * One or more instances of the given resource type are missing. (code: `deployments.instances_missing_on_update_error`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
              - deployments.instances_missing_on_update_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'A Resource that was previously stored no longer exists. (code:
            `deployments.deployment_resource_no_longer_exists`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_no_longer_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Commands
  "/deployments/{deployment_id}/{resource_kind}/{ref_id}/instances/{instance_ids}/maintenance-mode/_stop":
    post:
      tags:
      - Deployments
      summary: Stop maintenance mode
      description: Stops maintenance mode of instances belonging to a Resource.
      operationId: stop-deployment-resource-maintenance-mode
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment.
        required: true
        type: string
      - name: resource_kind
        in: path
        description: The kind of resource (one of elasticsearch, kibana, apm, or integrations_server).
        required: true
        type: string
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      - name: instance_ids
        in: path
        description: A comma-separated list of instance identifiers.
        required: true
        type: array
        items:
          type: string
        collectionFormat: csv
      - name: ignore_missing
        in: query
        description: If true and the instance does not exist then quietly proceed
          to the next instance, otherwise treated as an error.
        required: false
        type: boolean
        default: false
      responses:
        '202':
          description: The stop maintenance mode command was issued successfully.
          schema:
            "$ref": "#/definitions/DeploymentResourceCommandResponse"
        '403':
          description: 'The stop maintenance mode command was prohibited for the given
            Resource. (code: `deployments.instance_update_prohibited_error`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.instance_update_prohibited_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
            * One or more instances of the given resource type are missing. (code: `deployments.instances_missing_on_update_error`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
              - deployments.instances_missing_on_update_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'A Resource that was previously stored no longer exists. (code:
            `deployments.deployment_resource_no_longer_exists`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_no_longer_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Commands
  "/deployments/{deployment_id}/{resource_kind}/{ref_id}/plan/pending":
    delete:
      tags:
      - Deployments
      summary: Cancel resource pending plan
      description: Cancels the pending plan of a Resource belonging to a given Deployment.
      operationId: cancel-deployment-resource-pending-plan
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment
        required: true
        type: string
      - name: resource_kind
        in: path
        description: The kind of resource
        required: true
        type: string
        enum:
        - elasticsearch
        - kibana
        - apm
        - appsearch
        - enterprise_search
        - integrations_server
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one)
        required: true
        type: string
      - name: force_delete
        in: query
        description: When `true`, deletes the pending plan instead of attempting a
          graceful cancellation. The default is `false`.
        required: false
        type: boolean
        default: false
      - name: ignore_missing
        in: query
        description: When `true`, returns successfully, even when plans are missing.
          The default is `false`.
        required: false
        type: boolean
        default: false
      responses:
        '200':
          description: Standard Deployment Resource Crud Response
          schema:
            "$ref": "#/definitions/DeploymentResourceCrudResponse"
        '400':
          description: 'The Resource does not have a pending plan. (code: `deployments.resource_does_not_have_a_pending_plan`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.resource_does_not_have_a_pending_plan
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: 'The Deployment specified by {deployment_id} cannot be found.
            (code: `deployments.deployment_not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '409':
          description: 'Vacate plans can only be cancelled by platform administrators.
            (code: `deployments.vacate_plan_cancellation_restricted`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.vacate_plan_cancellation_restricted
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'We have failed you. (code: `deployments.deployment_resource_no_longer_exists`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_no_longer_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment Resources - CRUD
  "/deployments/{deployment_id}/{resource_kind}/{ref_id}/user_settings":
    get:
      tags:
      - Deployments
      summary: Get the user settings of a Deployment resource
      description: Retrieves the current user-defined settings for a resource belonging
        to a given Deployment.
      operationId: get-deployment-resource-user-settings
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment
        required: true
        type: string
      - name: resource_kind
        in: path
        description: The kind of resource
        required: true
        type: string
        enum:
        - elasticsearch
        - kibana
        - apm
        - appsearch
        - enterprise_search
        - integrations_server
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one)
        required: true
        type: string
      responses:
        '200':
          description: The current user-defined settings for the resource
          schema:
            "$ref": "#/definitions/DeploymentResourceUserSettingsResponse"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'We have failed you. (code: `deployments.metadata_internal_error`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.metadata_internal_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment Resources - CRUD
    put:
      tags:
      - Deployments
      summary: Update user settings for a deployment resource
      description: Replaces the component-level user-defined settings for the specified
        resource kind in the deployment. All existing component-level user settings
        are overwritten with the provided values. Submitting an empty object will
        remove all component-level user settings for the resource. This endpoint does
        not support tier/topology-level user settings overrides.
      operationId: update-deployment-resource-user-settings
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment
        required: true
        type: string
      - name: resource_kind
        in: path
        description: The kind of resource
        required: true
        type: string
        enum:
        - elasticsearch
        - kibana
        - apm
        - appsearch
        - enterprise_search
        - integrations_server
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one)
        required: true
        type: string
      - in: body
        name: body
        description: The user settings to apply to the deployment resource. Replaces
          all existing user settings.
        required: true
        schema:
          "$ref": "#/definitions/DeploymentResourceUserSettings"
      responses:
        '200':
          description: The updated user settings for the deployment resource
          schema:
            "$ref": "#/definitions/DeploymentResourceUserSettings"
        '400':
          description: |-
            * Plan or user settings validation failed. (code: `clusters.cluster_invalid_plan`)
            * The deployment plan could not be applied; see the error message. (code: `user_settings.update_failed`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - clusters.cluster_invalid_plan
              - user_settings.update_failed
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment Resources - CRUD
  "/deployments/{deployment_id}/{stateless_resource_kind}/{ref_id}/_restart":
    post:
      tags:
      - Deployments
      summary: Restart Deployment Stateless Resource
      description: 'Restarts a Stateless Resource. If a Resource is active: this command
        re-applies the existing plan but applies a "cluster_reboot", which issues
        a restart command and waits for it to complete. If a Resource is inactive:
        this command starts it up with the most recent successful plan.'
      operationId: restart-deployment-stateless-resource
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment.
        required: true
        type: string
      - name: stateless_resource_kind
        in: path
        description: The kind of stateless resource
        required: true
        type: string
        enum:
        - kibana
        - apm
        - appsearch
        - enterprise_search
        - integrations_server
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      - name: cancel_pending
        in: query
        description: If true, cancels any pending plans before restarting. If false
          and there are pending plans, returns an error.
        required: false
        type: boolean
        default: false
      responses:
        '202':
          description: The restart command was issued successfully
          schema:
            "$ref": "#/definitions/DeploymentResourceCommandResponse"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '422':
          description: 'The command sent to a Resource found the Resource in an illegal
            state, the error message gives more details. (code: `deployments.deployment_resource_plan_change_error`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_plan_change_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'We have failed you. (code: `deployments.deployment_resource_no_longer_exists`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_no_longer_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Commands
  "/deployments/{deployment_id}/{stateless_resource_kind}/{ref_id}/_shutdown":
    post:
      tags:
      - Deployments
      summary: Shutdown Deployment Stateless Resource
      description: |-
        Shut down Stateless Resource belonging to a given Deployment.
        Kibana cannot be shut down on Elasticsearch Service as it is required for Elasticsearch administrative functions, such as Snapshot Lifecycle Management and version upgrades.
      operationId: shutdown-deployment-stateless-resource
      produces:
      - application/json
      parameters:
      - name: deployment_id
        in: path
        description: Identifier for the Deployment.
        required: true
        type: string
      - name: stateless_resource_kind
        in: path
        description: The kind of stateless resource
        required: true
        type: string
        enum:
        - kibana
        - apm
        - appsearch
        - enterprise_search
        - integrations_server
      - name: ref_id
        in: path
        description: User-specified RefId for the Resource (or '_main' if there is
          only one).
        required: true
        type: string
      - name: hide
        in: query
        description: Hide cluster on shutdown. Hidden clusters are not listed by default.
          Only applicable for Platform administrators.
        required: false
        type: boolean
      - name: skip_snapshot
        in: query
        description: If true, will skip taking a snapshot of the cluster before shutting
          the cluster down (if even possible)
        required: false
        type: boolean
        default: false
      responses:
        '200':
          description: Standard response
          schema:
            "$ref": "#/definitions/DeploymentResourceCommandResponse"
        '400':
          description: 'Parameter is restricted and can only be set by a Platform
            administrator. (code: `deployments.restricted_parameter`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.restricted_parameter
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: |-
            * The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`)
            * The Resource specified by {ref_id} cannot be found. (code: `deployments.deployment_resource_not_found`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_not_found
              - deployments.deployment_resource_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '500':
          description: 'We have failed you. (code: `deployments.deployment_resource_no_longer_exists`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - deployments.deployment_resource_no_longer_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Deployment - Commands
  "/organizations":
    get:
      tags:
      - Organizations
      - IamService
      summary: List organizations
      description: Fetch organizations available to the current user. Currently unavailable
        in self-hosted ECE.
      operationId: list-organizations
      produces:
      - application/json
      parameters: []
      responses:
        '200':
          description: Organizations fetched successfully
          schema:
            "$ref": "#/definitions/OrganizationList"
        '401':
          description: 'User not found. (code: `user.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - user.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Organizations
  "/organizations/invitations/{invitation_token}":
    get:
      tags:
      - Organizations
      - IamService
      summary: Get organization invitation
      description: Gets a single invitation to an organization by token. Currently
        unavailable in self-hosted ECE.
      operationId: get-organization-invitation
      produces:
      - application/json
      parameters:
      - name: invitation_token
        in: path
        description: Organization invitation token
        required: true
        type: string
      responses:
        '200':
          description: Organization invitation fetched successfully
          schema:
            "$ref": "#/definitions/OrganizationInvitation"
        '404':
          description: 'Invitation not found. (code: `organization.invitation_not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.invitation_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Organizations
  "/organizations/invitations/{invitation_token}/_accept":
    post:
      tags:
      - Organizations
      - IamService
      summary: Accept an organization invitation
      description: Accepts an organization invitation. Currently unavailable in self-hosted
        ECE.
      operationId: accept-organization-invitation
      produces:
      - application/json
      parameters:
      - name: invitation_token
        in: path
        description: Organization invitation token
        required: true
        type: string
      responses:
        '200':
          description: Organization invitation accepted successfully
          schema:
            "$ref": "#/definitions/EmptyResponse"
        '400':
          description: 'User already belongs to organization. (code: `organization.user_organization_already_belongs`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.user_organization_already_belongs
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '403':
          description: 'The current user authentication is not valid. (code: `root.invalid_authentication`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - root.invalid_authentication
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: |-
            * Organization not found. (code: `organization.not_found`)
            * User not found. (code: `user.not_found`)
            * Invitation not found. (code: `organization.invitation_not_found`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.not_found
              - user.not_found
              - organization.invitation_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Organizations
  "/organizations/{organization_id}":
    get:
      tags:
      - Organizations
      - IamService
      summary: Fetch organization information
      description: Fetch a single organization by id. Currently unavailable in self-hosted
        ECE.
      operationId: get-organization
      produces:
      - application/json
      parameters:
      - name: organization_id
        in: path
        description: Identifier for the Organization
        required: true
        type: string
      responses:
        '200':
          description: Organization fetched successfully
          schema:
            "$ref": "#/definitions/Organization"
        '401':
          description: 'User not found. (code: `user.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - user.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '403':
          description: 'The current user does not have access to the requested organization.
            (code: `organization.invalid_access`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.invalid_access
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: 'Organization not found. (code: `organization.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Organizations
    put:
      tags:
      - Organizations
      - IamService
      summary: Update organization
      description: |-
        > WARNING
        > This endpoint is deprecated and scheduled to be removed in the next major version.

        Updates an existing organization. Currently unavailable in self-hosted ECE.
      operationId: update-organization
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - name: organization_id
        in: path
        description: Identifier for the Organization
        required: true
        type: string
      - in: body
        name: body
        description: The organization to update
        required: true
        schema:
          "$ref": "#/definitions/OrganizationRequest"
      responses:
        '200':
          description: Organization updated successfully
          schema:
            "$ref": "#/definitions/Organization"
        '400':
          description: |-
            * Name must be between 2 and 30 characters. (code: `organization.invalid_name`)
            * User already has an organization. (code: `organization.user_organization_already_exists`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.invalid_name
              - organization.user_organization_already_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '401':
          description: You are not authorized to perform this action
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '403':
          description: 'The current user does not have access to the requested organization.
            (code: `organization.invalid_access`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.invalid_access
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: 'Organization not found. (code: `organization.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Organizations
  "/organizations/{organization_id}/domains":
    get:
      tags:
      - Organizations
      - IamService
      summary: Get domain claims
      description: Get domain claims for the organization.
      operationId: domain-claim-get-domain-claims
      produces:
      - application/json
      parameters:
      - name: organization_id
        in: path
        description: Identifier for the Organization
        required: true
        type: string
      responses:
        '200':
          description: The claimed domains for the organization
          schema:
            "$ref": "#/definitions/GetOrganizationClaimedDomainsResponse"
        '404':
          description: 'Organization not found. (code: `organization.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: IamService
    delete:
      tags:
      - Organizations
      - IamService
      summary: Delete domain claim
      description: Delete domain claim.
      operationId: domain-claim-delete
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - name: organization_id
        in: path
        description: Identifier for the Organization
        required: true
        type: string
      - in: body
        name: body
        description: The domain claim to remove
        required: true
        schema:
          "$ref": "#/definitions/DeleteDomainClaimRequest"
      responses:
        '200':
          description: With status 200 ok to signal the domain has been unclaimed
          schema:
            "$ref": "#/definitions/EmptyResponse"
        '400':
          description: 'An IdP is configured for the organization. (code: `org.idp.idp_configured`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - org.idp.idp_configured
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: 'Organization not found. (code: `organization.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '409':
          description: 'Concurrent organization modification. (code: `org.domain_claim.concurrent_organization_modification`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - org.domain_claim.concurrent_organization_modification
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: IamService
  "/organizations/{organization_id}/domains/_generate_verification_code":
    post:
      tags:
      - Organizations
      - IamService
      summary: Generate verification code
      description: Generate verification code for the domain claim challenge.
      operationId: domain-claim-generate-verification-code
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - name: organization_id
        in: path
        description: Identifier for the Organization
        required: true
        type: string
      - in: body
        name: body
        description: The verification code request
        required: true
        schema:
          "$ref": "#/definitions/VerificationCodeRequest"
      responses:
        '200':
          description: The verification code response
          schema:
            "$ref": "#/definitions/VerificationCodeResponse"
        '404':
          description: 'Organization not found. (code: `organization.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: IamService
  "/organizations/{organization_id}/domains/_verify":
    post:
      tags:
      - Organizations
      - IamService
      summary: Verify domain claim
      description: Verify domain claim challenge.
      operationId: domain-claim-verify-domain
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - name: organization_id
        in: path
        description: Identifier for the Organization
        required: true
        type: string
      - in: body
        name: body
        description: The verification code request
        required: true
        schema:
          "$ref": "#/definitions/DomainVerificationRequest"
      responses:
        '200':
          description: With status 200 ok to signal the domain has been claimed
          schema:
            "$ref": "#/definitions/EmptyResponse"
        '400':
          description: 'Domain claim already exists. (code: `org.domain_claim.already_exists`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - org.domain_claim.already_exists
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: 'Organization not found. (code: `organization.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '409':
          description: 'Concurrent organization modification. (code: `org.domain_claim.concurrent_organization_modification`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - org.domain_claim.concurrent_organization_modification
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '449':
          description: The challenge can not be verified at the moment, please retry
            later
          schema:
            "$ref": "#/definitions/EmptyResponse"
      x-doc:
        tag: IamService
  "/organizations/{organization_id}/idp":
    get:
      tags:
      - Organizations
      - IamService
      summary: Get organization IdP
      description: Gets the oranization's IdP. Currently unavailable in self-hosted
        ECE.
      operationId: get-organization-idp
      produces:
      - application/json
      parameters:
      - name: organization_id
        in: path
        description: Identifier for the Organization
        required: true
        type: string
      responses:
        '200':
          description: The IdP info
          schema:
            "$ref": "#/definitions/OrganizationIdp"
        '404':
          description: 'IdP was not configured yet. (code: `org.idp.idp_not_configured`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - org.idp.idp_not_configured
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Organizations
    put:
      tags:
      - Organizations
      - IamService
      summary: Setup organization IdP
      description: Sets up an organization's IdP. Currently unavailable in self-hosted
        ECE.
      operationId: setup-organization-idp
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - name: organization_id
        in: path
        description: Identifier for the Organization
        required: true
        type: string
      - in: body
        name: body
        description: The IdP configuration
        required: true
        schema:
          "$ref": "#/definitions/IdpConfigurationRequest"
      responses:
        '200':
          description: The IdP info
          schema:
            "$ref": "#/definitions/OrganizationIdp"
        '404':
          description: 'Organization not found. (code: `organization.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Organizations
    delete:
      tags:
      - Organizations
      - IamService
      summary: Tear down organization IdP
      description: Tear down up an organization's IdP. Currently unavailable in self-hosted
        ECE.
      operationId: teardown-organization-idp
      produces:
      - application/json
      parameters:
      - name: organization_id
        in: path
        description: Identifier for the Organization
        required: true
        type: string
      responses:
        '200':
          description: The IdP was successfully removed
          schema:
            "$ref": "#/definitions/EmptyResponse"
        '404':
          description: 'Organization IdP not configured. (code: `org.idp.idp_not_configured`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - org.idp.idp_not_configured
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Organizations
  "/organizations/{organization_id}/idp/metadata.xml":
    get:
      tags:
      - Organizations
      - IamService
      summary: Get organization service provider SAML2 metadata.xml for configuring
        the identity provider
      description: Gets the oranization's IdP metadata.xml. Currently unavailable
        in self-hosted ECE.
      operationId: get-organization-idp-metadata
      produces:
      - application/xml
      parameters:
      - name: organization_id
        in: path
        description: Identifier for the Organization
        required: true
        type: string
      responses:
        '200':
          description: The IdP info
          schema:
            type: string
        '404':
          description: 'IdP was not configured yet. (code: `org.idp.idp_not_configured`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - org.idp.idp_not_configured
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Organizations
  "/organizations/{organization_id}/invitations":
    get:
      tags:
      - Organizations
      - IamService
      summary: List organization invitations
      description: Fetch open invitations to the selected organization. Currently
        unavailable in self-hosted ECE.
      operationId: list-organization-invitations
      produces:
      - application/json
      parameters:
      - name: organization_id
        in: path
        description: Identifier for the Organization
        required: true
        type: string
      responses:
        '200':
          description: Organization invitations fetched successfully
          schema:
            "$ref": "#/definitions/OrganizationInvitations"
        '404':
          description: 'Organization not found. (code: `organization.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Organizations
    post:
      tags:
      - Organizations
      - IamService
      summary: Create organization invitations
      description: Creates or refreshes organization invitations. Currently unavailable
        in self-hosted ECE.
      operationId: create-organization-invitations
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - name: organization_id
        in: path
        description: Identifier for the Organization
        required: true
        type: string
      - in: body
        name: body
        description: The organization invitations to create or refresh
        required: true
        schema:
          "$ref": "#/definitions/OrganizationInvitationRequest"
      responses:
        '201':
          description: Organization invitations created successfully
          schema:
            "$ref": "#/definitions/OrganizationInvitations"
        '400':
          description: |-
            * Invitation email was not valid. (code: `organization.invitation_invalid_email`)
            * Invitation already sent. (code: `organization.invitation_already_exists`)
            * User already belongs to organization. (code: `organization.user_organization_already_belongs`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.invitation_invalid_email
              - organization.invitation_already_exists
              - organization.user_organization_already_belongs
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '403':
          description: 'The current user authentication is not valid. (code: `root.invalid_authentication`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - root.invalid_authentication
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: |-
            * Organization not found. (code: `organization.not_found`)
            * User not found. (code: `user.not_found`)
            * Invitation sender does not belong to organization. (code: `organization.user_organization_does_not_belong`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.not_found
              - user.not_found
              - organization.user_organization_does_not_belong
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '429':
          description: 'Request exceeds organization invitation creation rate limits.
            (code: `organization.invitations_rate_limit_exceeded`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.invitations_rate_limit_exceeded
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Organizations
  "/organizations/{organization_id}/invitations/{invitation_tokens}":
    delete:
      tags:
      - Organizations
      - IamService
      summary: Delete organization invitations
      description: Deletes one or more organization invitations. Currently unavailable
        in self-hosted ECE.
      operationId: delete-organization-invitations
      produces:
      - application/json
      parameters:
      - name: organization_id
        in: path
        description: Identifier for the Organization
        required: true
        type: string
      - name: invitation_tokens
        in: path
        description: CSV list of Invitation tokens
        required: true
        type: string
      responses:
        '200':
          description: Organization invitations deleted successfully
          schema:
            "$ref": "#/definitions/EmptyResponse"
        '400':
          description: 'No valid invitation token was supplied. (code: `root.invalid_data`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - root.invalid_data
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: |-
            * Organization not found. (code: `organization.not_found`)
            * Invitation not found. (code: `organization.invitation_not_found`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.not_found
              - organization.invitation_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Organizations
  "/organizations/{organization_id}/members":
    get:
      tags:
      - Organizations
      - IamService
      summary: List organization members
      description: Fetch users belonging to the selected organization. Currently unavailable
        in self-hosted ECE.
      operationId: list-organization-members
      produces:
      - application/json
      parameters:
      - name: organization_id
        in: path
        description: Identifier for the Organization
        required: true
        type: string
      responses:
        '200':
          description: Organization members fetched successfully
          schema:
            "$ref": "#/definitions/OrganizationMemberships"
        '404':
          description: 'Organization not found. (code: `organization.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Organizations
  "/organizations/{organization_id}/members/{user_ids}":
    delete:
      tags:
      - Organizations
      - IamService
      summary: Delete organization memberships
      description: Deletes one or more organization memberships. Currently unavailable
        in self-hosted ECE.
      operationId: delete-organization-memberships
      produces:
      - application/json
      parameters:
      - name: organization_id
        in: path
        description: Identifier for the Organization
        required: true
        type: string
      - name: user_ids
        in: path
        description: CSV list of User identifiers
        required: true
        type: string
      - name: force
        in: query
        description: Whether or not to force the removal of Org memberships (effective
          only for Platform Admins)
        required: false
        type: boolean
        default: false
      responses:
        '200':
          description: Organization membership deleted successfully
          schema:
            "$ref": "#/definitions/EmptyResponse"
        '404':
          description: |-
            * User not found. (code: `user.not_found`)
            * Organization not found. (code: `organization.not_found`)
            * Organization membership not found. (code: `organization.membership_not_found`)
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - user.not_found
              - organization.not_found
              - organization.membership_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Organizations
  "/organizations/{organization_id}/role_mappings":
    get:
      tags:
      - Organizations
      - IamService
      summary: Get role mappings
      description: Gets the organization role  mappings. Currently unavailable in
        self-hosted ECE.
      operationId: get-role-mappings
      produces:
      - application/json
      parameters:
      - name: organization_id
        in: path
        description: Identifier for the Organization
        required: true
        type: string
      responses:
        '200':
          description: The IdP info
          schema:
            "$ref": "#/definitions/GetRoleMappingsResponse"
        '404':
          description: 'Organization not found. (code: `organization.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Organizations
    put:
      tags:
      - Organizations
      - IamService
      summary: Updates role mappings
      description: Updates the role assignments applicable when logging via SSO. Currently
        unavailable in self-hosted ECE.
      operationId: update-role-mappings
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - name: organization_id
        in: path
        description: Identifier for the Organization
        required: true
        type: string
      - in: body
        name: body
        description: The role  mappings to update
        required: true
        schema:
          "$ref": "#/definitions/UpdateOrganizationRoleMappingRequest"
      responses:
        '200':
          description: An empty response
          schema:
            "$ref": "#/definitions/EmptyResponse"
        '400':
          description: 'Validation error. (code: `org.role_mapping_rule.syntax_error`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - org.role_mapping_rule.syntax_error
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '404':
          description: 'Organization not found. (code: `organization.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Organizations
    delete:
      tags:
      - Organizations
      - IamService
      summary: Delete role mappings
      description: Deletes the organization role  mappings. Currently unavailable
        in self-hosted ECE.
      operationId: delete-role-mappings
      produces:
      - application/json
      parameters:
      - name: organization_id
        in: path
        description: Identifier for the Organization
        required: true
        type: string
      responses:
        '200':
          description: The mappings were successfully deleted
          schema:
            "$ref": "#/definitions/EmptyResponse"
        '404':
          description: 'Organization not found. (code: `organization.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Organizations
  "/stack/versions":
    get:
      tags:
      - Stack
      summary: Get stack versions
      description: By default, retrieves only the available Elastic Stack versions.
        To retrieve all of the Elastic Stack versions, use the `show_deleted parameter`.
      operationId: get-version-stacks
      produces:
      - application/json
      parameters:
      - name: show_deleted
        in: query
        description: Whether to show deleted stack versions or not
        required: false
        type: boolean
        default: false
      - name: show_unusable
        in: query
        description: Whether to show versions that are unusable by the authenticated
          user
        required: false
        type: boolean
        default: false
      responses:
        '200':
          description: The list of all available Elastic Stack versions are retrieved,
            including the template version and structure.
          schema:
            "$ref": "#/definitions/StackVersionConfigs"
      x-doc:
        tag: Stack - Versions - CRUD
  "/trusted-environments":
    get:
      tags:
      - TrustedEnvironments
      summary: Get trusted environments
      description: Returns the list of trusted environments for the organization.
        If no organization is passed in, the organization attached to the user is
        assumed.
      operationId: get-trusted-envs
      produces:
      - application/json
      parameters: []
      responses:
        '200':
          description: Trusted environments for this organization
          schema:
            "$ref": "#/definitions/ElasticsearchClusterTrustSettings"
        '404':
          description: 'Organization not found. (code: `organization.not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - organization.not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: TrustedEnvironments
  "/users/auth/keys":
    get:
      tags:
      - Authentication
      - IamService
      summary: Get all API keys
      description: Retrieves the metadata for all of the API keys that the user generated.
      operationId: get-api-keys
      produces:
      - application/json
      parameters:
      - name: next_page
        in: query
        description: Pagination cursor to get the next page of records
        required: false
        type: string
      responses:
        '200':
          description: The metadata for the API keys is retrieved.
          schema:
            "$ref": "#/definitions/ApiKeysResponse"
      x-doc:
        tag: Authentication
    post:
      tags:
      - Authentication
      - IamService
      summary: Create API key
      description: Creates a new API key.
      operationId: create-api-key
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - in: body
        name: body
        description: The request to create the API key
        required: true
        schema:
          "$ref": "#/definitions/CreateApiKeyRequest"
      responses:
        '201':
          description: The API key is created and returned in the body of the response.
          schema:
            "$ref": "#/definitions/ApiKeyResponse"
        '400':
          description: 'The request is invalid. Specify a different request, then
            try again. (code: `api_keys.invalid_input`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - api_keys.invalid_input
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Authentication
    delete:
      tags:
      - Authentication
      - IamService
      summary: Delete API keys
      description: Delete or invalidate API keys.
      operationId: delete-api-keys
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - in: body
        name: body
        description: The request to delete API keys
        required: true
        schema:
          "$ref": "#/definitions/DeleteApiKeysRequest"
      responses:
        '200':
          description: The API keys are deleted.
          schema:
            "$ref": "#/definitions/EmptyResponse"
      x-doc:
        tag: Authentication
  "/users/auth/keys/{api_key_id}":
    get:
      tags:
      - Authentication
      - IamService
      summary: Get API key
      description: Retrieves the metadata for an API key.
      operationId: get-api-key
      produces:
      - application/json
      parameters:
      - name: api_key_id
        in: path
        description: The API Key ID.
        required: true
        type: string
      responses:
        '200':
          description: The API key metadata is retrieved.
          schema:
            "$ref": "#/definitions/ApiKeyResponse"
        '404':
          description: 'The {api_key_id} can''t be found. (code: `api_keys.key_not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - api_keys.key_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Authentication
    delete:
      tags:
      - Authentication
      - IamService
      summary: Delete API key
      description: Delete or invalidate the API key.
      operationId: delete-api-key
      produces:
      - application/json
      parameters:
      - name: api_key_id
        in: path
        description: The API Key ID.
        required: true
        type: string
      responses:
        '200':
          description: The API key is deleted.
          schema:
            "$ref": "#/definitions/EmptyResponse"
        '404':
          description: 'The {api_key_id} can''t be found. (code: `api_keys.key_not_found`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - api_keys.key_not_found
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Authentication
  "/users/{user_id}/role_assignments":
    post:
      tags:
      - UserRoleAssignments
      - IamService
      summary: Add Role Assignments
      description: Adds a set of RoleAssignments to the specified User. Currently
        unavailable in self-hosted ECE.
      operationId: add-role-assignments
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - name: user_id
        in: path
        description: Identifier for the user; include realm name and id if required
        required: true
        type: string
      - in: body
        name: body
        description: The Role Assignments to add
        required: true
        schema:
          "$ref": "#/definitions/RoleAssignments"
      responses:
        '200':
          description: Role Assignments were successfully added to the target User
          schema:
            "$ref": "#/definitions/EmptyResponse"
        '400':
          description: 'The target user Id is invalid. (code: `role_assignments.invalid_target_user_id`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - role_assignments.invalid_target_user_id
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '401':
          description: 'Credentials were invalid. (code: `root.unauthorized`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - root.unauthorized
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '403':
          description: 'You are not authorised to add the specified RoleAssignments.
            (code: `role_assignments.unauthorized_role_assignments`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - role_assignments.unauthorized_role_assignments
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Users - Role Assignments
    delete:
      tags:
      - UserRoleAssignments
      - IamService
      summary: Remove Role Assignments
      description: Removes a set of RoleAssignments from the specified User. Currently
        unavailable in self-hosted ECE.
      operationId: remove-role-assignments
      consumes:
      - application/json
      produces:
      - application/json
      parameters:
      - name: user_id
        in: path
        description: Identifier for the user; include realm name and id if required
        required: true
        type: string
      - in: body
        name: body
        description: The Role Assignments to remove
        required: true
        schema:
          "$ref": "#/definitions/RoleAssignments"
      responses:
        '200':
          description: Role Assignments were successfully removed from the target
            User
          schema:
            "$ref": "#/definitions/EmptyResponse"
        '400':
          description: 'The target user Id is invalid. (code: `role_assignments.invalid_target_user_id`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - role_assignments.invalid_target_user_id
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '401':
          description: 'Credentials were invalid. (code: `root.unauthorized`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - root.unauthorized
          schema:
            "$ref": "#/definitions/BasicFailedReply"
        '403':
          description: 'You are not authorised to remove the specified RoleAssignments.
            (code: `role_assignments.unauthorized_role_assignments`)'
          headers:
            x-cloud-error-codes:
              type: string
              description: The error codes associated with the response
              enum:
              - role_assignments.unauthorized_role_assignments
          schema:
            "$ref": "#/definitions/BasicFailedReply"
      x-doc:
        tag: Users - Role Assignments
securityDefinitions:
  apiKey:
    type: apiKey
    name: Authorization
    in: header
definitions:
  AccountResponse:
    type: object
    required:
    - id
    properties:
      id:
        type: string
        description: The account's identifier
      trust:
        description: Settings related to the level of trust of the clusters in this
          account
        "$ref": "#/definitions/AccountTrustSettings"
    description: An account is the entity that owns deployments, and it is accessed
      by users. Accounts are isolated from each other.
  AccountTrustRelationship:
    type: object
    required:
    - account_id
    - trust_all
    properties:
      account_id:
        type: string
        description: the ID of the Account
      name:
        type: string
        description: A human readable name of the trust relationship
      trust_all:
        type: boolean
        description: If true, all clusters in this account will by default be trusted
          and the `trust_allowlist` is ignored.
      trust_allowlist:
        type: array
        description: The list of clusters to trust. Only used when `trust_all` is
          false.
        items:
          type: string
    description: The trust relationship with the clusters of one account.
  AccountTrustSettings:
    type: object
    required:
    - trust_all
    properties:
      trust_all:
        type: boolean
        description: If true, all clusters in this account will by default trust all
          other clusters in the same account
    description: Settings related to the level of trust of the clusters in this account
  AccountUpdateRequest:
    type: object
    properties:
      trust:
        description: Settings related to the level of trust of the clusters in this
          account
        "$ref": "#/definitions/AccountTrustSettings"
    description: A request to update an account
  AllocatorMoveRequest:
    type: object
    required:
    - from
    properties:
      from:
        type: string
        description: The allocator id off which all instances in the cluster should
          be moved
      to:
        type: array
        description: An optional list of allocator ids to which the instance(s) should
          be moved. If not specified then any available allocator can be used (including
          the current one if it is healthy)
        items:
          type: string
      allocator_down:
        type: boolean
        description: 'Tells the infrastructure that all instances on the allocator
          should be considered as permanently down when deciding how to migrate data
          to new nodes. If left blank then the system will auto-decide (currently:
          will treat the allocator as up)'
    description: As part of the upgrade plan, identifies the move requests for the
      Kibana instances or APM Servers on the allocators.
  ApiKeyResponse:
    type: object
    required:
    - creation_date
    - description
    - id
    properties:
      id:
        type: string
        description: The API key ID.
      user_id:
        type: string
        description: The user ID.
      organization_id:
        type: string
        description: The organization ID linked to the API key
      description:
        type: string
        description: 'The API key description. TIP: Useful when you have multiple
          API keys.'
      key:
        type: string
        description: 'The API key. TIP: Since the API key is returned only once, save
          it in a safe place.'
      creation_date:
        type: string
        format: date-time
        description: The date/time for when the API key is created.
      expiration_date:
        type: string
        format: date-time
        description: The date/time when the API key expires.
      role_assignments:
        description: The optional roles for the API key. Currently unavailable in
          self-hosted ECE.
        "$ref": "#/definitions/RoleAssignments"
    description: The response model for an API key.
  ApiKeysResponse:
    type: object
    required:
    - keys
    properties:
      keys:
        type: array
        description: The list of API keys.
        items:
          "$ref": "#/definitions/ApiKeyResponse"
      next_page:
        type: string
        description: A cursor to get the next page of results
    description: The response model for the API keys.
  Apm:
    type: object
    required:
    - backend_plan
    - display_name
    - elasticsearch_cluster_ref_id
    - ref_id
    properties:
      ref_id:
        type: string
        description: A locally-unique user-specified id
      display_name:
        type: string
        description: The human readable name (defaults to the generated cluster id
          if not specified)
      elasticsearch_cluster_ref_id:
        type: string
        description: The user-specified id of the Elasticsearch Cluster that this
          will link to
      backend_plan:
        type: object
        description: The backend plan as JSON
    description: Holds diagnostics for an APM resource
  ApmConfiguration:
    type: object
    properties:
      version:
        type: string
        description: The version of the Apm cluster (must be one of the ECE supported
          versions, and won't work unless it matches the APM version. Leave blank
          to auto-detect version.)
      docker_image:
        type: string
        description: A docker URI that allows overriding of the default docker image
          specified for this version
      system_settings:
        "$ref": "#/definitions/ApmSystemSettings"
      user_settings_json:
        type: object
        description: An arbitrary JSON object allowing (non-admin) cluster owners
          to set their parameters (only one of this and 'user_settings_yaml' is allowed),
          provided the parameters are on the allowlist and not on the denylist. (This
          field together with 'user_settings_override*' and 'system_settings' defines
          the total set of Apm settings)
      user_settings_yaml:
        type: string
        description: An arbitrary YAML object allowing (non-admin) cluster owners
          to set their parameters (only one of this and 'user_settings_json' is allowed),
          provided the parameters are on the allowlist and not on the denylist. (These
          field together with 'user_settings_override*' and 'system_settings' defines
          the total set of Apm settings)
      user_settings_override_json:
        type: object
        description: An arbitrary JSON object allowing ECE admins owners to set clusters'
          parameters (only one of this and 'user_settings_override_yaml' is allowed),
          ie in addition to the documented 'system_settings'. (This field together
          with 'system_settings' and 'user_settings*' defines the total set of Apm
          settings)
      user_settings_override_yaml:
        type: string
        description: An arbitrary YAML object allowing ECE admins owners to set clusters'
          parameters (only one of this and 'user_settings_override_json' is allowed),
          ie in addition to the documented 'system_settings'. (This field together
          with 'system_settings' and 'user_settings*' defines the total set of Apm
          settings)
    description: The configuration options for the APM Server.
  ApmCrudResponse:
    type: object
    required:
    - secret_token
    properties:
      apm_id:
        type: string
        description: For an operation creating or updating an APM server, the Id of
          that server
      secret_token:
        type: string
        description: The secret token for accessing the server
      diagnostics:
        type: object
        description: If the endpoint is called with URL param 'validate_only=true',
          then this contains advanced debug info (the internal plan representation)
    description: The response to an APM CRUD (create/update-plan) request.
  ApmInfo:
    type: object
    required:
    - elasticsearch_cluster
    - external_links
    - healthy
    - id
    - name
    - plan_info
    - status
    - topology
    properties:
      id:
        type: string
        description: The id of the APM
      name:
        type: string
        description: The name of the APM
      elasticsearch_cluster:
        "$ref": "#/definitions/TargetElasticsearchCluster"
      deployment_id:
        type: string
        description: The id of the deployment that this APM Server belongs to.
      healthy:
        type: boolean
        description: 'Whether the APM is healthy or not (one or more of the info subsections
          will have healthy: false)'
      status:
        type: string
        description: APM status
        enum:
        - initializing
        - stopping
        - stopped
        - rebooting
        - restarting
        - reconfiguring
        - started
      plan_info:
        "$ref": "#/definitions/ApmPlansInfo"
      metadata:
        "$ref": "#/definitions/ClusterMetadataInfo"
      topology:
        "$ref": "#/definitions/ClusterTopologyInfo"
      external_links:
        type: array
        description: External resources related to the APM
        uniqueItems: true
        items:
          "$ref": "#/definitions/ExternalHyperlink"
      links:
        type: object
        description: A map of application-specific operations (which map to 'operationId's
          in the Swagger API) to metadata about that operation
        additionalProperties:
          "$ref": "#/definitions/Hyperlink"
      settings:
        description: The cluster metadata settings for the APM
        "$ref": "#/definitions/ApmSettings"
      region:
        type: string
        description: The region that this APM belongs to. Only populated in SaaS or
          federated ECE.
      apm_server_mode:
        type: string
        description: The mode APM is operating in.
        enum:
        - standalone
        - managed
    description: The overview information for the APM Server.
  ApmPayload:
    type: object
    required:
    - elasticsearch_cluster_ref_id
    - plan
    - ref_id
    - region
    properties:
      ref_id:
        type: string
        description: A locally-unique user-specified id for APM
      elasticsearch_cluster_ref_id:
        type: string
        description: Alias to the Elasticsearch Cluster to attach APM to
      display_name:
        type: string
        description: 'The human readable name for the APM cluster (default: takes
          the name of its Elasticsearch cluster)'
      region:
        type: string
        description: The region where this resource exists
      plan:
        "$ref": "#/definitions/ApmPlan"
      settings:
        description: The settings for building this APM cluster
        "$ref": "#/definitions/ApmSettings"
    description: An APM creation request paired with the alias of the Elasticsearch
      cluster it should be paired with
  ApmPlan:
    type: object
    required:
    - apm
    properties:
      cluster_topology:
        type: array
        items:
          "$ref": "#/definitions/ApmTopologyElement"
      apm:
        "$ref": "#/definitions/ApmConfiguration"
      transient:
        "$ref": "#/definitions/TransientApmPlanConfiguration"
    description: The plan for the APM Server.
  ApmPlanControlConfiguration:
    type: object
    properties:
      timeout:
        type: integer
        format: int64
        description: The total timeout in seconds after which the plan is cancelled
          even if it is not complete. Defaults to 4x the max memory capacity per node
          (in MB)
      calm_wait_time:
        type: integer
        format: int64
        description: This timeout determines how long to give a cluster after it responds
          to API calls before performing actual operations on it. It defaults to 5s
      extended_maintenance:
        type: boolean
        description: If true (default false), does not clear the maintenance flag
          (which prevents its API from being accessed except by the constructor) on
          new instances added until after a snapshot has been restored, otherwise,
          the maintenance flag is cleared once the new instances successfully join
          the new cluster
      cluster_reboot:
        type: string
        description: Set to 'forced' to force a reboot as part of the upgrade plan
        enum:
        - forced
    description: The plan control configuration options for the APM Server.
  ApmPlanInfo:
    type: object
    required:
    - healthy
    - plan_attempt_log
    - warnings
    properties:
      plan_attempt_id:
        type: string
        description: A UUID for each plan attempt
      plan_attempt_name:
        type: string
        description: A human readable name for each plan attempt, only populated when
          retrieving plan histories
      healthy:
        type: boolean
        description: Either the plan ended successfully, or is not yet completed (and
          no errors have occurred)
      attempt_start_time:
        type: string
        format: date-time
        description: When this plan attempt (ie to apply the plan to the APM) started
          (ISO format in UTC)
      attempt_end_time:
        type: string
        format: date-time
        description: If this plan completed or failed (ie is not pending), when the
          attempt ended (ISO format in UTC)
      plan_end_time:
        type: string
        format: date-time
        description: If this plan is not current or pending, when the plan was no
          longer active (ISO format in UTC)
      plan:
        "$ref": "#/definitions/ApmPlan"
      plan_attempt_log:
        type: array
        items:
          "$ref": "#/definitions/ClusterPlanStepInfo"
      source:
        description: Information describing the source that facilitated the plans
          current state
        "$ref": "#/definitions/ChangeSourceInfo"
      warnings:
        type: array
        items:
          "$ref": "#/definitions/ClusterPlanWarning"
      error:
        "$ref": "#/definitions/ClusterPlanAttemptError"
    description: Information about the APM Server plan.
  ApmPlansInfo:
    type: object
    required:
    - healthy
    - history
    properties:
      healthy:
        type: boolean
        description: Whether the plan situation is healthy (if unhealthy, means the
          last plan attempt failed)
      current:
        "$ref": "#/definitions/ApmPlanInfo"
      pending:
        "$ref": "#/definitions/ApmPlanInfo"
      history:
        type: array
        items:
          "$ref": "#/definitions/ApmPlanInfo"
    description: Information about current, pending, and past APM Server plans.
  ApmResourceInfo:
    type: object
    required:
    - elasticsearch_cluster_ref_id
    - id
    - info
    - ref_id
    - region
    properties:
      ref_id:
        type: string
        description: The locally-unique user-specified id of a Resource
      elasticsearch_cluster_ref_id:
        type: string
        description: The Elasticsearch cluster that this resource depends on.
      id:
        type: string
        description: The randomly-generated id of a Resource
      region:
        type: string
        description: The region where this resource exists
      info:
        description: Info for the resource.
        "$ref": "#/definitions/ApmInfo"
    description: Describes an APM resource belonging to a Deployment
  ApmSettings:
    type: object
    properties:
      metadata:
        "$ref": "#/definitions/ClusterMetadataSettings"
    description: The settings for the APM Server.
  ApmSubInfo:
    type: object
    required:
    - apm_id
    - enabled
    properties:
      apm_id:
        type: string
        description: The APM cluster Id
      enabled:
        type: boolean
        description: Whether the associated APM cluster is currently available
      links:
        type: object
        description: A map of application-specific operations (which map to 'operationId's
          in the Swagger API) to metadata about that operation
        additionalProperties:
          "$ref": "#/definitions/Hyperlink"
    description: Information about the APM Servers associated with the Elasticsearch
      cluster.
  ApmSystemSettings:
    type: object
    properties:
      elasticsearch_username:
        type: string
        description: Optionally override the account within APM - defaults to a system
          account that always exists (if specified, the password must also be specified).
          Note that this field is never returned from the API, it is write only.
      elasticsearch_password:
        type: string
        description: Optionally override the account within APM - defaults to a system
          account that always exists (if specified, the username must also be specified).
          Note that this field is never returned from the API, it is write only.
      secret_token:
        type: string
        description: Optionally override the secret token within APM - defaults to
          the previously existing secretToken
      debug_enabled:
        type: boolean
        description: Optionally enable debug mode for APM servers - defaults false
    description: "A structure that defines a curated subset of the APM Server settings.
      \nTIP: To define the complete set of APM Server setting, use `ApmSystemSettings`
      with `user_settings_override_` and `user_settings_`."
  ApmTopologyElement:
    type: object
    properties:
      instance_configuration_id:
        type: string
        description: Controls the allocation of this topology element as well as allowed
          sizes and node_types. It needs to match the id of an existing instance configuration.
      instance_configuration_version:
        type: integer
        format: int32
        description: The version of the Instance Configuration Id. If it is unset,
          the meaning depends on read vs writes. For deployment reads, it is equivalent
          to version 0 (or the IC is unversioned); for deployment creates and deployment
          template use, it is equivalent to 'the latest version'; and for deployment
          updates, it is equivalent to 'retain the current version'.
      size:
        "$ref": "#/definitions/TopologySize"
      zone_count:
        type: integer
        format: int32
        description: number of zones in which nodes will be placed
      apm:
        "$ref": "#/definitions/ApmConfiguration"
    description: Defines the topology of the APM Server nodes. For example, the number
      or capacity of the nodes, and where you can allocate the nodes.
  AppSearch:
    type: object
    required:
    - backend_plan
    - display_name
    - elasticsearch_cluster_ref_id
    - ref_id
    properties:
      ref_id:
        type: string
        description: A locally-unique user-specified id
      display_name:
        type: string
        description: The human readable name (defaults to the generated cluster id
          if not specified)
      elasticsearch_cluster_ref_id:
        type: string
        description: The user-specified id of the Elasticsearch Cluster that this
          will link to
      backend_plan:
        type: object
        description: The backend plan as JSON
    description: Holds diagnostics for an AppSearch resource
  AppSearchConfiguration:
    type: object
    properties:
      version:
        type: string
        description: The version of the AppSearch cluster (must be one of the ECE
          supported versions, and won't work unless it matches the Elasticsearch version.
          Leave blank to auto-detect version.)
      docker_image:
        type: string
        description: A docker URI that allows overriding of the default docker image
          specified for this version
      system_settings:
        "$ref": "#/definitions/AppSearchSystemSettings"
      user_settings_json:
        type: object
        description: An arbitrary JSON object allowing (non-admin) cluster owners
          to set their parameters (only one of this and 'user_settings_yaml' is allowed),
          provided the parameters are on the allowlist and not on the denylist. (This
          field together with 'user_settings_override*' and 'system_settings' defines
          the total set of AppSearch settings)
      user_settings_yaml:
        type: string
        description: An arbitrary YAML object allowing (non-admin) cluster owners
          to set their parameters (only one of this and 'user_settings_json' is allowed),
          provided the parameters are on the allowlist and not on the denylist. (These
          field together with 'user_settings_override*' and 'system_settings' defines
          the total set of AppSearch settings)
      user_settings_override_json:
        type: object
        description: An arbitrary JSON object allowing ECE admins owners to set clusters'
          parameters (only one of this and 'user_settings_override_yaml' is allowed),
          ie in addition to the documented 'system_settings'. (This field together
          with 'system_settings' and 'user_settings*' defines the total set of AppSearch
          settings)
      user_settings_override_yaml:
        type: string
        description: An arbitrary YAML object allowing ECE admins owners to set clusters'
          parameters (only one of this and 'user_settings_override_json' is allowed),
          ie in addition to the documented 'system_settings'. (This field together
          with 'system_settings' and 'user_settings*' defines the total set of AppSearch
          settings)
  AppSearchInfo:
    type: object
    required:
    - elasticsearch_cluster
    - external_links
    - healthy
    - id
    - name
    - plan_info
    - status
    - topology
    properties:
      id:
        type: string
        description: The id of the App Search
      name:
        type: string
        description: The name of the App Search
      elasticsearch_cluster:
        "$ref": "#/definitions/TargetElasticsearchCluster"
      deployment_id:
        type: string
        description: The id of the deployment that this App Search belongs to.
      healthy:
        type: boolean
        description: 'Whether the App Search is healthy or not (one or more of the
          info subsections will have healthy: false)'
      status:
        type: string
        description: App Search status
        enum:
        - initializing
        - stopping
        - stopped
        - rebooting
        - restarting
        - reconfiguring
        - started
      plan_info:
        "$ref": "#/definitions/AppSearchPlansInfo"
      metadata:
        "$ref": "#/definitions/ClusterMetadataInfo"
      topology:
        "$ref": "#/definitions/ClusterTopologyInfo"
      external_links:
        type: array
        description: External resources related to the App Search
        uniqueItems: true
        items:
          "$ref": "#/definitions/ExternalHyperlink"
      links:
        type: object
        description: A map of application-specific operations (which map to 'operationId's
          in the Swagger API) to metadata about that operation
        additionalProperties:
          "$ref": "#/definitions/Hyperlink"
      settings:
        description: The cluster metadata settings for the App Search
        "$ref": "#/definitions/AppSearchSettings"
      region:
        type: string
        description: The region that this App Search belongs to. Only populated in
          SaaS or federated ECE.
    description: The overview information for the App Search Server.
  AppSearchNodeTypes:
    type: object
    required:
    - appserver
    - worker
    properties:
      appserver:
        type: boolean
        description: Defines whether this instance should run as Application/API server
      worker:
        type: boolean
        description: Defines whether this instance should run as background worker
    description: Node types to enable for an AppSearch instance
  AppSearchPayload:
    type: object
    required:
    - elasticsearch_cluster_ref_id
    - plan
    - ref_id
    - region
    properties:
      ref_id:
        type: string
        description: A locally-unique user-specified id for AppSearch
      elasticsearch_cluster_ref_id:
        type: string
        description: Alias to the Elasticsearch Cluster to attach AppSearch to
      display_name:
        type: string
        description: 'The human readable name for the AppSearch cluster (default:
          takes the name of its Elasticsearch cluster)'
      region:
        type: string
        description: The region where this resource exists
      plan:
        "$ref": "#/definitions/AppSearchPlan"
      settings:
        description: The settings for building this AppSearch cluster
        "$ref": "#/definitions/AppSearchSettings"
    description: An AppSearch creation request paired with the alias of the Elasticsearch
      cluster it should be paired with
  AppSearchPlan:
    type: object
    required:
    - appsearch
    properties:
      cluster_topology:
        type: array
        items:
          "$ref": "#/definitions/AppSearchTopologyElement"
      appsearch:
        "$ref": "#/definitions/AppSearchConfiguration"
      transient:
        "$ref": "#/definitions/TransientAppSearchPlanConfiguration"
    description: The plan for the App Search cluster.
  AppSearchPlanControlConfiguration:
    type: object
    properties:
      timeout:
        type: integer
        format: int64
        description: The total timeout in seconds after which the plan is cancelled
          even if it is not complete. Defaults to 4x the max memory capacity per node
          (in MB)
      calm_wait_time:
        type: integer
        format: int64
        description: This timeout determines how long to give a cluster after it responds
          to API calls before performing actual operations on it. It defaults to 5s
      move_instances:
        type: array
        items:
          "$ref": "#/definitions/InstanceMoveRequest"
      move_allocators:
        type: array
        items:
          "$ref": "#/definitions/AllocatorMoveRequest"
      reallocate_instances:
        type: boolean
        description: 'If true (default: false) does not allow re-using any existing
          instances currently in the cluster, ie even unchanged instances will be
          re-created'
      preferred_allocators:
        type: array
        description: List of allocators on which instances are placed if possible
          (if not possible/not specified then any available allocator with space is
          used)
        items:
          type: string
      extended_maintenance:
        type: boolean
        description: If true (default false), does not clear the maintenance flag
          (which prevents its API from being accessed except by the constructor) on
          new instances added until after a snapshot has been restored, otherwise,
          the maintenance flag is cleared once the new instances successfully join
          the new cluster
      cluster_reboot:
        type: string
        description: Set to 'forced' to force a reboot as part of the upgrade plan
        enum:
        - forced
  AppSearchPlanInfo:
    type: object
    required:
    - healthy
    - plan_attempt_log
    - warnings
    properties:
      plan_attempt_id:
        type: string
        description: A UUID for each plan attempt
      plan_attempt_name:
        type: string
        description: A human readable name for each plan attempt, only populated when
          retrieving plan histories
      healthy:
        type: boolean
        description: Either the plan ended successfully, or is not yet completed (and
          no errors have occurred)
      attempt_start_time:
        type: string
        format: date-time
        description: When this plan attempt (ie to apply the plan to the App Search)
          started (ISO format in UTC)
      attempt_end_time:
        type: string
        format: date-time
        description: If this plan completed or failed (ie is not pending), when the
          attempt ended (ISO format in UTC)
      plan_end_time:
        type: string
        format: date-time
        description: If this plan is not current or pending, when the plan was no
          longer active (ISO format in UTC)
      plan:
        "$ref": "#/definitions/AppSearchPlan"
      plan_attempt_log:
        type: array
        items:
          "$ref": "#/definitions/ClusterPlanStepInfo"
      source:
        description: Information describing the source that facilitated the plans
          current state
        "$ref": "#/definitions/ChangeSourceInfo"
      warnings:
        type: array
        items:
          "$ref": "#/definitions/ClusterPlanWarning"
      error:
        "$ref": "#/definitions/ClusterPlanAttemptError"
    description: Information about the App Search Server plan.
  AppSearchPlansInfo:
    type: object
    required:
    - healthy
    - history
    properties:
      healthy:
        type: boolean
        description: Whether the plan situation is healthy (if unhealthy, means the
          last plan attempt failed)
      current:
        "$ref": "#/definitions/AppSearchPlanInfo"
      pending:
        "$ref": "#/definitions/AppSearchPlanInfo"
      history:
        type: array
        items:
          "$ref": "#/definitions/AppSearchPlanInfo"
    description: Information about current, pending, and past App Search Server plans.
  AppSearchResourceInfo:
    type: object
    required:
    - elasticsearch_cluster_ref_id
    - id
    - info
    - ref_id
    - region
    properties:
      ref_id:
        type: string
        description: The locally-unique user-specified id of a Resource
      elasticsearch_cluster_ref_id:
        type: string
        description: The Elasticsearch cluster that this resource depends on.
      id:
        type: string
        description: The randomly-generated id of a Resource
      region:
        type: string
        description: The region where this resource exists
      info:
        description: Info for the resource.
        "$ref": "#/definitions/AppSearchInfo"
    description: Describes an App Search resource belonging to a Deployment
  AppSearchSettings:
    type: object
    properties:
      metadata:
        "$ref": "#/definitions/ClusterMetadataSettings"
    description: The settings for the App Search.
  AppSearchSubInfo:
    type: object
    required:
    - app_search_id
    - enabled
    properties:
      app_search_id:
        type: string
        description: The App Search Id
      enabled:
        type: boolean
        description: Whether the associated App Search is currently available
      links:
        type: object
        description: A map of application-specific operations (which map to 'operationId's
          in the Swagger API) to metadata about that operation
        additionalProperties:
          "$ref": "#/definitions/Hyperlink"
    description: Information about the APM Servers associated with the Elasticsearch
      cluster.
  AppSearchSystemSettings:
    type: object
    properties:
      elasticsearch_url:
        type: string
        description: Optionally override the URL to which to send data (for advanced
          users only, if unspecified the system selects an internal URL)
      elasticsearch_username:
        type: string
        description: Optionally override the account within App Search - defaults
          to a system account that always exists (if specified, the password must
          also be specified). Note that this field is never returned from the API,
          it is write only.
      elasticsearch_password:
        type: string
        description: Optionally override the account within App Search - defaults
          to a system account that always exists (if specified, the username must
          also be specified). Note that this field is never returned from the API,
          it is write only.
      secret_session_key:
        type: string
        description: Optionally override the secret session key within App Search
          - defaults to the previously existing secretSession. Note that this field
          is never returned from the API, it is write only.
    description: This structure defines a curated subset of the AppSearch settings.
      (This field together with 'user_settings_override*' and  'user_settings*' defines
      the total set of AppSearch settings)
  AppSearchTopologyElement:
    type: object
    properties:
      node_type:
        description: Defines the AppSearch node type
        "$ref": "#/definitions/AppSearchNodeTypes"
      instance_configuration_id:
        type: string
        description: Controls the allocation of this topology element as well as allowed
          sizes and node_types. It needs to match the id of an existing instance configuration.
      instance_configuration_version:
        type: integer
        format: int32
        description: The version of the Instance Configuration Id. If it is unset,
          the meaning depends on read vs writes. For deployment reads, it is equivalent
          to version 0 (or the IC is unversioned); for deployment creates and deployment
          template use, it is equivalent to 'the latest version'; and for deployment
          updates, it is equivalent to 'retain the current version'.
      size:
        "$ref": "#/definitions/TopologySize"
      zone_count:
        type: integer
        format: int32
        description: number of zones in which nodes will be placed
      appsearch:
        "$ref": "#/definitions/AppSearchConfiguration"
    description: Defines the topology of the AppSearch nodes (eg number/capacity of
      nodes, and where they can be allocated)
  AutoOpsSettings:
    type: object
    required:
    - status
    properties:
      status:
        type: string
        description: See AutoOps integration status for this deployment.
        enum:
        - connected
        - not_connected
        - excluded
    description: AutoOps settings for this deployment.
  AutodetectStrategyConfig:
    type: object
    description: A strategy that lets constructor choose the most optimal way to execute
      the plan.
  Balance:
    type: object
    required:
    - available
    - line_items
    - remaining
    properties:
      available:
        type: number
        format: double
        description: Available balance
      remaining:
        type: number
        format: double
        description: Remaining balance
      line_items:
        type: array
        description: A collection of order line items for for an organization
        items:
          "$ref": "#/definitions/SimplifiedLineItem"
    description: The available balance for an organization
  BasicFailedReply:
    type: object
    required:
    - errors
    properties:
      errors:
        type: array
        description: A list of errors that occurred in the failing request
        items:
          "$ref": "#/definitions/BasicFailedReplyElement"
  BasicFailedReplyElement:
    type: object
    required:
    - code
    - message
    properties:
      code:
        type: string
        description: A structured code representing the error type that occurred
      message:
        type: string
        description: A human readable message describing the error that occurred
      fields:
        type: array
        description: If the error can be tied to a specific field or fields in the
          user request, this lists those fields
        items:
          type: string
  BoolQuery:
    type: object
    properties:
      must:
        type: array
        items:
          "$ref": "#/definitions/QueryContainer"
      should:
        type: array
        items:
          "$ref": "#/definitions/QueryContainer"
      must_not:
        type: array
        items:
          "$ref": "#/definitions/QueryContainer"
      filter:
        type: array
        items:
          "$ref": "#/definitions/QueryContainer"
      minimum_should_match:
        type: integer
        format: int32
        description: The minimum number of optional should clauses to match.
    description: A query for documents that match boolean combinations of other queries.
  CertificateAuthority:
    type: object
    required:
    - public_certificates
    - recommended_trust_restriction
    properties:
      recommended_trust_restriction:
        type: string
        description: The trust restriction expression to use that would provide trust
          with the Elasticsearch nodes of this deployment
      public_certificates:
        type: array
        description: The certificates used by this certificate authority. The active
          certificate is the one that has been used to sign the current certificates
          of the Elasticsearch instances. All others are either certificates used
          in the past or certificates that will be used in the future when the currently
          active certificate expires.
        items:
          "$ref": "#/definitions/PublicCertificate"
    description: The certificate authority used to sign the certificates of this deployment
  CertificateMetaData:
    type: object
    required:
    - fingerprint
    - valid_from
    - valid_to
    properties:
      fingerprint:
        type: string
        description: The fingerprint of the certificate
      valid_to:
        type: string
        format: date-time
        description: The expiry date of the certificate in UTC
      valid_from:
        type: string
        format: date-time
        description: The valid from date of the certificate in UTC
      also_trusted_by:
        type: array
        description: Other deployments also trusting this certificate
        items:
          type: string
    description: The certificate MetaData
  ChangeSourceInfo:
    type: object
    required:
    - action
    - date
    - facilitator
    properties:
      facilitator:
        type: string
        description: The service where the change originated from
      action:
        type: string
        description: The type of plan change that was initiated
      date:
        type: string
        format: date-time
        description: The time the change was initiated
      user_id:
        type: string
        description: The user that requested the change
      admin_id:
        type: string
        description: The admin user that requested the change
      remote_addresses:
        type: array
        description: The host addresses of the user that originated the change
        items:
          type: string
    description: A container for information about the source of a change.
  ChartItem:
    type: object
    required:
    - timestamp
    - values
    properties:
      timestamp:
        type: integer
        format: int64
        description: Axis X position
      values:
        type: array
        description: the collection of values to plot the chart item
        items:
          "$ref": "#/definitions/ChartItemValue"
    description: Chart Item
  ChartItemValue:
    type: object
    required:
    - id
    - name
    - value
    properties:
      id:
        type: string
        description: The id of chart item value
      name:
        type: string
        description: The name of the chart item value
      value:
        type: number
        format: double
        description: The actual value of the chart item value
    description: A ChartItem value
  ChartItems:
    type: object
    required:
    - data
    properties:
      data:
        type: array
        description: The list of chart item
        items:
          "$ref": "#/definitions/ChartItem"
    description: A collection of ChartItems
  ClusterCredentials:
    type: object
    required:
    - password
    - username
    properties:
      username:
        type: string
        description: The username of the newly created cluster
      password:
        type: string
        description: The password of the newly created cluster
    description: The username and password for the new Elasticsearch cluster, which
      is returned from the Elasticsearch cluster `create` command.
  ClusterCurationSettings:
    type: object
    required:
    - specs
    properties:
      specs:
        type: array
        description: Specifications for curation
        items:
          "$ref": "#/definitions/ClusterCurationSpec"
    description: The index curation settings for an Elasticsearch cluster.
  ClusterCurationSpec:
    type: object
    required:
    - index_pattern
    - trigger_interval_seconds
    properties:
      index_pattern:
        type: string
        description: Index matching pattern
      trigger_interval_seconds:
        type: integer
        format: int32
        description: Number of seconds after index creation to trigger this spec
    description: Specifies the conditions to trigger an Elasticsearch cluster curation.
  ClusterInstanceConfigurationInfo:
    type: object
    required:
    - id
    - name
    - resource
    properties:
      id:
        type: string
        description: The id of the configuration used to create the instance
      name:
        type: string
        description: The name of the configuration used to create the instance
      config_version:
        type: integer
        format: int32
        description: If the IC is configuration controlled, this field is the version
          either being read back (reads return the latest IC unless specified by the
          'config_version' URL param), or the version to update. Cannot be used in
          creates. For unversioned IC reads it is left empty.
      resource:
        type: string
        description: The resource type of the instance configuration
        enum:
        - memory
        - storage
    description: Information about a configuration that creates a Kibana instance
      or APM Server.
  ClusterInstanceDiskInfo:
    type: object
    required:
    - disk_space_used
    - storage_multiplier
    properties:
      disk_space_available:
        type: integer
        format: int64
        description: If known, the amount of total disk space available to the container
          in MB
      disk_space_used:
        type: integer
        format: int64
        description: The amount of disk space being used by the service in MB
      storage_multiplier:
        type: number
        format: double
        description: The storage multiplier originally defined to calculate disk space.
    description: Information about the use and storage capacity of a Kibana instance
      or APM Server.
  ClusterInstanceInfo:
    type: object
    required:
    - container_started
    - healthy
    - instance_name
    - maintenance_mode
    - service_running
    properties:
      instance_name:
        type: string
        description: The name of the instance in Elastic Cloud
      instance_configuration:
        "$ref": "#/definitions/ClusterInstanceConfigurationInfo"
      service_version:
        type: string
        description: The version of the service that the instance is running (eg Elasticsearch
          or Kibana), if available
      healthy:
        type: boolean
        description: Whether the instance is healthy (ie started and running)
      container_started:
        type: boolean
        description: Whether the container has started (does not tell you anything
          about the service -ie Elasticsearch- running inside the container)
      service_running:
        type: boolean
        description: Whether the service launched inside the container -ie Elasticsearch-
          is actually running
      maintenance_mode:
        type: boolean
        description: Whether the service is is maintenance mode (meaning that the
          proxy is not routing external traffic to it)
      zone:
        type: string
        description: The zone in which this instance is being allocated
      allocator_id:
        type: string
        description: The id of the allocator on which this instance is running (if
          the container is started or starting)
      memory:
        "$ref": "#/definitions/ClusterInstanceMemoryInfo"
      disk:
        "$ref": "#/definitions/ClusterInstanceDiskInfo"
      service_roles:
        type: array
        description: 'List of roles assigned to the service running in the instance.
          Currently only populated for Elasticsearch, with possible values: master,data,ingest,ml'
        items:
          type: string
      node_roles:
        type: array
        description: A list of the node roles assigned to the service running in the
          instance. Currently populated only for Elasticsearch.
        items:
          type: string
          enum:
          - master
          - ingest
          - ml
          - data_hot
          - data_content
          - data_warm
          - data_cold
          - data_frozen
          - remote_cluster_client
          - transform
          - voting_only
      instance_overrides:
        description: Instance overrides
        "$ref": "#/definitions/InstanceOverrides"
    description: Information about each Kibana instance and APM Server in the Elasticsearch
      cluster.
  ClusterInstanceMemoryInfo:
    type: object
    required:
    - instance_capacity
    properties:
      instance_capacity:
        type: integer
        format: int32
        description: The memory capacity in MB of the instance
      instance_capacity_planned:
        type: integer
        format: int32
        description: The planned memory capacity in MB of the instance (only shown
          when an override is present)
      memory_pressure:
        type: integer
        format: int32
        description: The % memory pressure of Elasticsearch JVM heap space if available
          (60-75% consider increasing capacity, >75% can incur significant performance
          and stability issues)
      native_memory_pressure:
        type: integer
        format: int32
        description: The % memory pressure of the instance Docker container (if available)
    description: Information about the specific instances memory capacity and its
      usage
  ClusterMetadataInfo:
    type: object
    required:
    - last_modified
    - version
    properties:
      version:
        type: integer
        format: int32
        description: The resource version number of the cluster metadata
      last_modified:
        type: string
        format: date-time
        description: The most recent time the cluster metadata was changed (ISO format
          in UTC)
      endpoint:
        type: string
        description: The DNS name of the cluster endpoint, if available
      service_url:
        type: string
        description: The full URL to access this deployment resource
      aliased_endpoint:
        type: string
        description: The DNS name of the cluster endpoint derived from the deployment
          alias, if available
      aliased_url:
        type: string
        description: The full aliased URL to access this deployment resource
      cloud_id:
        type: string
        description: The cloud ID, an encoded string that provides other Elastic services
          with the necessary information to connect to this Elasticsearch and Kibana
          (only present if both exist)
      raw:
        type: object
        description: 'An unstructured JSON representation of the public and internal
          state (can be filtered out via URL parameter). The contents and structure
          of the `raw` field can change at any time. '
      ports:
        description: The ports that allow communication with the cluster using various
          protocols.
        "$ref": "#/definitions/ClusterMetadataPortInfo"
      services_urls:
        type: array
        description: A list of the URLs to access services that the resource provides
          at this time. Note that if the service is not running or has not started
          yet, the URL to access it won't be available
        items:
          "$ref": "#/definitions/ServiceUrl"
    description: Information about the public and internal state, and the configuration
      settings of an Elasticsearch cluster.
  ClusterMetadataPortInfo:
    type: object
    required:
    - http
    - https
    - transport_passthrough
    properties:
      http:
        type: integer
        format: int32
        description: Port where the cluster listens for HTTP traffic
      https:
        type: integer
        format: int32
        description: Port where the cluster listens for HTTPS traffic
      transport_passthrough:
        type: integer
        format: int32
        description: Port where the cluster listens for transport traffic using TLS
    description: Information about the ports that allow communication between the
      Elasticsearch cluster and various protocols.
  ClusterMetadataSettings:
    type: object
    properties:
      name:
        type: string
        description: The display name of the cluster
    description: The top-level configuration settings for the Elasticsearch cluster.
  ClusterPlanAttemptError:
    type: object
    required:
    - details
    - message
    - timestamp
    properties:
      timestamp:
        type: string
        format: date-time
        description: Timestamp marking on info log of step
      message:
        type: string
        description: Human readable error message
      details:
        type: object
        description: A map with details regarding the error. Both the keys and values
          are always strings, representing the name of the detail and its value, respectively.
        additionalProperties:
          type: string
      failure_type:
        type: string
        description: The failure type
    description: Information about an error during a plan attempt.
  ClusterPlanStepInfo:
    type: object
    required:
    - info_log
    - stage
    - started
    - status
    - step_id
    properties:
      step_id:
        type: string
        description: ID of current step
      started:
        type: string
        format: date-time
        description: When the step started (ISO format in UTC)
      completed:
        type: string
        format: date-time
        description: When the step completed (ISO format in UTC)
      duration_in_millis:
        type: integer
        format: int64
        description: The duration of the step in MS
      status:
        type: string
        description: The status of the step (success, warning, error - warning means
          something didn't go as expected but it was not serious enough to abort the
          plan)
        enum:
        - success
        - warning
        - error
        - pending
      stage:
        type: string
        description: Current stage that the step is in
        enum:
        - starting
        - completed
        - in_progress
      info_log:
        type: array
        description: Human readable summaries of the step, including messages for
          each stage of the step
        items:
          "$ref": "#/definitions/ClusterPlanStepLogMessageInfo"
    description: Information about a step in a plan.
  ClusterPlanStepLogMessageInfo:
    type: object
    required:
    - details
    - message
    - stage
    - timestamp
    properties:
      timestamp:
        type: string
        format: date-time
        description: Timestamp marking on info log of step
      delta_in_millis:
        type: integer
        format: int64
        description: Time in milliseconds since previous log message
      stage:
        type: string
        description: Stage that info log message takes place in
        enum:
        - starting
        - completed
        - in_progress
      message:
        type: string
        description: Human readable log message
      details:
        type: object
        description: A map with details for the log about what happened during the
          step execution. Keys and values for are always both strings, representing
          the name of the detail and its value, respectively.
        additionalProperties:
          type: string
      failure_type:
        type: string
        description: The failure type, in case the step failed
    description: The log message from a specified stage of an executed step in a plan.
  ClusterPlanWarning:
    type: object
    required:
    - code
    - message
    properties:
      code:
        type: string
        description: A unique warning code
      message:
        type: string
        description: A description of the warning
      step_id:
        type: string
        description: The ID of the step which produced a warning, if any
    description: Information about a warning from a plan.
  ClusterSnapshotRetention:
    type: object
    properties:
      snapshots:
        type: integer
        format: int32
        description: Number of snapshots to retain
      max_age:
        type: string
        description: 'Total retention period for all snapshots, with the format ''length
          unit'' (space is optional), where unit can be one of: d (day), h (hour),
          min (minute)'
    description: Information about the Elasticsearch cluster snapshot retention.
  ClusterSnapshotSettings:
    type: object
    properties:
      interval:
        type: string
        description: 'Interval between snapshots, with the format ''length unit''
          (space is optional), where unit can be one of: d (day), h (hour), min (minute).
          Default is 30 minutes'
      retention:
        description: Cluster snapshot retention information
        "$ref": "#/definitions/ClusterSnapshotRetention"
      slm:
        type: boolean
        description: When set to true, the deployment will have SLM enabled. Default
          value is true.
        readOnly: true
      cron_expression:
        type: string
        description: Cron expression indicating when should snapshots be taken. This
          can be enabled only if SLM is enabled for the deployment and 'interval'
          is not present
    description: The snapshot configuration settings for an Elasticsearch cluster.
  ClusterSystemAlert:
    type: object
    required:
    - alert_type
    - instance_name
    - timestamp
    properties:
      timestamp:
        type: string
        format: date-time
        description: Timestamp marking the system alert
      instance_name:
        type: string
        description: Instance that caused the system alert
      alert_type:
        type: string
        description: Type of system alert
        enum:
        - automatic_restart
        - heap_dump
        - unknown_event
      url:
        type: string
        description: 'The URL related to the event. Only applicable for alert_type:
          heap_dump'
      exit_code:
        type: integer
        format: int32
        description: 'The exit_code related to the event. Only applicable for alert_type:
          slain'
    description: Information about a system alert on an Elasticsearch cluster.
  ClusterTopologyInfo:
    type: object
    required:
    - healthy
    - instances
    properties:
      healthy:
        type: boolean
        description: Whether the cluster topology is healthy (ie all instances are
          started and the services they run - ie elasticsearch - are available
      instances:
        type: array
        items:
          "$ref": "#/definitions/ClusterInstanceInfo"
    description: The topology for Elasticsearch clusters, multiple Kibana instances,
      or multiple APM Servers. The `ClusterTopologyInfo` also includes the instances
      and containers, and where they are located.
  Costs:
    type: object
    required:
    - dimensions
    - total
    properties:
      total:
        type: number
        format: double
        description: Total costs
      dimensions:
        type: array
        description: A collection of billing details by dimension.
        items:
          "$ref": "#/definitions/Dimension"
    description: Costs overview for an organization. All of the costs, credits, trials
      are expressed in Elastic Consumption Unit (ECU).
  CostsOverview:
    type: object
    required:
    - costs
    - hourly_rate
    - trials
    properties:
      costs:
        description: Costs for the organization
        "$ref": "#/definitions/Costs"
      trials:
        type: number
        format: double
        description: Trial costs for the organization
      hourly_rate:
        type: number
        format: double
        description: Hourly rate applied.
      balance:
        description: Balance for the organization
        "$ref": "#/definitions/Balance"
    description: The top level costs overview for an organization. All of the costs,
      credits, trials are expressed in Elastic Consumption Unit (ECU).
  CreateApiKeyRequest:
    type: object
    required:
    - description
    properties:
      description:
        type: string
        description: API key description. Useful if there are multiple keys
      expiration:
        type: string
        description: 'The optional expiration for the API key, provided as a duration
          (ex: ''1d'', ''3h'')'
      role_assignments:
        description: The optional roles for the API key. Takes the role of the creator
          if not specified. Currently unavailable in self-hosted ECE.
        "$ref": "#/definitions/RoleAssignments"
    description: The request payload that creates the API keys.
  CreateExtensionRequest:
    type: object
    required:
    - extension_type
    - name
    - version
    properties:
      name:
        type: string
        description: The extension name. Only ASCII alphanumeric and [_.-] characters
          allowed
      description:
        type: string
        description: The extension description.
      download_url:
        type: string
        description: The URL to download the extension archive.
      extension_type:
        type: string
        description: The extension type.
        enum:
        - plugin
        - bundle
      version:
        type: string
        description: The Elasticsearch version.
    description: The body of a request to create a new extension
  CreateSnapshotDependencyRequest:
    type: object
    required:
    - source_deployment_id
    properties:
      source_deployment_id:
        type: string
        description: Source deployment ID whose snapshots will be accessible from
          the target cluster
    description: Request to create a snapshot dependency between deployments
  CreateSnapshotDependencyResponse:
    type: object
    required:
    - message
    properties:
      message:
        type: string
        description: Message indicating the request status
    description: Response from creating a snapshot dependency
  Creates:
    type: object
    properties:
      elasticsearch:
        type: array
        description: Diagnostics for Elasticsearch clusters
        items:
          "$ref": "#/definitions/Elasticsearch"
      kibana:
        type: array
        description: Diagnostics for Kibanas
        items:
          "$ref": "#/definitions/Kibana"
      apm:
        type: array
        description: Diagnostics for APMs
        items:
          "$ref": "#/definitions/Apm"
      integrations_server:
        type: array
        description: Diagnostics for Integrations Server
        items:
          "$ref": "#/definitions/IntegrationsServer"
      appsearch:
        type: array
        description: Diagnostics for AppSearches
        items:
          "$ref": "#/definitions/AppSearch"
      enterprise_search:
        type: array
        description: Diagnostics for Enterprise Search resources
        items:
          "$ref": "#/definitions/EnterpriseSearch"
    description: Holds diagnostics for resources that will be created
  DeleteApiKeysRequest:
    type: object
    required:
    - keys
    properties:
      keys:
        type: array
        description: The list of API key IDs.
        items:
          type: string
    description: The request payload that deletes the API keys.
  DeleteDomainClaimRequest:
    type: object
    required:
    - domain_claim_request
    properties:
      domain_claim_request:
        type: string
        description: The request to remove a domain claim
  DeploymentCosts:
    type: object
    required:
    - costs
    - deployment_id
    - deployment_name
    - hourly_rate
    properties:
      deployment_id:
        type: string
        description: Elasticsearch deployment id
      deployment_name:
        type: string
        description: Elasticsearch deployment name
      costs:
        description: Costs associated to the deployment
        "$ref": "#/definitions/Costs"
      hourly_rate:
        type: number
        format: double
        description: Price per hour
      period:
        description: Period
        "$ref": "#/definitions/Period"
    description: Detailed costs for a deployment for an organization. All of the costs
      are expressed in Elastic Consumption Unit (ECU).
  DeploymentCreateMetadata:
    type: object
    properties:
      tags:
        type: array
        description: Arbitrary user-defined metadata associated with this deployment
        items:
          "$ref": "#/definitions/MetadataItem"
    description: Additional information about the new deployment object.
  DeploymentCreateRequest:
    type: object
    properties:
      name:
        type: string
        description: A name for the deployment; otherwise this will be the generated
          deployment id
      resources:
        description: The Resources that will belong to this Deployment
        "$ref": "#/definitions/DeploymentCreateResources"
      settings:
        description: Additional configuration for this Deployment
        "$ref": "#/definitions/DeploymentCreateSettings"
      metadata:
        description: Additional information about this deployment
        "$ref": "#/definitions/DeploymentCreateMetadata"
      alias:
        type: string
        description: A user-defined alias to use in place of Cluster IDs for user-friendly
          URLs
      region:
        type: string
        description: Identifier of the region to be used as the default for all the
          resources of the deployment
      version:
        type: string
        description: The version for all the resources of the deployment (must be
          one of the supported versions). Defaults to the latest version if not specified.
    description: A request for creating a new Deployment consisting of multiple clusters
  DeploymentCreateResources:
    type: object
    properties:
      elasticsearch:
        type: array
        description: A list of payloads for Elasticsearch cluster creation.
        items:
          "$ref": "#/definitions/ElasticsearchPayload"
      kibana:
        type: array
        description: A list of payloads for Kibana creation.
        items:
          "$ref": "#/definitions/KibanaPayload"
      apm:
        type: array
        description: 'A list of payloads for APM creation. WARNING: For stack versions
          8.0.0 and higher the integrations_server payload should be used instead,
          as this field becomes deprecated.'
        items:
          "$ref": "#/definitions/ApmPayload"
      appsearch:
        type: array
        description: A list of payloads for AppSearch updates. AppSearch has been
          replaced by Enterprise Search in the Elastic Stack 7.7 and higher.
        items:
          "$ref": "#/definitions/AppSearchPayload"
      enterprise_search:
        type: array
        description: A list of payloads for Enterprise Search creation.
        items:
          "$ref": "#/definitions/EnterpriseSearchPayload"
      integrations_server:
        type: array
        description: A list of payloads for Integrations Server creation.
        items:
          "$ref": "#/definitions/IntegrationsServerPayload"
    description: Describes the resources that will belong to a Deployment
  DeploymentCreateResponse:
    type: object
    required:
    - created
    - id
    - name
    - resources
    properties:
      id:
        type: string
        description: The id of the deployment
      name:
        type: string
        description: The name of the deployment
      alias:
        type: string
        description: A user-defined deployment alias for user-friendly resource URLs
      created:
        type: boolean
        description: Whether or not the deployment was freshly created
      resources:
        type: array
        description: List of created resources.
        items:
          "$ref": "#/definitions/DeploymentResource"
      diagnostics:
        description: Backend diagnostics. Sent if validation is requested.
        "$ref": "#/definitions/DeploymentDiagnostics"
    description: A response returned from the Deployment create endpoint
  DeploymentCreateSettings:
    type: object
    properties:
      traffic_filter_settings:
        description: The traffic filter rulesets to apply to this deployment.
        "$ref": "#/definitions/TrafficFilterSettings"
      observability:
        description: Observability settings for this deployment
        "$ref": "#/definitions/DeploymentObservabilitySettings"
      autoscaling_enabled:
        type: boolean
        description: Enable autoscaling for this deployment.
      solution_type:
        type: string
        description: 'An optional string that declares the deployment''s expected
          application. Example supported values are: elasticsearch, observability,
          security.'
    description: Additional configuration for the new deployment object.
  DeploymentDiagnostics:
    type: object
    properties:
      creates:
        description: Diagnostics for resources to be created
        "$ref": "#/definitions/Creates"
      updates:
        description: Diagnostics for existing resources that may be updated
        "$ref": "#/definitions/Updates"
    description: Describes the diagnostics for a given Deployment-modifying payload
  DeploymentGetResponse:
    type: object
    required:
    - healthy
    - id
    - name
    - resources
    properties:
      id:
        type: string
        description: A randomly-generated id of this Deployment
      name:
        type: string
        description: The name of this deployment
      alias:
        type: string
        description: A user-defined deployment alias for user-friendly resource URLs
      healthy:
        type: boolean
        description: 'Whether the deployment is overall healthy or not (one or more
          of the resource info subsections will have healthy: false)'
      resources:
        description: The Resources that belong to this Deployment
        "$ref": "#/definitions/DeploymentResources"
      settings:
        description: Additional configuration for this Deployment
        "$ref": "#/definitions/DeploymentSettings"
      metadata:
        description: Additional information about this deployment
        "$ref": "#/definitions/DeploymentMetadata"
      observability:
        description: The observability information for this deployment
        "$ref": "#/definitions/DeploymentObservability"
      instance_configurations:
        type: array
        description: List of instance configurations used in the deployment.
        items:
          "$ref": "#/definitions/InstanceConfigurationInfo"
    description: Describes a given Deployment
  DeploymentLogging:
    type: object
    required:
    - healthy
    properties:
      healthy:
        type: boolean
        description: Whether the deployment logging is healthy or not
      urls:
        type: object
        description: The URLs to view this deployment's logs in Kibana
        additionalProperties:
          type: string
      issues:
        type: array
        description: Logging health issues for the deployment
        items:
          "$ref": "#/definitions/ObservabilityIssue"
    description: Logging information for a deployment
  DeploymentLoggingSettings:
    type: object
    required:
    - destination
    properties:
      destination:
        description: The destination deployment that this deployment's logs will be
          sent to
        "$ref": "#/definitions/ObservabilityAbsoluteDeployment"
    description: The logging settings for a deployment
  DeploymentMetadata:
    type: object
    properties:
      tags:
        type: array
        description: Arbitrary user-defined metadata associated with this deployment
        items:
          "$ref": "#/definitions/MetadataItem"
      byok_enabled:
        type: boolean
        description: Indicates if the Deployment is BYOK enabled or not
        readOnly: true
    description: Additional information about the current deployment object.
  DeploymentMetrics:
    type: object
    required:
    - healthy
    properties:
      healthy:
        type: boolean
        description: Whether the deployment metrics are healthy or not
      urls:
        type: object
        description: The URLs to view this deployment's metrics in Kibana
        additionalProperties:
          type: string
      issues:
        type: array
        description: Metrics health issues for the deployment
        items:
          "$ref": "#/definitions/ObservabilityIssue"
    description: Metrics information for a deployment
  DeploymentMetricsSettings:
    type: object
    required:
    - destination
    properties:
      destination:
        description: The destination deployment that this deployment's metrics will
          be sent to
        "$ref": "#/definitions/ObservabilityAbsoluteDeployment"
    description: The metrics settings for a deployment
  DeploymentObservability:
    type: object
    required:
    - healthy
    properties:
      healthy:
        type: boolean
        description: 'Whether the deployment observability is healthy or not (one
          or more of the subsections will have healthy: false)'
      logging:
        description: The logging information for the deployment
        "$ref": "#/definitions/DeploymentLogging"
      metrics:
        description: The metrics information for the deployment
        "$ref": "#/definitions/DeploymentMetrics"
      issues:
        type: array
        description: General observability health issues for the deployment
        items:
          "$ref": "#/definitions/ObservabilityIssue"
    description: Observability information for a deployment
  DeploymentObservabilitySettings:
    type: object
    properties:
      logging:
        description: The logging settings for the deployment
        "$ref": "#/definitions/DeploymentLoggingSettings"
      metrics:
        description: The metrics settings for the deployment
        "$ref": "#/definitions/DeploymentMetricsSettings"
    description: The observability settings for a deployment
  DeploymentResource:
    type: object
    required:
    - id
    - kind
    - ref_id
    - region
    properties:
      ref_id:
        type: string
        description: A locally-unique friendly alias for this Elasticsearch cluster
      elasticsearch_cluster_ref_id:
        type: string
        description: The Elasticsearch cluster that this resource depends on.
      id:
        type: string
        description: A system-unique id for the created resource
      kind:
        type: string
        description: The kind of resource
      region:
        type: string
        description: Identifier of the region in which this resource runs.
      cloud_id:
        type: string
        description: An encoded string that provides other Elastic services with the
          necessary information to connect to this Elasticsearch and Kibana
      credentials:
        description: Credentials for logging into a created resource. Only provided
          on initial create and absent otherwise.
        "$ref": "#/definitions/ClusterCredentials"
      secret_token:
        type: string
        description: Secret token for using a created resource. Only provided on initial
          create and absent otherwise.
      warnings:
        type: array
        description: List of warnings generated from validating resource updates
        items:
          "$ref": "#/definitions/ReplyWarning"
    description: Data for a deployment resource
  DeploymentResourceCommandResponse:
    type: object
    properties:
      warnings:
        type: array
        description: List of warnings generated from validating command
        items:
          "$ref": "#/definitions/ReplyWarning"
    description: Response returned when a command is successfully issued against a
      given Deployment resource
  DeploymentResourceCrudResponse:
    type: object
    required:
    - id
    - kind
    - ref_id
    properties:
      id:
        type: string
        description: The id of the deployment
      kind:
        type: string
        description: The kind of the stateless resource
      ref_id:
        type: string
        description: The reference id of the resource
    description: A response returned from the Deployment Resource endpoints
  DeploymentResourceUserSettings:
    type: object
    required:
    - user_settings
    properties:
      user_settings:
        type: object
        description: A JSON object containing the user settings for the resource.
          Replaces all existing user settings when submitted via PUT.
    description: The user-defined settings for a deployment resource
  DeploymentResourceUserSettingsResponse:
    type: object
    properties:
      user_settings:
        type: object
        description: The user-defined settings for the resource
    description: The user-defined settings for a Deployment resource.
  DeploymentResources:
    type: object
    required:
    - apm
    - appsearch
    - elasticsearch
    - enterprise_search
    - integrations_server
    - kibana
    properties:
      elasticsearch:
        type: array
        description: List of Elasticsearch resources in your Deployment
        items:
          "$ref": "#/definitions/ElasticsearchResourceInfo"
      kibana:
        type: array
        description: List of Kibana resources in your Deployment
        items:
          "$ref": "#/definitions/KibanaResourceInfo"
      apm:
        type: array
        description: List of Apm resources in your Deployment
        items:
          "$ref": "#/definitions/ApmResourceInfo"
      appsearch:
        type: array
        description: List of App Search resources in your Deployment
        items:
          "$ref": "#/definitions/AppSearchResourceInfo"
      enterprise_search:
        type: array
        description: List of Enterprise Search resources in your Deployment
        items:
          "$ref": "#/definitions/EnterpriseSearchResourceInfo"
      integrations_server:
        type: array
        description: List of Integrations Server resources in your Deployment
        items:
          "$ref": "#/definitions/IntegrationsServerResourceInfo"
    description: Describes a resource belonging to a Deployment
  DeploymentRestoreResponse:
    type: object
    required:
    - id
    properties:
      id:
        type: string
        description: The id of the deployment
    description: A response returned from the Deployment restore endpoint
  DeploymentRoleAssignment:
    type: object
    required:
    - organization_id
    - role_id
    properties:
      role_id:
        type: string
        description: The ID of the role that is assigned.
      organization_id:
        type: string
        description: The ID of the organization the role is scoped to.
      all:
        type: boolean
        description: When true, the role applies to all deployments in the organization,
          otherwise the role is scoped to the deployments specified in `deployment_ids`.
      deployment_ids:
        type: array
        description: The IDs of the deployments the role is scoped to. Must be absent
          if `all` is true, and present if `all` is false.
        items:
          type: string
      application_roles:
        type: array
        description: If provided, the user assigned this role assignment will be granted
          this application role when signing in to the deployment(s) specified in
          the role assignment.
        items:
          type: string
    description: Assignment for a role with deployment scope.
  DeploymentSearchResponse:
    type: object
    required:
    - healthy
    - id
    - name
    - resources
    properties:
      id:
        type: string
        description: A randomly-generated id of this Deployment
      name:
        type: string
        description: The name of this deployment
      alias:
        type: string
        description: A user-defined deployment alias for user-friendly resource URLs
      healthy:
        type: boolean
        description: 'Whether the deployment is overall healthy or not (one or more
          of the resource info subsections will have healthy: false)'
      resources:
        description: The Resources that belong to this Deployment
        "$ref": "#/definitions/DeploymentResources"
      settings:
        description: Additional configuration for this Deployment
        "$ref": "#/definitions/DeploymentSettings"
      metadata:
        description: Additional information about this deployment
        "$ref": "#/definitions/DeploymentMetadata"
    description: Describes a searched Deployment
  DeploymentSettings:
    type: object
    required:
    - auto_ops
    properties:
      traffic_filter_settings:
        description: The traffic filter rulesets for this deployment.
        "$ref": "#/definitions/TrafficFilterSettings"
      observability:
        description: Logging and monitoring settings for this deployment.
        "$ref": "#/definitions/DeploymentObservabilitySettings"
      autoscaling_enabled:
        type: boolean
        description: If autoscaling is enabled for this deployment.
      auto_ops:
        description: See AutoOps integration status for this deployment.
        "$ref": "#/definitions/AutoOpsSettings"
      solution_type:
        type: string
        description: 'An optional string that declares the deployment''s expected
          application. Example supported values are: elasticsearch, observability,
          security.'
    description: Additional configuration about the current deployment object.
  DeploymentShutdownResponse:
    type: object
    required:
    - id
    - name
    properties:
      id:
        type: string
        description: The id of the deployment
      name:
        type: string
        description: The name of the deployment
      orphaned:
        description: Details about orphaned resources
        "$ref": "#/definitions/Orphaned"
    description: A response returned from the Deployment shutdown endpoint
  DeploymentTagsResponse:
    type: object
    properties:
      tags:
        type: array
        description: Arbitrary user-defined metadata associated with this deployment
        items:
          "$ref": "#/definitions/MetadataItem"
    description: A response returned from the Deployment tags endpoints
  DeploymentTemplateInfoV2:
    type: object
    required:
    - deployment_template
    - id
    - instance_configurations
    - name
    properties:
      id:
        type: string
        description: The unique identifier for the template.
      name:
        type: string
        description: A human readable name for the template.
      description:
        type: string
        description: An optional description for the template.
      deployment_template:
        description: The body of the deployment template to use for creating a deployment.
        "$ref": "#/definitions/DeploymentCreateRequest"
      system_owned:
        type: boolean
        description: Whether or not if this is system owned template.
      source:
        description: Information describing the source that created or modified the
          template.
        "$ref": "#/definitions/ChangeSourceInfo"
      metadata:
        type: array
        description: Optional arbitrary metadata to associate with this template.
        items:
          "$ref": "#/definitions/MetadataItem"
      instance_configurations:
        type: array
        description: List of instance configurations used in the cluster template.
        items:
          "$ref": "#/definitions/InstanceConfigurationInfo"
      order:
        type: integer
        format: int32
        description: Determines the order in which this template should be returned
          when listed. Templates are returned in ascending order. If not specified,
          then the template willbe appended to the end of the list.
      min_version:
        type: string
        description: Minimum stack version required by this template, if any.
      template_category_id:
        type: string
        description: Provider and version agnostic template identifier used for grouping
          related template types.
      kibana_deeplink:
        type: array
        description: The Kibana Deeplink for this type of deployment.
        items:
          "$ref": "#/definitions/KibanaDeeplink"
    description: Deployment template detailed information
  DeploymentTemplateReference:
    type: object
    required:
    - id
    properties:
      id:
        type: string
        description: The unique identifier of the deployment template
      version:
        type: string
        description: A version identifier to disambiguate multiple revisions of the
          same template
    description: Specifies the deployment template used to create the plan.
  DeploymentUpdateMetadata:
    type: object
    properties:
      tags:
        type: array
        description: Arbitrary user-defined metadata associated with this deployment
        items:
          "$ref": "#/definitions/MetadataItem"
    description: Additional information about the current deployment object.
  DeploymentUpdateRequest:
    type: object
    required:
    - prune_orphans
    properties:
      name:
        type: string
        description: A new name for the deployment, otherwise stays the same.
      prune_orphans:
        type: boolean
        description: Whether or not to prune orphan resources that are no longer mentioned
          in this request. Note that resourcesare tracked by ref_id, and if a resource's
          ref_id is changed, any previous running resources created with that previousref_id
          are considered to be orphaned as well.
      resources:
        description: New information about the Resources that will have this Deployment,
          otherwise they stay the same
        "$ref": "#/definitions/DeploymentUpdateResources"
      settings:
        description: Any new configuration for the current deployment object. If there
          is no new configuration the value is unchanged.
        "$ref": "#/definitions/DeploymentUpdateSettings"
      metadata:
        description: Any new information about the current deployment object. If there
          is no new information the value is unchanged.
        "$ref": "#/definitions/DeploymentUpdateMetadata"
      alias:
        type: string
        description: A user-defined alias to use in place of Cluster IDs for user-friendly
          URLs
    description: A request for updating a Deployment consisting of multiple resources
  DeploymentUpdateResources:
    type: object
    properties:
      elasticsearch:
        type: array
        description: A list of payloads for Elasticsearch cluster updates
        items:
          "$ref": "#/definitions/ElasticsearchPayload"
      kibana:
        type: array
        description: A list of payloads for Kibana updates
        items:
          "$ref": "#/definitions/KibanaPayload"
      apm:
        type: array
        description: A list of payloads for APM updates
        items:
          "$ref": "#/definitions/ApmPayload"
      appsearch:
        type: array
        description: A list of payloads for AppSearch updates. AppSearch has been
          replaced by Enterprise Search in the Elastic Stack 7.7 and higher
        items:
          "$ref": "#/definitions/AppSearchPayload"
      enterprise_search:
        type: array
        description: A list of payloads for Enterprise Search updates
        items:
          "$ref": "#/definitions/EnterpriseSearchPayload"
      integrations_server:
        type: array
        description: A list of payloads for Integrations Server updates
        items:
          "$ref": "#/definitions/IntegrationsServerPayload"
    description: Describes the Deployment resource updates
  DeploymentUpdateResponse:
    type: object
    required:
    - id
    - name
    - resources
    properties:
      id:
        type: string
        description: The id of the deployment
      name:
        type: string
        description: The name of the deployment
      alias:
        type: string
        description: A user-defined alias to use in place of ResourceIds for user-friendly
          resource URLs
      resources:
        type: array
        description: List of resources that are part of the deployment after the update
          operation.
        items:
          "$ref": "#/definitions/DeploymentResource"
      shutdown_resources:
        description: List of resources that have been shut down
        "$ref": "#/definitions/Orphaned"
      diagnostics:
        description: Backend diagnostics. Sent if validation is requested.
        "$ref": "#/definitions/DeploymentDiagnostics"
      settings:
        description: Additional configuration for this Deployment
        "$ref": "#/definitions/DeploymentSettings"
    description: A response returned from the Deployment update endpoint
  DeploymentUpdateSettings:
    type: object
    properties:
      observability:
        description: Logging and monitoring settings for this deployment. If provided
          it will change observability settings, if null observability will be removed
          from the deployment, otherwise will stay the same
        "$ref": "#/definitions/DeploymentObservabilitySettings"
      autoscaling_enabled:
        type: boolean
        description: Enable autoscaling for this deployment.
      auto_ops:
        description: See AutoOps integration status for this deployment.
        "$ref": "#/definitions/AutoOpsSettings"
    description: Additional configuration for the new deployment object.
  DeploymentUpgradeAssistantStatusResponse:
    type: object
    required:
    - details
    - ready_for_upgrade
    properties:
      ready_for_upgrade:
        type: boolean
        description: A boolean indicating whether or not the cluster is ready to be
          upgraded
      details:
        type: string
        description: Message with information about the number of Elasticsearch and
          Kibana deprecations
    description: The status of your cluster and its readiness to be upgraded
  DeploymentsCosts:
    type: object
    required:
    - deployments
    - total_cost
    properties:
      total_cost:
        type: number
        format: double
        description: Total cost for all deployments
      deployments:
        type: array
        description: Costs of the list of deployments
        items:
          "$ref": "#/definitions/DeploymentCosts"
    description: Costs associated to a set of deployments for an organization. All
      of the costs are expressed in Elastic Consumption Unit (ECU).
  DeploymentsListResponse:
    type: object
    required:
    - deployments
    properties:
      deployments:
        type: array
        description: The deployments
        items:
          "$ref": "#/definitions/DeploymentsListingData"
    description: Contains a list of deployments
  DeploymentsListingData:
    type: object
    required:
    - id
    - name
    - resources
    properties:
      id:
        type: string
        description: The id of this deployment
      name:
        type: string
        description: The name of this deployment
      resources:
        type: array
        description: List of resources in this deployment
        items:
          "$ref": "#/definitions/DeploymentResource"
  DeploymentsSearchResponse:
    type: object
    required:
    - deployments
    - return_count
    properties:
      return_count:
        type: integer
        format: int32
        description: The number of deployments actually returned, either as deployment
          instances or as minimalMetadata objects
      match_count:
        type: integer
        format: int32
        description: If a query is supplied, then the total number of deployments
          that matched
      deployments:
        type: array
        items:
          "$ref": "#/definitions/DeploymentSearchResponse"
      minimal_metadata:
        type: array
        items:
          type: object
      cursor:
        type: string
        description: To retrieve the next batch of deployments from this search, specify
          this value in the cursor field of the next search request. For paginated
          searches, it is recommended to sort on a static and unique field, like deployment
          or cluster id. A static and unique sort avoids concurrent updates causing
          a deployment to move across pages and becoming a duplicate or lost entry.
          The default sort of rank and modified date is often good for getting a particular
          deployment into the first page, but if a not yet seen deployment is modified
          in between page requests, then it would be left out from the next page.
    description: Contains a list of Deployments as result of a search request.
  Dimension:
    type: object
    required:
    - cost
    - type
    properties:
      type:
        type: string
        description: The type of the billing dimension
        enum:
        - capacity
        - data_in
        - data_internode
        - data_out
        - storage_api
        - storage_bytes
      cost:
        type: number
        format: double
        description: The cost of the billing dimension
    description: Billing dimension
  DirectTrustRelationship:
    type: object
    required:
    - certificates
    - name
    - trust_all
    properties:
      uid:
        type: string
        description: Auto generated identifier for this trust, allows distinguishing
          between update vs remove and add.
      name:
        type: string
        description: a human readable name of the trust relationship
      type:
        type: string
        description: The type can either be ESS, ECE, generic or proxy. If none is
          specified, then generic is assumed. If proxy is specified, trust_all should
          be false and trust_allowlist, scope_id and additional_node_names should
          be omitted.
        enum:
        - ECE
        - ESS
        - generic
        - proxy
      trust_all:
        type: boolean
        description: If true, scope_id is required and the `trust_allowlist` is ignored
          and all clusters matching the scope id will be trusted.
      trust_allowlist:
        type: array
        description: The list of clusters with matching scope to trust. Only used
          when `trust_all` is false. Providing one or more clusters makes scope_id
          mandatory.
        items:
          type: string
      scope_id:
        type: string
        example: abc123
        description: A lowercase alphanumerical string of max 32 characters. Usually
          an organization id or an environment id, but could really be any suitable
          suffix for clusters using the CA certificate of this trust. Required unless
          trust_all is false and trust_allowlist is empty.
      additional_node_names:
        type: array
        description: A list of node names trusted in addition to those deducible from
          trust_allowlist and scope id. Allows trusting nodes that don't have a scoped
          name at the cost of maintaining the list. Mandatory if scope id is not defined.
          Wildcards are not allowed.
        items:
          type: string
      certificates:
        type: array
        description: The public ca certificate(s) to trust. Only one is required,
          but it is possible to specify multiple certificates in order to facilitate
          key rotation.
        items:
          "$ref": "#/definitions/TrustedCertificate"
    description: The trust relationship with entities trusted directly having their
      certificate bundled together with the trust settings.
  DiscreteSizes:
    type: object
    required:
    - sizes
    properties:
      sizes:
        type: array
        description: List of supported sizes
        items:
          type: integer
          format: int32
      default_size:
        type: integer
        format: int32
        description: The default size
      resource:
        type: string
        description: The unit that each size represents. If not specified, it will
          default to 'memory'.
        enum:
        - memory
        - storage
    description: Instance sizes that are supported by the Elasticsearch instance,
      Kibana instance, or APM Server configuration.
  DomainVerificationRequest:
    type: object
    required:
    - domain_claim_request
    properties:
      domain_claim_request:
        type: string
        description: The domain claim request
  DtsDimensionCosts:
    type: object
    required:
    - cost
    - name
    - quantity
    - rate
    - sku
    - type
    properties:
      cost:
        type: number
        format: double
        description: Costs associated to the Data Transfer and Storage (DTS) dimensions
          for an organization
      name:
        type: string
        description: DTS dimension name
      quantity:
        description: DTS usage
        "$ref": "#/definitions/DtsQuantity"
      rate:
        description: Cost per unit
        "$ref": "#/definitions/DtsRate"
      sku:
        type: string
        description: DTS dimension Stock Keeping Unit (SKU)
      type:
        type: string
        description: Type of the DTS dimension usage
    description: The costs associated to a Data Transfer and Storage (DTS) dimension
      for an organization. All of the costs, credits, and trials are expressed in
      Elastic Consumption Units (ECU).
  DtsQuantity:
    type: object
    required:
    - formatted_value
    - value
    properties:
      value:
        type: integer
        format: int64
        description: Raw quantity
      formatted_value:
        type: string
        description: Quantity in human readable format
    description: DTS quantity
  DtsRate:
    type: object
    required:
    - formatted_value
    - value
    properties:
      value:
        type: number
        format: double
        description: Raw rate
      formatted_value:
        type: string
        description: Rate in human readable format
    description: DTS Rate
  Elasticsearch:
    type: object
    required:
    - backend_plan
    - display_name
    - ref_id
    properties:
      ref_id:
        type: string
        description: A locally-unique user-specified id
      display_name:
        type: string
        description: The human readable name for the cluster (defaults to the generated
          cluster id if not specified)
      backend_plan:
        type: object
        description: The backend plan as JSON
    description: Holds diagnostics for an Elasticsearch cluster
  ElasticsearchBlockingIssueElement:
    type: object
    required:
    - description
    - level
    properties:
      description:
        type: string
        description: Description of the block
      level:
        type: string
        description: Applicable level for the block. Either global ie. cluster-wide
          or index level
        enum:
        - index
        - global
    description: Information about index or cluster blocks
  ElasticsearchBlockingIssues:
    type: object
    required:
    - blocks
    - healthy
    properties:
      healthy:
        type: boolean
        description: Whether the cluster has issues (false) or not (true)
      blocks:
        type: array
        description: A list of blocks that affect the availability of the cluster
        items:
          "$ref": "#/definitions/ElasticsearchBlockingIssueElement"
    description: Issues that prevent the Elasticsearch cluster or index from correctly
      operating.
  ElasticsearchClusterBlockingIssueElement:
    type: object
    required:
    - description
    - instances
    properties:
      description:
        type: string
        description: Description of the issue
      instances:
        type: array
        description: A list of instances that are affected by the issue
        items:
          type: string
    description: |-
      > WARNING
      > This endpoint is deprecated and scheduled to be removed in the next major version. Use `blocks` in `cluster_blocking_issues` instead

      Information about an issue and the Elasticsearch instance it affects.
  ElasticsearchClusterBlockingIssues:
    type: object
    required:
    - cluster_level
    - healthy
    - index_level
    properties:
      healthy:
        type: boolean
        description: Whether the cluster has issues (false) or not (true)
      cluster_level:
        type: array
        description: A list of issues that affect availability of entire cluster
        items:
          "$ref": "#/definitions/ElasticsearchClusterBlockingIssueElement"
      index_level:
        type: array
        description: A list of issues that affect availability of the cluster's indices
        items:
          "$ref": "#/definitions/ElasticsearchClusterBlockingIssueElement"
    description: |-
      > WARNING
      > This endpoint is deprecated and scheduled to be removed in the next major version. Use `cluster_blocking_issues` instead

      Issues that prevent the Elasticsearch cluster or index from operating correctly.
  ElasticsearchClusterInfo:
    type: object
    required:
    - associated_apm_clusters
    - associated_appsearch_clusters
    - associated_enterprise_search_clusters
    - associated_kibana_clusters
    - cluster_id
    - cluster_name
    - elasticsearch
    - external_links
    - healthy
    - metadata
    - plan_info
    - snapshots
    - status
    - topology
    properties:
      cluster_id:
        type: string
        description: The id of the cluster
      cluster_name:
        type: string
        description: The name of the cluster
      deployment_id:
        type: string
        description: The id of the deployment that this Elasticsearch belongs to.
      healthy:
        type: boolean
        description: 'Whether the cluster is healthy or not (one or more of the info
          subsections will have healthy: false)'
      status:
        type: string
        description: Cluster status
        enum:
        - initializing
        - stopping
        - stopped
        - rebooting
        - restarting
        - reconfiguring
        - started
      plan_info:
        "$ref": "#/definitions/ElasticsearchClusterPlansInfo"
      elasticsearch:
        "$ref": "#/definitions/ElasticsearchInfo"
      metadata:
        "$ref": "#/definitions/ClusterMetadataInfo"
      topology:
        "$ref": "#/definitions/ClusterTopologyInfo"
      system_alerts:
        type: array
        description: List of cluster system alerts
        items:
          "$ref": "#/definitions/ClusterSystemAlert"
      associated_kibana_clusters:
        type: array
        items:
          "$ref": "#/definitions/KibanaSubClusterInfo"
      associated_apm_clusters:
        type: array
        items:
          "$ref": "#/definitions/ApmSubInfo"
      associated_appsearch_clusters:
        type: array
        items:
          "$ref": "#/definitions/AppSearchSubInfo"
      associated_enterprise_search_clusters:
        type: array
        items:
          "$ref": "#/definitions/EnterpriseSearchSubInfo"
      security:
        "$ref": "#/definitions/ElasticsearchClusterSecurityInfo"
      elasticsearch_monitoring_info:
        "$ref": "#/definitions/ElasticsearchMonitoringInfo"
      snapshots:
        "$ref": "#/definitions/SnapshotStatusInfo"
      external_links:
        type: array
        description: External resources related to the cluster
        uniqueItems: true
        items:
          "$ref": "#/definitions/ExternalHyperlink"
      links:
        type: object
        description: A map of application-specific operations (which map to 'operationId's
          in the Swagger API) to metadata about that operation
        additionalProperties:
          "$ref": "#/definitions/Hyperlink"
      settings:
        "$ref": "#/definitions/ElasticsearchClusterSettings"
      region:
        type: string
        description: The region that this cluster belongs to. Only populated in SaaS
          or federated ECE.
    description: The information for an Elasticsearch cluster.
  ElasticsearchClusterPlan:
    type: object
    required:
    - cluster_topology
    - elasticsearch
    properties:
      cluster_topology:
        type: array
        items:
          "$ref": "#/definitions/ElasticsearchClusterTopologyElement"
      elasticsearch:
        "$ref": "#/definitions/ElasticsearchConfiguration"
      deployment_template:
        description: Documents which deployment template was used in the creation
          of this plan
        "$ref": "#/definitions/DeploymentTemplateReference"
      transient:
        "$ref": "#/definitions/TransientElasticsearchPlanConfiguration"
      autoscaling_enabled:
        type: boolean
        description: Enable autoscaling for this Elasticsearch cluster.
    description: The plan for the Elasticsearch cluster.
  ElasticsearchClusterPlanInfo:
    type: object
    required:
    - healthy
    - plan_attempt_log
    - warnings
    properties:
      plan_attempt_id:
        type: string
        description: A UUID for each plan attempt
      plan_attempt_name:
        type: string
        description: A human readable name for each plan attempt, only populated when
          retrieving plan histories
      healthy:
        type: boolean
        description: Either the plan ended successfully, or is not yet completed (and
          no errors have occurred)
      attempt_start_time:
        type: string
        format: date-time
        description: When this plan attempt (ie to apply the plan to the cluster)
          started (ISO format in UTC)
      attempt_end_time:
        type: string
        format: date-time
        description: If this plan completed or failed (ie is not pending), when the
          attempt ended (ISO format in UTC)
      plan_end_time:
        type: string
        format: date-time
        description: If this plan is not current or pending, when the plan was no
          longer active (ISO format in UTC)
      plan:
        "$ref": "#/definitions/ElasticsearchClusterPlan"
      plan_attempt_log:
        type: array
        items:
          "$ref": "#/definitions/ClusterPlanStepInfo"
      source:
        description: Information describing the source that facilitated the plans
          current state
        "$ref": "#/definitions/ChangeSourceInfo"
      warnings:
        type: array
        items:
          "$ref": "#/definitions/ClusterPlanWarning"
      error:
        "$ref": "#/definitions/ClusterPlanAttemptError"
    description: Information about the Elasticsearch cluster plan.
  ElasticsearchClusterPlansInfo:
    type: object
    required:
    - healthy
    - history
    properties:
      healthy:
        type: boolean
        description: Whether the plan situation is healthy (if unhealthy, means the
          last plan attempt failed)
      current:
        "$ref": "#/definitions/ElasticsearchClusterPlanInfo"
      pending:
        "$ref": "#/definitions/ElasticsearchClusterPlanInfo"
      history:
        type: array
        items:
          "$ref": "#/definitions/ElasticsearchClusterPlanInfo"
    description: Information about the current, pending, and past Elasticsearch cluster
      plans.
  ElasticsearchClusterRole:
    type: object
    required:
    - roles
    - username
    properties:
      username:
        type: string
        description: The username
      roles:
        type: array
        description: The list of roles for this user
        items:
          type: string
    description: The authorization information for an Elasticsearch cluster user.
  ElasticsearchClusterSecurityInfo:
    type: object
    required:
    - last_modified
    - roles
    - users
    - users_roles
    - version
    properties:
      version:
        type: integer
        format: int32
        description: The resource version number of the security settings
      last_modified:
        type: string
        format: date-time
        description: The most recent time the security settings were changed (ISO
          format in UTC)
      users:
        type: array
        items:
          "$ref": "#/definitions/ElasticsearchClusterUser"
      roles:
        type: object
        description: An arbitrarily nested JSON object mapping roles to sets of resources
          and permissions - see the Elasticsearch security documentation for more
          details on roles
      users_roles:
        type: array
        items:
          "$ref": "#/definitions/ElasticsearchClusterRole"
    description: For 2.x Elasticsearch clusters, specifies the information about the
      users and roles. For 5.x Elasticsearch clusters, use the Kibana management UI.
  ElasticsearchClusterSettings:
    type: object
    properties:
      snapshot:
        description: The snapshot settings for this deployment. When provided, snapshot
          settings are changed as specified. A `null` value reverts the field to the
          default value. Otherwise, all snapshot settings remain as they were set
          previously.
        "$ref": "#/definitions/ClusterSnapshotSettings"
      monitoring:
        description: The monitoring settings for this deployment. When provided, monitoring
          settings are changed as specified. A `null` value reverts the field to the
          default value. Otherwise, all monitoring settings remain as they were set
          previously.
        "$ref": "#/definitions/ManagedMonitoringSettings"
      metadata:
        "$ref": "#/definitions/ClusterMetadataSettings"
      curation:
        description: The curation settings for this deployment. When provided, curation
          settings are changed as specified. A `null` value reverts the field to the
          default value. Otherwise, all curation settings remain as they were set
          previously.
        "$ref": "#/definitions/ClusterCurationSettings"
      dedicated_masters_threshold:
        type: integer
        format: int32
        description: Threshold starting from which the number of instances in the
          cluster results in the introduction of dedicated masters. If the cluster
          is downscaled to a number of nodes below this one, dedicated masters will
          be removed. Limit is inclusive. When provided the threshold setting is updated.
          A `null` value removes the field. Otherwise, the setting remains as it was
          set previously.
      traffic_filter:
        description: The rulesets to apply to all resources in this cluster. When
          specified, the set of rulesets is updated and the same rulesets will be
          applied to Kibana and APM clusters as well. If not specified, the rulesets
          remain as they were set previously.
        "$ref": "#/definitions/TrafficFilterSettings"
      trust:
        description: Configuration of trust with other clusters. When provided, trust
          settings are changed as specified. A `null` value reverts the field to the
          default value. Otherwise, all trust settings remain as they were set previously.
        "$ref": "#/definitions/ElasticsearchClusterTrustSettings"
      keystore_contents:
        description: The contents of the Elasticsearch keystore. It's a write only
          field.
        "$ref": "#/definitions/KeystoreContents"
    description: The settings for an Elasticsearch cluster.
  ElasticsearchClusterTopologyElement:
    type: object
    properties:
      id:
        type: string
        description: Unique identifier of this topology element
      node_type:
        "$ref": "#/definitions/ElasticsearchNodeType"
      node_roles:
        type: array
        description: 'The list of node roles for this topology element (ES version
          >= 7.10). Allowable values are: master, ingest, ml, data_hot, data_content,
          data_warm, data_cold, data_frozen, remote_cluster_client, transform'
        items:
          type: string
          enum:
          - master
          - ingest
          - ml
          - data_hot
          - data_content
          - data_warm
          - data_cold
          - data_frozen
          - remote_cluster_client
          - transform
      zone_count:
        type: integer
        format: int32
        description: The default number of zones in which data nodes will be placed
      elasticsearch:
        "$ref": "#/definitions/ElasticsearchConfiguration"
      instance_configuration_id:
        type: string
        description: Controls the allocation of this topology element as well as allowed
          sizes and node_types. It needs to match the id of an existing instance configuration.
      instance_configuration_version:
        type: integer
        format: int32
        description: The version of the Instance Configuration Id. If it is unset,
          the meaning depends on read vs writes. For deployment reads, it is equivalent
          to version 0 (or the IC is unversioned); for deployment creates and deployment
          template use, it is equivalent to 'the latest version'; and for deployment
          updates, it is equivalent to 'retain the current version'.
      size:
        "$ref": "#/definitions/TopologySize"
      autoscaling_min:
        description: The minimum size of this topology element when autoscaling is
          enabled. This property is only supported, and must be provided, for ML topology
          elements.
        "$ref": "#/definitions/TopologySize"
      autoscaling_max:
        description: The maximum size of this topology element when autoscaling is
          enabled. This property is only supported, and must be provided, for data
          and ML topology elements.
        "$ref": "#/definitions/TopologySize"
      autoscaling_policy_override_json:
        type: object
        description: An arbitrary JSON object overriding the default autoscaling policy.
          Don't set unless you really know what you are doing.
      topology_element_control:
        "$ref": "#/definitions/TopologyElementControl"
      autoscaling_tier_override:
        type: boolean
        description: Set to true to enable autoscaling for this topology element,
          even if the cluster-level 'autoscaling_enabled' field is false. Note that
          'autoscaling_tier_override' cannot be set to false if cluster-level 'autoscaling_enabled'
          is true. Currently only supported for the 'ml' tier
    description: The topology of the Elasticsearch nodes, including the number, capacity,
      and type of nodes, and where they can be allocated.
  ElasticsearchClusterTrustSettings:
    type: object
    properties:
      accounts:
        type: array
        description: The list of trust relationships with different accounts
        items:
          "$ref": "#/definitions/AccountTrustRelationship"
      external:
        type: array
        description: The list of trust relationships with external entities
        items:
          "$ref": "#/definitions/ExternalTrustRelationship"
      direct:
        type: array
        description: The list of trust relationships where the certificate is bundled
          with the trust setting. Allows configuring trust for clusters running outside
          of an Elastic Cloud managed environment or in an Elastic Cloud environment
          without an environment level trust established.
        items:
          "$ref": "#/definitions/DirectTrustRelationship"
    description: Configuration of trust with other clusters.
  ElasticsearchClusterUser:
    type: object
    required:
    - password_hash
    - username
    properties:
      username:
        type: string
        description: The username
      password_hash:
        type: string
        description: The hashed password
    description: The information about an Elasticsearch cluster user.
  ElasticsearchConfiguration:
    type: object
    properties:
      version:
        type: string
        description: The version of the Elasticsearch cluster (must be one of the
          ECE supported versions). Currently cannot be different across the topology
          (and is generally specified in the globals). Defaults to the latest version
          if not specified.
      docker_image:
        type: string
        description: A docker URI that allows overriding of the default docker image
          specified for this version
      system_settings:
        "$ref": "#/definitions/ElasticsearchSystemSettings"
      user_settings_json:
        type: object
        description: 'An arbitrary JSON object allowing cluster owners to set their
          parameters (only one of this and ''user_settings_yaml'' is allowed), provided
          the parameters arey are on the allowlist and not on the denylist. NOTES:
          (This field together with ''user_settings_override*'' and ''system_settings''
          defines the total set of Elasticsearch settings)'
      user_settings_yaml:
        type: string
        description: 'An arbitrary YAML object allowing cluster owners to set their
          parameters (only one of this and ''user_settings_json'' is allowed), provided
          the parameters arey are on the allowlist and not on the denylist. NOTES:
          (This field together with ''user_settings_override*'' and ''system_settings''
          defines the total set of Elasticsearch settings)'
      user_settings_override_json:
        type: object
        description: 'An arbitrary JSON object allowing ECE admins owners to set clusters''
          parameters (only one of this and ''user_settings_override_yaml'' is allowed),
          ie in addition to the documented ''system_settings''. NOTES: (This field
          together with ''system_settings'' and ''user_settings*'' defines the total
          set of Elasticsearch settings)'
      user_settings_override_yaml:
        type: string
        description: 'An arbitrary YAML object allowing ECE admins owners to set clusters''
          parameters (only one of this and ''user_settings_override_json'' is allowed),
          ie in addition to the documented ''system_settings''. NOTES: (This field
          together with ''system_settings'' and ''user_settings*'' defines the total
          set of Elasticsearch settings)'
      enabled_built_in_plugins:
        type: array
        description: 'A list of plugin names from the Elastic-supported subset that
          are bundled with the version images. NOTES: (Users should consult the Elastic
          stack objects to see what plugins are available, this is currently only
          available from the UI)'
        items:
          type: string
      user_plugins:
        type: array
        description: A list of admin-uploaded plugin objects that are available for
          this user.
        items:
          "$ref": "#/definitions/ElasticsearchUserPlugin"
      user_bundles:
        type: array
        description: A list of admin-uploaded bundle objects (eg scripts, synonym
          files) that are available for this user.
        items:
          "$ref": "#/definitions/ElasticsearchUserBundle"
      curation:
        description: Defines the index curation routing for the cluster
        "$ref": "#/definitions/ElasticsearchCuration"
      node_attributes:
        type: object
        description: Defines the Elasticsearch node attributes for the instances in
          the topology
        additionalProperties:
          type: string
    description: The Elasticsearch cluster settings. When specified at the top level,
      provides a field-by-field default. When specified at the topology level, provides
      the override settings.
  ElasticsearchCuration:
    type: object
    required:
    - from_instance_configuration_id
    - to_instance_configuration_id
    properties:
      from_instance_configuration_id:
        type: string
        description: The source instance configuration
      to_instance_configuration_id:
        type: string
        description: The destination instance configuration
    description: The structure that defines the routing settings for index curation.
  ElasticsearchDependant:
    type: object
    required:
    - id
    - kind
    properties:
      id:
        type: string
        description: The id of the orphaned resource
      kind:
        type: string
        description: The kind of resource
    description: Details about an orphaned Elasticsearch-dependent resources.
  ElasticsearchElasticUserPasswordResetResponse:
    type: object
    required:
    - password
    - username
    properties:
      username:
        type: string
        description: The username for the newly-reset password for the given Elasticsearch
          cluster
      password:
        type: string
        description: The newly-reset password for the given Elasticsearch cluster
    description: Envelope holding the newly-reset password for a cluster's user
  ElasticsearchInfo:
    type: object
    required:
    - blocking_issues
    - healthy
    - master_info
    - shard_info
    properties:
      healthy:
        type: boolean
        description: Whether the Elasticsearch cluster is healthy (check the sub-objects
          for more details if not)
      shard_info:
        description: |-
          > WARNING
          > This endpoint is deprecated and scheduled to be removed in the next major version. Use `shards_status` instead.

          Elasticsearch shard info
        "$ref": "#/definitions/ElasticsearchShardsInfo"
      shards_status:
        "$ref": "#/definitions/ElasticsearchShardsStatus"
      master_info:
        "$ref": "#/definitions/ElasticsearchMasterInfo"
      blocking_issues:
        description: |-
          > WARNING
          > This endpoint is deprecated and scheduled to be removed in the next major version. Use `cluster_blocking_issues` instead.

          cluster-wide and/or index blocks
        "$ref": "#/definitions/ElasticsearchClusterBlockingIssues"
      cluster_blocking_issues:
        "$ref": "#/definitions/ElasticsearchBlockingIssues"
    description: Information about the Elasticsearch cluster.
  ElasticsearchMasterElement:
    type: object
    required:
    - instances
    - master_node_id
    properties:
      master_node_id:
        type: string
        description: The Elasticsearch node id of a master node
      master_instance_name:
        type: string
        description: The corresponding instance name of the container hosting the
          Elasticsearch master node, if available
      instances:
        type: array
        description: The names of the instance/container hosting the node belong to
          the cluster with the given master
        items:
          type: string
    description: Information about the Elasticsearch instances. For split-brain cases,
      this also includes sub-clusters.
  ElasticsearchMasterInfo:
    type: object
    required:
    - healthy
    - instances_with_no_master
    - masters
    properties:
      healthy:
        type: boolean
        description: Whether the master situation in the cluster is healthy (ie is
          the number of masters != 1), or do any instances have no master
      masters:
        type: array
        items:
          "$ref": "#/definitions/ElasticsearchMasterElement"
      instances_with_no_master:
        type: array
        description: A list of any instances with no master
        items:
          type: string
    description: Information about the master nodes in the Elasticsearch cluster.
  ElasticsearchMonitoringInfo:
    type: object
    required:
    - destination_cluster_ids
    - healthy
    - last_modified
    - last_update_status
    - source_cluster_ids
    properties:
      healthy:
        type: boolean
        description: Whether the Monitoring configuration has been successfully applied
      last_modified:
        type: string
        format: date-time
        description: The time the monitoring configuration was last changed
      last_update_status:
        type: string
        description: The status message from the last update (successful or not)
      source_cluster_ids:
        type: array
        description: The list of clusters Ids from which this cluster is currently
          receiving monitoring data
        items:
          type: string
      destination_cluster_ids:
        type: array
        description: The list of clusters Ids to which this cluster is currently sending
          monitoring data
        items:
          type: string
    description: Information about the monitoring status for the Elasticsearch cluster.
  ElasticsearchNodeType:
    type: object
    properties:
      master:
        type: boolean
        description: 'Defines whether this node can be elected master (default: false)'
      data:
        type: boolean
        description: 'Defines whether this node can hold data (default: false)'
      ingest:
        type: boolean
        description: 'Defines whether this node can run an ingest pipeline (default:
          false)'
      ml:
        type: boolean
        description: 'Defines whether this node can run ml jobs, valid only for versions
          5.4.0 or greater (default: false)'
    description: 'Controls the combinations of Elasticsearch node types. TIP: By default,
      the Elasticsearch node is master eligible, can hold data, and run ingest pipelines.
      WARNING: Do not set for tiebreaker topologies.'
  ElasticsearchPayload:
    type: object
    required:
    - plan
    - ref_id
    - region
    properties:
      ref_id:
        type: string
        description: A locally-unique user-specified id for this Elasticsearch cluster
      display_name:
        type: string
        description: The human readable name for the cluster (defaults to the generated
          cluster id if not specified)
      region:
        type: string
        description: The region where this resource exists
      plan:
        description: The plan for building this Elasticsearch cluster
        "$ref": "#/definitions/ElasticsearchClusterPlan"
      settings:
        description: The settings for building this Elasticsearch cluster
        "$ref": "#/definitions/ElasticsearchClusterSettings"
    description: An alias for an Elasticsearch Cluster paired with a request for creating
      one
  ElasticsearchPlanControlConfiguration:
    type: object
    properties:
      timeout:
        type: integer
        format: int64
        description: 'The total timeout in seconds after which the plan is cancelled
          even if it is not complete. Defaults to 4x the max memory capacity per node
          (in MB). NOTES: A 3 zone cluster with 2 nodes of 2048 each would have a
          timeout of 4*2048=8192 seconds. Timeout does not include time required to
          run rollback actions.'
      calm_wait_time:
        type: integer
        format: int64
        description: This timeout determines how long to give a cluster after it responds
          to API calls before performing actual operations on it. It defaults to 5s
      skip_snapshot:
        type: boolean
        description: 'If true (default: false), does not take (or require) a successful
          snapshot to be taken before performing any potentially destructive changes
          to this cluster'
      max_snapshot_attempts:
        type: integer
        format: int32
        description: 'If taking a snapshot (ie unless ''skip_snapshots'': true) then
          will retry on failure at most this number of times (default: 5)'
      max_snapshot_age:
        type: integer
        format: int64
        description: When you take a snapshot and 'skip_snapshots' is false, specifies
          the maximum age in seconds of the most recent snapshot before a new snapshot
          is created. Default is 300
      extended_maintenance:
        type: boolean
        description: If true (default false), does not clear the maintenance flag
          (which prevents its API from being accessed except by the constructor) on
          new instances added until after a snapshot has been restored, otherwise,
          the maintenance flag is cleared once the new instances successfully join
          the new cluster
      cluster_reboot:
        type: string
        description: 'Set to ''forced'' to force a reboot as part of the upgrade plan.
          NOTES: (ie taking an existing plan and leaving it alone except for setting
          ''transient.plan_configuration.cluster_reboot'': ''forced'' will reboot
          the cluster)'
        enum:
        - forced
    description: The configuration settings for the timeout and fallback parameters.
  ElasticsearchReplicaElement:
    type: object
    required:
    - instance_name
    - replica_count
    properties:
      instance_name:
        type: string
        description: The Elastic Cloud name/id of the instance (container)
      replica_count:
        type: integer
        format: int32
        description: The number of unavailable replicas on this instance
    description: 'Information about the unavailable replicas. NOTE: Unlike shards,
      unavailable replicas indicate a loss of redundancy rather than a loss of availability.'
  ElasticsearchResourceInfo:
    type: object
    required:
    - id
    - info
    - ref_id
    - region
    properties:
      ref_id:
        type: string
        description: The locally-unique user-specified id of a Resource
      id:
        type: string
        description: The randomly-generated id of a Resource
      region:
        type: string
        description: The region where this resource exists
      info:
        description: Info for the resource.
        "$ref": "#/definitions/ElasticsearchClusterInfo"
    description: Describes an Elasticsearch resource belonging to a Deployment
  ElasticsearchScriptTypeSettings:
    type: object
    properties:
      enabled:
        type: boolean
        description: 'If enabled (default: true) then scripts are enabled, either
          for sandboxing languages (by default), or for all installed languages if
          ''sandbox_mode'' is disabled (or for 6.x). NOTES: (Corresponds to the parameter
          ''script.file|stored/indexed|inline'')'
      sandbox_mode:
        type: boolean
        description: 'If enabled (default: true) and this script type is enabled,
          then only the sandbox languages are allowed. By default the sandbox languages
          are painless, expressions and mustache, but this can be restricted via the
          ''painless_enabled'', ''mustache_enabled'' ''expression_enabled'' settings.NOTES:
          Not supported in 6.x. (Corresponds to the parameters ''script.engine.[painless|mustache|expressions].[file|stored|inline]'')'
    description: Enables scripting for the specified type and controls other parameters.
      Store scripts in indexes (`stored`), upload in file bundles (`file`), or use
      in API requests (`inline`).
  ElasticsearchScriptingUserSettings:
    type: object
    properties:
      painless_enabled:
        type: boolean
        description: "(5.x+ only) If enabled (the default) then the painless scripting
          engine is allowed as a sandboxed language. Sandboxed languages are the only
          ones allowed if 'sandbox_mode' is set to true. NOTES: (Corresponds to the
          parameters 'script.engine.painless.[file|stored|inline]')"
      mustache_enabled:
        type: boolean
        description: "(5.x+ only) If enabled (the default) then the mustache scripting
          engine is allowed as a sandboxed language. Sandboxed languages are the only
          ones allowed if 'sandbox_mode' is set to true. NOTES: (Corresponds to the
          parameters 'script.engine.mustache.[file|stored|inline]')"
      expressions_enabled:
        type: boolean
        description: "(5.x+ only) If enabled (the default) then the expressions scripting
          engine is allowed as a sandboxed language. Sandboxed languages are the only
          ones allowed if 'sandbox_mode' is set to true. NOTES: (Corresponds to the
          parameters 'script.engine.expression.[file|stored|inline]')"
      stored:
        "$ref": "#/definitions/ElasticsearchScriptTypeSettings"
      file:
        "$ref": "#/definitions/ElasticsearchScriptTypeSettings"
      inline:
        "$ref": "#/definitions/ElasticsearchScriptTypeSettings"
    description: 'Controls the languages supported by the Elasticsearch cluster, such
      as Painless, Mustache, and Expressions. Controls how the languages are used,
      such as file, index, and inline. TIP: For complex configurations, leave these
      blank and configure these settings in the user YAML or JSON.'
  ElasticsearchShardElement:
    type: object
    required:
    - instance_name
    - shard_count
    properties:
      instance_name:
        type: string
        description: The Elastic Cloud name/id of the instance (container)
      shard_count:
        type: integer
        format: int32
        description: The number of shards of the given type (available/unavailable)
          on this instance
    description: 'Information about the shards for each Elasticsearch instance container
      that hosts an Elasticsearch node. TIP: When the shard is unavailable, the cluster
      is unable to serve all of the data.'
  ElasticsearchShardsInfo:
    type: object
    required:
    - available_shards
    - healthy
    - unavailable_replicas
    - unavailable_shards
    properties:
      healthy:
        type: boolean
        description: Whether the shard situation is healthy (any unavailable shards
          is unhealthy)
      available_shards:
        type: array
        items:
          "$ref": "#/definitions/ElasticsearchShardElement"
      unavailable_shards:
        type: array
        items:
          "$ref": "#/definitions/ElasticsearchShardElement"
      unavailable_replicas:
        type: array
        items:
          "$ref": "#/definitions/ElasticsearchReplicaElement"
    description: |-
      > WARNING
      > This endpoint is deprecated and scheduled to be removed in the next major version. Use `shards_status` instead.

      Information about the shards and replicas that comprise the Elasticsearch indices.
  ElasticsearchShardsStatus:
    type: object
    required:
    - status
    properties:
      status:
        type: string
        description: Indicates the elasticsearch cluster health status as a color
        enum:
        - green
        - red
        - yellow
    description: Shards status represented as green, yellow, or red, as returned by
      the Elasticsearch cluster health API
  ElasticsearchSystemSettings:
    type: object
    properties:
      scripting:
        "$ref": "#/definitions/ElasticsearchScriptingUserSettings"
      reindex_whitelist:
        type: array
        description: Limits remote Elasticsearch clusters that can be used as the
          source for '_reindex' API commands
        items:
          type: string
      auto_create_index:
        type: boolean
        description: 'If true (the default), then any write operation on an index
          that does not currently exist will create it. NOTES: (Corresponds to the
          parameter ''action.auto_create_index'')'
      enable_close_index:
        type: boolean
        description: 'Defaults to false on versions <= 7.2.0, true otherwise. If false,
          then the API commands to close indices are disabled. This is important because
          Elasticsearch does not snapshot or migrate close indices on versions under
          7.2.0, therefore standard Elastic Cloud configuration operations will cause
          irretrievable loss of indices'' data. NOTES: (Corresponds to the parameter
          ''cluster.indices.close.enable'')'
      destructive_requires_name:
        type: boolean
        description: 'If true (default is false) then the index deletion API will
          not support wildcards or ''_all''. NOTES: (Corresponds to the parameter
          ''action.destructive_requires_name'')'
      watcher_trigger_engine:
        type: string
        description: 'The trigger engine for Watcher, defaults to ''scheduler'' -
          see the xpack documentation for more information. NOTES: (Corresponds to
          the parameter ''(xpack.)watcher.trigger.schedule.engine'', depending on
          version. Ignored from 6.x onwards.)'
      default_shards_per_index:
        type: integer
        format: int32
        description: "(2.x only - to get the same result in 5.x template mappings
          must be used) Sets the default number of shards per index, defaulting to
          1 if not specified. (Corresponds to the parameter 'index.number_of_shards'
          in 2.x, not supported in 5.x)"
      monitoring_collection_interval:
        type: integer
        format: int32
        description: 'The default interval at which monitoring information from the
          cluster if collected, if monitoring is enabled. NOTES: (Corresponds to the
          parameter ''marvel.agent.interval'' in 2.x and ''xpack.monitoring.collection.interval''
          in 5.x)'
      monitoring_history_duration:
        type: string
        description: 'The duration for which monitoring history is stored (format
          ''(NUMBER)d'' eg ''3d'' for 3 days). NOTES: (''Corresponds to the parameter
          xpack.monitoring.history.duration'' in 5.x, defaults to ''7d'')'
    description: 'A subset of Elasticsearch settings. TIP: To define the complete
      set of Elasticsearch settings, use `ElasticsearchSystemSettings` with `user_settings_override*`
      and `user_settings*`.'
  ElasticsearchUserBundle:
    type: object
    required:
    - elasticsearch_version
    - name
    - url
    properties:
      name:
        type: string
        description: The name of the bundle
      url:
        type: string
        description: The URL of the bundle, which must be accessible from the ECE
          infrastructure. This URL could be cached by platform, make sure to change
          it when updating the bundle
      elasticsearch_version:
        type: string
        description: The supported Elasticsearch version (must match the version in
          the plan)
    description: A list of admin-uploaded bundle objects, such as scripts and synonym
      files.
  ElasticsearchUserPlugin:
    type: object
    required:
    - elasticsearch_version
    - name
    - url
    properties:
      name:
        type: string
        description: The name of the plugin
      url:
        type: string
        description: The URL of the plugin (must be accessible from the ECE infrastructure)
      elasticsearch_version:
        type: string
        description: The supported Elasticsearch version (must match the version in
          the plan)
    description: A list of admin-uploaded plugin objects.
  EmptyResponse:
    type: object
  EnableIlmRequest:
    type: object
    required:
    - index_patterns
    properties:
      index_patterns:
        type: array
        description: A locally-unique user-specified id for Kibana
        items:
          "$ref": "#/definitions/IndexPattern"
    description: Request sent to enable ILM on a deployment.
  EnterpriseSearch:
    type: object
    required:
    - backend_plan
    - display_name
    - elasticsearch_cluster_ref_id
    - ref_id
    properties:
      ref_id:
        type: string
        description: A locally-unique user-specified id
      display_name:
        type: string
        description: The human readable name (defaults to the generated cluster id
          if not specified)
      elasticsearch_cluster_ref_id:
        type: string
        description: The user-specified id of the Elasticsearch Cluster that this
          will link to
      backend_plan:
        type: object
        description: The backend plan as JSON
    description: Holds diagnostics for an Enterprise Search resource
  EnterpriseSearchConfiguration:
    type: object
    properties:
      version:
        type: string
        description: The version of the Enterprise Search cluster (must be one of
          the ECE supported versions, and won't work unless it matches the Elasticsearch
          version. Leave blank to auto-detect version.)
      docker_image:
        type: string
        description: A docker URI that allows overriding of the default docker image
          specified for this version
      system_settings:
        "$ref": "#/definitions/EnterpriseSearchSystemSettings"
      user_settings_json:
        type: object
        description: An arbitrary JSON object allowing (non-admin) cluster owners
          to set their parameters (only one of this and 'user_settings_yaml' is allowed),
          provided the parameters are on the allowlist and not on the denylist. (This
          field together with 'user_settings_override*' and 'system_settings' defines
          the total set of Enterprise Search settings)
      user_settings_yaml:
        type: string
        description: An arbitrary YAML object allowing (non-admin) cluster owners
          to set their parameters (only one of this and 'user_settings_json' is allowed),
          provided the parameters are on the allowlist and not on the denylist. (This
          field together with 'user_settings_override*' and 'system_settings' defines
          the total set of Enterprise Search settings)
      user_settings_override_json:
        type: object
        description: An arbitrary JSON object allowing ECE admins to set clusters'
          parameters (only one of this and 'user_settings_override_yaml' is allowed),
          i.e. in addition to the documented 'system_settings'. (This field together
          with 'system_settings' and 'user_settings*' defines the total set of Enterprise
          Search settings)
      user_settings_override_yaml:
        type: string
        description: An arbitrary YAML object allowing ECE admins to set clusters'
          parameters (only one of this and 'user_settings_override_json' is allowed),
          i.e. in addition to the documented 'system_settings'. (This field together
          with 'system_settings' and 'user_settings*' defines the total set of Enterprise
          Search settings)
  EnterpriseSearchInfo:
    type: object
    required:
    - elasticsearch_cluster
    - external_links
    - healthy
    - id
    - name
    - plan_info
    - status
    - topology
    properties:
      id:
        type: string
        description: The id of the Enterprise Search
      name:
        type: string
        description: The name of the Enterprise Search
      elasticsearch_cluster:
        "$ref": "#/definitions/TargetElasticsearchCluster"
      deployment_id:
        type: string
        description: The id of the deployment that this Enterprise Search belongs
          to.
      healthy:
        type: boolean
        description: 'Whether the Enterprise Search is healthy or not (one or more
          of the info subsections will have healthy: false)'
      status:
        type: string
        description: Enterprise Search status
        enum:
        - initializing
        - stopping
        - stopped
        - rebooting
        - restarting
        - reconfiguring
        - started
      plan_info:
        "$ref": "#/definitions/EnterpriseSearchPlansInfo"
      metadata:
        "$ref": "#/definitions/ClusterMetadataInfo"
      topology:
        "$ref": "#/definitions/ClusterTopologyInfo"
      external_links:
        type: array
        description: External resources related to the Enterprise Search
        uniqueItems: true
        items:
          "$ref": "#/definitions/ExternalHyperlink"
      links:
        type: object
        description: A map of application-specific operations (which map to 'operationId's
          in the Swagger API) to metadata about that operation
        additionalProperties:
          "$ref": "#/definitions/Hyperlink"
      settings:
        description: The cluster metadata settings for the Enterprise Search
        "$ref": "#/definitions/EnterpriseSearchSettings"
      region:
        type: string
        description: The region that this Enterprise Search belongs to. Only populated
          in SaaS or federated ECE.
    description: The overview information for the Enterprise Search Server.
  EnterpriseSearchNodeTypes:
    type: object
    required:
    - appserver
    - connector
    - worker
    properties:
      appserver:
        type: boolean
        description: Defines whether this instance should run as Application/API server
      worker:
        type: boolean
        description: Defines whether this instance should run as background worker
      connector:
        type: boolean
        description: Defines whether this instance should run as Connector
    description: Node types to enable for an Enterprise Search instance
  EnterpriseSearchPayload:
    type: object
    required:
    - elasticsearch_cluster_ref_id
    - plan
    - ref_id
    - region
    properties:
      ref_id:
        type: string
        description: A locally-unique user-specified id for Enterprise Search
      elasticsearch_cluster_ref_id:
        type: string
        description: Alias to the Elasticsearch Cluster to attach Enterprise Search
          to
      display_name:
        type: string
        description: 'The human readable name for the Enterprise Search cluster (default:
          takes the name of its Elasticsearch cluster)'
      region:
        type: string
        description: The region where this resource exists
      plan:
        "$ref": "#/definitions/EnterpriseSearchPlan"
      settings:
        description: The settings for building this Enterprise Search cluster
        "$ref": "#/definitions/EnterpriseSearchSettings"
    description: An Enterprise Search creation request paired with the alias of the
      Elasticsearch cluster it should be paired with
  EnterpriseSearchPlan:
    type: object
    required:
    - enterprise_search
    properties:
      cluster_topology:
        type: array
        items:
          "$ref": "#/definitions/EnterpriseSearchTopologyElement"
      enterprise_search:
        "$ref": "#/definitions/EnterpriseSearchConfiguration"
      transient:
        "$ref": "#/definitions/TransientEnterpriseSearchPlanConfiguration"
    description: The plan for the Enterprise Search cluster.
  EnterpriseSearchPlanControlConfiguration:
    type: object
    properties:
      timeout:
        type: integer
        format: int64
        description: The total timeout in seconds after which the plan is cancelled
          even if it is not complete. Defaults to 4x the max memory capacity per node
          (in MB)
      calm_wait_time:
        type: integer
        format: int64
        description: This timeout determines how long to give a cluster after it responds
          to API calls before performing actual operations on it. It defaults to 5s
      move_instances:
        type: array
        items:
          "$ref": "#/definitions/InstanceMoveRequest"
      move_allocators:
        type: array
        items:
          "$ref": "#/definitions/AllocatorMoveRequest"
      reallocate_instances:
        type: boolean
        description: 'If true (default: false) does not allow re-using any existing
          instances currently in the cluster, i.e. even unchanged instances will be
          re-created'
      preferred_allocators:
        type: array
        description: List of allocators on which instances are placed if possible
          (if not possible/not specified then any available allocator with space is
          used)
        items:
          type: string
      extended_maintenance:
        type: boolean
        description: If true (default false), does not clear the maintenance flag
          (which prevents its API from being accessed except by the constructor) on
          new instances added until after a snapshot has been restored, otherwise,
          the maintenance flag is cleared once the new instances successfully join
          the new cluster
      cluster_reboot:
        type: string
        description: Set to 'forced' to force a reboot as part of the upgrade plan
        enum:
        - forced
  EnterpriseSearchPlanInfo:
    type: object
    required:
    - healthy
    - plan_attempt_log
    - warnings
    properties:
      plan_attempt_id:
        type: string
        description: A UUID for each plan attempt
      plan_attempt_name:
        type: string
        description: A human readable name for each plan attempt, only populated when
          retrieving plan histories
      healthy:
        type: boolean
        description: Either the plan ended successfully, or is not yet completed (and
          no errors have occurred)
      attempt_start_time:
        type: string
        format: date-time
        description: When this plan attempt (ie to apply the plan to the Enterprise
          Search) started (ISO format in UTC)
      attempt_end_time:
        type: string
        format: date-time
        description: If this plan completed or failed (ie is not pending), when the
          attempt ended (ISO format in UTC)
      plan_end_time:
        type: string
        format: date-time
        description: If this plan is not current or pending, when the plan was no
          longer active (ISO format in UTC)
      plan:
        "$ref": "#/definitions/EnterpriseSearchPlan"
      plan_attempt_log:
        type: array
        items:
          "$ref": "#/definitions/ClusterPlanStepInfo"
      source:
        description: Information describing the source that facilitated the plans
          current state
        "$ref": "#/definitions/ChangeSourceInfo"
      warnings:
        type: array
        items:
          "$ref": "#/definitions/ClusterPlanWarning"
      error:
        "$ref": "#/definitions/ClusterPlanAttemptError"
    description: Information about the Enterprise Search Server plan.
  EnterpriseSearchPlansInfo:
    type: object
    required:
    - healthy
    - history
    properties:
      healthy:
        type: boolean
        description: Whether the plan situation is healthy (if unhealthy, means the
          last plan attempt failed)
      current:
        "$ref": "#/definitions/EnterpriseSearchPlanInfo"
      pending:
        "$ref": "#/definitions/EnterpriseSearchPlanInfo"
      history:
        type: array
        items:
          "$ref": "#/definitions/EnterpriseSearchPlanInfo"
    description: Information about current, pending, and past Enterprise Search Server
      plans.
  EnterpriseSearchResourceInfo:
    type: object
    required:
    - elasticsearch_cluster_ref_id
    - id
    - info
    - ref_id
    - region
    properties:
      ref_id:
        type: string
        description: The locally-unique user-specified id of a Resource
      elasticsearch_cluster_ref_id:
        type: string
        description: The Elasticsearch cluster that this resource depends on.
      id:
        type: string
        description: The randomly-generated id of a Resource
      region:
        type: string
        description: The region where this resource exists
      info:
        description: Info for the resource.
        "$ref": "#/definitions/EnterpriseSearchInfo"
    description: Describes an Enterprise Search resource belonging to a Deployment
  EnterpriseSearchSettings:
    type: object
    properties:
      metadata:
        "$ref": "#/definitions/ClusterMetadataSettings"
    description: The settings for the Enterprise Search.
  EnterpriseSearchSubInfo:
    type: object
    required:
    - enabled
    - enterprise_search_id
    properties:
      enterprise_search_id:
        type: string
        description: The Enterprise Search Id
      enabled:
        type: boolean
        description: Whether the associated Enterprise Search is currently available
      links:
        type: object
        description: A map of application-specific operations (which map to 'operationId's
          in the Swagger API) to metadata about that operation
        additionalProperties:
          "$ref": "#/definitions/Hyperlink"
    description: Information about the APM Servers associated with the Elasticsearch
      cluster.
  EnterpriseSearchSystemSettings:
    type: object
    properties:
      elasticsearch_username:
        type: string
        description: Optionally override the account within Enterprise Search - defaults
          to a system account that always exists (if specified, the password must
          also be specified). Note that this field is never returned from the API,
          it is write only.
      elasticsearch_password:
        type: string
        description: Optionally override the account within Enterprise Search - defaults
          to a system account that always exists (if specified, the username must
          also be specified). Note that this field is never returned from the API,
          it is write only.
      secret_session_key:
        type: string
        description: Optionally override the secret session key within Enterprise
          Search - defaults to the previously existing secretSession. Note that this
          field is never returned from the API, it is write only.
    description: This structure defines a curated subset of the Enterprise Search
      settings. (This field together with 'user_settings_override*' and  'user_settings*'
      defines the total set of Enterprise Search settings)
  EnterpriseSearchTopologyElement:
    type: object
    properties:
      node_type:
        description: Defines the EnterpriseSearch node type
        "$ref": "#/definitions/EnterpriseSearchNodeTypes"
      instance_configuration_id:
        type: string
        description: Controls the allocation of this topology element as well as allowed
          sizes and node_types. It needs to match the id of an existing instance configuration.
      instance_configuration_version:
        type: integer
        format: int32
        description: The version of the Instance Configuration Id. If it is unset,
          the meaning depends on read vs writes. For deployment reads, it is equivalent
          to version 0 (or the IC is unversioned); for deployment creates and deployment
          template use, it is equivalent to 'the latest version'; and for deployment
          updates, it is equivalent to 'retain the current version'.
      size:
        "$ref": "#/definitions/TopologySize"
      zone_count:
        type: integer
        format: int32
        description: number of zones in which nodes will be placed
      enterprise_search:
        "$ref": "#/definitions/EnterpriseSearchConfiguration"
      allocator_filter:
        type: object
      node_configuration:
        type: string
      memory_per_node:
        type: object
      node_count_per_zone:
        type: object
    description: Defines the topology of the Enterprise Search nodes (e.g. number/capacity
      of nodes, and where they can be allocated)
  ExistsQuery:
    type: object
    required:
    - field
    properties:
      field:
        type: string
        description: The field to check for non-null values in.
    description: Matches documents that have at least one non-`null` value in the
      original field.
  Extension:
    type: object
    required:
    - extension_type
    - id
    - name
    - url
    - version
    properties:
      id:
        type: string
        description: The extension ID
      name:
        type: string
        description: The extension name.
      description:
        type: string
        description: The extension description.
      url:
        type: string
        description: The extension URL to be used in the plan.
      download_url:
        type: string
        description: The download URL specified during extension creation.
      extension_type:
        type: string
        description: The extension type.
        enum:
        - plugin
        - bundle
      version:
        type: string
        description: The Elasticsearch version.
      deployments:
        type: array
        description: List of deployments using this extension. Up to only 10000 deployments
          will be included in the list.
        items:
          type: string
      file_metadata:
        description: The extension file metadata.
        "$ref": "#/definitions/ExtensionFileMetadata"
    description: An API extension. It represents clusters' plugins and bundles
  ExtensionFileMetadata:
    type: object
    properties:
      last_modified_date:
        type: string
        format: date-time
        description: The date and time the extension was last modified.
      size:
        type: integer
        format: int64
        description: The extension file size in bytes.
      url:
        type: string
        format: uri
        description: The temporary URL to download the extension file. Usable for
          verification.
  Extensions:
    type: object
    required:
    - extensions
    properties:
      extensions:
        type: array
        description: The list of extensions.
        items:
          "$ref": "#/definitions/Extension"
    description: A collection of extensions
  ExternalHyperlink:
    type: object
    required:
    - id
    - label
    properties:
      id:
        type: string
        description: Identifier of the external link
      label:
        type: string
        description: Human-readable description of the external link
      uri:
        type: string
        description: hyperlink to an external resource
  ExternalTrustRelationship:
    type: object
    required:
    - trust_all
    - trust_relationship_id
    properties:
      trust_relationship_id:
        type: string
        description: The ID of the external trust relationship
      name:
        type: string
        description: The name of the external trust relationship. Retrieved from the
          TrustRelationship and ignored on write.
      trust_all:
        type: boolean
        description: If true, all clusters in this external entity will be trusted
          and the `trust_allowlist` is ignored.
      trust_allowlist:
        type: array
        description: The list of clusters to trust. Only used when `trust_all` is
          false.
        items:
          type: string
    description: The trust relationship with external entities (remote environments,
      remote accounts...).
  FilterAssociation:
    type: object
    required:
    - entity_type
    - id
    properties:
      entity_type:
        type: string
        description: Type of the traffic filter ruleset association, such as 'deployment',
          'cluster'
      id:
        type: string
        description: ID of the entity, such as the deployment ID or Elasticsearch
          cluster ID.
    description: The association with a ruleset or user auth token for a deployment,
      template, or product.
  GetOrganizationClaimedDomainsResponse:
    type: object
    required:
    - domains
    properties:
      domains:
        type: array
        description: The list of claimed domains in the organization
        items:
          type: string
  GetRoleMappingsResponse:
    type: object
    required:
    - mappings
    properties:
      mappings:
        type: array
        description: The list of role assignments for the organization
        items:
          "$ref": "#/definitions/RoleMapping"
  GrowShrinkStrategyConfig:
    type: object
    description: A strategy that creates instances with the new plan, migrates data
      from the old instances, then shuts down the old instances. `GrowShrinkStrategyConfig`
      is safer than 'rolling' and ensures single node availability during a plan change,
      but can be a lot slower on larger clusters.
  Hyperlink:
    type: object
    properties:
      need_elevated_permissions:
        type: boolean
        description: Whether the operation requires elevated permissions (when the
          field is present, elevated permissions are required).
  IdpConfigurationRequest:
    type: object
    required:
    - enabled
    - login_identifier_prefix
    - saml_idp
    properties:
      enabled:
        type: boolean
        description: Whether or not the IdP is enabled
      login_identifier_prefix:
        type: string
        description: The prefix of the login identifier that will be generated
      saml_idp:
        description: The SAML2 IdP configuration
        "$ref": "#/definitions/SamlIdp"
    description: A request to setup an organization IdP
  IndexPattern:
    type: object
    required:
    - index_pattern
    - policy_name
    properties:
      index_pattern:
        type: string
        description: Index pattern to which the ILM policy will be applied.
      policy_name:
        type: string
        description: Name of the policy to create
      node_attributes:
        type: object
        description: Defines the Elasticsearch node attributes for the warm element
          of the topology
        additionalProperties:
          type: string
    description: An index pattern described indicating how it has to be migrated to
      ILM.
  InstanceConfigurationInfo:
    type: object
    required:
    - discrete_sizes
    - name
    properties:
      id:
        type: string
        description: Unique identifier for the instance configuration
      name:
        type: string
        description: Display name for the instance configuration.
      config_version:
        type: integer
        format: int32
        description: If the IC is configuration controlled, this field is the version
          either being read back (reads return the latest IC unless specified by the
          'config_version' URL param), or the version to update. Cannot be used in
          creates. For unversioned IC reads it is left empty.
      description:
        type: string
        description: Optional description for the instance configuration
      instance_type:
        type: string
        description: The type of instance. For instance configurations where the type
          is specified in the 'id', the default value of 'instance_type' will be automatically
          inferred.
        enum:
        - elasticsearch
        - kibana
        - apm
        - integrations_server
        - appsearch
        - enterprise_search
      node_types:
        type: array
        description: Node types (master, data) for the instance. For instance configurations
          where the type (and tier) is specified in the 'id', the default value of
          'node_types' will be automatically inferred.
        items:
          type: string
      discrete_sizes:
        description: Numerics representing possible instance sizes that the instance
          configuration supports.
        "$ref": "#/definitions/DiscreteSizes"
      storage_multiplier:
        type: number
        format: double
        description: Settings for the instance storage multiplier
      cpu_multiplier:
        type: number
        format: double
        description: Settings for the instance CPU multiplier
      metadata:
        type: object
        description: Optional arbitrary metadata to associate with this template.
      max_zones:
        type: integer
        format: int32
        description: The maximum number of availability zones in which this instance
          configuration has allocators. This field will be missing unless explicitly
          requested with the show_max_zones parameter.
        readOnly: true
    description: The configuration template for Elasticsearch instances, Kibana instances,
      and APM Servers.
  InstanceMoveRequest:
    type: object
    required:
    - from
    properties:
      from:
        type: string
        description: The instance id that is going to be moved
      to:
        type: array
        description: An optional list of allocator ids to which the instance should
          be moved. If not specified then any available allocator can be used (including
          the current one if it is healthy)
        items:
          type: string
      instance_down:
        type: boolean
        description: 'Tells the infrastructure that the instance should be considered
          as permanently down when deciding how to migrate data to new nodes. If left
          blank then the system will automatically decide (currently: will treat the
          instances as up)'
    description: The request that specifies the Elasticsearch or stateless (eg Kibana)
      instances to move to allocators as part of the upgrade plan. When used in conjunction
      with '\_\_all\_\_' (roll all instances as a single unit) strategy, these instances
      are not restarted, which can sometimes enable recovery plans when these instances
      are boot-looping.
  InstanceOverrides:
    type: object
    properties:
      capacity:
        type: integer
        format: int32
        description: Sets the memory capacity for the instances container. Requires
          a restart to take effect.
      storage_multiplier:
        type: number
        format: double
        description: Overrides the disk quota multiplier for the instance
  IntegrationsServer:
    type: object
    required:
    - backend_plan
    - display_name
    - elasticsearch_cluster_ref_id
    - ref_id
    properties:
      ref_id:
        type: string
        description: A locally-unique user-specified id
      display_name:
        type: string
        description: The human readable name (defaults to the generated cluster id
          if not specified)
      elasticsearch_cluster_ref_id:
        type: string
        description: The user-specified id of the Elasticsearch Cluster that this
          will link to
      backend_plan:
        type: object
        description: The backend plan as JSON
    description: Holds diagnostics for an Integrations Server resource
  IntegrationsServerConfiguration:
    type: object
    properties:
      version:
        type: string
        description: The version of the Integrations Server cluster (must be one of
          the ECE supported versions, and won't work unless it matches the Integrations
          Server version. Leave blank to auto-detect version.)
      docker_image:
        type: string
        description: A docker URI that allows overriding of the default docker image
          specified for this version
      system_settings:
        "$ref": "#/definitions/IntegrationsServerSystemSettings"
      user_settings_json:
        type: object
        description: An arbitrary JSON object allowing (non-admin) cluster owners
          to set their parameters (only one of this and 'user_settings_yaml' is allowed),
          provided the parameters are on the allowlist and not on the denylist. (This
          field together with 'user_settings_override*' and 'system_settings' defines
          the total set of Integrations Server settings)
      user_settings_yaml:
        type: string
        description: An arbitrary YAML object allowing (non-admin) cluster owners
          to set their parameters (only one of this and 'user_settings_json' is allowed),
          provided the parameters are on the allowlist and not on the denylist. (These
          field together with 'user_settings_override*' and 'system_settings' defines
          the total set of Integrations Server settings)
      user_settings_override_json:
        type: object
        description: An arbitrary JSON object allowing ECE admins owners to set clusters'
          parameters (only one of this and 'user_settings_override_yaml' is allowed),
          ie in addition to the documented 'system_settings'. (This field together
          with 'system_settings' and 'user_settings*' defines the total set of Integrations
          Server settings)
      user_settings_override_yaml:
        type: string
        description: An arbitrary YAML object allowing ECE admins owners to set clusters'
          parameters (only one of this and 'user_settings_override_json' is allowed),
          ie in addition to the documented 'system_settings'. (This field together
          with 'system_settings' and 'user_settings*' defines the total set of Integrations
          Server settings)
      mode:
        type: string
        description: The mode the Integrations Server is operating in.
        enum:
        - standalone
        - managed
    description: The configuration options for the Integrations Server.
  IntegrationsServerInfo:
    type: object
    required:
    - elasticsearch_cluster
    - external_links
    - healthy
    - id
    - name
    - plan_info
    - status
    - topology
    properties:
      id:
        type: string
        description: The id of the Integrations Server
      name:
        type: string
        description: The name of the Integrations Server
      elasticsearch_cluster:
        "$ref": "#/definitions/TargetElasticsearchCluster"
      deployment_id:
        type: string
        description: The id of the deployment that this Integrations Server belongs
          to.
      healthy:
        type: boolean
        description: 'Whether the Integrations Server is healthy or not (one or more
          of the info subsections will have healthy: false)'
      status:
        type: string
        description: Integrations Server status
        enum:
        - initializing
        - stopping
        - stopped
        - rebooting
        - restarting
        - reconfiguring
        - started
      plan_info:
        "$ref": "#/definitions/IntegrationsServerPlansInfo"
      metadata:
        "$ref": "#/definitions/ClusterMetadataInfo"
      topology:
        "$ref": "#/definitions/ClusterTopologyInfo"
      external_links:
        type: array
        description: External resources related to the Integrations Server
        uniqueItems: true
        items:
          "$ref": "#/definitions/ExternalHyperlink"
      links:
        type: object
        description: A map of application-specific operations (which map to 'operationId's
          in the Swagger API) to metadata about that operation
        additionalProperties:
          "$ref": "#/definitions/Hyperlink"
      settings:
        description: The cluster metadata settings for the Integrations Server
        "$ref": "#/definitions/IntegrationsServerSettings"
      region:
        type: string
        description: The region that this Integrations Server belongs to. Only populated
          in SaaS or federated ECE.
      apm_server_mode:
        type: string
        description: The mode APM is operating in.
        enum:
        - standalone
        - managed
    description: The overview information for the Integrations Server.
  IntegrationsServerPayload:
    type: object
    required:
    - elasticsearch_cluster_ref_id
    - plan
    - ref_id
    - region
    properties:
      ref_id:
        type: string
        description: A locally-unique user-specified id for the Integrations Server
      elasticsearch_cluster_ref_id:
        type: string
        description: Alias to the Elasticsearch Cluster to attach the Integrations
          Server to
      display_name:
        type: string
        description: 'The human readable name for the Integrations Server cluster
          (default: takes the name of its Elasticsearch cluster)'
      region:
        type: string
        description: The region where this resource exists
      plan:
        "$ref": "#/definitions/IntegrationsServerPlan"
      settings:
        description: The settings for building this Integrations Server cluster
        "$ref": "#/definitions/IntegrationsServerSettings"
    description: An Integrations Server creation request paired with the alias of
      the Elasticsearch cluster it should be paired with
  IntegrationsServerPlan:
    type: object
    required:
    - integrations_server
    properties:
      cluster_topology:
        type: array
        items:
          "$ref": "#/definitions/IntegrationsServerTopologyElement"
      integrations_server:
        "$ref": "#/definitions/IntegrationsServerConfiguration"
      transient:
        "$ref": "#/definitions/TransientIntegrationsServerPlanConfiguration"
    description: The plan for the Integrations Server.
  IntegrationsServerPlanControlConfiguration:
    type: object
    properties:
      timeout:
        type: integer
        format: int64
        description: The total timeout in seconds after which the plan is cancelled
          even if it is not complete. Defaults to 4x the max memory capacity per node
          (in MB)
      calm_wait_time:
        type: integer
        format: int64
        description: This timeout determines how long to give a cluster after it responds
          to API calls before performing actual operations on it. It defaults to 5s
      extended_maintenance:
        type: boolean
        description: If true (default false), does not clear the maintenance flag
          (which prevents its API from being accessed except by the constructor) on
          new instances added until after a snapshot has been restored, otherwise,
          the maintenance flag is cleared once the new instances successfully join
          the new cluster
      cluster_reboot:
        type: string
        description: Set to 'forced' to force a reboot as part of the upgrade plan
        enum:
        - forced
    description: The plan control configuration options for the Integrations Server.
  IntegrationsServerPlanInfo:
    type: object
    required:
    - healthy
    - plan_attempt_log
    - warnings
    properties:
      plan_attempt_id:
        type: string
        description: A UUID for each plan attempt
      plan_attempt_name:
        type: string
        description: A human readable name for each plan attempt, only populated when
          retrieving plan histories
      healthy:
        type: boolean
        description: Either the plan ended successfully, or is not yet completed (and
          no errors have occurred)
      attempt_start_time:
        type: string
        format: date-time
        description: When this plan attempt (ie to apply the plan to the Integrations
          Server) started (ISO format in UTC)
      attempt_end_time:
        type: string
        format: date-time
        description: If this plan completed or failed (ie is not pending), when the
          attempt ended (ISO format in UTC)
      plan_end_time:
        type: string
        format: date-time
        description: If this plan is not current or pending, when the plan was no
          longer active (ISO format in UTC)
      plan:
        "$ref": "#/definitions/IntegrationsServerPlan"
      plan_attempt_log:
        type: array
        items:
          "$ref": "#/definitions/ClusterPlanStepInfo"
      source:
        description: Information describing the source that facilitated the plans
          current state
        "$ref": "#/definitions/ChangeSourceInfo"
      warnings:
        type: array
        items:
          "$ref": "#/definitions/ClusterPlanWarning"
      error:
        "$ref": "#/definitions/ClusterPlanAttemptError"
    description: Information about the Integrations Server plan.
  IntegrationsServerPlansInfo:
    type: object
    required:
    - healthy
    - history
    properties:
      healthy:
        type: boolean
        description: Whether the plan situation is healthy (if unhealthy, means the
          last plan attempt failed)
      current:
        "$ref": "#/definitions/IntegrationsServerPlanInfo"
      pending:
        "$ref": "#/definitions/IntegrationsServerPlanInfo"
      history:
        type: array
        items:
          "$ref": "#/definitions/IntegrationsServerPlanInfo"
    description: Information about current, pending, and past Integrations Server
      plans.
  IntegrationsServerResourceInfo:
    type: object
    required:
    - elasticsearch_cluster_ref_id
    - id
    - info
    - ref_id
    - region
    properties:
      ref_id:
        type: string
        description: The locally-unique user-specified id of a Resource
      elasticsearch_cluster_ref_id:
        type: string
        description: The Elasticsearch cluster that this resource depends on.
      id:
        type: string
        description: The randomly-generated id of a Resource
      region:
        type: string
        description: The region where this resource exists
      info:
        description: Info for the resource.
        "$ref": "#/definitions/IntegrationsServerInfo"
    description: Describes an Integrations Server resource belonging to a Deployment
  IntegrationsServerSettings:
    type: object
    properties:
      metadata:
        "$ref": "#/definitions/ClusterMetadataSettings"
    description: The settings for the Integrations Server.
  IntegrationsServerSystemSettings:
    type: object
    properties:
      elasticsearch_username:
        type: string
        description: Optionally override the account within Integrations Server -
          defaults to a system account that always exists (if specified, the password
          must also be specified). Note that this field is never returned from the
          API, it is write only.
      elasticsearch_password:
        type: string
        description: Optionally override the account within Integrations Server -
          defaults to a system account that always exists (if specified, the username
          must also be specified). Note that this field is never returned from the
          API, it is write only.
      secret_token:
        type: string
        description: Optionally override the secret token within Integrations Server
          - defaults to the previously existing secretToken
      debug_enabled:
        type: boolean
        description: Optionally enable debug mode for Integrations Server - defaults
          false
    description: "A structure that defines a curated subset of the Integrations Server
      settings. \nTIP: To define the complete set of Integrations Server setting,
      use `IntegrationsSystemSettings` with `user_settings_override_` and `user_settings_`."
  IntegrationsServerTopologyElement:
    type: object
    properties:
      instance_configuration_id:
        type: string
        description: Controls the allocation of this topology element as well as allowed
          sizes and node_types. It needs to match the id of an existing instance configuration.
      instance_configuration_version:
        type: integer
        format: int32
        description: The version of the Instance Configuration Id. If it is unset,
          the meaning depends on read vs writes. For deployment reads, it is equivalent
          to version 0 (or the IC is unversioned); for deployment creates and deployment
          template use, it is equivalent to 'the latest version'; and for deployment
          updates, it is equivalent to 'retain the current version'.
      size:
        "$ref": "#/definitions/TopologySize"
      zone_count:
        type: integer
        format: int32
        description: number of zones in which nodes will be placed
      integrations_server:
        "$ref": "#/definitions/IntegrationsServerConfiguration"
    description: Defines the topology of the Integrations Server nodes. For example,
      the number or capacity of the nodes, and where you can allocate the nodes.
  ItemCosts:
    type: object
    required:
    - hours
    - instance_count
    - kind
    - name
    - period
    - price
    - price_per_hour
    - sku
    properties:
      hours:
        type: integer
        format: int64
        description: Resource usage in hours
      instance_count:
        type: integer
        format: int32
        description: Number of instances
      period:
        description: Period
        "$ref": "#/definitions/Period"
      kind:
        type: string
        description: Kind of resource
        enum:
        - elasticsearch
        - kibana
        - apm
        - integrations_server
        - appsearch
        - enterprise_search
      price:
        type: number
        format: double
        description: Resource price
      price_per_hour:
        type: number
        format: double
        description: Price per hour
      name:
        type: string
        description: Resource name
      sku:
        type: string
        description: Stock Keeping Unit (SKU)
    description: Detailed costs associated to an Elastic Cloud Resource for an organization.
      All of the costs are expressed in Elastic Consumption Unit (ECU).
  ItemsCosts:
    type: object
    required:
    - costs
    - data_transfer_and_storage
    - resources
    properties:
      costs:
        description: Costs for the Elastic Cloud resources
        "$ref": "#/definitions/Costs"
      data_transfer_and_storage:
        type: array
        description: List of the detailed costs associated to the Data Transfer and
          Storage (DTS) dimensions
        items:
          "$ref": "#/definitions/DtsDimensionCosts"
      resources:
        type: array
        description: Costs of the list of resources
        items:
          "$ref": "#/definitions/ItemCosts"
    description: Costs associated to a set of Elastic Cloud resources for an organization.
      All of the costs are expressed in Elastic Consumption Unit (ECU).
  KeystoreContents:
    type: object
    required:
    - secrets
    properties:
      secrets:
        type: object
        description: List of secrets
        additionalProperties:
          "$ref": "#/definitions/KeystoreSecret"
    description: The contents of the Elasticsearch keystore.
  KeystoreSecret:
    type: object
    properties:
      value:
        type: object
        description: 'Value of this setting. This can either be a string or a JSON
          object that is stored as a JSON string in the keystore. NOTE: When the keystore
          secret is unspecified, it is removed.'
      as_file:
        type: boolean
        description: Stores the keystore secret as a file. The default is false, which
          stores the keystore secret as string when value is a plain string, or true
          when value is an object.
      is_allowlisted:
        type: boolean
        description: Read-only field, ignored on write. Only returned when calling
          the set-deployment-es-resource-keystore endpoint with `validate_only=true`.
          True if this setting/value pair is allowlisted (the allowlist is for informational
          purposes).
      is_reloadable:
        type: boolean
        description: Read-only field, ignored on write. Only returned when calling
          the set-deployment-es-resource-keystore endpoint with `validate_only=true`.
          True if this setting is reloadable, or if false it requires a cluster restart.
    description: The value that you configure for the Elasticsearch keystore secret.
  Kibana:
    type: object
    required:
    - backend_plan
    - display_name
    - elasticsearch_cluster_ref_id
    - ref_id
    properties:
      ref_id:
        type: string
        description: A locally-unique user-specified id
      display_name:
        type: string
        description: The human readable name (defaults to the generated cluster id
          if not specified)
      elasticsearch_cluster_ref_id:
        type: string
        description: The user-specified id of the Elasticsearch Cluster that this
          will link to
      backend_plan:
        type: object
        description: The backend plan as JSON
    description: Holds diagnostics for a Kibana resource
  KibanaClusterInfo:
    type: object
    required:
    - cluster_id
    - cluster_name
    - elasticsearch_cluster
    - external_links
    - healthy
    - metadata
    - plan_info
    - status
    - topology
    properties:
      cluster_id:
        type: string
        description: The id of the cluster
      cluster_name:
        type: string
        description: The name of the cluster
      elasticsearch_cluster:
        "$ref": "#/definitions/TargetElasticsearchCluster"
      deployment_id:
        type: string
        description: The id of the deployment to which this Kibana Server belongs
          to.
      healthy:
        type: boolean
        description: 'Whether the cluster is healthy or not (one or more of the info
          subsections will have healthy: false)'
      status:
        type: string
        description: Cluster status
        enum:
        - initializing
        - stopping
        - stopped
        - rebooting
        - restarting
        - reconfiguring
        - started
      plan_info:
        "$ref": "#/definitions/KibanaClusterPlansInfo"
      metadata:
        "$ref": "#/definitions/ClusterMetadataInfo"
      topology:
        "$ref": "#/definitions/ClusterTopologyInfo"
      external_links:
        type: array
        description: External resources related to the cluster
        uniqueItems: true
        items:
          "$ref": "#/definitions/ExternalHyperlink"
      links:
        type: object
        description: A map of application-specific operations (which map to 'operationId's
          in the Swagger API) to metadata about that operation
        additionalProperties:
          "$ref": "#/definitions/Hyperlink"
      settings:
        description: The cluster metadata settings for a kibana cluster
        "$ref": "#/definitions/KibanaClusterSettings"
      region:
        type: string
        description: The region that this cluster belongs to. Only populated in SaaS
          or federated ECE.
    description: The top-level object information for a Kibana instance.
  KibanaClusterPlan:
    type: object
    required:
    - kibana
    properties:
      cluster_topology:
        type: array
        items:
          "$ref": "#/definitions/KibanaClusterTopologyElement"
      kibana:
        "$ref": "#/definitions/KibanaConfiguration"
      transient:
        "$ref": "#/definitions/TransientKibanaPlanConfiguration"
    description: The plan for the Kibana instance.
  KibanaClusterPlanInfo:
    type: object
    required:
    - healthy
    - plan_attempt_log
    - warnings
    properties:
      plan_attempt_id:
        type: string
        description: A UUID for each plan attempt
      plan_attempt_name:
        type: string
        description: A human readable name for each plan attempt, only populated when
          retrieving plan histories
      healthy:
        type: boolean
        description: Either the plan ended successfully, or is not yet completed (and
          no errors have occurred)
      attempt_start_time:
        type: string
        format: date-time
        description: When this plan attempt (ie to apply the plan to the cluster)
          started (ISO format in UTC)
      attempt_end_time:
        type: string
        format: date-time
        description: If this plan completed or failed (ie is not pending), when the
          attempt ended (ISO format in UTC)
      plan_end_time:
        type: string
        format: date-time
        description: If this plan is not current or pending, when the plan was no
          longer active (ISO format in UTC)
      plan:
        "$ref": "#/definitions/KibanaClusterPlan"
      plan_attempt_log:
        type: array
        items:
          "$ref": "#/definitions/ClusterPlanStepInfo"
      source:
        description: Information describing the source that facilitated the plans
          current state
        "$ref": "#/definitions/ChangeSourceInfo"
      warnings:
        type: array
        items:
          "$ref": "#/definitions/ClusterPlanWarning"
      error:
        "$ref": "#/definitions/ClusterPlanAttemptError"
    description: Information about the current, pending, or past Kibana instance plan.
  KibanaClusterPlansInfo:
    type: object
    required:
    - healthy
    - history
    properties:
      healthy:
        type: boolean
        description: Whether the plan situation is healthy (if unhealthy, means the
          last plan attempt failed)
      current:
        "$ref": "#/definitions/KibanaClusterPlanInfo"
      pending:
        "$ref": "#/definitions/KibanaClusterPlanInfo"
      history:
        type: array
        items:
          "$ref": "#/definitions/KibanaClusterPlanInfo"
    description: Information about the current, pending, or past Kibana instance plans.
  KibanaClusterSettings:
    type: object
    properties:
      metadata:
        "$ref": "#/definitions/ClusterMetadataSettings"
    description: The settings for multiple Kibana instances.
  KibanaClusterTopologyElement:
    type: object
    properties:
      instance_configuration_id:
        type: string
        description: Controls the allocation of this topology element as well as allowed
          sizes and node_types. It needs to match the id of an existing instance configuration.
      instance_configuration_version:
        type: integer
        format: int32
        description: The version of the Instance Configuration Id. If it is unset,
          the meaning depends on read vs writes. For deployment reads, it is equivalent
          to version 0 (or the IC is unversioned); for deployment creates and deployment
          template use, it is equivalent to 'the latest version'; and for deployment
          updates, it is equivalent to 'retain the current version'.
      size:
        "$ref": "#/definitions/TopologySize"
      zone_count:
        type: integer
        format: int32
        description: number of zones in which nodes will be placed
      kibana:
        "$ref": "#/definitions/KibanaConfiguration"
    description: The topology of the Kibana nodes, including the number, capacity,
      and type of nodes, and where they can be allocated.
  KibanaConfiguration:
    type: object
    properties:
      version:
        type: string
        description: The version of the Kibana cluster (must be one of the ECE supported
          versions, and won't work unless it matches the Elasticsearch version. Leave
          blank to auto-detect version.)
      docker_image:
        type: string
        description: A docker URI that allows overriding of the default docker image
          specified for this version
      system_settings:
        "$ref": "#/definitions/KibanaSystemSettings"
      user_settings_json:
        type: object
        description: An arbitrary JSON object allowing (non-admin) cluster owners
          to set their parameters (only one of this and 'user_settings_yaml' is allowed),
          provided the parameters are on the allowlist and not on the denylist. (This
          field together with 'user_settings_override*' and 'system_settings' defines
          the total set of Kibana settings)
      user_settings_yaml:
        type: string
        description: An arbitrary YAML object allowing (non-admin) cluster owners
          to set their parameters (only one of this and 'user_settings_json' is allowed),
          provided the parameters are on the allowlist and not on the denylist. (These
          field together with 'user_settings_override*' and 'system_settings' defines
          the total set of Kibana settings)
      user_settings_override_json:
        type: object
        description: An arbitrary JSON object allowing ECE admins owners to set clusters'
          parameters (only one of this and 'user_settings_override_yaml' is allowed),
          ie in addition to the documented 'system_settings'. (This field together
          with 'system_settings' and 'user_settings*' defines the total set of Kibana
          settings)
      user_settings_override_yaml:
        type: string
        description: An arbitrary YAML object allowing ECE admins owners to set clusters'
          parameters (only one of this and 'user_settings_override_json' is allowed),
          ie in addition to the documented 'system_settings'. (This field together
          with 'system_settings' and 'user_settings*' defines the total set of Kibana
          settings)
    description: The Kibana instance settings. When specified at the top level, provides
      a field-by-field default. When specified at the topology level, provides the
      override settings.
  KibanaDeeplink:
    type: object
    required:
    - semver
    - uri
    properties:
      semver:
        type: string
        description: Semver condition when to apply the URI.
      uri:
        type: string
        description: URI to which the user should be directed.
    description: Embedded object that contains information for linking into a specific
      Kibana page configured via the template.
  KibanaPayload:
    type: object
    required:
    - elasticsearch_cluster_ref_id
    - plan
    - ref_id
    - region
    properties:
      ref_id:
        type: string
        description: A locally-unique user-specified id for Kibana
      elasticsearch_cluster_ref_id:
        type: string
        description: Alias to the Elasticsearch Cluster to attach Kibana to
      display_name:
        type: string
        description: 'The human readable name for the Kibana cluster (default: takes
          the name of its Elasticsearch cluster)'
      region:
        type: string
        description: The region where this resource exists
      plan:
        "$ref": "#/definitions/KibanaClusterPlan"
      settings:
        description: The settings for building this Kibana cluster
        "$ref": "#/definitions/KibanaClusterSettings"
    description: A Kibana creation request paired with the alias of the Elasticsearch
      cluster it should be paired with
  KibanaPlanControlConfiguration:
    type: object
    properties:
      timeout:
        type: integer
        format: int64
        description: The total timeout in seconds after which the plan is cancelled
          even if it is not complete. Defaults to 4x the max memory capacity per node
          (in MB)
      calm_wait_time:
        type: integer
        format: int64
        description: This timeout determines how long to give a cluster after it responds
          to API calls before performing actual operations on it. It defaults to 5s
      extended_maintenance:
        type: boolean
        description: If true (default false), does not clear the maintenance flag
          (which prevents its API from being accessed except by the constructor) on
          new instances added until after a snapshot has been restored, otherwise,
          the maintenance flag is cleared once the new instances successfully join
          the new cluster
      cluster_reboot:
        type: string
        description: Set to 'forced' to force a reboot as part of the upgrade plan
        enum:
        - forced
    description: The configuration settings for the timeout and fallback parameters.
  KibanaResourceInfo:
    type: object
    required:
    - elasticsearch_cluster_ref_id
    - id
    - info
    - ref_id
    - region
    properties:
      ref_id:
        type: string
        description: The locally-unique user-specified id of a Resource
      elasticsearch_cluster_ref_id:
        type: string
        description: The Elasticsearch cluster that this resource depends on.
      id:
        type: string
        description: The randomly-generated id of a Resource
      region:
        type: string
        description: The region where this resource exists
      info:
        description: Info for the resource.
        "$ref": "#/definitions/KibanaClusterInfo"
    description: Describes an Kibana resource belonging to a Deployment
  KibanaSubClusterInfo:
    type: object
    required:
    - enabled
    - kibana_id
    properties:
      kibana_id:
        type: string
        description: The Kibana cluster Id
      enabled:
        type: boolean
        description: Whether the associated Kibana cluster is currently available
      links:
        type: object
        description: A map of application-specific operations (which map to 'operationId's
          in the Swagger API) to metadata about that operation
        additionalProperties:
          "$ref": "#/definitions/Hyperlink"
    description: Information about the Kibana instances associated with the Elasticsearch
      cluster.
  KibanaSystemSettings:
    type: object
    properties:
      elasticsearch_username:
        type: string
        description: Optionally override the account within Elasticsearch - defaults
          to a system account that always exists (if specified, the password must
          also be specified). Note that this field is never returned from the API,
          it is write only.
      elasticsearch_password:
        type: string
        description: Optionally override the account within Elasticsearch - defaults
          to a system account that always exists (if specified, the username must
          also be specified). Note that this field is never returned from the API,
          it is write only.
    description: 'A subset of Kibana settings. TIP: To define the complete set of
      Elasticsearch settings, use `KibanaSystemSettings` with `user_settings_override_`
      and `user_settings_`.'
  ManagedMonitoringSettings:
    type: object
    required:
    - target_cluster_id
    properties:
      target_cluster_id:
        type: string
        description: The Id of the target cluster to which to send monitoring information
    description: The settings for sending monitoring information to another cluster.
  MatchAllQuery:
    type: object
    description: A query that matches all documents.
  MatchNoneQuery:
    type: object
    description: A query that doesn't match any documents.
  MatchQuery:
    type: object
    required:
    - query
    properties:
      query:
        type: string
        description: The text/numeric/date to query for.
      operator:
        type: string
        description: The operator flag can be set to or or and to control the boolean
          clauses (defaults to or).
      minimum_should_match:
        type: integer
        format: int32
        description: The minimum number of optional should clauses to match.
      analyzer:
        type: string
        description: The analyzer that will be used to perform the analysis process
          on the text. Defaults to the analyzer that was used to index the field.
    description: Consumes and analyzes text, numbers, and dates, then constructs a
      query.
  MetadataItem:
    type: object
    required:
    - key
    - value
    properties:
      key:
        type: string
        description: The metadata field name
      value:
        type: string
        description: The metadata value
    description: The key-value pair.
  NestedQuery:
    type: object
    required:
    - path
    - query
    properties:
      query:
        description: The actual query to execute on the nested objects.
        "$ref": "#/definitions/QueryContainer"
      path:
        type: string
        description: The path to the nested object.
      score_mode:
        type: string
        description: Allows to specify how inner children matching affects score of
          the parent. Refer to the Elasticsearch documentation for details.
        enum:
        - avg
        - sum
        - min
        - max
        - none
    description: A query that matches nested objects.
  ObservabilityAbsoluteDeployment:
    type: object
    required:
    - deployment_id
    properties:
      deployment_id:
        type: string
        description: The deployment to send logs and/or metrics to. Contains either
          the deployment's ID or 'self'.
      ref_id:
        type: string
        description: RefId of the Elasticsearch cluster to send logs and/or metrics
          to. If not specified, refId is resolved automatically as long as the destination
          deployment contains a single Elasticsearch resource.
    description: The destination to send logs and metrics to
  ObservabilityIssue:
    type: object
    required:
    - description
    - severity
    properties:
      description:
        type: string
        description: A user-friendly description of the observability health issue
      severity:
        type: string
        description: Severity of the health issue
    description: Observability health issue
  Organization:
    type: object
    required:
    - id
    - name
    properties:
      id:
        type: string
        description: The organization's identifier
      name:
        type: string
        description: The organization's friendly name
      default_disk_usage_alerts_enabled:
        type: boolean
        description: Whether the default disk alerts are enabled
      notifications_allowed_email_domains:
        type: array
        description: The list of allowed domains for notification-email recipients
        items:
          type: string
      billing_contacts:
        type: array
        description: The list of contacts for billing notifications, if specified
        items:
          type: string
      operational_contacts:
        type: array
        description: The list of contacts for operational notifications, if specified
        items:
          type: string
      sso_login_identifier:
        type: string
        description: The login identifier for initiating SSO
    description: An organization
  OrganizationIdp:
    type: object
    required:
    - acs
    - configuration
    - login_identifier
    - metadata_url
    - signing_certificate
    - sp_entity_id
    - sso_login_url
    properties:
      login_identifier:
        type: string
        description: The login identifier that is unique to this organization
      sso_login_url:
        type: string
        description: The Elastic Cloud login URL for this IdP
      metadata_url:
        type: string
        description: The SAML2 metadata url for downloading the SAML2 SP metadata
          XML
      acs:
        type: string
        description: The SAML2 assertion consumer service of the SP
      sp_entity_id:
        type: string
        description: The SP entity ID and the audience for SAML2 response assertions
      signing_certificate:
        type: array
        description: The certificate that will sign SAML2 requests to the IdP
        items:
          type: string
      configuration:
        description: The organization's IdP configuration
        "$ref": "#/definitions/OrganizationIdpConfiguration"
    description: The organization's IdP info
  OrganizationIdpConfiguration:
    type: object
    required:
    - enabled
    - login_identifier_prefix
    - saml_idp
    properties:
      enabled:
        type: boolean
        description: Whether or not the IdP is enabled
      login_identifier_prefix:
        type: string
        description: The prefix of the login identifier that will be generated
      saml_idp:
        description: The SAML2 IdP configuration
        "$ref": "#/definitions/SamlIdp"
    description: The organization's IdP configuration
  OrganizationInvitation:
    type: object
    required:
    - created_at
    - email
    - expired
    - expires_at
    - organization
    - token
    properties:
      token:
        type: string
        description: The token used to accept the invitation
      email:
        type: string
        description: The email address to invite to the organization
      created_at:
        type: string
        format: date-time
        description: The date and time when the invitation was created
      expires_at:
        type: string
        format: date-time
        description: The date and time when the invitation expires
      expired:
        type: boolean
        description: True if the invitation is expired
      accepted_at:
        type: string
        format: date-time
        description: The date and time when the invitation was accepted
      organization:
        description: The organization associated with this invitation
        "$ref": "#/definitions/Organization"
      role_assignments:
        description: The roles that will be assigned to users once they accept the
          invitation. Currently unavailable in self-hosted ECE.
        "$ref": "#/definitions/RoleAssignments"
    description: An invitation to an organization
  OrganizationInvitationRequest:
    type: object
    required:
    - emails
    properties:
      emails:
        type: array
        description: The email addresses to invite to the organization
        items:
          type: string
      expires_in:
        type: string
        description: The date and time when the invitation expires. Defaults to three
          days from now.
      role_assignments:
        description: The roles that will be assigned to users once they accept the
          invitation. Currently unavailable in self-hosted ECE.
        "$ref": "#/definitions/RoleAssignments"
    description: A request to create one or more invitations to an organization
  OrganizationInvitations:
    type: object
    required:
    - invitations
    properties:
      invitations:
        type: array
        description: The list of organization invitations
        items:
          "$ref": "#/definitions/OrganizationInvitation"
    description: A collection of invitations to an organization
  OrganizationList:
    type: object
    required:
    - organizations
    properties:
      organizations:
        type: array
        description: The list of organizations
        items:
          "$ref": "#/definitions/Organization"
      next_page:
        type: string
        description: A cursor to get the next page of results
    description: A collection of Organizations
  OrganizationMembership:
    type: object
    required:
    - member_since
    - organization_id
    - user_id
    properties:
      organization_id:
        type: string
        description: The organization's identifier
      user_id:
        type: string
        description: The users's identifier
      name:
        type: string
        description: The user's full name
      email:
        type: string
        description: The user's email address
      member_since:
        type: string
        format: date-time
        description: The date and time the user was added to the organization
      role_assignments:
        description: The user's assigned roles. Currently unavailable in self-hosted
          ECE.
        "$ref": "#/definitions/RoleAssignments"
    description: A user's membership to an organization
  OrganizationMemberships:
    type: object
    required:
    - members
    properties:
      members:
        type: array
        description: The list of organization memberships
        items:
          "$ref": "#/definitions/OrganizationMembership"
    description: All user memberships to an organization
  OrganizationRequest:
    type: object
    properties:
      name:
        type: string
        description: The organization's friendly name
      default_disk_usage_alerts_enabled:
        type: boolean
        description: Whether the default disk alerts are enabled
      notifications_allowed_email_domains:
        type: array
        description: The list of allowed domains for notification-email recipients
        items:
          type: string
      billing_contacts:
        type: array
        description: The list of contacts for billing notifications
        items:
          type: string
      operational_contacts:
        type: array
        description: The list of contacts for operational notifications
        items:
          type: string
    description: A request to create or update an organization
  OrganizationRoleAssignment:
    type: object
    required:
    - organization_id
    - role_id
    properties:
      role_id:
        type: string
        description: The ID of the role that is assigned.
      organization_id:
        type: string
        description: The ID of the organization the role is scoped to.
      application_roles:
        type: array
        description: If provided, the user assigned this role assignment will be granted
          this application role when signing in to a deployment or project
        items:
          type: string
    description: Assignment for a role with organization scope.
  Orphaned:
    type: object
    required:
    - apm
    - appsearch
    - elasticsearch
    - enterprise_search
    - integrations_server
    - kibana
    properties:
      elasticsearch:
        type: array
        description: List of orphaned Elasticsearch resources
        items:
          "$ref": "#/definitions/OrphanedElasticsearch"
      kibana:
        type: array
        description: List of orphaned Kibana resource ids
        items:
          type: string
      apm:
        type: array
        description: List of orphaned APM resource ids
        items:
          type: string
      appsearch:
        type: array
        description: List of orphaned AppSearch resource ids
        items:
          type: string
      enterprise_search:
        type: array
        description: List of orphaned Enterprise Search resource ids
        items:
          type: string
      integrations_server:
        type: array
        description: List of orphaned Integrations Server resource ids
        items:
          type: string
    description: Details about orphaned resources.
  OrphanedElasticsearch:
    type: object
    required:
    - dependents
    - id
    properties:
      id:
        type: string
        description: The id of the orphaned resource
      dependents:
        type: array
        description: List of orphaned dependent resources
        items:
          "$ref": "#/definitions/ElasticsearchDependant"
    description: Details about an orphaned Elasticsearch resources.
  Period:
    type: object
    required:
    - end
    - start
    properties:
      start:
        type: string
        format: date-time
        description: Start
      end:
        type: string
        format: date-time
        description: End
    description: Period
  PlanStrategy:
    type: object
    properties:
      rolling:
        "$ref": "#/definitions/RollingStrategyConfig"
      grow_and_shrink:
        "$ref": "#/definitions/GrowShrinkStrategyConfig"
      rolling_grow_and_shrink:
        "$ref": "#/definitions/RollingGrowShrinkStrategyConfig"
      autodetect:
        "$ref": "#/definitions/AutodetectStrategyConfig"
    description: The options for performing a plan change. Specify only one property
      each time. The default is `grow_and_shrink`.
  PlatformRoleAssignment:
    type: object
    required:
    - role_id
    properties:
      role_id:
        type: string
        description: The ID of the role that is assigned.
    description: Assignment for a role with platform scope.
  PrefixQuery:
    type: object
    required:
    - value
    properties:
      value:
        type: string
        description: The prefix to search for.
      boost:
        type: number
        format: float
        description: An optional boost value to apply to the query.
    description: The query that matches documents with fields that contain terms with
      a specified, not analyzed, prefix.
  ProjectRoleAssignment:
    type: object
    required:
    - organization_id
    - role_id
    properties:
      role_id:
        type: string
        description: The ID of the role that is assigned.
      organization_id:
        type: string
        description: The ID of the organization the role is scoped to.
      all:
        type: boolean
        description: When true, the role applies to all projects in the organization,
          otherwise the role is scoped to the projects specified in `project_ids`.
      project_ids:
        type: array
        description: The IDs of the projects the role is scoped to. Must be absent
          if `all` is true, and present if `all` is false.
        items:
          type: string
      application_roles:
        type: array
        description: If provided, the user assigned this role assignment will be granted
          this application role when signing in to the project(s) specified in the
          role assignment.
        items:
          type: string
    description: Assignment for a role with project scope.
  ProjectRoleAssignments:
    type: object
    properties:
      elasticsearch:
        type: array
        description: The Elasticsearch project-scoped role assignments to set
        items:
          "$ref": "#/definitions/ProjectRoleAssignment"
      observability:
        type: array
        description: The Observability project-scoped role assignments to set
        items:
          "$ref": "#/definitions/ProjectRoleAssignment"
      security:
        type: array
        description: The Security project-scoped role assignments to set
        items:
          "$ref": "#/definitions/ProjectRoleAssignment"
      workplaceai:
        type: array
        description: The WorkplaceAI project-scoped role assignments to set
        items:
          "$ref": "#/definitions/ProjectRoleAssignment"
    description: Assignments for roles with project scope.
  PublicCertificate:
    type: object
    required:
    - active
    - metadata
    - pem
    properties:
      active:
        type: boolean
        description: If true, this certificate is the one which has been used to sign
          the current certificates. Otherwise, it may be the one that will be used
          when this certificate expires.
      pem:
        type: string
        description: The public certificate as string in PEM format.
      metadata:
        description: Metadata about the certificate, including fingerprint and expiry
          date. Generated by the Cloud service and ignored on write.
        "$ref": "#/definitions/CertificateMetaData"
    description: A certificate used to sign the certificates of this deployment
  QueryContainer:
    type: object
    properties:
      match:
        type: object
        additionalProperties:
          "$ref": "#/definitions/MatchQuery"
      match_all:
        "$ref": "#/definitions/MatchAllQuery"
      match_none:
        "$ref": "#/definitions/MatchNoneQuery"
      term:
        type: object
        additionalProperties:
          "$ref": "#/definitions/TermQuery"
      bool:
        "$ref": "#/definitions/BoolQuery"
      query_string:
        "$ref": "#/definitions/QueryStringQuery"
      nested:
        "$ref": "#/definitions/NestedQuery"
      prefix:
        type: object
        additionalProperties:
          "$ref": "#/definitions/PrefixQuery"
      exists:
        "$ref": "#/definitions/ExistsQuery"
      range:
        type: object
        additionalProperties:
          "$ref": "#/definitions/RangeQuery"
      simple_query_string:
        "$ref": "#/definitions/SimpleQueryStringQuery"
    description: The container for all of the allowed Elasticsearch queries. Specify
      only one property each time.
  QueryStringQuery:
    type: object
    required:
    - query
    properties:
      query:
        type: string
        description: The actual query to be parsed.
      default_field:
        type: string
        description: The default field for query terms if no prefix field is specified.
      analyzer:
        type: string
        description: The analyzer used to analyze each term of the query when creating
          composite queries.
      default_operator:
        type: string
        description: The default operator used if no explicit operator is specified.
      allow_leading_wildcard:
        type: boolean
        description: When set, * or ? are allowed as the first character. Defaults
          to false.
    description: A query that uses the strict query string syntax for parsing. Will
      return an error for invalid syntax.
  RangeQuery:
    type: object
    properties:
      gt:
        type: object
        description: Greater-than
      gte:
        type: object
        description: Greater-than or equal to
      lt:
        type: object
        description: Less-than
      lte:
        type: object
        description: Less-than or equal to.
      boost:
        type: number
        format: float
        description: An optional boost value to apply to the query.
      format:
        type: string
        description: Formatted dates will be parsed using the format specified on
          the date field by default, but it can be overridden by passing the format
          parameter.
      time_zone:
        type: string
        description: Dates can be converted from another timezone to UTC either by
          specifying the time zone in the date value itself (if the format accepts
          it), or it can be specified as the time_zone parameter.
    description: The query that matches documents with fields that contain terms within
      a specified range.
  ReadOnlyRequest:
    type: object
    required:
    - enabled
    properties:
      enabled:
        type: boolean
        description: Enabled or disabled read-only mode
    description: Read-only mode request payload
  ReadOnlyResponse:
    type: object
    required:
    - enabled
    properties:
      enabled:
        type: boolean
        description: Whether read-only mode is enabled or disabled
    description: Read-only mode response
  RemoteResourceInfo:
    type: object
    required:
    - compatible
    - connected
    - healthy
    - trusted
    - trusted_back
    properties:
      healthy:
        type: boolean
        description: Whether or not the remote cluster is healthy
      connected:
        type: boolean
        description: Whether or not there is at least one connection to the remote
          cluster.
      compatible:
        type: boolean
        description: Whether or not the remote cluster version is compatible with
          this cluster version.
      trusted:
        type: boolean
        description: Whether or not the remote cluster is trusted by this cluster.
      trusted_back:
        type: boolean
        description: Whether or not the remote cluster trusts this cluster back.
    description: Information about a Remote Cluster.
  RemoteResourceRef:
    type: object
    required:
    - alias
    - deployment_id
    - elasticsearch_ref_id
    properties:
      deployment_id:
        type: string
        description: The id of the deployment
      elasticsearch_ref_id:
        type: string
        description: The locally-unique user-specified id of an Elasticsearch Resource
      alias:
        type: string
        description: The alias for this remote cluster. Aliases must only contain
          letters, digits, dashes and underscores
      skip_unavailable:
        type: boolean
        description: 'If true, skip this cluster during search if it is disconnected.
          Default: false'
      info:
        description: Information about a Remote Cluster.
        readOnly: true
        "$ref": "#/definitions/RemoteResourceInfo"
    description: The Elasticsearch resource used as a Remote Cluster.
  RemoteResources:
    type: object
    required:
    - resources
    properties:
      resources:
        type: array
        description: The remote resources
        items:
          "$ref": "#/definitions/RemoteResourceRef"
    description: The list of resources used as remote clusters
  ReplyWarning:
    type: object
    required:
    - code
    properties:
      code:
        type: string
        description: A structured code representing the error type that occurred
      message:
        type: string
        description: A human readable message describing the warning that occurred
  RestoreSnapshotApiConfiguration:
    type: object
    properties:
      indices:
        type: array
        description: The list of indices to restore (supports +ve and -ve selection
          and wildcarding - see the default Elasticsearch index format documentation)
        items:
          type: string
      raw_settings:
        type: object
        description: This JSON object (merged with the 'indices' field (if present)
          is passed untouched into the restore command - see the Elasticsearch '_snapshot'
          documentation for more details on supported formats
    description: The configuration for the restore command, such as which indices
      you want to restore.
  RestoreSnapshotConfiguration:
    type: object
    required:
    - snapshot_name
    properties:
      repository_name:
        type: string
        description: If specified, contains the name of the snapshot repository -
          else will default to the Elastic Cloud system repo ('found-snapshots')
      snapshot_name:
        type: string
        description: The name of the snapshot to restore. Use '\_\_latest_success\_\_'
          to get the most recent snapshot from the specified repository
      repository_config:
        description: Raw remote snapshot restore settings. Do not send this if you
          are sending source_cluster_id
        "$ref": "#/definitions/RestoreSnapshotRepoConfiguration"
      restore_payload:
        "$ref": "#/definitions/RestoreSnapshotApiConfiguration"
      strategy:
        type: string
        description: The restore strategy to use. Defaults to a full restore. Partial
          restore will attempt to restore unavailable indices only
        enum:
        - partial
        - full
        - recovery
      source_cluster_id:
        type: string
        description: If specified, contains the name of the source cluster id. Do
          not send this if you are sending repository_config
    description: Restores a snapshot from a local or remote repository.
  RestoreSnapshotRepoConfiguration:
    type: object
    properties:
      raw_settings:
        type: object
        description: The remote snapshot settings raw JSON - see the Elasticsearch
          '_snapshot' documentation for more details on supported formats
    description: Configures the location of a remote repository. The default is the
      system repository.
  RoleAssignments:
    type: object
    properties:
      platform:
        type: array
        description: Assignments for roles with platform scope.
        items:
          "$ref": "#/definitions/PlatformRoleAssignment"
      organization:
        type: array
        description: Assignments for roles with organization scope.
        items:
          "$ref": "#/definitions/OrganizationRoleAssignment"
      deployment:
        type: array
        description: Assignments for roles with deployment scope.
        items:
          "$ref": "#/definitions/DeploymentRoleAssignment"
      project:
        description: Assignments for roles with project scope.
        "$ref": "#/definitions/ProjectRoleAssignments"
    description: Roles assigned to users, API keys or organization invitations. Currently
      unavailable in self-hosted ECE.
  RoleMapping:
    type: object
    required:
    - enabled
    - name
    - role_assignments
    - rule
    properties:
      enabled:
        type: boolean
        description: Whether or not the role mapping is enabled
      name:
        type: string
        description: The name of the role mapping
      rule:
        description: The rule to match
        "$ref": "#/definitions/RoleMappingRule"
      role_assignments:
        description: The role assignments to apply if the rule matches
        "$ref": "#/definitions/RoleAssignments"
  RoleMappingGroupRule:
    type: object
    required:
    - group
    properties:
      group:
        type: string
        description: The group to match. Can have wildcards.
  RoleMappingRule:
    type: object
    properties:
      any:
        type: array
        description: The rules that must match. Only one rule must match for the role
          assignment to be applied.
        items:
          "$ref": "#/definitions/RoleMappingGroupRule"
      all:
        type: array
        description: The rules that must match. All rules must match for the role
          assignment to be applied.
        items:
          "$ref": "#/definitions/RoleMappingGroupRule"
  RollingGrowShrinkStrategyConfig:
    type: object
    description: A strategy that creates new Elasticsearch instances, Kibana instances,
      and APM Servers with the new plan, then migrates the node data to minimize the
      amount of spare capacity.
  RollingStrategyConfig:
    type: object
    properties:
      group_by:
        type: string
        description: Specifies the grouping attribute to use when rolling several
          instances. Instances that share the same value for the provided attribute
          key are rolled together as a unit. Examples that make sense to use are '\_\_all\_\_'
          (roll all instances as a single unit), 'logical_zone_name' (roll instances
          by zone), '\_\_name\_\_' (roll one instance at a time, the default if not
          specified). Note that '\_\_all\_\_' is required when performing a major
          version upgrade
      allow_inline_resize:
        type: boolean
        description: 'Whether we allow changing the capacity of instances (default
          false). This is currently implemented by stopping, re-creating then starting
          the affected instance on its associated allocator when performing the changes.
          NOTES: This requires a round-trip through the allocation infrastructure
          of the active constructor, as it has to reserve the target capacity without
          over-committing'
      skip_synced_flush:
        type: boolean
        description: 'Whether to skip attempting to do a synced flush on the filesystem
          of the container (default: false), which is less safe but may be required
          if the container is unhealthy'
      shard_init_wait_time:
        type: integer
        format: int64
        description: 'The time, in seconds, to wait for shards that show no progress
          of initializing before rolling the next group (default: 10 minutes)'
    description: 'Performs inline, rolling configuration changes that mutate existing
      containers. TIP: This is the fastest way to update a plan, but can fail for
      complex plan changes, such as topology changes. Also, this is less safe for
      configuration changes that leave a cluster in a non running state. NOTE: When
      you perform a major version upgrade, and ''group_by'' is set to ''pass:macros[__all__]'';,
      rolling is required.'
  RulesetAssociations:
    type: object
    required:
    - associations
    - total_associations
    properties:
      associations:
        type: array
        description: List of associations
        items:
          "$ref": "#/definitions/FilterAssociation"
      total_associations:
        type: integer
        format: int32
        description: Total number of associations. This includes associations the
          user does not have permission to view.
    description: The configuration settings for the traffic filter.
  SamlIdp:
    type: object
    required:
    - issuer
    - public_certificate
    - sso_url
    properties:
      public_certificate:
        type: array
        description: Base64-encoded PEM-format X.509 certificate
        items:
          type: string
      issuer:
        type: string
        description: The IdP URI that identifies the issuer of a SAML2 response message
          assertion
      sso_url:
        type: string
        description: The IdP SAML HTTP-POST endpoint URL that will receive SAML requests
          during SP-initiated login
    description: SAML2 IdP configuration object
  SearchRequest:
    type: object
    properties:
      from:
        type: integer
        format: int32
        description: Deprecated, use cursor for a more scalable approach to paging.
      cursor:
        type: string
        description: To retrieve the next page of hits, set this to the cursor value
          of the previous response. When set, all other fields are ignored.
      size:
        type: integer
        format: int32
        description: The maximum number of search results to return.
      query:
        "$ref": "#/definitions/QueryContainer"
      sort:
        type: array
        description: An array of fields to sort the search results by. Defaults to
          query rank and last modified date descending.
        items:
          type: object
    description: An Elasticsearch search request with a subset of options.
  ServiceUrl:
    type: object
    required:
    - service
    - url
    properties:
      service:
        type: string
        description: Name of the service
      url:
        type: string
        description: The full URL to access the service
    description: A URL to access the service of a resource
  SimpleQueryStringQuery:
    type: object
    required:
    - query
    properties:
      query:
        type: string
        description: The query expressed in simple query string syntax.
      fields:
        type: array
        description: Array of fields to search
        items:
          type: string
      default_operator:
        type: string
        description: The boolean operator used to combine the terms of the query.
          Valid values are `OR` (default) and `AND`.
      analyze_wildcard:
        type: boolean
        description: If `true`, the query attempts to analyze wildcard terms. Defaults
          to `false`.
      analyzer:
        type: string
        description: The name of the analyzer to use to convert the query text into
          tokens.
      auto_generate_synonyms_phrase_query:
        type: boolean
        description: If `true`, the parse creates a `match_phrase` uery for each multi-position
          token. Defaults to `true`.
      flags:
        type: string
        description: List of enabled operators for the simple query string syntax.
          Defaults to `ALL`.
      fuzzy_max_expansions:
        type: integer
        format: int32
        description: Maximum number of terms to which the query expands for fuzzy
          matching. Defaults to 50.
      fuzzy_prefix_length:
        type: integer
        format: int32
        description: Number of beginning characters left unchanged for fuzzy matching.
          Defaults to 0.
      fuzzy_transpositions:
        type: boolean
        description: If `true`, edits for fuzzy matching include transpositions of
          two adjacent characters. Defaults to `false`.
      lenient:
        type: boolean
        description: If `true`, format-based errors, such as providing a text value
          for a numeric field are ignored. Defaults to `false`.
      minimum_should_match:
        type: string
        description: Minimum number of clauses that must match for a document to be
          returned.
      quote_field_suffix:
        type: string
        description: Suffix appended to quoted text in the query string.
    description: A query that uses simple query string syntax. Will ignore invalid
      syntax.
  SimplifiedLineItem:
    type: object
    required:
    - ecu_balance
    - ecu_quantity
    - end
    - id
    - start
    properties:
      id:
        type: string
        description: Line Item ID
      ecu_quantity:
        type: number
        format: double
        description: Original Elastic Consumption Unit (ECU) quantity
      ecu_balance:
        type: number
        format: double
        description: Elastic Consumption Unit (ECU) Balance
      start:
        type: string
        format: date-time
        description: Start of the line item's validity
      end:
        type: string
        format: date-time
        description: Expiration of the line item
    description: Line Item
  SnapshotDependency:
    type: object
    required:
    - cluster_id
    - repository_name
    properties:
      cluster_id:
        type: string
        description: Elasticsearch cluster id
      deployment_id:
        type: string
        description: Deployment id
      deployment_name:
        type: string
        description: Deployment name
      repository_name:
        type: string
        description: The name of the snapshot repository in Elasticsearch (e.g. _clone_abcd1234)
    description: The additional resource of Elasticsearch cluster.
  SnapshotDependencyConfiguration:
    type: object
    required:
    - source_cluster_id
    properties:
      source_cluster_id:
        type: string
        description: The cluster ID of the source cluster whose snapshots will be
          made available
    description: Configuration for attaching a snapshot repository dependency from
      another cluster. This creates a snapshot repository in the target cluster pointing
      to the source cluster's snapshots.
  SnapshotRepositories:
    type: object
    required:
    - repositories
    properties:
      repositories:
        type: array
        description: List of snapshot repositories (other deployments whose snapshots
          this deployment can access)
        items:
          "$ref": "#/definitions/SnapshotDependency"
    description: The snapshot repositories linked to this deployment.
  SnapshotStatusInfo:
    type: object
    required:
    - count
    - healthy
    - recent_success
    properties:
      healthy:
        type: boolean
        description: Health status of snapshots for this cluster
      count:
        type: integer
        format: int32
        description: Number of snapshots stored for this cluster
      latest_successful:
        type: boolean
        description: Latest snapshot status
      latest_status:
        type: string
        description: Status of the latest snapshot attempt, if any exist.
      scheduled_time:
        type: string
        format: date-time
        description: Scheduled time of next snapshot attempt
      latest_end_time:
        type: string
        format: date-time
        description: The end time of the most recently attempted snapshot
      latest_successful_end_time:
        type: string
        format: date-time
        description: The end time of the most recently successful snapshot
      recent_success:
        type: boolean
        description: Indicates whether the cluster has a relatively recent successful
          snapshot.
    description: Information about the snapshot status for the Elasticsearch cluster.
      For example, the health status.
  StackVersionApmConfig:
    type: object
    required:
    - blacklist
    - docker_image
    properties:
      version:
        type: string
        description: Version of APM
      docker_image:
        type: string
        description: Docker image for the APM
      blacklist:
        type: array
        description: List of configuration options that cannot be overridden by user
          settings
        items:
          type: string
      settings:
        type: object
        description: Settings that are applied to all nodes of this type
      capacity_constraints:
        description: |-
          > WARNING
          > This endpoint is deprecated and scheduled to be removed in the next major version. This field will soon be removed in favor of having a global capacity constraint for all node types.

          Capacity constraints for the node type
        "$ref": "#/definitions/StackVersionInstanceCapacityConstraint"
      compatible_node_types:
        type: array
        description: Node types that are compatible with this one
        items:
          type: string
    description: The APM Server configuration for an Elastic Stack version.
  StackVersionAppSearchConfig:
    type: object
    required:
    - blacklist
    - docker_image
    properties:
      version:
        type: string
        description: Version of AppSearch
      docker_image:
        type: string
        description: Docker image for the AppSearch
      blacklist:
        type: array
        description: List of configuration options that cannot be overridden by user
          settings
        items:
          type: string
      settings:
        type: object
        description: Settings that are applied to all nodes of this type
      capacity_constraints:
        description: |-
          > WARNING
          > This endpoint is deprecated and scheduled to be removed in the next major version. This field will soon be removed in favor of having a global capacity constraint for all node types.

          Capacity constraints for the node type
        "$ref": "#/definitions/StackVersionInstanceCapacityConstraint"
      compatible_node_types:
        type: array
        description: Node types that are compatible with this one
        items:
          type: string
      node_types:
        type: array
        description: Node types that are supported by this stack version
        items:
          "$ref": "#/definitions/StackVersionNodeType"
    description: AppSearch related configuration of an Elastic Stack version
  StackVersionConfig:
    type: object
    required:
    - elasticsearch
    - kibana
    - template
    - upgradable_to
    properties:
      version:
        type: string
        description: Stack version
        readOnly: true
      template:
        "$ref": "#/definitions/StackVersionTemplateInfo"
      elasticsearch:
        "$ref": "#/definitions/StackVersionElasticsearchConfig"
      kibana:
        "$ref": "#/definitions/StackVersionKibanaConfig"
      apm:
        "$ref": "#/definitions/StackVersionApmConfig"
      appsearch:
        "$ref": "#/definitions/StackVersionAppSearchConfig"
      metadata:
        "$ref": "#/definitions/StackVersionMetadata"
      deleted:
        type: boolean
        description: Identifies that the Elastic Stack version is marked for deletion
        readOnly: true
      upgradable_to:
        type: array
        description: Stack Versions that this version can upgrade to
        items:
          type: string
      min_upgradable_from:
        type: string
        example: 6.7.0
        description: The minimum version recommended to upgrade this version.
      whitelisted:
        type: boolean
        description: Whether or not this version is whitelisted. This is only relevant
          in EC (SaaS) and is not sent in ECE.
      accessible:
        type: boolean
        description: Whether or not this version is accessible by the calling user.
          This is only relevant in EC (SaaS) and is not sent in ECE.
      rolling_upgrade_compatible_versions:
        type: array
        description: List of versions that can be upgraded to the current version
          of the stackpack
        items:
          type: string
    description: The details for an Elastic Stack configuration.
  StackVersionConfigs:
    type: object
    required:
    - stacks
    properties:
      stacks:
        type: array
        items:
          "$ref": "#/definitions/StackVersionConfig"
    description: The details for multiple Elastic Stack configurations.
  StackVersionElasticsearchConfig:
    type: object
    required:
    - blacklist
    - default_plugins
    - docker_image
    - plugins
    properties:
      docker_image:
        type: string
        description: Docker image for the Elasticsearch
      plugins:
        type: array
        description: List of available plugins
        items:
          type: string
      default_plugins:
        type: array
        description: List of default plugins
        items:
          type: string
      blacklist:
        type: array
        description: List of configuration options that cannot be overridden by user
          settings
        items:
          type: string
      node_types:
        type: array
        description: Node types that are supported by this stack version
        items:
          "$ref": "#/definitions/StackVersionNodeType"
      settings:
        type: object
        description: Settings that are applied to all nodes of this type
      capacity_constraints:
        description: |-
          > WARNING
          > This endpoint is deprecated and scheduled to be removed in the next major version. This field will soon be removed in favor of having a global capacity constraint for all node types.

          Capacity constraints for the node type
        "$ref": "#/definitions/StackVersionInstanceCapacityConstraint"
      compatible_node_types:
        type: array
        description: Node types that are compatible with this one
        items:
          type: string
    description: 'The Elasticsearch configuration for an Elastic Stack version. '
  StackVersionInstanceCapacityConstraint:
    type: object
    required:
    - max
    - min
    properties:
      min:
        type: integer
        format: int32
        description: Min capacity of the instances
      max:
        type: integer
        format: int32
        description: Max capacity of the instances
    description: The Elasticsearch instance, Kibana instance, APM Server capacity
      constraints for an Elastic Stack node type.
  StackVersionKibanaConfig:
    type: object
    required:
    - blacklist
    - docker_image
    properties:
      version:
        type: string
        description: Version of Kibana
      docker_image:
        type: string
        description: Docker image for the kibana
      blacklist:
        type: array
        description: List of configuration options that cannot be overridden by user
          settings
        items:
          type: string
      settings:
        type: object
        description: Settings that are applied to all nodes of this type
      capacity_constraints:
        description: |-
          > WARNING
          > This endpoint is deprecated and scheduled to be removed in the next major version. This field will soon be removed in favor of having a global capacity constraint for all node types.

          Capacity constraints for the node type
        "$ref": "#/definitions/StackVersionInstanceCapacityConstraint"
      compatible_node_types:
        type: array
        description: Node types that are compatible with this one
        items:
          type: string
    description: The Kibana configuration for an Elastic Stack version.
  StackVersionMetadata:
    type: object
    properties:
      notes:
        type: string
        description: Notes for administrator
      pre_release:
        type: boolean
        description: Indicates that the stack pack version is not GA and is not supposed
          to be used in production
      min_platform_version:
        type: string
        description: The minimum version of the platform that the stack pack version
          is compatible with
      min_wire_compatibility_version:
        type: string
        description: The minimum version required for performing a rolling upgrade
          to this stack version.
      min_index_compatibility_version:
        type: string
        description: The minimum version required for performing a full cluster restart
          upgrade to this stack version.
      schema_version:
        type: integer
        format: int32
        description: The schema version of the stack pack version
      is_fips:
        type: boolean
        description: Is this a fips stackpack
    description: The metadata for the Elastic Stack.
  StackVersionNodeType:
    type: object
    required:
    - description
    - name
    - node_type
    properties:
      node_type:
        type: string
        description: Type of the node (master, data, ...)
      name:
        type: string
        description: Name of the node type
      description:
        type: string
        description: Description of the node type
      settings:
        type: object
        description: Settings that are applied to all nodes of this type
      capacity_constraints:
        description: |-
          > WARNING
          > This endpoint is deprecated and scheduled to be removed in the next major version. This field will soon be removed in favor of having a global capacity constraint for all node types.

          Capacity constraints for the node type
        "$ref": "#/definitions/StackVersionInstanceCapacityConstraint"
      compatible_node_types:
        type: array
        description: Node types that are compatible with this one
        items:
          type: string
      mandatory:
        type: boolean
        description: Flag to specify a node type is mandatory in a cluster's plan
    description: The configuration for an Elastic Stack node type.
  StackVersionTemplateFileHash:
    type: object
    required:
    - hash
    - path
    properties:
      path:
        type: string
        description: File path relative to template's root
      hash:
        type: string
        description: SHA-256 hash of a file
    description: The template file hash for an Elastic Stack version.
  StackVersionTemplateInfo:
    type: object
    properties:
      template_version:
        type: string
        description: Template version
        readOnly: true
      hashes:
        type: array
        description: Relative paths of files with SHA-256 hashes that contains the
          template
        readOnly: true
        items:
          "$ref": "#/definitions/StackVersionTemplateFileHash"
    description: The template information for an Elastic Stack version.
  TargetElasticsearchCluster:
    type: object
    required:
    - elasticsearch_id
    properties:
      elasticsearch_id:
        type: string
        description: The Elasticsearch cluster Id
      links:
        type: object
        description: A map of application-specific operations (which map to 'operationId's
          in the Swagger API) to metadata about that operation
        additionalProperties:
          "$ref": "#/definitions/Hyperlink"
    description: Information about the specified Elasticsearch cluster.
  TermQuery:
    type: object
    required:
    - value
    properties:
      value:
        type: string
        description: The exact value to query for.
    description: A query for documents that contain the specified term in the inverted
      index.
  TierConfig:
    type: object
    properties:
      memory_size:
        type: integer
        format: int32
        description: The desired memory size in MB for this tier.
      zone_count:
        type: integer
        format: int32
        description: The number of availability zones for this tier. If omitted, the
          current zone count is preserved.
    description: Configuration for an individual Elasticsearch tier
  TiersUpdateRequest:
    type: object
    properties:
      hot_content:
        description: Configuration for the hot_content tier
        "$ref": "#/definitions/TierConfig"
      warm:
        description: Configuration for the warm tier
        "$ref": "#/definitions/TierConfig"
      cold:
        description: Configuration for the cold tier
        "$ref": "#/definitions/TierConfig"
      frozen:
        description: Configuration for the frozen tier
        "$ref": "#/definitions/TierConfig"
      master:
        description: Configuration for the master tier
        "$ref": "#/definitions/TierConfig"
      coordinating:
        description: Configuration for the coordinating tier
        "$ref": "#/definitions/TierConfig"
      ml:
        description: Configuration for the ml tier
        "$ref": "#/definitions/TierConfig"
    description: Update the size and/or zone count of one or more Elasticsearch tiers.
      Only include the tiers you want to modify.
  TopologyElementControl:
    type: object
    required:
    - min
    properties:
      min:
        description: Absolute minimum size limit for a topology element created with
          a deployment template. If the value is 0, that means the topology element
          can be disabled.
        "$ref": "#/definitions/TopologySize"
    description: Controls for the topology element. Only used as part of the deployment
      template. Ignored if included as part of a deployment.
  TopologySize:
    type: object
    required:
    - resource
    - value
    properties:
      value:
        type: integer
        format: int32
        description: Amount of resource
      resource:
        type: string
        description: Type of resource. In ESS the resource used should always be `memory`.
        enum:
        - memory
        - storage
    description: Measured by the amount of a resource. The final cluster size is calculated
      using multipliers from the topology instance configuration.
  TrafficFilterClaimedLinkIdInfo:
    type: object
    required:
    - region
    properties:
      link_id:
        type: string
        description: Link id. A GCP private service connect ID or AWS VPC endpoint
          ID
      azure_endpoint_name:
        type: string
        description: Name of the Azure Private Endpoint to allow connections from
      azure_endpoint_guid:
        type: string
        description: Resource GUID of the Azure Private Endpoint to allow connections
          from
      region:
        type: string
        description: The claimed link id can be used only for traffic filter in the
          specific region
  TrafficFilterClaimedLinkIdRequest:
    type: object
    required:
    - region
    properties:
      link_id:
        type: string
        description: Link id. A GCP private service connect ID or AWS VPC endpoint
          ID
      azure_endpoint_name:
        type: string
        description: Name of the Azure Private Endpoint to allow connections from
      azure_endpoint_guid:
        type: string
        description: Resource GUID of the Azure Private Endpoint to allow connections
          from
      region:
        type: string
        description: The claimed link id can be used only for traffic filter in the
          specific region
    description: The specification for traffic filter claimed link id.
  TrafficFilterClaimedLinkIds:
    type: object
    required:
    - claimed_link_ids
    properties:
      claimed_link_ids:
        type: array
        description: List of traffic filter claimed link id
        items:
          "$ref": "#/definitions/TrafficFilterClaimedLinkIdInfo"
    description: The container for a set of traffic filter claimed link id.
  TrafficFilterEgressRule:
    type: object
    required:
    - protocol
    - target
    properties:
      target:
        type: string
        description: 'Allowed traffic filter egress target: IP address or CIDR mask'
      ports:
        type: array
        description: A list of target ports for an egress rule
        items:
          type: integer
          format: int32
      protocol:
        type: string
        description: The target protocol for an egress rule
        enum:
        - all
        - tcp
        - udp
    description: The rule detail for a traffic filter egress rule.
  TrafficFilterRule:
    type: object
    properties:
      id:
        type: string
        description: The rule ID
      remote_cluster_org_id:
        type: string
        description: The remote cluster organization ID
      remote_cluster_id:
        type: string
        description: The remote cluster ID
      description:
        type: string
        description: Description of the rule
      source:
        type: string
        description: 'Allowed traffic filter source: IP address, CIDR mask, or VPC
          endpoint ID'
      azure_endpoint_name:
        type: string
        description: Name of the Azure Private Endpoint to allow connections from
      azure_endpoint_guid:
        type: string
        description: Resource GUID of the Azure Private Endpoint to allow connections
          from
      egress_rule:
        description: An egress traffic filter rule
        "$ref": "#/definitions/TrafficFilterEgressRule"
    description: The container for a traffic filter rule.
  TrafficFilterRulesetInfo:
    type: object
    required:
    - id
    - include_by_default
    - name
    - region
    - rules
    - type
    properties:
      id:
        type: string
        description: The ruleset ID
      name:
        type: string
        description: Name of the ruleset
      description:
        type: string
        description: Description of the ruleset
      type:
        type: string
        description: Type of the ruleset
        enum:
        - ip
        - azure_private_endpoint
        - gcp_private_service_connect_endpoint
        - vpce
        - egress_firewall
        - remote_cluster
      include_by_default:
        type: boolean
        description: Should the ruleset be automatically included in the new deployments
      region:
        type: string
        description: The ruleset can be attached only to deployments in the specific
          region
      rules:
        type: array
        description: List of rules
        items:
          "$ref": "#/definitions/TrafficFilterRule"
      associations:
        type: array
        description: List of associations. Returned only when include_associations
          query parameter is true
        items:
          "$ref": "#/definitions/FilterAssociation"
      total_associations:
        type: integer
        format: int32
        description: Total number of associations. This includes associations the
          user does not have permission to view.Returned only when include_associations
          query parameter is true
    description: The container for a set of traffic filter rules.
  TrafficFilterRulesetRequest:
    type: object
    required:
    - include_by_default
    - name
    - region
    - rules
    - type
    properties:
      name:
        type: string
        description: Name of the ruleset
      description:
        type: string
        description: Description of the ruleset
      type:
        type: string
        description: Type of the ruleset
      include_by_default:
        type: boolean
        description: Should the ruleset be automatically included in the new deployments
      region:
        type: string
        description: The ruleset can be attached only to deployments in the specific
          region
      rules:
        type: array
        description: List of rules
        items:
          "$ref": "#/definitions/TrafficFilterRule"
    description: The specification for traffic filter ruleset.
  TrafficFilterRulesetResponse:
    type: object
    required:
    - id
    properties:
      id:
        type: string
        description: The new ruleset ID
    description: The response after you create a new ruleset.
  TrafficFilterRulesets:
    type: object
    required:
    - rulesets
    properties:
      rulesets:
        type: array
        description: List of traffic filter rules
        items:
          "$ref": "#/definitions/TrafficFilterRulesetInfo"
    description: The container for a set of traffic filter rulesets.
  TrafficFilterSettings:
    type: object
    required:
    - rulesets
    properties:
      rulesets:
        type: array
        description: IDs of the traffic filter rulesets
        items:
          type: string
    description: The configuration settings for the traffic filter.
  TransientApmPlanConfiguration:
    type: object
    properties:
      strategy:
        "$ref": "#/definitions/PlanStrategy"
      plan_configuration:
        "$ref": "#/definitions/ApmPlanControlConfiguration"
    description: Defines the configuration parameters that control how the plan is
      applied. For example, the Elasticsearch cluster topology and APM Server settings.
  TransientAppSearchPlanConfiguration:
    type: object
    properties:
      strategy:
        "$ref": "#/definitions/PlanStrategy"
      plan_configuration:
        "$ref": "#/definitions/AppSearchPlanControlConfiguration"
    description: Defines configuration parameters that control how the plan (ie consisting
      of the cluster topology and AppSearch settings) is applied
  TransientElasticsearchPlanConfiguration:
    type: object
    properties:
      strategy:
        "$ref": "#/definitions/PlanStrategy"
      plan_configuration:
        "$ref": "#/definitions/ElasticsearchPlanControlConfiguration"
      restore_snapshot:
        "$ref": "#/definitions/RestoreSnapshotConfiguration"
      snapshot_dependency:
        description: Configuration for attaching a snapshot dependency from another
          cluster
        "$ref": "#/definitions/SnapshotDependencyConfiguration"
      remote_clusters:
        description: The list of resources that will be configured as remote clusters
        "$ref": "#/definitions/RemoteResources"
      cluster_settings_json:
        type: object
        description: |-
          If specified, contains transient settings to be applied to an Elasticsearch cluster during changes,default values shown below applied.
          These can be overridden by specifying them in the map (or null to unset). Additional settings can also be set. Settings will be cleared after the plan has finished. If not specified, no settings will be applied.
          NOTE: These settings are only explicitly cleared for 5.x+ clusters, they must be hand-reset to their defaults in 2.x- (or a cluster reboot will clear them).
          - indices.store.throttle.max_bytes_per_sec: 120Mb
          - indices.recovery.max_bytes_per_sec: 120Mb
          - cluster.routing.allocation.cluster_concurrent_rebalance: 5
          - cluster.routing.allocation.node_initial_primaries_recoveries: 5
          - cluster.routing.allocation.node_concurrent_incoming_recoveries: 5
          For version 8.1 and later no defaults are provided through this mechanism, but instead hardware dependent settings are provided to each instance.
    description: Defines the configuration parameters that control how the plan is
      applied. For example, the Elasticsearch cluster topology and Elasticsearch settings.
  TransientEnterpriseSearchPlanConfiguration:
    type: object
    properties:
      strategy:
        "$ref": "#/definitions/PlanStrategy"
      plan_configuration:
        "$ref": "#/definitions/EnterpriseSearchPlanControlConfiguration"
    description: Defines configuration parameters that control how the plan (i.e.
      consisting of the cluster topology and Enterprise Search settings) is applied
  TransientIntegrationsServerPlanConfiguration:
    type: object
    properties:
      strategy:
        "$ref": "#/definitions/PlanStrategy"
      plan_configuration:
        "$ref": "#/definitions/IntegrationsServerPlanControlConfiguration"
    description: Defines the configuration parameters that control how the plan is
      applied. For example, the Elasticsearch cluster topology and Integrations Server
      settings.
  TransientKibanaPlanConfiguration:
    type: object
    properties:
      strategy:
        "$ref": "#/definitions/PlanStrategy"
      plan_configuration:
        "$ref": "#/definitions/KibanaPlanControlConfiguration"
    description: Defines the configuration parameters that control how the plan is
      applied. For example, the Elasticsearch cluster topology and Kibana instance
      settings.
  TrustedCertificate:
    type: object
    required:
    - pem
    properties:
      pem:
        type: string
        description: The public ca certificate as string in PEM format.
      metadata:
        description: Metadata about the certificate, including fingerprint and expiry
          date. Generated by the Cloud service and ignored on write.
        readOnly: true
        "$ref": "#/definitions/CertificateMetaData"
    description: An x509 certificate used by a DirectTrustRelationship
  UpdateExtensionRequest:
    type: object
    required:
    - extension_type
    - name
    - version
    properties:
      name:
        type: string
        description: The extension name.
      description:
        type: string
        description: The extension description.
      download_url:
        type: string
        description: The URL to download the extension archive.
      extension_type:
        type: string
        description: The extension type.
        enum:
        - plugin
        - bundle
      version:
        type: string
        description: The Elasticsearch version.
    description: The body of a request to update an extension
  UpdateOrganizationRoleMappingRequest:
    type: object
    required:
    - mappings
    properties:
      mappings:
        type: array
        description: The rules for mapping role assignments in the organization
        items:
          "$ref": "#/definitions/RoleMapping"
  Updates:
    type: object
    properties:
      elasticsearch:
        type: array
        description: Diagnostics for Elasticsearch clusters
        items:
          "$ref": "#/definitions/Elasticsearch"
      kibana:
        type: array
        description: Diagnostics for Kibanas
        items:
          "$ref": "#/definitions/Kibana"
      apm:
        type: array
        description: Diagnostics for APMs
        items:
          "$ref": "#/definitions/Apm"
      integrations_server:
        type: array
        description: Diagnostics for Integrations Server
        items:
          "$ref": "#/definitions/IntegrationsServer"
      appsearch:
        type: array
        description: Diagnostics for AppSearches
        items:
          "$ref": "#/definitions/AppSearch"
      enterprise_search:
        type: array
        description: Diagnostics for Enterprise Search resources
        items:
          "$ref": "#/definitions/EnterpriseSearch"
    description: Holds diagnostics for existing resources that might be updated
  VerificationCodeRequest:
    type: object
    required:
    - domain_claim_request
    properties:
      domain_claim_request:
        type: string
        description: The domain claim request
  VerificationCodeResponse:
    type: object
    required:
    - verification
    properties:
      verification:
        type: string
        description: The verification code to use for the domain claim challenge
x-elastic:
  curl:
    auth: '-H "Authorization: ApiKey $EC_API_KEY"'
tags:
- name: Accounts
  description: Retrieve and update the current Elasticsearch Service account.
- name: Authentication
  description: Manage your Elasticsearch Service API keys.
- name: BillingCostsAnalysis
  x-displayName: Billing costs analysis
  description: Get an overview of your costs by organization ID.
- name: Deployments
  description: 'Manage APM routes and read-only mode on App Search resources. Perform
    CRUD operations and commands. Get information about the certificate authorities,
    resources, remote clusters, and upgrade assistant status in your deployments.

    '
- name: Extensions
  x-displayName: Deployments - Extensions
  description: Manage the extensions for your deployment.
- name: DeploymentTemplates
  x-displayName: Deployments - Templates
  description: Retrieve available deployment templates.
- name: DeploymentsTrafficFilter
  x-displayName: Deployments - Traffic filter
  description: 'Manage traffic filter rulesets and their associations with your deployments.
    Manage the ownership of traffic link IDs.

    '
- name: Organizations
  description: Manage organization invitations and memberships.
- name: Stack
  x-displayName: Stack - Versions - CRUD
  description: Retrieve the available Elastic Stack versions for your deployments.
- name: TrustedEnvironments
  x-displayName: Trusted environments
  description: Get the list of trusted environments for the organization.
- name: UserRoleAssignments
  x-displayName: Users - Role Assignments
  description: Manage your user role assignments.
x-topics:
- title: Principles
  content: |
    The Elasticsearch Service API is built on REST. This means that:

    - URLs are based on resource IDs.
    - JSON is the data interchange format.
    - Standard HTTP response codes and verbs are used.

    RESTful API calls are stateless.
    Every request that you make happens in isolation from other calls and must include all the information necessary for Elasticsearch Service to fulfill the request.
    API requests return JSON output, which is a format that is machine-readable and works well for automation.

    Calls to API endpoints require different request methods, depending on what they do.
    You use these four request methods to communicate with the Elasticsearch Service RESTful API:

    - To fetch a resource: GET
    - To create a new resource: POST
    - To update an existing resource: PUT or PATCH
    - To delete a resource: DELETE
- title: Rate limiting
  content: |
    API calls are rate limited in a timing window.
    The current remaining available calls quota is available through the following header fields, included in each API call response:

    - `x-ratelimit-interval` - The time duration for the quota calculation.
    - `x-ratelimit-remaining` - The remaining number of API calls available.
    - `x-ratelimit-limit` - The total number of calls available in the duration `x-ratelimit-interval`.
- title: Authentication
  content: "Elastic Cloud APIs support key-based authentication.\nYou must [create
    an API key](https://www.elastic.co/guide/en/cloud/current/ec-api-authentication.html)
    and use the encoded value in the request header.            \nFor convenience,
    you can export your API key into your shell environment:\n\n```\nexport EC_API_KEY=\"YOUR_GENERATED_API_KEY\"\n```\n\nFor
    example, the following `curl` command retrieves a list of your deployments:\n\n```\ncurl
    -H \"Authorization: ApiKey $EC_API_KEY\" https://api.elastic-cloud.com/api/v1/deployments\n```\n"
