Amazon API Gateway Operations: Difference between revisions
(39 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
=External= | |||
* https://docs.aws.amazon.com/apigateway/latest/developerguide/getting-started.html | |||
=Internal= | =Internal= | ||
* [[Amazon API Gateway#Subjects|Amazon API Gateway]] | * [[Amazon API Gateway#Subjects|Amazon API Gateway]] | ||
* [[Amazon API Gateway Deployment with CloudFormation|Amazon API Gateway Deployment with CloudFormation]] | |||
=Examples= | |||
* <span id='HTTP_Proxy_Integration_Example'></span>[[Amazon API Gateway HTTP Proxy Integration Example|Example of API Gateway HTTP Proxy Integration built with AWS Console]] | |||
* <span id='Lambda_Integration_Example'></span>[[Amazon API Gateway Lambda Integration Example|Example of API Gateway Lambda Integration Example built with AWS Console]] | |||
* [[Amazon API Gateway Mock Integration built with CloudFormation|Example of API Gateway Mock Integration built with CloudFormation]] | |||
* [[Amazon API Gateway HTTP Integration built with CloudFormation|Example of API Gateway HTTP Integration built with CloudFormation]] | |||
* [[Amazon API Gateway Lambda Integration built with CloudFormation|Example of API Gateway Lambda Integration built with CloudFormation]] | |||
=Interacting with Amazon API Gateway= | =Interacting with Amazon API Gateway= | ||
==AWS CLI== | |||
{{Internal|Aws_apigateway|Command Line Operations}} | |||
==Amazon API Gateway Console== | ==Amazon API Gateway Console== | ||
Line 9: | Line 25: | ||
{{External|https://console.aws.amazon.com/apigateway}} | {{External|https://console.aws.amazon.com/apigateway}} | ||
==Sending REST API Invocations== | ==Sending REST API Invocations== | ||
==Using AWS SDK== | ==Using AWS SDK== | ||
=Amazon API Gateway and CloudFormation= | |||
{{Internal|Amazon API Gateway Deployment with CloudFormation|Amazon API Gateway Deployment with CloudFormation}} | |||
=API Inspection= | =API Inspection= | ||
Line 27: | Line 45: | ||
=API Creation= | =API Creation= | ||
With [[#Amazon_API_Gateway_Console|Amazon API Gateway Console]]: Create API | With [[#Amazon_API_Gateway_Console|Amazon API Gateway Console]]: Create API. | ||
Examples: | |||
* [[Amazon_API_Gateway_HTTP_Proxy_Integration_Example|API Gateway HTTP Proxy Integration Example]] | |||
=API Deployment= | =API Deployment= | ||
An API deployment happens in a [[Amazon_API_Gateway_Concepts#Stage|stage]]. | |||
[[#Amazon_API_Gateway_Console|API Gateway Console]] -> APIs -> <''API Name''> -> Actions -> Deploy API. This is where an existing or a new [[Amazon_API_Gateway_Concepts#Stage|stage]] is specified. | |||
==Stage Manipulation== | |||
Stage Editor: [[#Amazon_API_Gateway_Console|API Gateway Console]] -> APIs -> <''API Name''> -> Stages -> <''stage name''> | |||
==Updating an Existing OpenAPI Definition== | |||
<font color=darkgray>TODO: | |||
* https://docs.aws.amazon.com/apigateway/latest/developerguide/api-gateway-import-api-update.html | |||
* https://docs.aws.amazon.com/apigateway/latest/developerguide/api-gateway-import-api.html | |||
</font> | |||
Also see: {{Internal|Aws_apigateway#put-rest-api|aws apigateway put-rest-api}} | |||
=API Testing= | =API Testing= | ||
=Create a VPC Link= | |||
Amazon API Gateway -> VPC Links -> Create: | |||
Add VPC Link | |||
Name: playground | |||
Description: Access to the playground cluster and ECS services. | |||
Target NLB: playground-nlb. The previously created NLB should be accessible in the drop-down box. | |||
If a network load balancer needs to be created, this is the procedure: {{Internal|AWS_Elastic_Load_Balancing_Operations#Create_a_Network_Load_Balancer|Create a Network Load Balancer}} | |||
{{Note|If the network load balancer is [[AWS_Elastic_Load_Balancing_Concepts#Internet-Facing|internet-facing]], the VPC Link is not necessary, as the URLs exposes by the load balancer can be accessed directly.}} | |||
Create. | |||
<font color=darkgray>Grant permissions to create VPC link: https://docs.aws.amazon.com/apigateway/latest/developerguide/grant-permissions-to-create-vpclink.html</font> | |||
=Amazon API Gateway Importer= | |||
{{Internal|Amazon API Gateway Importer|Amazon API Gateway Importer}} | |||
=Configuring CloudWatch Logging= | |||
{{External|[https://docs.aws.amazon.com/apigateway/latest/developerguide/set-up-logging.html Set Up CloudWatch API Logging in API Gateway]}} | |||
Also see: {{Internal|Amazon_API_Gateway_Concepts#Logging|Amazon API Gateway Logging}} |
Latest revision as of 17:27, 30 March 2019
External
Internal
Examples
- Example of API Gateway HTTP Proxy Integration built with AWS Console
- Example of API Gateway Lambda Integration Example built with AWS Console
- Example of API Gateway Mock Integration built with CloudFormation
- Example of API Gateway HTTP Integration built with CloudFormation
- Example of API Gateway Lambda Integration built with CloudFormation
Interacting with Amazon API Gateway
AWS CLI
Amazon API Gateway Console
Sending REST API Invocations
Using AWS SDK
Amazon API Gateway and CloudFormation
API Inspection
Resources
API Gateway Console -> APIs -> <API Name> -> Resources. The "Resources" pane shows the structure of the API as a tree of nodes.
Aslo:
Methods
API Gateway Console -> APIs -> <API Name> -> Resources -> Select a Resource node -> API methods defined on each resource are the leafs of the tree.
API Creation
With Amazon API Gateway Console: Create API.
Examples:
API Deployment
An API deployment happens in a stage.
API Gateway Console -> APIs -> <API Name> -> Actions -> Deploy API. This is where an existing or a new stage is specified.
Stage Manipulation
Stage Editor: API Gateway Console -> APIs -> <API Name> -> Stages -> <stage name>
Updating an Existing OpenAPI Definition
TODO:
- https://docs.aws.amazon.com/apigateway/latest/developerguide/api-gateway-import-api-update.html
- https://docs.aws.amazon.com/apigateway/latest/developerguide/api-gateway-import-api.html
Also see:
API Testing
Create a VPC Link
Amazon API Gateway -> VPC Links -> Create:
Add VPC Link
Name: playground
Description: Access to the playground cluster and ECS services.
Target NLB: playground-nlb. The previously created NLB should be accessible in the drop-down box.
If a network load balancer needs to be created, this is the procedure:
If the network load balancer is internet-facing, the VPC Link is not necessary, as the URLs exposes by the load balancer can be accessed directly.
Create.
Grant permissions to create VPC link: https://docs.aws.amazon.com/apigateway/latest/developerguide/grant-permissions-to-create-vpclink.html
Amazon API Gateway Importer
Configuring CloudWatch Logging
Also see: