Archive an empty workflow folder with workspace write access. recursive=true also archives its subfolders and workflows, stopping the archived workflows' triggers and hosted surfaces. Use Restore workflow to recover workflows.
OAuth scope: api:write.
/api/v2/workflows/foldersYour Sim API key, personal or workspace-scoped. Generate one under Settings, then API Keys. Operations that reject workspace keys say so in their own description.
In: header
Request examples use an API key. For OAuth, replace the X-API-Key header with Authorization: Bearer YOUR_ACCESS_TOKEN.
curl -X DELETE "https://www.sim.ai/api/v2/workflows/folders?workspaceId=string&path=string" \ -H "X-API-Key: YOUR_API_KEY"{
"data": {
"path": "/Operations",
"deleted": true,
"deletedItems": {
"folders": 1,
"workflows": 0
}
}
}{
"error": {
"code": "BAD_REQUEST",
"message": "Invalid request"
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "Authentication required"
}
}{
"error": {
"code": "FORBIDDEN",
"message": "Insufficient workspace permissions",
"details": {
"code": "INSUFFICIENT_WORKSPACE_ROLE"
}
}
}{
"error": {
"code": "NOT_FOUND",
"message": "Not found"
}
}{
"error": {
"code": "CONFLICT",
"message": "The request conflicts with current resource state"
}
}{
"error": {
"code": "PAYLOAD_TOO_LARGE",
"message": "Request body is too large"
}
}{
"error": {
"code": "LOCKED",
"message": "Workflow is locked"
}
}{
"error": {
"code": "RATE_LIMITED",
"message": "API rate limit exceeded",
"details": {
"retryAfter": "2026-01-01T00:00:30.000Z"
}
}
}{
"error": {
"code": "INTERNAL_ERROR",
"message": "Internal server error"
}
}{
"error": {
"code": "SERVICE_UNAVAILABLE",
"message": "Service temporarily unavailable"
}
}Query parameters
Workspace containing the folder.
1 <= length <= 128Path of the folder to delete.
length <= 4096Delete the folder's contents and nested folders too. Required for a non-empty folder. Only the listed case-sensitive spellings are accepted.
"false""true" | "1" | "yes" | "on" | "y" | "enabled" | "false" | "0" | "no" | "off" | "n" | "disabled"Response body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json