schadem-cdk-construct-textract-generic-async
Project description
Context
This CDK Construct can be used as Step Function task and call Textract in Asynchonous mode for DetectText and AnalyzeDocument APIs.
Input
Expects a Manifest JSON at 'Payload'.
Example call in Python
textract_async_task = t_async.TextractGenericAsyncSfnTask(
self,
"textract-async-task",
s3_output_bucket=s3_output_bucket,
s3_temp_output_prefix=s3_temp_output_prefix,
integration_pattern=sfn.IntegrationPattern.WAIT_FOR_TASK_TOKEN,
lambda_log_level="DEBUG",
timeout=Duration.hours(24),
input=sfn.TaskInput.from_object({
"Token":
sfn.JsonPath.task_token,
"ExecutionId":
sfn.JsonPath.string_at('$$.Execution.Id'),
"Payload":
sfn.JsonPath.entire_payload,
}),
result_path="$.textract_result")
Output
Adds the "TextractTempOutputJsonPath" to the Step Function ResultPath:
example with ResultPath = textract_result (like configured above):
"textract_result": {
"TextractTempOutputJsonPath": "s3://schademcdkstackpaystuban-schademcdkidpstackpaystu-bt0j5wq0zftu/textract-temp-output/c6e141e8f4e93f68321c17dcbc6bf7291d0c8cdaeb4869758604c387ce91a480"
}
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for schadem-cdk-construct-textract-generic-async-0.0.3.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | ef013612e00e4d7ebef6d452379139cbbf1d2751281dd5f7d16b8cadacf234c2 |
|
MD5 | 224adabc29a60746a50641e5118971f4 |
|
BLAKE2b-256 | ca3376e6a9cf38fe2bf29419efc56daf76107e9b95cda9cfdabe17fd7e243b55 |
Close
Hashes for schadem_cdk_construct_textract_generic_async-0.0.3-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ba52fd0df24f14e34f874fa4c3eca44fa936d9b51dd3163d170c4689aafb18ca |
|
MD5 | 945e1aded7deb40fbc06369b604395f9 |
|
BLAKE2b-256 | dd1ae8131ba9bafd7052b3795bea56f8f7bbf62c04d4df5bbd7ae70080b763ee |