Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stepfunctions-Textract-StartDocumentTextDetection does not accept SNSTopicArn in NotificationChannel #198

Closed
fanick1 opened this issue Sep 5, 2023 · 1 comment
Labels
bug Something isn't working

Comments

@fanick1
Copy link

fanick1 commented Sep 5, 2023

I think there must be some validation error on the backend of step function schema validation when validating NotificationChannel parameter on async Textract operations such as StartDocumentTextDetection.

According to the documentation https://docs.aws.amazon.com/textract/latest/dg/API_StartDocumentTextDetection.html the operation takes parameter SNSTopicArn (absolutely crucial param) but this parameter can't be configured when we try to integrate it as a step in a step function.

On save the step function gets validated and validation error shows up:

The field "SNSTopicArn" is not supported by Step Functions /States/StartDocumentTextDetection/Parameters 
For more information, see Amazon States Language 

This basically disqualifies Textract with its async invocated operations from use in step functions. Workaround is probably to launch it from lambda function step.

Reproduction Steps

Create step function via aws console with this content:

{
  "StartAt": "StartDocumentTextDetection",
  "States": {
    "": {
      "Type": "Task",
      "Parameters": {
        "DocumentLocation": {},
        "NotificationChannel": {
          "RoleArn": "string",
          "SNSTopicArn": "string"
        }
      },
      "Resource": "arn:aws:states:::aws-sdk:textract:startDocumentTextDetection",
      "End": true
    }
  }
}

What did you expect to happen?

step function gets successfuly saved

What actually happened?

On save the step function gets validated and validation error shows up:

The field "SNSTopicArn" is not supported by Step Functions /States/StartDocumentTextDetection/Parameters 
For more information, see Amazon States Language 

Environment

  • AWS Step Functions Data Science Python SDK version :
  • Python Version:

Other


This is 🐛 Bug Report

@fanick1 fanick1 added the bug Something isn't working label Sep 5, 2023
@fanick1
Copy link
Author

fanick1 commented Sep 6, 2023

Ok, it's not a bug, the SNSTopicArn must be spelled out in pascal case - SnsTopicArn

@fanick1 fanick1 closed this as completed Sep 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant