API-Gateway S3 Proxy

S3 Change metadata dialog.
S3 Create bucket dialog
S3 Bucket policy allowing API Gateway access
Simple index.html file
Simple index.html file in the root of the S3 bucket
Create API Gateway dialog
Our new IAM role allowing API Gateway to connect to S3.
New API Gateway resource with a path of {item}
Item resource GET method configuration
API Gateway Method Execution display
Adding the item url parameter mapping.
Creation of the test stage and deployment of the API Gateway S3 Proxy
Test stage display showing the api-s3 proxy API URL.
api-s3 proxy API GET request index.html response
Adding the Content-Type and Content-Disposition headers to the Method Execution
Mapping the Integration request headers to the original request headers
Setting the Content-Type and Content-Disposition of the Method response
Setting the Integration response Content-Type and Content-Disposition values
Index.html rendered in the browser as text/html
Setting the X-Frame-Options header to the Method Response
  • deny: Do not allow the page to be used in an iframe.
  • sameorigin: Only allow the page to be used in an iframe on the same origin.
  • allow-from: Only allow the page to be used in an iframe from the specified origin.
Setting the X-Frame-Options header to ‘deny’

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Jason Conway-Williams

Jason Conway-Williams

Senior Full Stack Developer at MoneySupermarket.