/Docs
Search docs or ask a question⌘K
DocsAgent
Changelog
API Reference Delete Approval Gate

Delete Approval Gate

Delete an approval gate that has no pending approvals.

DELETE/v1/projects/{projectId}/approval-gates/{gateId}Try it
Session token

Delete a gate. Approvals already decided against it — approved or rejected — are deleted with it. A gate that still has pending approvals cannot be deleted: decide them first, or switch the gate off with enabled: false instead.

Note

Requires the admin or owner role, signed in with a session JWT — API keys are refused with 401. A member gets 403 forbidden with details.requiredRole: "admin" and details.currentRole — see Role errors. You must belong to the organization that owns {projectId}. Available on every plan.

Warning

Deleting a gate also deletes the history of every decided approval filed against it. Switch the gate off if you want to keep that history.

Path Parameters

NameDescription
projectId:stringpathRequired
The project ID.
gateId:stringpathRequired
The gate ID. A gate that belongs to another project returns 404.

Response — 200 OK

The response has no data field. The deletion is recorded in the audit log as approval_gate.delete.

Error Responses

401 Unauthorized

No session JWT, an expired one, or an API key.

403 Forbidden

forbidden — your role is below admin (details.requiredRole, details.currentRole), or you are not a member of the organization that owns the project.

404 Not Found

not_found — the project does not exist or was deleted, or the gate is not one of this project's.

409 Conflict

gate_in_use — approvals are still pending on the gate. details.pending is how many. Nothing was deleted.

json
{
"error": {
"code": "gate_in_use",
"message": "This gate has 2 pending approvals. Decide them or switch the gate off instead.",
"details": {
"pending": 2,
"traceId": "6f1c2a9e-3b7d-4c11-9a0e-2d5f8b4c7e10"
}
}
}
Was this page helpful? Yes No
Request
cURLJavaScriptPythonGoRubyPHPJavaC#cURL
curl -X DELETE https://api.syntext.dev/v1/projects/3f2a9c1e-8b4d-4e7a-9c21-5d6e7f8a9b0c/approval-gates/7c1e2f4a-9b3d-4e8a-a1c2-5d6f7e8a9b0c \
-H "Authorization: Bearer eyJhbGciOiJIUzI1NiIs..."
Responseapplication/json
200OK
{ "success": true }
Product
Resources
Company
© 2026 SyntextBuilt with Syntext