StartImportJob - Amazon Connect

StartImportJob

Start an asynchronous job to import Amazon Q in Connect resources from an uploaded source file. Before calling this API, use StartContentUpload to upload an asset that contains the resource data.

  • For importing Amazon Q in Connect quick responses, you need to upload a csv file including the quick responses. For information about how to format the csv file for importing quick responses, see Import quick responses.

Request Syntax

POST /knowledgeBases/knowledgeBaseId/importJobs HTTP/1.1 Content-type: application/json { "clientToken": "string", "externalSourceConfiguration": { "configuration": { ... }, "source": "string" }, "importJobType": "string", "metadata": { "string" : "string" }, "uploadId": "string" }

URI Request Parameters

The request uses the following URI parameters.

knowledgeBaseId

The identifier of the knowledge base. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • For importing Amazon Q in Connect quick responses, this should be a QUICK_RESPONSES type knowledge base.

Pattern: ^[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}$|^arn:[a-z-]*?:wisdom:[a-z0-9-]*?:[0-9]{12}:[a-z-]*?/[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}(?:/[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}){0,2}$

Required: Yes

Request Body

The request accepts the following data in JSON format.

clientToken

The tags used to organize, track, or control access for this resource.

Type: String

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

Required: No

externalSourceConfiguration

The configuration information of the external source that the resource data are imported from.

Type: ExternalSourceConfiguration object

Required: No

importJobType

The type of the import job.

  • For importing quick response resource, set the value to QUICK_RESPONSES.

Type: String

Valid Values: QUICK_RESPONSES

Required: Yes

metadata

The metadata fields of the imported Amazon Q in Connect resources.

Type: String to string map

Map Entries: Minimum number of 0 items. Maximum number of 10 items.

Key Length Constraints: Minimum length of 1. Maximum length of 4096.

Value Length Constraints: Minimum length of 1. Maximum length of 4096.

Required: No

uploadId

A pointer to the uploaded asset. This value is returned by StartContentUpload.

Type: String

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

Required: Yes

Response Syntax

HTTP/1.1 200 Content-type: application/json { "importJob": { "createdTime": number, "externalSourceConfiguration": { "configuration": { ... }, "source": "string" }, "failedRecordReport": "string", "importJobId": "string", "importJobType": "string", "knowledgeBaseArn": "string", "knowledgeBaseId": "string", "lastModifiedTime": number, "metadata": { "string" : "string" }, "status": "string", "uploadId": "string", "url": "string", "urlExpiry": number } }

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.

importJob

The import job.

Type: ImportJobData object

Errors

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

AccessDeniedException

You do not have sufficient access to perform this action.

HTTP Status Code: 403

ConflictException

The request could not be processed because of conflict in the current state of the resource. For example, if you're using a Create API (such as CreateAssistant) that accepts name, a conflicting resource (usually with the same name) is being created or mutated.

HTTP Status Code: 409

ResourceNotFoundException

The specified resource does not exist.

HTTP Status Code: 404

ServiceQuotaExceededException

You've exceeded your service quota. To perform the requested action, remove some of the relevant resources, or use service quotas to request a service quota increase.

HTTP Status Code: 402

ValidationException

The input fails to satisfy the constraints specified by a service.

HTTP Status Code: 400

See Also

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