Show / Hide Table of Contents

Class Integration

Manages an Amazon API Gateway Version 2 integration. More information can be found in the Amazon API Gateway Developer Guide.

Example Usage

Basic

using Pulumi;
using Aws = Pulumi.Aws;

class MyStack : Stack
{
public MyStack()
{
    var example = new Aws.ApiGatewayV2.Integration("example", new Aws.ApiGatewayV2.IntegrationArgs
    {
        ApiId = aws_apigatewayv2_api.Example.Id,
        IntegrationType = "MOCK",
    });
}

}

Lambda Integration

using Pulumi;
using Aws = Pulumi.Aws;

class MyStack : Stack
{
public MyStack()
{
    var exampleFunction = new Aws.Lambda.Function("exampleFunction", new Aws.Lambda.FunctionArgs
    {
        Code = new FileArchive("example.zip"),
        Handler = "index.handler",
        Role = aws_iam_role.Example.Arn,
        Runtime = "nodejs10.x",
    });
    var exampleIntegration = new Aws.ApiGatewayV2.Integration("exampleIntegration", new Aws.ApiGatewayV2.IntegrationArgs
    {
        ApiId = aws_apigatewayv2_api.Example.Id,
        ConnectionType = "INTERNET",
        ContentHandlingStrategy = "CONVERT_TO_TEXT",
        Description = "Lambda example",
        IntegrationMethod = "POST",
        IntegrationType = "AWS",
        IntegrationUri = exampleFunction.InvokeArn,
        PassthroughBehavior = "WHEN_NO_MATCH",
    });
}

}
Inheritance
System.Object
Resource
CustomResource
Integration
Inherited Members
CustomResource.Id
Resource.GetResourceType()
Resource.GetResourceName()
Resource.Urn
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Pulumi.Aws.ApiGatewayV2
Assembly: Pulumi.Aws.dll
Syntax
public class Integration : CustomResource

Constructors

View Source

Integration(String, IntegrationArgs, CustomResourceOptions)

Create a Integration resource with the given unique name, arguments, and options.

Declaration
public Integration(string name, IntegrationArgs args, CustomResourceOptions options = null)
Parameters
Type Name Description
System.String name

The unique name of the resource

IntegrationArgs args

The arguments used to populate this resource's properties

CustomResourceOptions options

A bag of options that control this resource's behavior

Properties

View Source

ApiId

The API identifier.

Declaration
public Output<string> ApiId { get; }
Property Value
Type Description
Output<System.String>
View Source

ConnectionId

The ID of the VPC link for a private integration. Supported only for HTTP APIs.

Declaration
public Output<string> ConnectionId { get; }
Property Value
Type Description
Output<System.String>
View Source

ConnectionType

The type of the network connection to the integration endpoint. Valid values: INTERNET, VPC_LINK. Default is INTERNET.

Declaration
public Output<string> ConnectionType { get; }
Property Value
Type Description
Output<System.String>
View Source

ContentHandlingStrategy

How to handle response payload content type conversions. Valid values: CONVERT_TO_BINARY, CONVERT_TO_TEXT. Supported only for WebSocket APIs.

Declaration
public Output<string> ContentHandlingStrategy { get; }
Property Value
Type Description
Output<System.String>
View Source

CredentialsArn

The credentials required for the integration, if any.

Declaration
public Output<string> CredentialsArn { get; }
Property Value
Type Description
Output<System.String>
View Source

Description

The description of the integration.

Declaration
public Output<string> Description { get; }
Property Value
Type Description
Output<System.String>
View Source

IntegrationMethod

The integration's HTTP method. Must be specified if integration_type is not MOCK.

Declaration
public Output<string> IntegrationMethod { get; }
Property Value
Type Description
Output<System.String>
View Source

IntegrationResponseSelectionExpression

The integration response selection expression for the integration.

Declaration
public Output<string> IntegrationResponseSelectionExpression { get; }
Property Value
Type Description
Output<System.String>
View Source

IntegrationType

The integration type of an integration. Valid values: AWS, AWS_PROXY, HTTP, HTTP_PROXY, MOCK.

Declaration
public Output<string> IntegrationType { get; }
Property Value
Type Description
Output<System.String>
View Source

IntegrationUri

The URI of the Lambda function for a Lambda proxy integration, when integration_type is AWS_PROXY. For an HTTP integration, specify a fully-qualified URL. For an HTTP API private integration, specify the ARN of an Application Load Balancer listener, Network Load Balancer listener, or AWS Cloud Map service.

Declaration
public Output<string> IntegrationUri { get; }
Property Value
Type Description
Output<System.String>
View Source

PassthroughBehavior

The pass-through behavior for incoming requests based on the Content-Type header in the request, and the available mapping templates specified as the request_templates attribute. Valid values: WHEN_NO_MATCH, WHEN_NO_TEMPLATES, NEVER. Default is WHEN_NO_MATCH. Supported only for WebSocket APIs.

Declaration
public Output<string> PassthroughBehavior { get; }
Property Value
Type Description
Output<System.String>
View Source

PayloadFormatVersion

The format of the payload sent to an integration. Valid values: 1.0, 2.0. Default is 1.0.

Declaration
public Output<string> PayloadFormatVersion { get; }
Property Value
Type Description
Output<System.String>
View Source

RequestTemplates

A map of Velocity templates that are applied on the request payload based on the value of the Content-Type header sent by the client. Supported only for WebSocket APIs.

Declaration
public Output<ImmutableDictionary<string, string>> RequestTemplates { get; }
Property Value
Type Description
Output<System.Collections.Immutable.ImmutableDictionary<System.String, System.String>>
View Source

TemplateSelectionExpression

The template selection expression for the integration.

Declaration
public Output<string> TemplateSelectionExpression { get; }
Property Value
Type Description
Output<System.String>
View Source

TimeoutMilliseconds

Custom timeout between 50 and 29,000 milliseconds. The default value is 29,000 milliseconds or 29 seconds.

Declaration
public Output<int?> TimeoutMilliseconds { get; }
Property Value
Type Description
Output<System.Nullable<System.Int32>>

Methods

View Source

Get(String, Input<String>, IntegrationState, CustomResourceOptions)

Get an existing Integration resource's state with the given name, ID, and optional extra properties used to qualify the lookup.

Declaration
public static Integration Get(string name, Input<string> id, IntegrationState state = null, CustomResourceOptions options = null)
Parameters
Type Name Description
System.String name

The unique name of the resulting resource.

Input<System.String> id

The unique provider ID of the resource to lookup.

IntegrationState state

Any extra arguments used during the lookup.

CustomResourceOptions options

A bag of options that control this resource's behavior

Returns
Type Description
Integration
  • View Source
Back to top Copyright 2016-2020, Pulumi Corporation.