Skip to main content
DELETE
/
workflows
/
{workflow_id}
cURL
curl -X DELETE \
  -H 'Authorization: Bearer $API_KEY' \
  -H 'Accept: application/json' \
  '$BASE_URL/workflows/$workflow_id'
import requests

headers = {
'x-api-key': '<YOUR_API_KEY>',
'Authorization': 'Bearer <YOUR_JWT_TOKEN>',
'Accept': 'application/json'
}
resp = requests.delete(f"https://example.com/workflows/{workflow_id}", headers=headers)
print(resp.status_code, resp.text)
fetch(`https://example.com/workflows/${workflow_id}`, {
method: 'DELETE',
headers: {
'x-api-key': '<YOUR_API_KEY>',
'Authorization': 'Bearer <YOUR_JWT_TOKEN>',
'Accept': 'application/json'
}
}).then(async res => {
console.log(res.status);
console.log(await res.text());
}).catch(err => console.error(err));
// Using HttpClient
HttpClient client = new HttpClient();
client.DefaultRequestHeaders.Add("x-api-key", "<YOUR_API_KEY>");
client.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Bearer", "<YOUR_JWT_TOKEN>");

var response = await client.DeleteAsync($"https://example.com/workflows/{workflow_id}");
string content = await response.Content.ReadAsStringAsync();
Console.WriteLine(response.StatusCode);
Console.WriteLine(content);
{
  "workflow": {
    "id": "123e4567-e89b-12d3-a456-426614174000",
    "name": "Deleted Workflow",
    "status": "removed",
    "deleted_at": "2024-12-31T00:00:00Z"
  }
}
{
"description": "Bad Request. Possibly invalid workflow_id format."
}
{
"description": "Unauthorized. The Bearer token or API key is invalid or missing."
}
{
"description": "Forbidden. The user does not have permission to delete this workflow."
}
{
"description": "Not Found. The workflow with the given ID was not found."
}
{
"description": "Internal Server Error. Something went wrong on the server."
}

Headers

x-api-key
string
required

Your API key. This is required by most endpoints to access the API programmatically. You can view your x-api-key using the 'Profile' tab on the website.

Authorization
string
required

Bearer token for authentication (JWT).

Path Parameters

workflow_id
string<uuid>
required

The UUID of the workflow you want to delete.

Response

Successful Deletion. The server returns a JSON body about the removed workflow.

workflow
object

The deleted workflow object or confirmation details.