interface EventBusReference
| Language | Type name |
|---|---|
.NET | Amazon.CDK.Interfaces.Events.EventBusReference |
Go | github.com/aws/aws-cdk-go/awscdk/v2/interfaces/awsevents#EventBusReference |
Java | software.amazon.awscdk.interfaces.events.EventBusReference |
Python | aws_cdk.interfaces.aws_events.EventBusReference |
TypeScript | aws-cdk-lib » interfaces » aws_events » EventBusReference |
A reference to a EventBus resource.
Example
import * as events from 'aws-cdk-lib/aws-events';
import { HttpEventBridgeIntegration } from 'aws-cdk-lib/aws-apigatewayv2-integrations';
declare const bus: events.IEventBus;
declare const httpApi: apigwv2.HttpApi;
// default integration (PutEvents)
httpApi.addRoutes({
path: '/default',
methods: [apigwv2.HttpMethod.POST],
integration: new HttpEventBridgeIntegration('DefaultEventBridgeIntegration', {
eventBusRef: bus.eventBusRef,
}),
});
// explicit subtype
httpApi.addRoutes({
path: '/put-events',
methods: [apigwv2.HttpMethod.POST],
integration: new HttpEventBridgeIntegration('ExplicitSubtypeIntegration', {
eventBusRef: bus.eventBusRef,
subtype: apigwv2.HttpIntegrationSubtype.EVENTBRIDGE_PUT_EVENTS,
}),
});
Properties
| Name | Type | Description |
|---|---|---|
| event | string | The ARN of the EventBus resource. |
| event | string | The Name of the EventBus resource. |
eventBusArn
Type:
string
The ARN of the EventBus resource.
eventBusName
Type:
string
The Name of the EventBus resource.

.NET
Go
Java
Python
TypeScript