We recommend new projects start with resources from the AWS provider.
aws-native.events.Connection
Explore with Pulumi AI
We recommend new projects start with resources from the AWS provider.
Resource Type definition for AWS::Events::Connection.
Example Usage
Example
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AwsNative = Pulumi.AwsNative;
return await Deployment.RunAsync(() =>
{
var config = new Config();
var pagerDutyAPIKeyParam = config.Require("pagerDutyAPIKeyParam");
var myConnection = new AwsNative.Events.Connection("myConnection", new()
{
AuthorizationType = AwsNative.Events.ConnectionAuthorizationType.ApiKey,
Description = "Connection to PagerDuty API",
AuthParameters = new AwsNative.Events.Inputs.ConnectionAuthParametersArgs
{
ApiKeyAuthParameters = new AwsNative.Events.Inputs.ConnectionApiKeyAuthParametersArgs
{
ApiKeyName = "PagerDuty Authorization",
ApiKeyValue = pagerDutyAPIKeyParam,
},
},
});
var myApiDestination = new AwsNative.Events.ApiDestination("myApiDestination", new()
{
ConnectionArn = myConnection.Arn,
Description = "API Destination to send events to PagerDuty",
HttpMethod = AwsNative.Events.ApiDestinationHttpMethod.Post,
InvocationEndpoint = "https://events.pagerduty.com/v2/enqueue",
});
});
package main
import (
"github.com/pulumi/pulumi-aws-native/sdk/go/aws/events"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi/config"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
cfg := config.New(ctx, "")
pagerDutyAPIKeyParam := cfg.Require("pagerDutyAPIKeyParam")
myConnection, err := events.NewConnection(ctx, "myConnection", &events.ConnectionArgs{
AuthorizationType: events.ConnectionAuthorizationTypeApiKey,
Description: pulumi.String("Connection to PagerDuty API"),
AuthParameters: &events.ConnectionAuthParametersArgs{
ApiKeyAuthParameters: &events.ConnectionApiKeyAuthParametersArgs{
ApiKeyName: pulumi.String("PagerDuty Authorization"),
ApiKeyValue: pulumi.String(pagerDutyAPIKeyParam),
},
},
})
if err != nil {
return err
}
_, err = events.NewApiDestination(ctx, "myApiDestination", &events.ApiDestinationArgs{
ConnectionArn: myConnection.Arn,
Description: pulumi.String("API Destination to send events to PagerDuty"),
HttpMethod: events.ApiDestinationHttpMethodPost,
InvocationEndpoint: pulumi.String("https://events.pagerduty.com/v2/enqueue"),
})
if err != nil {
return err
}
return nil
})
}
Coming soon!
import pulumi
import pulumi_aws_native as aws_native
config = pulumi.Config()
pager_duty_api_key_param = config.require("pagerDutyAPIKeyParam")
my_connection = aws_native.events.Connection("myConnection",
authorization_type=aws_native.events.ConnectionAuthorizationType.API_KEY,
description="Connection to PagerDuty API",
auth_parameters={
"api_key_auth_parameters": {
"api_key_name": "PagerDuty Authorization",
"api_key_value": pager_duty_api_key_param,
},
})
my_api_destination = aws_native.events.ApiDestination("myApiDestination",
connection_arn=my_connection.arn,
description="API Destination to send events to PagerDuty",
http_method=aws_native.events.ApiDestinationHttpMethod.POST,
invocation_endpoint="https://events.pagerduty.com/v2/enqueue")
import * as pulumi from "@pulumi/pulumi";
import * as aws_native from "@pulumi/aws-native";
const config = new pulumi.Config();
const pagerDutyAPIKeyParam = config.require("pagerDutyAPIKeyParam");
const myConnection = new aws_native.events.Connection("myConnection", {
authorizationType: aws_native.events.ConnectionAuthorizationType.ApiKey,
description: "Connection to PagerDuty API",
authParameters: {
apiKeyAuthParameters: {
apiKeyName: "PagerDuty Authorization",
apiKeyValue: pagerDutyAPIKeyParam,
},
},
});
const myApiDestination = new aws_native.events.ApiDestination("myApiDestination", {
connectionArn: myConnection.arn,
description: "API Destination to send events to PagerDuty",
httpMethod: aws_native.events.ApiDestinationHttpMethod.Post,
invocationEndpoint: "https://events.pagerduty.com/v2/enqueue",
});
Coming soon!
Create Connection Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Connection(name: string, args?: ConnectionArgs, opts?: CustomResourceOptions);
@overload
def Connection(resource_name: str,
args: Optional[ConnectionArgs] = None,
opts: Optional[ResourceOptions] = None)
@overload
def Connection(resource_name: str,
opts: Optional[ResourceOptions] = None,
auth_parameters: Optional[ConnectionAuthParametersArgs] = None,
authorization_type: Optional[ConnectionAuthorizationType] = None,
description: Optional[str] = None,
name: Optional[str] = None)
func NewConnection(ctx *Context, name string, args *ConnectionArgs, opts ...ResourceOption) (*Connection, error)
public Connection(string name, ConnectionArgs? args = null, CustomResourceOptions? opts = null)
public Connection(String name, ConnectionArgs args)
public Connection(String name, ConnectionArgs args, CustomResourceOptions options)
type: aws-native:events:Connection
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args ConnectionArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args ConnectionArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args ConnectionArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ConnectionArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args ConnectionArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Connection Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The Connection resource accepts the following input properties:
- Auth
Parameters Pulumi.Aws Native. Events. Inputs. Connection Auth Parameters - A
CreateConnectionAuthRequestParameters
object that contains the authorization parameters to use to authorize with the endpoint. - Pulumi.
Aws Native. Events. Connection Authorization Type The type of authorization to use for the connection.
OAUTH tokens are refreshed when a 401 or 407 response is returned.
- Description string
- Description of the connection.
- Name string
- Name of the connection.
- Auth
Parameters ConnectionAuth Parameters Args - A
CreateConnectionAuthRequestParameters
object that contains the authorization parameters to use to authorize with the endpoint. - Connection
Authorization Type The type of authorization to use for the connection.
OAUTH tokens are refreshed when a 401 or 407 response is returned.
- Description string
- Description of the connection.
- Name string
- Name of the connection.
- auth
Parameters ConnectionAuth Parameters - A
CreateConnectionAuthRequestParameters
object that contains the authorization parameters to use to authorize with the endpoint. - Connection
Authorization Type The type of authorization to use for the connection.
OAUTH tokens are refreshed when a 401 or 407 response is returned.
- description String
- Description of the connection.
- name String
- Name of the connection.
- auth
Parameters ConnectionAuth Parameters - A
CreateConnectionAuthRequestParameters
object that contains the authorization parameters to use to authorize with the endpoint. - Connection
Authorization Type The type of authorization to use for the connection.
OAUTH tokens are refreshed when a 401 or 407 response is returned.
- description string
- Description of the connection.
- name string
- Name of the connection.
- auth_
parameters ConnectionAuth Parameters Args - A
CreateConnectionAuthRequestParameters
object that contains the authorization parameters to use to authorize with the endpoint. - Connection
Authorization Type The type of authorization to use for the connection.
OAUTH tokens are refreshed when a 401 or 407 response is returned.
- description str
- Description of the connection.
- name str
- Name of the connection.
- auth
Parameters Property Map - A
CreateConnectionAuthRequestParameters
object that contains the authorization parameters to use to authorize with the endpoint. - "API_KEY" | "BASIC" | "OAUTH_CLIENT_CREDENTIALS"
The type of authorization to use for the connection.
OAUTH tokens are refreshed when a 401 or 407 response is returned.
- description String
- Description of the connection.
- name String
- Name of the connection.
Outputs
All input properties are implicitly available as output properties. Additionally, the Connection resource produces the following output properties:
- arn str
- The arn of the connection resource.
- id str
- The provider-assigned unique ID for this managed resource.
- secret_
arn str - The arn of the secrets manager secret created in the customer account.
Supporting Types
ConnectionApiKeyAuthParameters, ConnectionApiKeyAuthParametersArgs
- Api
Key stringName - The name of the API key to use for authorization.
- Api
Key stringValue - The value for the API key to use for authorization.
- Api
Key stringName - The name of the API key to use for authorization.
- Api
Key stringValue - The value for the API key to use for authorization.
- api
Key StringName - The name of the API key to use for authorization.
- api
Key StringValue - The value for the API key to use for authorization.
- api
Key stringName - The name of the API key to use for authorization.
- api
Key stringValue - The value for the API key to use for authorization.
- api_
key_ strname - The name of the API key to use for authorization.
- api_
key_ strvalue - The value for the API key to use for authorization.
- api
Key StringName - The name of the API key to use for authorization.
- api
Key StringValue - The value for the API key to use for authorization.
ConnectionAuthParameters, ConnectionAuthParametersArgs
- Api
Key Pulumi.Auth Parameters Aws Native. Events. Inputs. Connection Api Key Auth Parameters - The API Key parameters to use for authorization.
- Basic
Auth Pulumi.Parameters Aws Native. Events. Inputs. Connection Basic Auth Parameters - The authorization parameters for Basic authorization.
- Invocation
Http Pulumi.Parameters Aws Native. Events. Inputs. Connection Http Parameters - Additional parameters for the connection that are passed through with every invocation to the HTTP endpoint.
- OAuth
Parameters Pulumi.Aws Native. Events. Inputs. Connection OAuth Parameters - The OAuth parameters to use for authorization.
- Api
Key ConnectionAuth Parameters Api Key Auth Parameters - The API Key parameters to use for authorization.
- Basic
Auth ConnectionParameters Basic Auth Parameters - The authorization parameters for Basic authorization.
- Invocation
Http ConnectionParameters Http Parameters - Additional parameters for the connection that are passed through with every invocation to the HTTP endpoint.
- OAuth
Parameters ConnectionOAuth Parameters - The OAuth parameters to use for authorization.
- api
Key ConnectionAuth Parameters Api Key Auth Parameters - The API Key parameters to use for authorization.
- basic
Auth ConnectionParameters Basic Auth Parameters - The authorization parameters for Basic authorization.
- invocation
Http ConnectionParameters Http Parameters - Additional parameters for the connection that are passed through with every invocation to the HTTP endpoint.
- o
Auth ConnectionParameters OAuth Parameters - The OAuth parameters to use for authorization.
- api
Key ConnectionAuth Parameters Api Key Auth Parameters - The API Key parameters to use for authorization.
- basic
Auth ConnectionParameters Basic Auth Parameters - The authorization parameters for Basic authorization.
- invocation
Http ConnectionParameters Http Parameters - Additional parameters for the connection that are passed through with every invocation to the HTTP endpoint.
- o
Auth ConnectionParameters OAuth Parameters - The OAuth parameters to use for authorization.
- api_
key_ Connectionauth_ parameters Api Key Auth Parameters - The API Key parameters to use for authorization.
- basic_
auth_ Connectionparameters Basic Auth Parameters - The authorization parameters for Basic authorization.
- invocation_
http_ Connectionparameters Http Parameters - Additional parameters for the connection that are passed through with every invocation to the HTTP endpoint.
- o_
auth_ Connectionparameters OAuth Parameters - The OAuth parameters to use for authorization.
- api
Key Property MapAuth Parameters - The API Key parameters to use for authorization.
- basic
Auth Property MapParameters - The authorization parameters for Basic authorization.
- invocation
Http Property MapParameters - Additional parameters for the connection that are passed through with every invocation to the HTTP endpoint.
- o
Auth Property MapParameters - The OAuth parameters to use for authorization.
ConnectionAuthorizationType, ConnectionAuthorizationTypeArgs
- Api
Key - API_KEY
- Basic
- BASIC
- Oauth
Client Credentials - OAUTH_CLIENT_CREDENTIALS
- Connection
Authorization Type Api Key - API_KEY
- Connection
Authorization Type Basic - BASIC
- Connection
Authorization Type Oauth Client Credentials - OAUTH_CLIENT_CREDENTIALS
- Api
Key - API_KEY
- Basic
- BASIC
- Oauth
Client Credentials - OAUTH_CLIENT_CREDENTIALS
- Api
Key - API_KEY
- Basic
- BASIC
- Oauth
Client Credentials - OAUTH_CLIENT_CREDENTIALS
- API_KEY
- API_KEY
- BASIC
- BASIC
- OAUTH_CLIENT_CREDENTIALS
- OAUTH_CLIENT_CREDENTIALS
- "API_KEY"
- API_KEY
- "BASIC"
- BASIC
- "OAUTH_CLIENT_CREDENTIALS"
- OAUTH_CLIENT_CREDENTIALS
ConnectionBasicAuthParameters, ConnectionBasicAuthParametersArgs
ConnectionClientParameters, ConnectionClientParametersArgs
- Client
Id string - The client ID to use for OAuth authorization.
- Client
Secret string - The client secret assciated with the client ID to use for OAuth authorization.
- Client
Id string - The client ID to use for OAuth authorization.
- Client
Secret string - The client secret assciated with the client ID to use for OAuth authorization.
- client
Id String - The client ID to use for OAuth authorization.
- client
Secret String - The client secret assciated with the client ID to use for OAuth authorization.
- client
Id string - The client ID to use for OAuth authorization.
- client
Secret string - The client secret assciated with the client ID to use for OAuth authorization.
- client_
id str - The client ID to use for OAuth authorization.
- client_
secret str - The client secret assciated with the client ID to use for OAuth authorization.
- client
Id String - The client ID to use for OAuth authorization.
- client
Secret String - The client secret assciated with the client ID to use for OAuth authorization.
ConnectionHttpParameters, ConnectionHttpParametersArgs
- Body
Parameters List<Pulumi.Aws Native. Events. Inputs. Connection Parameter> - Contains additional body string parameters for the connection.
- Header
Parameters List<Pulumi.Aws Native. Events. Inputs. Connection Parameter> - Contains additional header parameters for the connection.
- Query
String List<Pulumi.Parameters Aws Native. Events. Inputs. Connection Parameter> - Contains additional query string parameters for the connection.
- Body
Parameters []ConnectionParameter - Contains additional body string parameters for the connection.
- Header
Parameters []ConnectionParameter - Contains additional header parameters for the connection.
- Query
String []ConnectionParameters Parameter - Contains additional query string parameters for the connection.
- body
Parameters List<ConnectionParameter> - Contains additional body string parameters for the connection.
- header
Parameters List<ConnectionParameter> - Contains additional header parameters for the connection.
- query
String List<ConnectionParameters Parameter> - Contains additional query string parameters for the connection.
- body
Parameters ConnectionParameter[] - Contains additional body string parameters for the connection.
- header
Parameters ConnectionParameter[] - Contains additional header parameters for the connection.
- query
String ConnectionParameters Parameter[] - Contains additional query string parameters for the connection.
- body_
parameters Sequence[ConnectionParameter] - Contains additional body string parameters for the connection.
- header_
parameters Sequence[ConnectionParameter] - Contains additional header parameters for the connection.
- query_
string_ Sequence[Connectionparameters Parameter] - Contains additional query string parameters for the connection.
- body
Parameters List<Property Map> - Contains additional body string parameters for the connection.
- header
Parameters List<Property Map> - Contains additional header parameters for the connection.
- query
String List<Property Map>Parameters - Contains additional query string parameters for the connection.
ConnectionOAuthParameters, ConnectionOAuthParametersArgs
- string
- The URL to the authorization endpoint when OAuth is specified as the authorization type.
- Client
Parameters Pulumi.Aws Native. Events. Inputs. Connection Client Parameters - A
CreateConnectionOAuthClientRequestParameters
object that contains the client parameters for OAuth authorization. - Http
Method Pulumi.Aws Native. Events. Connection OAuth Parameters Http Method - The method to use for the authorization request.
- OAuth
Http Pulumi.Parameters Aws Native. Events. Inputs. Connection Http Parameters - A
ConnectionHttpParameters
object that contains details about the additional parameters to use for the connection.
- string
- The URL to the authorization endpoint when OAuth is specified as the authorization type.
- Client
Parameters ConnectionClient Parameters - A
CreateConnectionOAuthClientRequestParameters
object that contains the client parameters for OAuth authorization. - Http
Method ConnectionOAuth Parameters Http Method - The method to use for the authorization request.
- OAuth
Http ConnectionParameters Http Parameters - A
ConnectionHttpParameters
object that contains details about the additional parameters to use for the connection.
- String
- The URL to the authorization endpoint when OAuth is specified as the authorization type.
- client
Parameters ConnectionClient Parameters - A
CreateConnectionOAuthClientRequestParameters
object that contains the client parameters for OAuth authorization. - http
Method ConnectionOAuth Parameters Http Method - The method to use for the authorization request.
- o
Auth ConnectionHttp Parameters Http Parameters - A
ConnectionHttpParameters
object that contains details about the additional parameters to use for the connection.
- string
- The URL to the authorization endpoint when OAuth is specified as the authorization type.
- client
Parameters ConnectionClient Parameters - A
CreateConnectionOAuthClientRequestParameters
object that contains the client parameters for OAuth authorization. - http
Method ConnectionOAuth Parameters Http Method - The method to use for the authorization request.
- o
Auth ConnectionHttp Parameters Http Parameters - A
ConnectionHttpParameters
object that contains details about the additional parameters to use for the connection.
- str
- The URL to the authorization endpoint when OAuth is specified as the authorization type.
- client_
parameters ConnectionClient Parameters - A
CreateConnectionOAuthClientRequestParameters
object that contains the client parameters for OAuth authorization. - http_
method ConnectionOAuth Parameters Http Method - The method to use for the authorization request.
- o_
auth_ Connectionhttp_ parameters Http Parameters - A
ConnectionHttpParameters
object that contains details about the additional parameters to use for the connection.
- String
- The URL to the authorization endpoint when OAuth is specified as the authorization type.
- client
Parameters Property Map - A
CreateConnectionOAuthClientRequestParameters
object that contains the client parameters for OAuth authorization. - http
Method "GET" | "POST" | "PUT" - The method to use for the authorization request.
- o
Auth Property MapHttp Parameters - A
ConnectionHttpParameters
object that contains details about the additional parameters to use for the connection.
ConnectionOAuthParametersHttpMethod, ConnectionOAuthParametersHttpMethodArgs
- Get
- GET
- Post
- POST
- Put
- PUT
- Connection
OAuth Parameters Http Method Get - GET
- Connection
OAuth Parameters Http Method Post - POST
- Connection
OAuth Parameters Http Method Put - PUT
- Get
- GET
- Post
- POST
- Put
- PUT
- Get
- GET
- Post
- POST
- Put
- PUT
- GET
- GET
- POST
- POST
- PUT
- PUT
- "GET"
- GET
- "POST"
- POST
- "PUT"
- PUT
ConnectionParameter, ConnectionParameterArgs
- Key string
- The key for a query string parameter.
- Value string
- The value associated with the key for the query string parameter.
- Is
Value boolSecret - Specifies whether the value is secret.
- Key string
- The key for a query string parameter.
- Value string
- The value associated with the key for the query string parameter.
- Is
Value boolSecret - Specifies whether the value is secret.
- key String
- The key for a query string parameter.
- value String
- The value associated with the key for the query string parameter.
- is
Value BooleanSecret - Specifies whether the value is secret.
- key string
- The key for a query string parameter.
- value string
- The value associated with the key for the query string parameter.
- is
Value booleanSecret - Specifies whether the value is secret.
- key str
- The key for a query string parameter.
- value str
- The value associated with the key for the query string parameter.
- is_
value_ boolsecret - Specifies whether the value is secret.
- key String
- The key for a query string parameter.
- value String
- The value associated with the key for the query string parameter.
- is
Value BooleanSecret - Specifies whether the value is secret.
Package Details
- Repository
- AWS Native pulumi/pulumi-aws-native
- License
- Apache-2.0
We recommend new projects start with resources from the AWS provider.