POST/v2/projects/{projectId}/tasks

Create a task

Creates a task for a project using the specified language, keys, assignees, and task type. Set type to TRANSLATE or REVIEW, and use the query filters to determine which keys are included. The task name, branch, and due date can also be supplied.

  • IdempotentThe SDK sends Idempotency-Key, so a retried request is only applied once.

6 parameters · 8 body fields
projectIdintegerrequired
The int64 identifier of the project in which to create the task.
filterStatearray<string>optional
Include keys with translations in these states: UNTRANSLATED, TRANSLATED, REVIEWED, or DISABLED.
filterOutdatedbooleanoptional
Whether to include keys whose translation is outdated.
filterTaskInStatusarray<string>optional
Filter by task membership using `taskType,status`. Status must be IN_OPEN_TASK, NOT_IN_OPEN_TASK, HAS_BEEN_IN_TASK, or NEVER_IN_TASK; task membership is evaluated for the task language, and conditions for different task types are combined with AND.
filterHasSuggestionsbooleanoptional
Whether to include only keys with an active suggestion in the task language.
filterHasNoSuggestionsbooleanoptional
Whether to include only keys without an active suggestion in the task language.

Task details, including its assignees, description, keys, language, and task type.

assigneesarray<integer>required
Set of user IDs assigned to the task.
branchstringoptional
Branch name. If empty or null, default branch is used.
descriptionstringrequired
Task description, from 0 to 2000 characters.
dueDateintegeroptional
Due to date in epoch format (milliseconds).
keysarray<integer>required
Set of key IDs included in the task.
languageIdintegerrequired
Id of language, this task is attached to.
namestringoptional
Task name, from 3 to 255 characters.
typestringrequired
Task type: TRANSLATE or REVIEW.
Allowed:TRANSLATEREVIEW

5 status codes
200Returns the created task, including its task number, state, language, assignees, description, item counts, and task type.
agencyobjectoptional
assigneesarray<object>required
authorobjectoptional
baseCharacterCountintegerrequired
baseWordCountintegerrequired
branchNamestringoptional
closedAtintegeroptional
createdAtintegeroptional
descriptionstringrequired
doneItemsintegerrequired
dueDateintegeroptional
languageobjectrequired
namestringoptional
numberintegerrequired
originBranchNamestringoptional
statestringrequired
Allowed:NEWIN_PROGRESSFINISHEDCANCELED
totalItemsintegerrequired
typestringrequired
Allowed:TRANSLATEREVIEW
400Returned when a required field is missing or a value fails validation, such as an invalid task type or name length.
codestringrequired
Allowed:unauthenticatedapi_access_forbiddenapi_key_not_foundinvalid_api_keyinvalid_project_api_keyproject_api_key_expiredbad_credentialsmfa_enabledinvalid_otp_codemfa_not_enabledcan_not_revoke_own_permissionsdata_corrupted
paramsarray<object>optional
401Returned when the request is not authenticated.
codestringrequired
Allowed:unauthenticatedapi_access_forbiddenapi_key_not_foundinvalid_api_keyinvalid_project_api_keyproject_api_key_expiredbad_credentialsmfa_enabledinvalid_otp_codemfa_not_enabledcan_not_revoke_own_permissionsdata_corrupted
paramsarray<object>optional
403Returned when the authenticated user is not permitted to create a task in the project.
codestringrequired
Allowed:unauthenticatedapi_access_forbiddenapi_key_not_foundinvalid_api_keyinvalid_project_api_keyproject_api_key_expiredbad_credentialsmfa_enabledinvalid_otp_codemfa_not_enabledcan_not_revoke_own_permissionsdata_corrupted
paramsarray<object>optional
404Returned when the project or a referenced resource cannot be found.
codestringrequired
Allowed:unauthenticatedapi_access_forbiddenapi_key_not_foundinvalid_api_keyinvalid_project_api_keyproject_api_key_expiredbad_credentialsmfa_enabledinvalid_otp_codemfa_not_enabledcan_not_revoke_own_permissionsdata_corrupted
paramsarray<object>optional

Error handling

A 400 is returned when the request is invalid; a 401 indicates missing or invalid authentication, and a 403 indicates access is denied. A 404 is returned when the project or a referenced resource cannot be found. The projectId path parameter must identify the project, and assignees, description, keys, languageId, and type are required; type must be TRANSLATE or REVIEW, and name must be 3 to 255 characters when provided.