create_attached_file
¶
create_attached_file(
instance_id: InstanceId,
file_use_case_type: FileUseCaseType,
file_source_uri: FileSourceUri,
associated_resource_arn: ARN,
*,
config_overrides: Optional[ConnectClientConfig] = None,
client_token: Optional[ClientToken] = None,
tags: Optional[TagMap] = None,
) -> CreateAttachedFileResponse
Creates an attached file for a completed voice contact by copying a recording from a source S3 URI into Connect Customer managed storage. Use this API to attach voice recordings to contacts for downstream processing such as conversational analytics.
The AssociatedResourceArn must be the ARN of a completed voice contact, FileUseCaseType must be set to VOICE_RECORDING, and FileSourceUri must be a valid S3 URI.
For example, you can call CreateContact, then CreateAttachedFile, then StartContactConversationalAnalyticsJob to create a contact, attach a recording, and run post-call analytics.
Parameters:
-
client_token(Optional[ClientToken], default:None) –A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency, see Making retries safe with idempotent APIs.
-
instance_id(InstanceId) –The identifier of the Connect Customer instance. You can find the instance ID in the Amazon Resource Name (ARN) of the instance.
-
file_use_case_type(FileUseCaseType) –The use case for the file.
Only
VOICE_RECORDINGis supported. -
file_source_uri(FileSourceUri) –The S3 URI of the file to be attached. Only S3 source URIs are supported.
-
associated_resource_arn(ARN) –The ARN of the completed voice contact to attach the file to. Only voice contacts with Telephony subtype are supported.
This value must be a valid ARN.
-
tags(Optional[TagMap], default:None) –The tags used to organize, track, or control access for this resource. For example,
{ "Tags": {"key1":"value1", "key2":"value2"} }.
Raises:
-
AccessDeniedException–You do not have sufficient permissions to perform this action.
-
InternalServiceException–Request processing failed because of an error or failure with the service.
-
InvalidRequestException–The request is not valid.
-
ResourceConflictException–A resource already has that name.
-
ServiceQuotaExceededException–The service quota has been exceeded.
-
ThrottlingException–The throttling limit has been exceeded.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_connect/_services/connect.py
3322 3323 3324 3325 3326 3327 3328 3329 3330 3331 3332 3333 3334 3335 3336 3337 3338 3339 3340 3341 3342 3343 3344 3345 3346 3347 3348 3349 3350 3351 3352 3353 3354 3355 3356 3357 3358 3359 3360 3361 3362 3363 3364 3365 3366 3367 3368 3369 3370 3371 3372 3373 3374 3375 3376 3377 3378 3379 3380 3381 3382 3383 3384 3385 3386 3387 3388 | |