Delete a file from an existing path
File Mutation
Delete file
Deletes a file or directory at the specified path in a workspace.
Requirements:
- The
ref_idmust be a workspace ID - Requires a client ID header
Behavior: The deletion is recorded in the workspace’s draft commit and can be reverted before committing.
Returns:
404 Not Foundif the path doesn’t exist202 Acceptedon successful deletion
DELETE
Delete a file from an existing path
Documentation Index
Fetch the complete documentation index at: https://docs.diversion.dev/llms.txt
Use this file to discover all available pages before exploring further.
Authorizations
This API uses OAuth 2 with the implicit grant flow
Headers
The unique id of the client making this request
Path Parameters
The repo ID of the repository. Repo name can be used instead of the ID, but usage of ID for permanent linking and API requests is preferred.
Required string length:
3 - 128Example:
"example_id"
An ID of a workspace, branch or commit.
Required string length:
3 - 128Example:
"example_id"
A path to a file inside the repository.
Example:
"/path/to/file"
Response
File deleted

