Menu
Amazon CloudWatch Events
API Reference (API Version 2015-10-07)

Target

Targets are the resources that can be invoked when a rule is triggered. Target types include AWS Lambda functions, Amazon Kinesis streams, and built-in targets.

Input and InputPath are mutually-exclusive and optional parameters of a target. When a rule is triggered due to a matched event, if for a target:

  • Neither Input nor InputPath is specified, then the entire event is passed to the target in JSON form.

  • InputPath is specified in the form of JSONPath (for example, $.detail), then only the part of the event specified in the path is passed to the target (for example, only the detail part of the event is passed).

  • Input is specified in the form of a valid JSON, then the matched event is overridden with this constant.

Contents

Arn

The Amazon Resource Name (ARN) of the target.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 1600.

Required: Yes

Id

The ID of the target.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 64.

Pattern: [\.\-_A-Za-z0-9]+

Required: Yes

Input

Valid JSON text passed to the target. For more information, see The JavaScript Object Notation (JSON) Data Interchange Format.

Type: String

Length Constraints: Maximum length of 8192.

Required: No

InputPath

The value of the JSONPath that is used for extracting part of the matched event when passing it to the target. For more information about JSON paths, see JSONPath.

Type: String

Length Constraints: Maximum length of 256.

Required: No