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

feat(aws-apigateway): add ability to include authorizer context in apigw sfn integration #18892

Merged
merged 7 commits into from Mar 4, 2022
Merged

feat(aws-apigateway): add ability to include authorizer context in apigw sfn integration #18892

merged 7 commits into from Mar 4, 2022

Conversation

rogerchi
Copy link
Contributor

@rogerchi rogerchi commented Feb 9, 2022

Implements #18891

This PR adds the ability to include custom authorizer context in the Step Functions API Gateway integration. This is useful if the custom authorizer sets custom context values, which can then be used downstream in the step function. This adds a authorizer: { ... } key to the state input.


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license

@gitpod-io
Copy link

gitpod-io bot commented Feb 9, 2022

@github-actions github-actions bot added the @aws-cdk/aws-apigateway Related to Amazon API Gateway label Feb 9, 2022
@rogerchi
Copy link
Contributor Author

rogerchi commented Feb 9, 2022

Is there an easy way to generate the expected string from the CFN template that the test is failing on?

otaviomacedo
otaviomacedo previously approved these changes Mar 4, 2022
@mergify mergify bot dismissed otaviomacedo’s stale review March 4, 2022 11:08

Pull request has been modified.

@otaviomacedo
Copy link
Contributor

@rogerchi I updated the tests for you.

@@ -193,6 +193,7 @@ new apigateway.StepFunctionsRestApi(this, 'StepFunctionsRestApi', {
headers: true,
path: false,
querystring: false,
authorizer: false,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This part was actually not implemented. Please take a look at the build failure.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My bad -- I added it to the Integration but not the RestApi

@mergify mergify bot dismissed otaviomacedo’s stale review March 4, 2022 16:36

Pull request has been modified.

@mergify
Copy link
Contributor

mergify bot commented Mar 4, 2022

Thank you for contributing! Your pull request will be updated from master and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: AutoBuildProject89A8053A-LhjRyN9kxr8o
  • Commit ID: 57153e1
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@mergify mergify bot merged commit e7c0c75 into aws:master Mar 4, 2022
@mergify
Copy link
Contributor

mergify bot commented Mar 4, 2022

Thank you for contributing! Your pull request will be updated from master and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).

@rogerchi rogerchi deleted the apigw-sfn-authorizer-context branch March 4, 2022 21:48
TheRealAmazonKendra pushed a commit to TheRealAmazonKendra/aws-cdk that referenced this pull request Mar 11, 2022
…igw sfn integration (aws#18892)

Implements aws#18891 

This PR adds the ability to include custom authorizer context in the Step Functions API Gateway integration.  This is useful if the custom authorizer sets custom context values, which can then be used downstream in the step function.  This adds a `authorizer: { ... }` key to the state input.

----

*By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
@aws-cdk/aws-apigateway Related to Amazon API Gateway
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants