crowdin / crowdin/crowdin-api-client-dotnet

Add directoryIds and branchIds to Apply Pre-Translation

Closed
#405 0 comments 0 reactions 0 assignees View on GitHub
enhancement good first issue
Dominant language
C#
Stars
62
Forks
39
Avg merge
1d 6h
Merged PRs (30d)
11

Description

The **Apply Pre-Translation** method (`POST /projects/{projectId}/pre-translations`, `api.projects.pre-translations.post`) now supports pre-translating whole directories and branches in file-based projects, in both Crowdin and Crowdin Enterprise:

- New optional request fields `directoryIds` (array of integers) and `branchIds` (array of integers) — all nested files are included.
- `fileIds` is no longer required — it must be provided only when neither `directoryIds` nor `branchIds` is set.
- The pre-translation status/response attributes now also include `directoryIds` and `branchIds`.

Additionally, the path parameter of **Get Pre-Translation Status**, **Edit Pre-Translation**, and **Get Pre-Translation Report** was renamed from `preTranslationId` to `jobIdentifier` (`/projects/{projectId}/pre-translations/{jobIdentifier}`). This is not a wire change, but generated clients and method signatures may reflect the new name.

Client libraries should make `fileIds` optional and expose the new `directoryIds`/`branchIds` request and response fields.

**References:**
- [Apply Pre-Translation](https://support.crowdin.com/developer/api/v2/#operation/api.projects.pre-translations.post)
- [Get Pre-Translation Status](https://support.crowdin.com/developer/api/v2/#operation/api.projects.pre-translations.get)
- Crowdin Enterprise: [Apply Pre-Translation](https://support.crowdin.com/developer/enterprise/api/v2/#operation/api.projects.pre-translations.post)

Contributor guide

Open the contributing guide

Research direction

Start with the api.projects.pre-translations.post client entry point and the methods for getting status, editing, and reporting pre-translations. Update the request and response models and generated method signatures to reflect optional fileIds, directoryIds, branchIds, and jobIdentifier. Done means the Crowdin and Crowdin Enterprise API references are represented consistently by the .NET client.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
api
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.