interface ApiDestinationProps
| Language | Type name | 
|---|---|
|  .NET | Amazon.CDK.AWS.Events.ApiDestinationProps | 
|  Go | github.com/aws/aws-cdk-go/awscdk/v2/awsevents#ApiDestinationProps | 
|  Java | software.amazon.awscdk.services.events.ApiDestinationProps | 
|  Python | aws_cdk.aws_events.ApiDestinationProps | 
|  TypeScript (source) | aws-cdk-lib»aws_events»ApiDestinationProps | 
The event API Destination properties.
Example
const connection = new events.Connection(this, 'Connection', {
  authorization: events.Authorization.apiKey('x-api-key', SecretValue.secretsManager('ApiSecretName')),
  description: 'Connection with API Key x-api-key',
});
const destination = new events.ApiDestination(this, 'Destination', {
  connection,
  endpoint: 'https://example.com',
  description: 'Calling example.com with API key x-api-key',
});
const rule = new events.Rule(this, 'Rule', {
  schedule: events.Schedule.rate(Duration.minutes(1)),
  targets: [new targets.ApiDestination(destination)],
});
Properties
| Name | Type | Description | 
|---|---|---|
| connection | IConnection | The ARN of the connection to use for the API destination. | 
| endpoint | string | The URL to the HTTP invocation endpoint for the API destination.. | 
| api | string | The name for the API destination. | 
| description? | string | A description for the API destination. | 
| http | Http | The method to use for the request to the HTTP invocation endpoint. | 
| rate | number | The maximum number of requests per second to send to the HTTP invocation endpoint. | 
connection
Type:
IConnection
The ARN of the connection to use for the API destination.
endpoint
Type:
string
The URL to the HTTP invocation endpoint for the API destination..
apiDestinationName?
Type:
string
(optional, default: A unique name will be generated)
The name for the API destination.
description?
Type:
string
(optional, default: none)
A description for the API destination.
httpMethod?
Type:
Http
(optional, default: HttpMethod.POST)
The method to use for the request to the HTTP invocation endpoint.
rateLimitPerSecond?
Type:
number
(optional, default: Not rate limited)
The maximum number of requests per second to send to the HTTP invocation endpoint.
