# Search Deployments **POST /deployments/_search** Retrieves the information for all of the deployments that match the specified query. ## Servers - https://api.elastic-cloud.com/api/v1: https://api.elastic-cloud.com/api/v1 () ## Parameters ### Query parameters - **minimal_metadata** (string) 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. ### Body: application/json (object) (Optional) The search query to run. When not specified, all of the deployments are matched. - **from** (integer(int32)) Deprecated, use cursor for a more scalable approach to paging. - **cursor** (string) 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** (integer(int32)) The maximum number of search results to return. - **query** (object) The container for all of the allowed Elasticsearch queries. Specify only one property each time. - **sort** (array[object]) An array of fields to sort the search results by. Defaults to query rank and last modified date descending. ## Responses ### 200 The list of deployments that match the specified query and belong to the authenticated user. #### Headers - **x-cloud-resource-version** (string) The resource version, which is used to avoid update conflicts with concurrent operations - **x-cloud-resource-created** (string) The date-time when the resource was created (ISO format relative to UTC) - **x-cloud-resource-last-modified** (string) The date-time when the resource was last modified (ISO format relative to UTC) #### Body: application/json (object) - **return_count** (integer(int32)) The number of deployments actually returned, either as deployment instances or as minimalMetadata objects - **match_count** (integer(int32)) If a query is supplied, then the total number of deployments that matched - **deployments** (array[object]) - **minimal_metadata** (array[object]) - **cursor** (string) 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. [Powered by Bump.sh](https://bump.sh)