Which solution will meet these requirements MOST cost-effectively?
Use Amazon API Gateway to create a private REST API. Create an HTTP integration to integrate with the third-party HTTP API. Add the company’s API key to the HTTP headers list of the integration request configuration.
Use Amazon API Gateway to create a private REST API. Create an AWS Lambda proxy integration. Make calls to the third-party HTTP API from the Lambda function. Pass the company’s API key as an HTTP request header.
Use Amazon API Gateway to create a REST API. Create an HTTP integration to integrate with the third-party HTTP API. Add the company’s API key to the HTTP headers list of the integration request configuration.
Use Amazon API Gateway to create a REST API. Create an AWS Lambda proxy integration. Make calls to the third-party HTTP API from the Lambda function. Pass the company’s API key as an HTTP request header.
Explanations:
Creating a private REST API with Amazon API Gateway means the API is not publicly accessible, which contradicts the requirement that the application be publicly accessible. Additionally, this option does not address how to securely pass the API key.
This option suggests using a private REST API, which is not suitable for publicly accessible applications. It also does not provide the most cost-effective method since integrating Lambda introduces additional costs.
This solution uses a public REST API and integrates directly with the third-party HTTP API. The company’s API key is securely handled on the server side, and it is not exposed to the client, meeting the requirements effectively and cost-efficiently.
Although this option suggests using an AWS Lambda function, which could securely handle the API key, the use of Lambda increases complexity and cost compared to directly integrating via API Gateway (as in Option C). Additionally, using Lambda for this use case is not the most cost-effective solution.