aws / aws/aws-appsync-community

Feature Request - Custom HTTP Response Headers

Open
#122 4 comments 35 reactions 0 assignees View on GitHub
feature-request
Dominant language
HTML
Stars
507
Forks
37
PR merge metrics
No merged PRs in 30d

Description

Can we have the ability to set a custom HTTP response header from AppSync? I have a requirement to set a custom HTTP header based on the user query. I see that AppSync provides access to the request headers here: https://docs.aws.amazon.com/appsync/latest/devguide/resolver-context-reference.html

However, there is no access to the response headers from the resolvers. I haven't figured out a good way to set a custom HTTP response header from AppSync within AWS yet. Currently, I am looking at intercepting the request / response through CloudFront/Lambda@Edge to be able to do this, which adds additional latency to our process.

Contributor guide

Open the contributing guide

Research direction

Start with the AppSync resolver context reference linked in the issue and compare its request-header access with the requested response-header behavior. Review the reported CloudFront/Lambda@Edge interception workaround as context. Done means AppSync can set a custom HTTP response header from resolver logic based on the user query without that workaround.

Written by the indexing model from the issue text.

Assessment

Tech stack
aws, graphql
Domain
api, backend
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.