This template demonstrates using the new HTTP APIs direct integration to an Amazon SQS queue, a Kinesis Data Stream, and the default EventBridge bus. The following resources are built:
- SQS Queue
- Kinesis Data Stream
- HTTP API
- IAM Role for HTTP API
- A Lambda function for testing.
The api.yaml file contains the OpenAPI definition for the direct integration.
From this folder run:
sam deploy -g
Update the '<url>' with your URL after deployment
curl --location --request POST '<url>/sqs' \
--header 'Content-Type: application/json' \
--data-raw '{"MessageBody":"This is my message"}'
curl --location --request POST '<url>/eb' \
--header 'Content-Type: application/json' \
--data-raw '{"Detail": {"First Name": "My first name"}}'
curl --location --request POST '<url>/kinesis' \
--header 'Content-Type: application/json' \
--data-raw '{"Data": "Here is the data"}'