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

CREATE_FAILED: ApiGatewayMethodActionPost (AWS::ApiGateway::Method) - Invalid type for parameter selectionPattern #256

Open
neeraj-sharma-0725 opened this issue Jun 23, 2024 · 0 comments

Comments

@neeraj-sharma-0725
Copy link

neeraj-sharma-0725 commented Jun 23, 2024

I'm trying to deploy my serverless app on local stack but Invalid type parameter for selectionPattern error is being thrown. Below is the complete error and serverless.yml

Error:

ApiGatewayMethodActionPost (Parameter validation failed:; Invalid type for parameter selectionPattern, value: 200, type: <class 'int'>, valid types: <class 'str'>)

serverless.yml

  events:
    - http:
        path: /action
        method: POST
        iamRole: arn:aws:iam::xxxxxxxxxxxx:role/someRole
        action: StartSyncExecution
        request:
          template:
            application/json: |
              {
                "stateMachineArn":"arn:aws:states:'us-west-2':xxxxxxxxxxxx:stateMachine:someMachine",
                "input": "$util.escapeJavaScript($input.json('$'))"
              }
        response:
            template: 
              application/json: |
                $input.path('$.output')

I was checking serverless-step-function code where selectionPattern is defined as integer and not string. Following is the link to the code: code

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants