CreateParallelData - Amazon Translate API Reference

CreateParallelData

Creates a parallel data resource in Amazon Translate by importing an input file from Amazon S3. Parallel data files contain examples that show how you want segments of text to be translated. By adding parallel data, you can influence the style, tone, and word choice in your translation output.

Request Syntax

{ "ClientToken": "string", "Description": "string", "EncryptionKey": { "Id": "string", "Type": "string" }, "Name": "string", "ParallelDataConfig": { "Format": "string", "S3Uri": "string" }, "Tags": [ { "Key": "string", "Value": "string" } ] }

Request Parameters

For information about the parameters that are common to all actions, see Common Parameters.

The request accepts the following data in JSON format.

ClientToken

A unique identifier for the request. This token is automatically generated when you use Amazon Translate through an AWS SDK.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 64.

Pattern: ^[a-zA-Z0-9-]+$

Required: Yes

Description

A custom description for the parallel data resource in Amazon Translate.

Type: String

Length Constraints: Maximum length of 256.

Pattern: [\P{M}\p{M}]{0,256}

Required: No

EncryptionKey

The encryption key used to encrypt this object.

Type: EncryptionKey object

Required: No

Name

A custom name for the parallel data resource in Amazon Translate. You must assign a name that is unique in the account and region.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 256.

Pattern: ^([A-Za-z0-9-]_?)+$

Required: Yes

ParallelDataConfig

Specifies the format and S3 location of the parallel data input file.

Type: ParallelDataConfig object

Required: Yes

Tags

Tags to be associated with this resource. A tag is a key-value pair that adds metadata to a resource. Each tag key for the resource must be unique. For more information, see Tagging your resources in the Amazon Translate Developer Guide.

Type: Array of Tag objects

Array Members: Minimum number of 0 items. Maximum number of 200 items.

Required: No

Response Syntax

{ "Name": "string", "Status": "string" }

Response Elements

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in JSON format by the service.

Name

The custom name that you assigned to the parallel data resource.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 256.

Pattern: ^([A-Za-z0-9-]_?)+$

Status

The status of the parallel data resource. When the resource is ready for you to use, the status is ACTIVE.

Type: String

Valid Values: CREATING | UPDATING | ACTIVE | DELETING | FAILED

Errors

For information about the errors that are common to all actions, see Common Errors.

ConcurrentModificationException

Another modification is being made. That modification must complete before you can make your change.

HTTP Status Code: 400

ConflictException

There was a conflict processing the request. Try your request again.

HTTP Status Code: 400

InternalServerException

An internal server error occurred. Retry your request.

HTTP Status Code: 500

InvalidParameterValueException

The value of the parameter is not valid. Review the value of the parameter you are using to correct it, and then retry your operation.

HTTP Status Code: 400

InvalidRequestException

The request that you made is not valid. Check your request to determine why it's not valid and then retry the request.

HTTP Status Code: 400

LimitExceededException

The specified limit has been exceeded. Review your request and retry it with a quantity below the stated limit.

HTTP Status Code: 400

TooManyRequestsException

You have made too many requests within a short period of time. Wait for a short time and then try your request again.

HTTP Status Code: 400

TooManyTagsException

You have added too many tags to this resource. The maximum is 50 tags.

HTTP Status Code: 400

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following: