---
title: "Add Source File Version"
method: POST
path: "/tasks/{taskId}/source-files/{sourceFileId}/versions"
tags: ["Source File"]
---

# Add Source File Version

`POST /tasks/{taskId}/source-files/{sourceFileId}/versions`

Adds a new version of the source file in [BCM](../../BCM/BCM.NET_client_API.html) or native format. More information about file formats can be found on the [File formats](../docs/File-formats.html) page.

The version is added on the task represented by `taskId`. To successfully  execute the add operation the task should already be assigned and accepted by a user. If the task is automatic, it's possible to add a source file version only when the status of task is `inProgress`.

The file versions added need to respect the output file type declared by the task type of the enclosing task. On the [Rules for sequencing tasks correctly](https://docs.rws.com/791595/885137/trados-enterprise/rules-for-sequencing-tasks-correctly) page from the official RWS Documentation Center, you can find out what output file type is supported by each task.

For adding a source file version using an extension task, the configuration of the task must declare the `scope`'s value as "file".

If the file type of the new added file is different than the supported source file type, the new `fileTypeSettingsId` must be specified in the body or an update of file type should be performed after the add operation, using the [Update Source File Properties](#/operations/UpdateSourceProperties).

The value of `fileTypeSettingsId` is one of the identifiers listed by the [List File Type Settings](#/operations/ListFileTypeSettings) endpoint.

The [List File Type Settings](#/operations/ListFileTypeSettings) endpoint must be called with the File Processing Configuration identifier of your project.

The File Processing Configuration of your project can be retrieved from [Get Project](#/operations/GetProject) endpoint.

The multipart parameters in the body should respect and strictly follow the order specified in our documentation. 

Consider the [file and project size limit](https://docs.rws.com/791595/815967/trados-enterprise---accelerate/file-and-project-size-limit) when adding files.

## Query parameters

- `fields` string

## Headers

- `Authorization` string, required
- `X-LC-Tenant` string, required

## Response `201`

Created

- SourceFileVersionResponse
  - `id` string, required — The source file version identifier.
  - `type` 'native' | 'bcm' — <div style="display:inline; float:right; color:#008080; margin-top:-23px; font-size:11px">default</div><div style="display: inline;">The version type.</div>

## Other responses

- `400` — Error codes: * "invalid": invalid input in the query parameter mentioned in the “name” field on the error response. * "invalid": the provided document is not a valid BCM file. * "invalid": invalid file format * "multiPartOrder": the multipart order in body is not correct. `properties` must be the first, followed by `file`.
- `401` — The user could not be identified.
- `403` — Error codes: * "forbidden": the authenticated user is not allowed to read the resource.
- `404` — Error codes: * "notFound": \ \- the specified task or the source file was not found.\ \- the request is performed in a task that doesn't have the input file type as source file and is used a target file identifier.
- `409` — Error codes: * "noOwner": the task has no owner. * "differentOwner": the authenticated user is not the owner of the task. * "differentServiceUserOwner": the authenticated service user is not the owner of the task. * "taskCompleted": adding source file version is not allowed when the task is completed. * "unsupported" : you cannot add a source file version for this task. * "duplicate": a file with the same name already exists.

---

[API](https://skmtc.net/rws/apis/trados-cloud-platform-api.md) · [All operations](https://skmtc.net/rws/apis/trados-cloud-platform-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/rws/trados-cloud-platform-api/revisions/d42dac7c28a3/schema)
