Skip to content

Instantly share code, notes, and snippets.

@realugbun
realugbun / eventBridgeAPIDestinations.ts
Created October 1, 2021 12:42
AWS Cloud Development Kit (CDK) EventBridge API Destinations
// ####### Event bus #######
// Create the bus
const bus = new events.EventBus(this, "myEventBus");
new cdk.CfnOutput(this, "BusName", {value: bus.eventBusName});
// ####### Connection #######
// Create connection for API Destination to use. This example uses basic auth. Check the docs for other options.
const myConnection = new events.CfnConnection(this, 'myConnection',{