### GET /deployments/templates Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json Retrieves all deployment templates. ```markdown ### Parameters - **metadata** (string, query, optional): 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. - **show_instance_configurations** (string, query, optional): If true, will return details for each instance configuration referenced by the template. - **show_max_zones** (string, query, optional): If true, will populate the max_zones field in the instance configurations. Only relevant if show_instance_configurations=true. - **stack_version** (string, query, optional): If present, it will cause the returned deployment templates to be adapted to return only the elements allowed in that version. - **hide_deprecated** (string, query, optional): If true, templates flagged as deprecated will NOT be returned. - **region** (string, query, required): Region of the deployment templates ### Responses #### 200 - The deployment templates were returned successfully. Empty response body #### 400 - The requested region was not found. (code: `templates.region_not_found`) The requested region was not found. (code: `templates.region_not_found`) #### 401 - The user is not authorized to access requested region. (code: `templates.region_not_allowed`) The user is not authorized to access requested region. (code: `templates.region_not_allowed`) ### Example Usage ```bash curl -X GET "https://api.example.com/deployments/templates?metadata=value&show_instance_configurations=value&show_max_zones=value&stack_version=value&hide_deprecated=value®ion=value" ``` ``` -------------------------------- ### GET /deployments/extensions Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json Retrieves all of the available extensions. ```markdown ### Responses #### 200 - The extensions that are available Empty response body ### Example Usage ```bash curl -X GET "https://api.example.com/deployments/extensions" ``` ``` -------------------------------- ### GET /deployments Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json List Deployments. ```markdown ### Responses #### 200 - The list of deployments that belong to the authenticated user. Empty response body #### 401 - You are not authorized to perform this action. You are not authorized to perform this action. ### Example Usage ```bash curl -X GET "https://api.example.com/deployments" ``` ``` -------------------------------- ### GET /deployments/extensions/{extension_id} Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json Retrieves an extension. ```markdown ### Parameters - **extension_id** (string, path, required): Id of an extension - **include_deployments** (string, query, optional): Include deployments referencing this extension. Up to only 10000 deployments will be included. ### Responses #### 200 - The Extension Empty response body #### 404 - The extension requested does not exist. (code: `extensions.not_found`) The extension requested does not exist. (code: `extensions.not_found`) ### Example Usage ```bash curl -X GET "https://api.example.com/deployments/extensions/{extension_id}?include_deployments=value" ``` ``` -------------------------------- ### POST /deployments/{deployment_id}/{resource_kind}/{ref_id}/instances/_start Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json Starts all instances belonging to a Deployment Resource. ```markdown ### Parameters - **deployment_id** (string, path, required): Identifier for the Deployment. - **resource_kind** (string, path, required): The kind of resource (one of elasticsearch, kibana, apm, or integrations_server). - **ref_id** (string, path, required): User-specified RefId for the Resource (or '_main' if there is only one). ### Responses #### 202 - The start command was issued successfully. Empty response body #### 403 - The start maintenance mode command was prohibited for the given Resource. (code: `deployments.instance_update_prohibited_error`) The start maintenance mode command was prohibited for the given Resource. (code: `deployments.instance_update_prohibited_error`) #### 404 - * 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`) * 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`) #### 500 - A Resource that was previously stored no longer exists. (code: `deployments.deployment_resource_no_longer_exists`) A Resource that was previously stored no longer exists. (code: `deployments.deployment_resource_no_longer_exists`) ### Example Usage ```bash curl -X POST "https://api.example.com/deployments/{deployment_id}/{resource_kind}/{ref_id}/instances/_start" ``` ``` -------------------------------- ### GET /deployments/{deployment_id}/upgrade_assistant/status Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json Get details about an Elasticsearch resource belonging to a given deployment. ```markdown ### Parameters - **deployment_id** (string, path, required): Identifier for the Deployment - **target_version** (string, query, optional): If present, value is included in resource request to provide additional context (only supported for Kibana) ### Responses #### 200 - The Upgrade Assistant returned the status successfully Empty response body #### 404 - The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`) The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`) ### Example Usage ```bash curl -X GET "https://api.example.com/deployments/{deployment_id}/upgrade_assistant/status?target_version=value" ``` ``` -------------------------------- ### POST /deployments/{deployment_id}/{resource_kind}/{ref_id}/instances/{instance_ids}/_start Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json Starts instances belonging to a Deployment Resource. ```markdown ### Parameters - **deployment_id** (string, path, required): Identifier for the Deployment. - **resource_kind** (string, path, required): The kind of resource (one of elasticsearch, kibana, apm, or integrations_server). - **ref_id** (string, path, required): User-specified RefId for the Resource (or '_main' if there is only one). - **instance_ids** (string, path, required): A comma-separated list of instance identifiers. - **ignore_missing** (string, query, optional): If true and the instance does not exist then quietly proceed to the next instance, otherwise treated as an error ### Responses #### 202 - The start command was issued successfully. Empty response body #### 403 - The start maintenance mode command was prohibited for the given Resource. (code: `deployments.instance_update_prohibited_error`) The start maintenance mode command was prohibited for the given Resource. (code: `deployments.instance_update_prohibited_error`) #### 404 - * 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`) * 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`) #### 500 - A Resource that was previously stored no longer exists. (code: `deployments.deployment_resource_no_longer_exists`) A Resource that was previously stored no longer exists. (code: `deployments.deployment_resource_no_longer_exists`) ### Example Usage ```bash curl -X POST "https://api.example.com/deployments/{deployment_id}/{resource_kind}/{ref_id}/instances/{instance_ids}/_start?ignore_missing=value" ``` ``` -------------------------------- ### GET /deployments/{deployment_id}/appsearch/{ref_id} Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json Get info about an App Search Resource belonging to a given Deployment. ```markdown ### Parameters - **deployment_id** (string, path, required): Identifier for the Deployment - **ref_id** (string, path, required): User-specified RefId for the Resource (or '_main' if there is only one). - **show_metadata** (string, query, optional): Whether to include the full cluster metadata in the response - can be large per cluster and also include credentials. - **show_plans** (string, query, optional): Whether to include the full current and pending plan information in the response - can be large per cluster. - **show_plan_logs** (string, query, optional): Whether to include with the current and pending plan information the attempt log - can be very large per cluster. - **show_plan_history** (string, query, optional): Whether to include with the current and pending plan information the plan history- can be very large per cluster. - **show_plan_defaults** (string, query, optional): If showing plans, whether to show values that are left at their default value (less readable but more informative). - **show_settings** (string, query, optional): Whether to show cluster settings in the response. - **clear_transient** (string, query, optional): If set (defaults to false) then removes the transient section from all child resources, making it safe to reapply via an update ### Responses #### 200 - Standard response. Empty response body #### 404 - The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`) The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`) #### 500 - We have failed you. (code: `deployments.deployment_resource_no_longer_exists`) We have failed you. (code: `deployments.deployment_resource_no_longer_exists`) ### Example Usage ```bash curl -X GET "https://api.example.com/deployments/{deployment_id}/appsearch/{ref_id}?show_metadata=value&show_plans=value&show_plan_logs=value&show_plan_history=value&show_plan_defaults=value&show_settings=value&clear_transient=value" ``` ``` -------------------------------- ### GET /deployments/templates/{template_id} Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json Retrieves a deployment template by id. ```markdown ### Parameters - **template_id** (string, path, required): The identifier for the deployment template. - **show_instance_configurations** (string, query, optional): If true, will return details for each instance configuration referenced by the template. - **show_max_zones** (string, query, optional): If true, will populate the max_zones field in the instance configurations. Only relevant if show_instance_configurations=true. - **stack_version** (string, query, optional): If present, it will cause the returned deployment template to be adapted to return only the elements allowed in that version. - **region** (string, query, required): Region of the deployment template ### Responses #### 200 - The deployment template was found and returned successfully. Empty response body #### 400 - The requested region is not supported. (code: `templates.region_not_found`) The requested region is not supported. (code: `templates.region_not_found`) #### 401 - The user is not authorized to access requested region. (code: `templates.region_not_allowed`) The user is not authorized to access requested region. (code: `templates.region_not_allowed`) #### 404 - The deployment template specified by {template_id} cannot be found. (code: `templates.template_not_found`) The deployment template specified by {template_id} cannot be found. (code: `templates.template_not_found`) ### Example Usage ```bash curl -X GET "https://api.example.com/deployments/templates/{template_id}?show_instance_configurations=value&show_max_zones=value&stack_version=value®ion=value" ``` ``` -------------------------------- ### GET /organizations/invitations/{invitation_token} Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json Gets a single invitation to an organization by token. Currently unavailable in self-hosted ECE. ```markdown ### Parameters - **invitation_token** (string, path, required): Organization invitation token ### Responses #### 200 - Organization invitation fetched successfully Empty response body #### 404 - Invitation not found. (code: `organization.invitation_not_found`) Invitation not found. (code: `organization.invitation_not_found`) ### Example Usage ```bash curl -X GET "https://api.example.com/organizations/invitations/{invitation_token}" ``` ``` -------------------------------- ### GET /organizations/{organization_id}/idp/metadata.xml Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json Gets the oranization's IdP metadata.xml. Currently unavailable in self-hosted ECE. ```markdown ### Parameters - **organization_id** (string, path, required): Identifier for the Organization ### Responses #### 200 - The IdP info Empty response body #### 404 - IdP was not configured yet. (code: `org.idp.idp_not_configured`) IdP was not configured yet. (code: `org.idp.idp_not_configured`) ### Example Usage ```bash curl -X GET "https://api.example.com/organizations/{organization_id}/idp/metadata.xml" ``` ``` -------------------------------- ### GET /deployments/{deployment_id}/integrations_server/{ref_id} Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json Get info about an Integrations Server Resource belonging to a given Deployment. ```markdown ### Parameters - **deployment_id** (string, path, required): Identifier for the Deployment - **ref_id** (string, path, required): User-specified RefId for the Resource (or '_main' if there is only one). - **show_metadata** (string, query, optional): Whether to include the full cluster metadata in the response - can be large per cluster and also include credentials. - **show_plans** (string, query, optional): Whether to include the full current and pending plan information in the response - can be large per cluster. - **show_plan_logs** (string, query, optional): Whether to include with the current and pending plan information the attempt log - can be very large per cluster. - **show_plan_history** (string, query, optional): Whether to include with the current and pending plan information the plan history- can be very large per cluster. - **show_plan_defaults** (string, query, optional): If showing plans, whether to show values that are left at their default value (less readable but more informative). - **show_settings** (string, query, optional): Whether to show cluster settings in the response. - **clear_transient** (string, query, optional): If set (defaults to false) then removes the transient section from all child resources, making it safe to reapply via an update ### Responses #### 200 - Standard response. Empty response body #### 404 - The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`) The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`) #### 500 - We have failed you. (code: `deployments.deployment_resource_no_longer_exists`) We have failed you. (code: `deployments.deployment_resource_no_longer_exists`) ### Example Usage ```bash curl -X GET "https://api.example.com/deployments/{deployment_id}/integrations_server/{ref_id}?show_metadata=value&show_plans=value&show_plan_logs=value&show_plan_history=value&show_plan_defaults=value&show_settings=value&clear_transient=value" ``` ``` -------------------------------- ### GET /account Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json Fetch current account information. ```markdown ### Responses #### 200 - Account fetched successfully Empty response body #### 404 - Account not found. (code: `accounts.not_found`) Account not found. (code: `accounts.not_found`) ### Example Usage ```bash curl -X GET "https://api.example.com/account" ``` ``` -------------------------------- ### GET /deployments/traffic-filter/rulesets Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json List all of the traffic filter rulesets. ```markdown ### Parameters - **include_associations** (string, query, optional): Retrieves a list of resources that are associated to the specified ruleset. - **region** (string, query, optional): If provided limits the rulesets to that region only. - **organization_id** (string, query, optional): Retrieves a list of resources that are associated to the specified organization ID. It only takes effect if the user is an admin. ### Responses #### 200 - The collection of traffic filter routes Empty response body #### 500 - Error fetching traffic filter rulesets. (code: `traffic_filter.request_execution_failed`) Error fetching traffic filter rulesets. (code: `traffic_filter.request_execution_failed`) ### Example Usage ```bash curl -X GET "https://api.example.com/deployments/traffic-filter/rulesets?include_associations=value®ion=value&organization_id=value" ``` ``` -------------------------------- ### POST /deployments/{deployment_id}/{stateless_resource_kind}/{ref_id}/_restart Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json 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. ```markdown ### Parameters - **deployment_id** (string, path, required): Identifier for the Deployment. - **stateless_resource_kind** (string, path, required): The kind of stateless resource - **ref_id** (string, path, required): User-specified RefId for the Resource (or '_main' if there is only one). - **cancel_pending** (string, query, optional): If true, cancels any pending plans before restarting. If false and there are pending plans, returns an error. ### Responses #### 202 - The restart command was issued successfully Empty response body #### 404 - * 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 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`) #### 422 - 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`) 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`) #### 500 - We have failed you. (code: `deployments.deployment_resource_no_longer_exists`) We have failed you. (code: `deployments.deployment_resource_no_longer_exists`) ### Example Usage ```bash curl -X POST "https://api.example.com/deployments/{deployment_id}/{stateless_resource_kind}/{ref_id}/_restart?cancel_pending=value" ``` ``` -------------------------------- ### POST /deployments/{deployment_id}/{resource_kind}/{ref_id}/instances/maintenance-mode/_start Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json Starts maintenance mode of all instances belonging to a Deployment Resource. ```markdown ### Parameters - **deployment_id** (string, path, required): Identifier for the Deployment. - **resource_kind** (string, path, required): The kind of resource (one of elasticsearch, kibana, apm, or integrations_server). - **ref_id** (string, path, required): User-specified RefId for the Resource (or '_main' if there is only one). ### Responses #### 202 - The start maintenance command was issued successfully. Empty response body #### 403 - The start maintenance mode command was prohibited for the given Resource. (code: `deployments.instance_update_prohibited_error`) The start maintenance mode command was prohibited for the given Resource. (code: `deployments.instance_update_prohibited_error`) #### 404 - * 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`) * 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`) #### 500 - A Resource that was previously stored no longer exists. (code: `deployments.deployment_resource_no_longer_exists`) A Resource that was previously stored no longer exists. (code: `deployments.deployment_resource_no_longer_exists`) ### Example Usage ```bash curl -X POST "https://api.example.com/deployments/{deployment_id}/{resource_kind}/{ref_id}/instances/maintenance-mode/_start" ``` ``` -------------------------------- ### GET /deployments/{deployment_id}/tags Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json Returns the tags for a Deployment. ```markdown ### Parameters - **deployment_id** (string, path, required): Identifier for the Deployment ### Responses #### 200 - The deployment tags were successfully returned Empty response body #### 404 - The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`) The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`) ### Example Usage ```bash curl -X GET "https://api.example.com/deployments/{deployment_id}/tags" ``` ``` -------------------------------- ### GET /deployments/{deployment_id} Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json Retrieves information about a Deployment. ```markdown ### Parameters - **deployment_id** (string, path, required): Identifier for the Deployment - **show_security** (string, query, optional): Whether to include the Elasticsearch 2.x security information in the response - can be large per cluster and also include credentials - **show_metadata** (string, query, optional): Whether to include the full cluster metadata in the response - can be large per cluster and also include credentials - **show_plans** (string, query, optional): Whether to include the full current and pending plan information in the response - can be large per cluster - **show_plan_logs** (string, query, optional): Whether to include with the current and pending plan information the attempt log - can be very large per cluster - **show_plan_history** (string, query, optional): 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`. - **show_plan_defaults** (string, query, optional): If showing plans, whether to show values that are left at their default value (less readable but more informative) - **convert_legacy_plans** (string, query, optional): 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') - **show_system_alerts** (string, query, optional): 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. - **show_settings** (string, query, optional): Whether to show cluster settings in the response. - **show_instance_metrics** (string, query, optional): Whether to show resources instance metrics in the response. - **show_instance_configurations** (string, query, optional): If true, will return details for each instance configuration referenced by the deployment. - **enrich_with_template** (string, query, optional): If showing plans, whether to enrich the plan by including the missing elements from the deployment template it is based on - **force_all_plan_history** (string, query, optional): Force show the entire plan history no matter how long. As noted in the `show_plan_history` parameter description, by default, a maximum of 100 plans are shown per resource. If `true`, this parameter overrides the default, and ALL plans are returned. Use with care as the plan history can be VERY large. Consider pairing with `show_plan_logs=false`. - **clear_transient** (string, query, optional): If set (defaults to false) then removes the transient section from all child resources, making it safe to reapply via an update ### Responses #### 200 - The Deployment info response Empty response body #### 401 - You are not authorized to perform this action. You are not authorized to perform this action. #### 404 - The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`) The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`) ### Example Usage ```bash curl -X GET "https://api.example.com/deployments/{deployment_id}?show_security=value&show_metadata=value&show_plans=value&show_plan_logs=value&show_plan_history=value&show_plan_defaults=value&convert_legacy_plans=value&show_system_alerts=value&show_settings=value&show_instance_metrics=value&show_instance_configurations=value&enrich_with_template=value&force_all_plan_history=value&clear_transient=value" ``` ``` -------------------------------- ### POST /deployments/{deployment_id}/{resource_kind}/{ref_id}/instances/{instance_ids}/maintenance-mode/_start Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json Starts maintenance mode of instances belonging to a Deployment Resource. ```markdown ### Parameters - **deployment_id** (string, path, required): Identifier for the Deployment. - **resource_kind** (string, path, required): The kind of resource (one of elasticsearch, kibana, apm, or integrations_server). - **ref_id** (string, path, required): User-specified RefId for the Resource (or '_main' if there is only one). - **instance_ids** (string, path, required): A comma-separated list of instance identifiers. - **ignore_missing** (string, query, optional): If true and the instance does not exist then quietly proceed to the next instance, otherwise treated as an error. ### Responses #### 202 - The start maintenance command was issued successfully. Empty response body #### 403 - The start maintenance mode command was prohibited for the given Resource. (code: `deployments.instance_update_prohibited_error`) The start maintenance mode command was prohibited for the given Resource. (code: `deployments.instance_update_prohibited_error`) #### 404 - * 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`) * 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`) #### 500 - A Resource that was previously stored no longer exists. (code: `deployments.deployment_resource_no_longer_exists`) A Resource that was previously stored no longer exists. (code: `deployments.deployment_resource_no_longer_exists`) ### Example Usage ```bash curl -X POST "https://api.example.com/deployments/{deployment_id}/{resource_kind}/{ref_id}/instances/{instance_ids}/maintenance-mode/_start?ignore_missing=value" ``` ``` -------------------------------- ### POST /deployments/{deployment_id}/elasticsearch/{ref_id}/_restart Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json 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. ```markdown ### Parameters - **deployment_id** (string, path, required): Identifier for the Deployment. - **ref_id** (string, path, required): User-specified RefId for the Resource (or '_main' if there is only one). - **restore_snapshot** (string, query, optional): When set to true and restoring from shutdown, then will restore the cluster from the last snapshot (if available). - **skip_snapshot** (string, query, optional): If true, will not take a snapshot of the cluster before restarting. - **cancel_pending** (string, query, optional): If true, cancels any pending plans before restarting. If false and there are pending plans, returns an error. - **group_attribute** (string, query, optional): 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 - **shard_init_wait_time** (string, query, optional): The time, in seconds, to wait for shards that show no progress of initializing, before rolling the next group (default: 10 minutes) ### Responses #### 202 - The restart command was issued successfully. Empty response body #### 404 - * 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 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`) #### 422 - 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`) 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`) #### 500 - A Resource that was previously stored no longer exists. (code: `deployments.deployment_resource_no_longer_exists`) A Resource that was previously stored no longer exists. (code: `deployments.deployment_resource_no_longer_exists`) ### Example Usage ```bash curl -X POST "https://api.example.com/deployments/{deployment_id}/elasticsearch/{ref_id}/_restart?restore_snapshot=value&skip_snapshot=value&cancel_pending=value&group_attribute=value&shard_init_wait_time=value" ``` ``` -------------------------------- ### GET /deployments/{deployment_id}/elasticsearch/{ref_id}/snapshot/repository Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json Lists all the snapshot repositories this deployment has access to. These are snapshot repositories of other deployments that have been linked to this deployment. ```markdown ### Parameters - **deployment_id** (string, path, required): Identifier for the Deployment - **ref_id** (string, path, required): User-specified RefId for the Resource (or '_main' if there is only one) ### Responses #### 200 - List of snapshot repositories for this deployment Empty response body #### 404 - * 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 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`) #### 500 - We have failed you. (code: `deployments.metadata_internal_error`) We have failed you. (code: `deployments.metadata_internal_error`) ### Example Usage ```bash curl -X GET "https://api.example.com/deployments/{deployment_id}/elasticsearch/{ref_id}/snapshot/repository" ``` ``` -------------------------------- ### GET /deployments/{deployment_id}/elasticsearch/{ref_id}/keystore Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json Fetches the current fields and metadata (but not the values) of the keystore for the Elasticsearch resource. ```markdown ### Parameters - **deployment_id** (string, path, required): Identifier for the Deployment - **ref_id** (string, path, required): User-specified RefId for the Resource (or '_main' if there is only one) ### Responses #### 200 - The contents of the Elasticsearch keystore, with values redacted Empty response body #### 404 - * 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 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`) #### 500 - We have failed you. (code: `deployments.metadata_internal_error`) We have failed you. (code: `deployments.metadata_internal_error`) ### Example Usage ```bash curl -X GET "https://api.example.com/deployments/{deployment_id}/elasticsearch/{ref_id}/keystore" ``` ``` -------------------------------- ### GET /billing/costs/{organization_id}/deployments/{deployment_id}/charts Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json Retrieves the usage charts for the given deployment. ```markdown ### Parameters - **organization_id** (string, path, required): Identifier for the organization - **deployment_id** (string, path, required): Id of a Deployment - **from** (string, query, optional): A datetime for the beginning of the desired range for which to fetch costs. Defaults to start of current month. - **to** (string, query, optional): A datetime for the end of the desired range for which to fetch costs. Defaults to the current date. - **bucketing_strategy** (string, query, optional): The desired bucketing strategy for the charts. Defaults to `daily`. ### Responses #### 200 - The usage charts of a deployment. Empty response body #### 400 - The specified date range is invalid. (code: `costs.invalid_date_range`) The specified date range is invalid. (code: `costs.invalid_date_range`) #### 403 - The current user does not have access to the requested organization. (code: `organization.invalid_access`) The current user does not have access to the requested organization. (code: `organization.invalid_access`) #### 404 - Organization not found. (code: `organization.not_found`) Organization not found. (code: `organization.not_found`) #### 429 - Too many requests. (code: `billing_service.rate_limited`) Too many requests. (code: `billing_service.rate_limited`) #### 500 - Error fetching the itemized costs for the organization. (code: `billing_service.failed_request`) Error fetching the itemized costs for the organization. (code: `billing_service.failed_request`) ### Example Usage ```bash curl -X GET "https://api.example.com/billing/costs/{organization_id}/deployments/{deployment_id}/charts?from=value&to=value&bucketing_strategy=value" ``` ``` -------------------------------- ### GET /deployments/{deployment_id}/migrate_template Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json Returns a deployment update request that would migrate this deployment to a different template. ```markdown ### Parameters - **deployment_id** (string, path, required): Identifier for the Deployment - **template_id** (string, query, required): The ID of the deployment template to migrate to - **skip_instance_metrics_check** (string, query, optional): If true, will skip the instance metrics check for memory and disk usage calculations ### Responses #### 200 - The request was valid and the deployment can be migrated to the template with the provided ID. Empty response body #### 400 - The deployment cannot be successfully migrated to the template with the provided ID. The deployment cannot be successfully migrated to the template with the provided ID. #### 401 - You are not authorized to perform this action. You are not authorized to perform this action. #### 404 - The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`) The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`) ### Example Usage ```bash curl -X GET "https://api.example.com/deployments/{deployment_id}/migrate_template?template_id=value&skip_instance_metrics_check=value" ``` ``` -------------------------------- ### GET /stack/versions Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json By default, retrieves only the available Elastic Stack versions. To retrieve all of the Elastic Stack versions, use the `show_deleted parameter`. ```markdown ### Parameters - **show_deleted** (string, query, optional): Whether to show deleted stack versions or not - **show_unusable** (string, query, optional): Whether to show versions that are unusable by the authenticated user ### Responses #### 200 - The list of all available Elastic Stack versions are retrieved, including the template version and structure. Empty response body ### Example Usage ```bash curl -X GET "https://api.example.com/stack/versions?show_deleted=value&show_unusable=value" ``` ``` -------------------------------- ### GET /trusted-environments Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json Returns the list of trusted environments for the organization. If no organization is passed in, the organization attached to the user is assumed. ```markdown ### Responses #### 200 - Trusted environments for this organization Empty response body #### 404 - Organization not found. (code: `organization.not_found`) Organization not found. (code: `organization.not_found`) ### Example Usage ```bash curl -X GET "https://api.example.com/trusted-environments" ``` ``` -------------------------------- ### GET /organizations/{organization_id}/domains Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json Get domain claims for the organization. ```markdown ### Parameters - **organization_id** (string, path, required): Identifier for the Organization ### Responses #### 200 - The claimed domains for the organization Empty response body #### 404 - Organization not found. (code: `organization.not_found`) Organization not found. (code: `organization.not_found`) ### Example Usage ```bash curl -X GET "https://api.example.com/organizations/{organization_id}/domains" ``` ``` -------------------------------- ### POST /deployments Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json Creates a Deployment. ```markdown ### Parameters - **request_id** (string, query, optional): 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) - **validate_only** (string, query, optional): If true, will just validate the Deployment definition but will not perform the creation - **template_id** (string, query, optional): 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. - **body** (DeploymentCreateRequest, body, required): The deployment definition ### Responses #### 200 - The request was valid (used when validate_only is true). Empty response body #### 201 - The request was valid and a new deployment was created Empty response body #### 202 - The request was valid and deployment creation had already been started. Empty response body #### 400 - The deployment request had errors. The deployment request had errors. #### 401 - You are not authorized to perform this action. You are not authorized to perform this action. ### Example Usage ```bash curl -X POST "https://api.example.com/deployments?request_id=value&validate_only=value&template_id=value" ``` ``` -------------------------------- ### GET /organizations/{organization_id}/role_mappings Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json Gets the organization role mappings. Currently unavailable in self-hosted ECE. ```markdown ### Parameters - **organization_id** (string, path, required): Identifier for the Organization ### Responses #### 200 - The IdP info Empty response body #### 404 - Organization not found. (code: `organization.not_found`) Organization not found. (code: `organization.not_found`) ### Example Usage ```bash curl -X GET "https://api.example.com/organizations/{organization_id}/role_mappings" ``` ``` -------------------------------- ### GET /organizations/{organization_id}/idp Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json Gets the oranization's IdP. Currently unavailable in self-hosted ECE. ```markdown ### Parameters - **organization_id** (string, path, required): Identifier for the Organization ### Responses #### 200 - The IdP info Empty response body #### 404 - IdP was not configured yet. (code: `org.idp.idp_not_configured`) IdP was not configured yet. (code: `org.idp.idp_not_configured`) ### Example Usage ```bash curl -X GET "https://api.example.com/organizations/{organization_id}/idp" ``` ``` -------------------------------- ### POST /deployments/extensions Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json 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. ```markdown ### Parameters - **body** (CreateExtensionRequest, body, required): the data that creates the extension ### Responses #### 201 - The extension that was just created. Empty response body #### 400 - Could not download the extension from the specified URL. (code: `extensions.request_execution_failed`) Could not download the extension from the specified URL. (code: `extensions.request_execution_failed`) #### 404 - Your current session does not have a user id associated with it. (code: `extensions.no_user_id`) Your current session does not have a user id associated with it. (code: `extensions.no_user_id`) #### 409 - An extension already exists with the generated id. Please try again. (code: `extensions.id_already_exists`) An extension already exists with the generated id. Please try again. (code: `extensions.id_already_exists`) ### Example Usage ```bash curl -X POST "https://api.example.com/deployments/extensions" ``` ``` -------------------------------- ### GET /deployments/{deployment_id}/kibana/{ref_id} Source: https://api.elastic-cloud.com/api/v1/api-docs-user/swagger.json Get info about a Kibana Resource belonging to a given Deployment. ```markdown ### Parameters - **deployment_id** (string, path, required): Identifier for the Deployment - **ref_id** (string, path, required): User-specified RefId for the Resource (or '_main' if there is only one). - **show_metadata** (string, query, optional): Whether to include the full cluster metadata in the response - can be large per cluster and also include credentials. - **show_plans** (string, query, optional): Whether to include the full current and pending plan information in the response - can be large per cluster. - **show_plan_logs** (string, query, optional): Whether to include with the current and pending plan information the attempt log - can be very large per cluster. - **show_plan_history** (string, query, optional): Whether to include with the current and pending plan information the plan history- can be very large per cluster. - **show_plan_defaults** (string, query, optional): If showing plans, whether to show values that are left at their default value (less readable but more informative). - **convert_legacy_plans** (string, query, optional): 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'). - **show_settings** (string, query, optional): Whether to show cluster settings in the response. - **clear_transient** (string, query, optional): If set (defaults to false) then removes the transient section from all child resources, making it safe to reapply via an update ### Responses #### 200 - Standard response. Empty response body #### 404 - The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`) The Deployment specified by {deployment_id} cannot be found. (code: `deployments.deployment_not_found`) #### 500 - We have failed you. (code: `deployments.deployment_resource_no_longer_exists`) We have failed you. (code: `deployments.deployment_resource_no_longer_exists`) ### Example Usage ```bash curl -X GET "https://api.example.com/deployments/{deployment_id}/kibana/{ref_id}?show_metadata=value&show_plans=value&show_plan_logs=value&show_plan_history=value&show_plan_defaults=value&convert_legacy_plans=value&show_settings=value&clear_transient=value" ``` ```