This version of the OpenSearch documentation is no longer maintained. For the latest version, see the current documentation. For information about OpenSearch version maintenance, see Release Schedule and Maintenance Policy.
Delete script
Deletes a stored script
Path parameters
Path parameters are optional.
Parameter | Data type | Description |
---|---|---|
script-id | String | ID of script to delete. |
Query parameters
Parameter | Data type | Description |
---|---|---|
cluster_manager_timeout | Time | Amount of time to wait for a connection to the cluster manager. Optional, defaults to 30s . |
timeout | Time | The period of time to wait for a response. If a response is not received before the timeout value, the request will be dropped. |
Example request
The following request deletes the my-first-script
script:
DELETE _scripts/my-script
copy
Example response
The DELETE _scripts/my-first-script
request returns the following field:
{
"acknowledged" : true
}
To determine whether the stored script was successfully deleted, use the Get stored script API, passing the script name as the script
path parameter.
Response fields
The request returns the following response fields:
Field | Data type | Description |
---|---|---|
acknowledged | Boolean | Whether the delete script request was received. |
当前内容版权归 OpenSearch 或其关联方所有,如需对内容或内容相关联开源项目进行关注与资助,请访问 OpenSearch .