Skip to content

Add support for asynchronous Branch, Directory and File deletion #270

Description

@crowdin-bot

The Crowdin API now supports asynchronous deletion of branches, directories, and files. The existing Delete endpoints accept an optional Prefer: respond-async request header (RFC 7240). When it is provided, the API responds with 202 Accepted and a delete job resource instead of 204 No Content, and new endpoints allow polling the job status.

New Check Delete Job Status endpoints:

  • Check Branch Deletion StatusGET /projects/{projectId}/branches/{branchId}/jobs/{jobIdentifier} (api.projects.branches.jobs.get) — file-based and string-based projects
  • Check Directory Deletion StatusGET /projects/{projectId}/directories/{directoryId}/jobs/{jobIdentifier} (api.projects.directories.jobs.get) — file-based projects only
  • Check File Deletion StatusGET /projects/{projectId}/files/{fileId}/jobs/{jobIdentifier} (api.projects.files.jobs.get) — file-based projects only

Updated endpoints (new optional Prefer header + 202 response): Delete Branch (api.projects.branches.delete), Delete Directory (api.projects.directories.delete), Delete File (api.projects.files.delete).

The job resource model includes: identifier (UUID string), status (created, in_progress, finished, failed), progress (integer, percent), attributes (contains branchId, directoryId, or fileId), error (object with message, present only when the operation failed), and createdAt/updatedAt/startedAt/finishedAt timestamps.

Client libraries should support the async deletion flow and the new job status methods. Available in both Crowdin and Crowdin Enterprise.

References:

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions