Skip to content
v2.278.0

Experimental

@aws-cdk/aws-pipes-targets-alpha is an experimental (alpha) package: its API may change in any release, without a major version bump.

ApiDestinationTargetParameters Struct ​

EventBridge API destination target properties.

Example ​

ts
declare const sourceQueue: sqs.Queue;
declare const dest: events.ApiDestination;

const apiTarget = new targets.ApiDestinationTarget(dest, {
  inputTransformation: pipes.InputTransformation.fromObject({ body: "👀" }),
});

const pipe = new pipes.Pipe(this, 'Pipe', {
    source: new SqsSource(sourceQueue),
    target: apiTarget,
});
python
# source_queue: sqs.Queue
# dest: events.ApiDestination


api_target = targets.ApiDestinationTarget(dest,
    input_transformation=pipes.InputTransformation.from_object({"body": "👀"})
)

pipe = pipes.Pipe(self, "Pipe",
    source=SqsSource(source_queue),
    target=api_target
)
java
Queue sourceQueue;
ApiDestination dest;


ApiDestinationTarget apiTarget = ApiDestinationTarget.Builder.create(dest)
        .inputTransformation(InputTransformation.fromObject(Map.of("body", "👀")))
        .build();

Pipe pipe = Pipe.Builder.create(this, "Pipe")
        .source(new SqsSource(sourceQueue))
        .target(apiTarget)
        .build();
csharp
// Install: dotnet add package Amazon.CDK.AWS.Pipes.Targets.Alpha
Queue sourceQueue;
ApiDestination dest;


var apiTarget = new ApiDestinationTarget(dest, new ApiDestinationTargetParameters {
    InputTransformation = InputTransformation.FromObject(new Dictionary<string, object> { { "body", "👀" } })
});

var pipe = new Pipe(this, "Pipe", new PipeProps {
    Source = new SqsSource(sourceQueue),
    Target = apiTarget
});
go
// Install: go get github.com/aws/aws-cdk-go/awscdkpipestargetsalpha/v2
var sourceQueue Queue
var dest ApiDestination


apiTarget := targets.NewApiDestinationTarget(dest, &ApiDestinationTargetParameters{
	InputTransformation: pipes.InputTransformation_FromObject(map[string]interface{}{
		"body": jsii.String("👀"),
	}),
})

pipe := pipes.NewPipe(this, jsii.String("Pipe"), &PipeProps{
	Source: awscdkpipessourcesalpha.NewSqsSource(sourceQueue),
	Target: apiTarget,
})

Properties ​

headerParametersoptional{ [key: string]: string }header_parametersoptionaltyping.Mapping[str, str]headerParametersoptionalMap<String, String>HeaderParametersoptionalIDictionary<string, string>HeaderParametersoptional*map[string]*string = none #
The headers to send as part of the request invoking the EventBridge API destination.

The headers are merged with the headers from the API destination. If there are conflicts, the headers from the API destination take precedence.

inputTransformationoptionalIInputTransformationinput_transformationoptionalIInputTransformationinputTransformationoptionalIInputTransformationInputTransformationoptionalIInputTransformationInputTransformationoptionalIInputTransformation = none #
The input transformation to apply to the message before sending it to the target.
pathParameterValuesoptionalstring[]path_parameter_valuesoptionaltyping.List[str]pathParameterValuesoptionalList<String>PathParameterValuesoptionalstring[]PathParameterValuesoptional*[]*string = none #
The path parameter values used to populate the EventBridge API destination path wildcards ("*").
queryStringParametersoptional{ [key: string]: string }query_string_parametersoptionaltyping.Mapping[str, str]queryStringParametersoptionalMap<String, String>QueryStringParametersoptionalIDictionary<string, string>QueryStringParametersoptional*map[string]*string = none #
The query string keys/values that need to be sent as part of request invoking the EventBridge API destination.