github.com/xsb/terraform@v0.6.13-0.20160314145438-fe415c2f09d7/website/source/docs/providers/aws/r/api_gateway_integration.html.markdown (about) 1 --- 2 layout: "aws" 3 page_title: "AWS: aws_api_gateway_integration" 4 sidebar_current: "docs-aws-resource-api-gateway-integration" 5 description: |- 6 Provides an HTTP Method Integration for an API Gateway Resource. 7 --- 8 9 # aws\_api\_gateway\_integration 10 11 Provides an HTTP Method Integration for an API Gateway Resource. 12 13 ## Example Usage 14 15 ``` 16 resource "aws_api_gateway_rest_api" "MyDemoAPI" { 17 name = "MyDemoAPI" 18 description = "This is my API for demonstration purposes" 19 } 20 21 resource "aws_api_gateway_resource" "MyDemoResource" { 22 rest_api_id = "${aws_api_gateway_rest_api.MyDemoAPI.id}" 23 parent_id = "${aws_api_gateway_rest_api.MyDemoAPI.root_resource_id}" 24 path_part = "mydemoresource" 25 } 26 27 resource "aws_api_gateway_method" "MyDemoMethod" { 28 rest_api_id = "${aws_api_gateway_rest_api.MyDemoAPI.id}" 29 resource_id = "${aws_api_gateway_resource.MyDemoResource.id}" 30 http_method = "GET" 31 authorization = "NONE" 32 } 33 34 resource "aws_api_gateway_integration" "MyDemoIntegration" { 35 rest_api_id = "${aws_api_gateway_rest_api.MyDemoAPI.id}" 36 resource_id = "${aws_api_gateway_resource.MyDemoResource.id}" 37 http_method = "${aws_api_gateway_method.MyDemoMethod.http_method}" 38 type = "MOCK" 39 } 40 ``` 41 42 ## Argument Reference 43 44 The following arguments are supported: 45 46 * `rest_api_id` - (Required) API Gateway ID 47 * `resource_id` - (Required) API Gateway Resource ID 48 * `http_method` - (Required) HTTP Method (GET, POST, PUT, DELETE, HEAD, OPTION) 49 * `type` - (Required) Specifies a put integration input's type (HTTP, MOCK, AWS) 50 * `uri` - (Optional) Input's Uniform Resource Identifier (HTTP, AWS) 51 * `integration_http_method` - (Optional) Integration HTTP Method (GET, POST, PUT, DELETE, HEAD, OPTION) 52