capabilities.work

Delete a branch

One step with Harness. We can help you get access.

Get something done

Delete a branch

with Harness
Works with AI assistants

Use Harness: its Harness Repository API lets you delete a branch in a single step (DELETE /code/api/v1/repos/{repo_identifier}/branches/{branch_name}). Harness also has an MCP server, so an AI assistant like Claude or ChatGPT can do it for you. capabilities.work can help you get signed up and connected.

  • How do I delete a branch that's already been merged?
  • Can I bypass branch rules when deleting a protected branch?
Say it to your AI assistant
  • Delete branch {branch} from repository {repo}.
  • Remove the {branch} branch in repo {repo}.
For your developer

DELETE /code/api/v1/repos/{repo_identifier}/branches/{branch_name} in Harness Repository API. Full spec on APIs.io.