# Delete custom operator

Delete a custom operator. Deletion is irreversible; please confirm that no workflow needs to use this operator before calling it.

```text
DELETE $CLOUDSIGMA_API_BASE/workflow/v2/custom-operators/$OPERATOR_ID
```

## Before you call this API

Configure the [regional API endpoint and authentication](https://omnifabric.cloudsigma.com/docs/developer/endpoints-and-authentication.html.md), and select the target workspace.

First [query custom operator details](https://omnifabric.cloudsigma.com/docs/reference/api/ai-studio/data-processing/custom-operators/get-custom-operator.html.md) to confirm the operator to be deleted.

## Request parameters

::::{div} mo-api-split
:::{div} mo-api-split-main

<dl class="mo-api-fields">

</dl>
:::
:::{div} mo-api-split-aside

<p class="mo-api-example-label">Request example</p>
```bash
curl -X DELETE "$CLOUDSIGMA_API_BASE/workflow/v2/custom-operators/$OPERATOR_ID" \
  -H "X-API-Key: $CLOUDSIGMA_API_KEY" \
  -H "X-Workspace-ID: $WORKSPACE_ID"
```

:::
::::

## Successful response

Response confirms that the operator has been deleted. After deletion, the operator can no longer be queried, modified or used.


The response fields are as follows.

::::{div} mo-api-split
:::{div} mo-api-split-main

<dl class="mo-api-fields">
  <div class="mo-api-field"><dt><code>code</code><span class="mo-api-field__type">string</span></dt><dd>OK on success.</dd></div>
  <div class="mo-api-field"><dt><code>msg</code><span class="mo-api-field__type">string</span></dt><dd>OK on success.</dd></div>
  <div class="mo-api-field"><dt><code>data.deleted</code><span class="mo-api-field__type">boolean</span></dt><dd>true when deleted successfully.</dd></div>
</dl>
:::
:::{div} mo-api-split-aside

<p class="mo-api-example-label">Successful response example</p>
```json
{
  "code": "OK",
  "msg": "OK",
  "data": {
    "deleted": true
  }
}
```

:::
::::

## Error response

::::{div} mo-api-split
:::{div} mo-api-split-main

<dl class="mo-api-fields">
  <div class="mo-api-field"><dt><code>code</code><span class="mo-api-field__type">string</span></dt><dd>Error code.</dd></div>
  <div class="mo-api-field"><dt><code>msg</code><span class="mo-api-field__type">string</span></dt><dd>Readable error message.</dd></div>
  <div class="mo-api-field"><dt><code>data</code><span class="mo-api-field__type">null</span></dt><dd>`null` in an error response.</dd></div>
</dl>
:::
:::{div} mo-api-split-aside

<p class="mo-api-example-label">Error response example</p>
```json
{
  "code": "ErrParamInvalid",
  "msg": "请求参数无效",
  "data": null
}
```

:::
::::

## Follow-up operations

[Query custom operator list](https://omnifabric.cloudsigma.com/docs/reference/api/ai-studio/data-processing/custom-operators/list-custom-operators.html.md), confirm that the target no longer appears.
