---
title: "Build Project Directory Translation"
method: POST
path: "/projects/{projectId}/translations/builds/directories/{directoryId}"
tags: ["Translations"]
---

# Build Project Directory Translation

`POST /projects/{projectId}/translations/builds/directories/{directoryId}`

## Request

- Base URL: `https://api.crowdin.com/api/v2`
- URL: `https://api.crowdin.com/api/v2/projects/{projectId}/translations/builds/directories/{directoryId}`
- Auth: none declared
- TypeScript: <https://skmtc.dev/crowdin/apis/crowdin-enterprise-api-v2/docs/projects/:projectId/translations/builds/directories/:directoryId/post.ts> (a function with typed inputs; its response is checked against the schema)

**Required scopes:** `project.source.file` (Read only).

## Path parameters

- `projectId` integer, required
- `directoryId` integer, required

## Request body

- EnterpriseTranslationCreateDirectoryBuildForm
  - `targetLanguageIds` string[]: Specify target languages for build. Get via [List Supported Languages](#operation/api.languages.getMany) * Leave this field empty to build all target languages
  - `skipUntranslatedStrings` boolean: Defines whether to export only translated strings __Note:__ `true` value can't be used with `skipUntranslatedFiles=true` in same request
  - `skipUntranslatedFiles` boolean: Defines whether to export only translated files __Note:__ `true` value can't be used with `skipUntranslatedStrings=true` in same request
  - `exportWithMinApprovalsCount` integer: Defines whether to export only approved strings __Note:__ value greater than `0` can't be used with `exportStringsThatPassedWorkflow=true` in same request
  - `exportStringsThatPassedWorkflow` boolean: Defines whether to export only strings that passed workflow __Note:__ `true` value can't be used with `exportWithMinApprovalsCount>0` in same request or in projects without an assigned workflow
  - `preserveFolderHierarchy` boolean: Preserve folder hierarchy

## Response `201`

Directory build was successfully started

- EnterpriseTranslationDirectoryBuildResource: Base schema of resource container. Container is a wrapper object that contains payload in required `data` property and provides space for adding any other metadata.
  - `data` EnterpriseDirectoryBuildResponse, required
    - `id` integer
    - `projectId` integer
    - `status` 'created' | 'inProgress' | 'canceled' | 'failed' | 'finished'
    - `progress` integer: in percentages
    - `createdAt` string, date-time, nullable
    - `updatedAt` string, date-time, nullable
    - `finishedAt` string, date-time, nullable
    - `attributes` EnterpriseDirectoryBuildAttributesResponseModel
      - `directoryId` integer, nullable
      - `targetLanguageIds` string[]
      - `skipUntranslatedStrings` boolean
      - `skipUntranslatedFiles` boolean
      - `exportWithMinApprovalsCount` integer
      - `exportStringsThatPassedWorkflow` boolean

## Other responses

- `400`: Invalid Request Parameters
- `401`: Unauthorized
- `403`: Forbidden
- `404`: Project, directory, or language with specified id was not found
- `405`: Method Not Allowed
- `500`: Internal Server Error
- `503`: Service Unavailable

---

[API](https://skmtc.dev/crowdin/apis/crowdin-enterprise-api-v2.md) - [All operations](https://skmtc.dev/crowdin/apis/crowdin-enterprise-api-v2/llms.txt) - [OpenAPI document](https://skmtc.dev/crowdin/apis/crowdin-enterprise-api-v2/revisions/dc68744c5384?raw)
