Table Of Contents

Feedback

User Guide

First time using the AWS CLI? See the User Guide for help getting started.

Note: You are viewing the documentation for an older major version of the AWS CLI (version 1).

AWS CLI version 2, the latest major version of AWS CLI, is now stable and recommended for general use. To view this page for the AWS CLI version 2, click here. For more information see the AWS CLI version 2 installation instructions and migration guide.

[ aws . logs ]

put-destination

Description

Creates or updates a destination. This operation is used only to create destinations for cross-account subscriptions.

A destination encapsulates a physical resource (such as an Amazon Kinesis stream) and enables you to subscribe to a real-time stream of log events for a different account, ingested using PutLogEvents .

Through an access policy, a destination controls what is written to it. By default, PutDestination does not set any access policy with the destination, which means a cross-account user cannot call PutSubscriptionFilter against this destination. To enable this, the destination owner must call PutDestinationPolicy after PutDestination .

See also: AWS API Documentation

See 'aws help' for descriptions of global parameters.

Synopsis

  put-destination
--destination-name <value>
--target-arn <value>
--role-arn <value>
[--cli-input-json <value>]
[--generate-cli-skeleton <value>]

Options

--destination-name (string)

A name for the destination.

--target-arn (string)

The ARN of an Amazon Kinesis stream to which to deliver matching log events.

--role-arn (string)

The ARN of an IAM role that grants CloudWatch Logs permissions to call the Amazon Kinesis PutRecord operation on the destination stream.

--cli-input-json (string) Performs service operation based on the JSON string provided. The JSON string follows the format provided by --generate-cli-skeleton. If other arguments are provided on the command line, the CLI values will override the JSON-provided values. It is not possible to pass arbitrary binary values using a JSON-provided value as the string will be taken literally.

--generate-cli-skeleton (string) Prints a JSON skeleton to standard output without sending an API request. If provided with no value or the value input, prints a sample input JSON that can be used as an argument for --cli-input-json. If provided with the value output, it validates the command inputs and returns a sample output JSON for that command.

See 'aws help' for descriptions of global parameters.

Output

destination -> (structure)

The destination.

destinationName -> (string)

The name of the destination.

targetArn -> (string)

The Amazon Resource Name (ARN) of the physical target to where the log events are delivered (for example, a Kinesis stream).

roleArn -> (string)

A role for impersonation, used when delivering log events to the target.

accessPolicy -> (string)

An IAM policy document that governs which AWS accounts can create subscription filters against this destination.

arn -> (string)

The ARN of this destination.

creationTime -> (long)

The creation time of the destination, expressed as the number of milliseconds after Jan 1, 1970 00:00:00 UTC.