Class ApiDestinationProps
Customize the EventBridge Api Destinations Target.
Inheritance
Namespace: Amazon.CDK.AWS.Events.Targets
Assembly: Amazon.CDK.AWS.Events.Targets.dll
Syntax (csharp)
public class ApiDestinationProps : Object, IApiDestinationProps, ITargetBaseProps
Syntax (vb)
Public Class ApiDestinationProps
Inherits Object
Implements IApiDestinationProps, ITargetBaseProps
Remarks
ExampleMetadata: fixture=_generated
Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.Events;
using Amazon.CDK.AWS.Events.Targets;
using Amazon.CDK.AWS.IAM;
using Amazon.CDK.AWS.SQS;
using Amazon.CDK;
Queue queue;
Role role;
RuleTargetInput ruleTargetInput;
var apiDestinationProps = new ApiDestinationProps {
DeadLetterQueue = queue,
Event = ruleTargetInput,
EventRole = role,
HeaderParameters = new Dictionary<string, string> {
{ "headerParametersKey", "headerParameters" }
},
MaxEventAge = Duration.Minutes(30),
PathParameterValues = new [] { "pathParameterValues" },
QueryStringParameters = new Dictionary<string, string> {
{ "queryStringParametersKey", "queryStringParameters" }
},
RetryAttempts = 123
};
Synopsis
Constructors
ApiDestinationProps() |
Properties
DeadLetterQueue | The SQS queue to be used as deadLetterQueue. Check out the considerations for using a dead-letter queue. |
Event | The event to send. |
EventRole | The role to assume before invoking the target. |
HeaderParameters | Additional headers sent to the API Destination. |
MaxEventAge | The maximum age of a request that Lambda sends to a function for processing. |
PathParameterValues | Path parameters to insert in place of path wildcards ( |
QueryStringParameters | Additional query string parameters sent to the API Destination. |
RetryAttempts | The maximum number of times to retry when the function returns an error. |
Constructors
ApiDestinationProps()
public ApiDestinationProps()
Properties
DeadLetterQueue
The SQS queue to be used as deadLetterQueue. Check out the considerations for using a dead-letter queue.
public IQueue DeadLetterQueue { get; set; }
Property Value
Remarks
The events not successfully delivered are automatically retried for a specified period of time, depending on the retry policy of the target. If an event is not delivered before all retry attempts are exhausted, it will be sent to the dead letter queue.
Default: - no dead-letter queue
Event
The event to send.
public RuleTargetInput Event { get; set; }
Property Value
Remarks
Default: - the entire EventBridge event
EventRole
The role to assume before invoking the target.
public IRole EventRole { get; set; }
Property Value
Remarks
Default: - a new role will be created
HeaderParameters
Additional headers sent to the API Destination.
public IDictionary<string, string> HeaderParameters { get; set; }
Property Value
System.Collections.Generic.IDictionary<System.String, System.String>
Remarks
These are merged with headers specified on the Connection, with the headers on the Connection taking precedence.
You can only specify secret values on the Connection.
Default: - none
MaxEventAge
The maximum age of a request that Lambda sends to a function for processing.
public Duration MaxEventAge { get; set; }
Property Value
Remarks
Minimum value of 60. Maximum value of 86400.
Default: Duration.hours(24)
PathParameterValues
Path parameters to insert in place of path wildcards (*
).
public string[] PathParameterValues { get; set; }
Property Value
System.String[]
Remarks
If the API destination has a wilcard in the path, these path parts will be inserted in that place.
Default: - none
QueryStringParameters
Additional query string parameters sent to the API Destination.
public IDictionary<string, string> QueryStringParameters { get; set; }
Property Value
System.Collections.Generic.IDictionary<System.String, System.String>
Remarks
These are merged with headers specified on the Connection, with the headers on the Connection taking precedence.
You can only specify secret values on the Connection.
Default: - none
RetryAttempts
The maximum number of times to retry when the function returns an error.
public Nullable<double> RetryAttempts { get; set; }
Property Value
System.Nullable<System.Double>
Remarks
Minimum value of 0. Maximum value of 185.
Default: 185