Class ConnectionProps
An API Destination Connection.
Inheritance
Implements
Namespace: Amazon.CDK.AWS.Events
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class ConnectionProps : Object, IConnectionProps
Syntax (vb)
Public Class ConnectionProps
Inherits Object
Implements IConnectionProps
Remarks
A connection defines the authorization type and credentials to use for authorization with an API destination HTTP endpoint.
ExampleMetadata: infused
Examples
var connection = new Connection(this, "Connection", new ConnectionProps {
Authorization = Authorization.ApiKey("x-api-key", SecretValue.SecretsManager("ApiSecretName")),
Description = "Connection with API Key x-api-key"
});
var destination = new ApiDestination(this, "Destination", new ApiDestinationProps {
Connection = connection,
Endpoint = "https://example.com",
Description = "Calling example.com with API key x-api-key"
});
var rule = new Rule(this, "Rule", new RuleProps {
Schedule = Schedule.Rate(Duration.Minutes(1)),
Targets = new [] { new ApiDestination(destination) }
});
Synopsis
Constructors
ConnectionProps() |
Properties
Authorization | The authorization type for the connection. |
BodyParameters | Additional string parameters to add to the invocation bodies. |
ConnectionName | The name of the connection. |
Description | The name of the connection. |
HeaderParameters | Additional string parameters to add to the invocation headers. |
QueryStringParameters | Additional string parameters to add to the invocation query strings. |
Constructors
ConnectionProps()
public ConnectionProps()
Properties
Authorization
The authorization type for the connection.
public Authorization Authorization { get; set; }
Property Value
BodyParameters
Additional string parameters to add to the invocation bodies.
public IDictionary<string, HttpParameter> BodyParameters { get; set; }
Property Value
System.Collections.Generic.IDictionary<System.String, HttpParameter>
Remarks
Default: - No additional parameters
ConnectionName
The name of the connection.
public string ConnectionName { get; set; }
Property Value
System.String
Remarks
Default: - A name is automatically generated
Description
The name of the connection.
public string Description { get; set; }
Property Value
System.String
Remarks
Default: - none
HeaderParameters
Additional string parameters to add to the invocation headers.
public IDictionary<string, HttpParameter> HeaderParameters { get; set; }
Property Value
System.Collections.Generic.IDictionary<System.String, HttpParameter>
Remarks
Default: - No additional parameters
QueryStringParameters
Additional string parameters to add to the invocation query strings.
public IDictionary<string, HttpParameter> QueryStringParameters { get; set; }
Property Value
System.Collections.Generic.IDictionary<System.String, HttpParameter>
Remarks
Default: - No additional parameters