From 8a10d575e41eaf8704701e176fa89b02014557af Mon Sep 17 00:00:00 2001 From: Elysa Hall Date: Thu, 18 Sep 2025 17:01:28 +0000 Subject: [PATCH] Examples for ivs-realtime, lambda, securityhub --- .../examples/ivs-realtime/get-composition.rst | 11 ++- .../ivs-realtime/start-composition.rst | 91 ++++++++++++++++++- awscli/examples/lambda/create-function.rst | 8 +- awscli/examples/lambda/get-function.rst | 6 +- awscli/examples/lambda/list-functions.rst | 12 +-- awscli/examples/securityhub/describe-hub.rst | 10 +- 6 files changed, 114 insertions(+), 24 deletions(-) diff --git a/awscli/examples/ivs-realtime/get-composition.rst b/awscli/examples/ivs-realtime/get-composition.rst index 98fd9d57212a..dc2a8ebbf493 100644 --- a/awscli/examples/ivs-realtime/get-composition.rst +++ b/awscli/examples/ivs-realtime/get-composition.rst @@ -51,9 +51,10 @@ Output:: ], "layout": { "grid": { - "featuredParticipantAttribute": "" + "featuredParticipantAttribute": "", "gridGap": 2, "omitStoppedVideo": false, + "participantOrderAttribute": "", "videoAspectRatio": "VIDEO", "videoFillMode": "" } @@ -65,7 +66,7 @@ Output:: } } -For more information, see `IVS Composite Recording | Real-Time Streaming `__ in the *Amazon IVS Real-Time Streaming User Guide*. +For more information, see `IVS Composite Recording | Real-Time Streaming `__ in the *Amazon Interactive Video Service User Guide*. **Example 2: To get a composition with PiP layout** @@ -123,6 +124,7 @@ Output:: "featuredParticipantAttribute": "abcdefg", "gridGap": 0, "omitStoppedVideo": false, + "participantOrderAttribute": "", "pipBehavior": "STATIC", "pipOffset": 0, "pipParticipantAttribute": "", @@ -137,7 +139,7 @@ Output:: } } -For more information, see `IVS Composite Recording | Real-Time Streaming `__ in the *Amazon IVS Real-Time Streaming User Guide*. +For more information, see `IVS Composite Recording | Real-Time Streaming `__ in the *Amazon Interactive Video Service User Guide*. **Example 3: To get a composition with thumbnail recording enabled** @@ -203,6 +205,7 @@ Output:: "featuredParticipantAttribute": "" "gridGap": 2, "omitStoppedVideo": false, + "participantOrderAttribute": "", "videoAspectRatio": "VIDEO", "videoFillMode": "" } }, @@ -213,4 +216,4 @@ Output:: } } -For more information, see `IVS Composite Recording | Real-Time Streaming `__ in the *Amazon IVS Real-Time Streaming User Guide*. \ No newline at end of file +For more information, see `IVS Composite Recording | Real-Time Streaming `__ in the *Amazon Interactive Video Service User Guide*. \ No newline at end of file diff --git a/awscli/examples/ivs-realtime/start-composition.rst b/awscli/examples/ivs-realtime/start-composition.rst index 985a8f761984..48814ca6865e 100644 --- a/awscli/examples/ivs-realtime/start-composition.rst +++ b/awscli/examples/ivs-realtime/start-composition.rst @@ -57,6 +57,7 @@ Output:: "featuredParticipantAttribute": "" "gridGap": 2, "omitStoppedVideo": false, + "participantOrderAttribute": "", "videoAspectRatio": "VIDEO", "videoFillMode": "" } @@ -68,7 +69,7 @@ Output:: } } -For more information, see `IVS Composite Recording | Real-Time Streaming `__ in the *Amazon IVS Real-Time Streaming User Guide*. +For more information, see `IVS Composite Recording | Real-Time Streaming `__ in the *Amazon Interactive Video Service User Guide*. **Example 2: To start a composition with PiP layout** @@ -129,6 +130,7 @@ Output:: "featuredParticipantAttribute": "abcdefg", "gridGap": 0, "omitStoppedVideo": false, + "participantOrderAttribute": "", "pipBehavior": "STATIC", "pipOffset": 0, "pipParticipantAttribute": "", @@ -143,7 +145,7 @@ Output:: } } -For more information, see `IVS Composite Recording | Real-Time Streaming `__ in the *Amazon IVS Real-Time Streaming User Guide*. +For more information, see `IVS Composite Recording | Real-Time Streaming `__ in the *Amazon Interactive Video Service User Guide*. **Example 3: To start a composition with thumbnail recording enabled** @@ -212,6 +214,7 @@ Output:: "featuredParticipantAttribute": "" "gridGap": 2, "omitStoppedVideo": false, + "participantOrderAttribute": "", "videoAspectRatio": "VIDEO", "videoFillMode": "" } @@ -223,4 +226,86 @@ Output:: } } -For more information, see `IVS Composite Recording | Real-Time Streaming `__ in the *Amazon IVS Real-Time Streaming User Guide*. \ No newline at end of file +For more information, see `Composite Recording (Real-Time Streaming) `__ in the *Amazon Interactive Video Service User Guide*. + +**Example 4: To start a composition using grid layout with custom participant ordering** + +The following ``start-composition`` example starts a composition for the specified stage to be streamed to the specified locations using grid layout with custom participant ordering. :: + + aws ivs-realtime start-composition \ + --stage-arn arn:aws:ivs:ap-northeast-1:123456789012:stage/defgABCDabcd \ + --destinations '[{"channel": {"channelArn": "arn:aws:ivs:ap-northeast-1:123456789012:channel/abcABCdefDEg", \ + "encoderConfigurationArn": "arn:aws:ivs:ap-northeast-1:123456789012:encoder-configuration/ABabCDcdEFef"}}, \ + {"s3": {"encoderConfigurationArns": ["arn:aws:ivs:ap-northeast-1:123456789012:encoder-configuration/ABabCDcdEFef"], \ + "storageConfigurationArn": "arn:aws:ivs:ap-northeast-1:123456789012:storage-configuration/FefABabCDcdE", \ + "thumbnailConfigurations": [{"storage": ["SEQUENTIAL"],"targetIntervalSeconds": 60}]}}]' \ + --layout grid='{participantOrderAttribute="abcdefg"}' + +Output:: + + { + "composition": { + "arn": "arn:aws:ivs:ap-northeast-1:123456789012:composition/abcdABCDefgh", + "destinations": [ + { + "configuration": { + "channel": { + "channelArn": "arn:aws:ivs:ap-northeast-1:123456789012:channel/abcABCdefDEg", + "encoderConfigurationArn": "arn:aws:ivs:ap-northeast-1:123456789012:encoder-configuration/ABabCDcdEFef" + }, + "name": "" + }, + "id": "AabBCcdDEefF", + "state": "STARTING" + }, + { + "configuration": { + "name": "", + "s3": { + "encoderConfigurationArns": [ + "arn:aws:ivs:arn:aws:ivs:ap-northeast-1:123456789012:encoder-configuration/ABabCDcdEFef" + ], + "recordingConfiguration": { + "format": "HLS", + "hlsConfiguration": { + "targetSegmentDurationSeconds": 2 + } + }, + "storageConfigurationArn": "arn:arn:aws:ivs:ap-northeast-1:123456789012:storage-configuration/FefABabCDcdE", + "thumbnailConfigurations": [ + { + "targetIntervalSeconds": 60, + "storage": [ + "SEQUENTIAL" + ] + } + ] + } + }, + "detail": { + "s3": { + "recordingPrefix": "aBcDeFgHhGfE/AbCdEfGhHgFe/GHFabcgefABC/composite" + } + }, + "id": "GHFabcgefABC", + "state": "STARTING" + } + ], + "layout": { + "grid": { + "featuredParticipantAttribute": "" + "gridGap": 2, + "omitStoppedVideo": false, + "participantOrderAttribute": "abcdefg", + "videoAspectRatio": "VIDEO", + "videoFillMode": "" + } + }, + "stageArn": "arn:aws:ivs:ap-northeast-1:123456789012:stage/defgABCDabcd", + "startTime": "2023-10-16T23:24:00+00:00", + "state": "STARTING", + "tags": {} + } + } + +For more information, see `IVS Composite Recording | Real-Time Streaming `__ in the *Amazon Interactive Video Service User Guide*. \ No newline at end of file diff --git a/awscli/examples/lambda/create-function.rst b/awscli/examples/lambda/create-function.rst index 40fe331b8775..b7ea79426662 100755 --- a/awscli/examples/lambda/create-function.rst +++ b/awscli/examples/lambda/create-function.rst @@ -4,7 +4,7 @@ The following ``create-function`` example creates a Lambda function named ``my-f aws lambda create-function \ --function-name my-function \ - --runtime nodejs18.x \ + --runtime nodejs22.x \ --zip-file fileb://my-function.zip \ --handler my-function.handler \ --role arn:aws:iam::123456789012:role/service-role/MyTestFunction-role-tges6bf4 @@ -28,10 +28,10 @@ Output:: "Version": "$LATEST", "Role": "arn:aws:iam::123456789012:role/service-role/MyTestFunction-role-zgur6bf4", "Timeout": 3, - "LastModified": "2023-10-14T22:26:11.234+0000", + "LastModified": "2025-10-14T22:26:11.234+0000", "Handler": "my-function.handler", - "Runtime": "nodejs18.x", + "Runtime": "nodejs22.x", "Description": "" } -For more information, see `AWS Lambda Function Configuration `__ in the *AWS Lambda Developer Guide*. +For more information, see `Configure Lambda function memory `__ in the *AWS Lambda Developer Guide*. diff --git a/awscli/examples/lambda/get-function.rst b/awscli/examples/lambda/get-function.rst index 83728b0ff46e..adc3fbc08b9f 100755 --- a/awscli/examples/lambda/get-function.rst +++ b/awscli/examples/lambda/get-function.rst @@ -34,10 +34,10 @@ Output:: "Handler": "index.handler", "Role": "arn:aws:iam::123456789012:role/service-role/helloWorldPython-role-uy3l9qyq", "Timeout": 3, - "LastModified": "2019-09-24T18:20:35.054+0000", - "Runtime": "nodejs10.x", + "LastModified": "2025-09-24T18:20:35.054+0000", + "Runtime": "nodejs22.x", "Description": "" } } -For more information, see `AWS Lambda Function Configuration `__ in the *AWS Lambda Developer Guide*. +For more information, see `Configure Lambda function memory `__ in the *AWS Lambda Developer Guide*. diff --git a/awscli/examples/lambda/list-functions.rst b/awscli/examples/lambda/list-functions.rst index 7cf2d23e10cc..13c7ee114a5f 100755 --- a/awscli/examples/lambda/list-functions.rst +++ b/awscli/examples/lambda/list-functions.rst @@ -22,8 +22,8 @@ Output:: "Handler": "helloworld.handler", "Role": "arn:aws:iam::123456789012:role/service-role/MyTestFunction-role-zgur6bf4", "Timeout": 3, - "LastModified": "2023-09-23T18:32:33.857+0000", - "Runtime": "nodejs18.x", + "LastModified": "2025-09-23T18:32:33.857+0000", + "Runtime": "nodejs22.x", "Description": "" }, { @@ -45,8 +45,8 @@ Output:: "Handler": "index.handler", "Role": "arn:aws:iam::123456789012:role/service-role/helloWorldPython-role-uy3l9qyq", "Timeout": 3, - "LastModified": "2023-10-01T16:47:28.490+0000", - "Runtime": "nodejs18.x", + "LastModified": "2025-10-01T16:47:28.490+0000", + "Runtime": "nodejs22.x", "Description": "" }, { @@ -78,11 +78,11 @@ Output:: "Handler": "lambda_function.lambda_handler", "Role": "arn:aws:iam::123456789012:role/service-role/my-python-function-role-z5g7dr6n", "Timeout": 3, - "LastModified": "2023-10-01T19:40:41.643+0000", + "LastModified": "2025-10-01T19:40:41.643+0000", "Runtime": "python3.11", "Description": "" } ] } -For more information, see `AWS Lambda Function Configuration `__ in the *AWS Lambda Developer Guide*. \ No newline at end of file +For more information, see `Configure Lambda function memory `__ in the *AWS Lambda Developer Guide*. diff --git a/awscli/examples/securityhub/describe-hub.rst b/awscli/examples/securityhub/describe-hub.rst index c78c456d7109..1983c4b88164 100644 --- a/awscli/examples/securityhub/describe-hub.rst +++ b/awscli/examples/securityhub/describe-hub.rst @@ -1,15 +1,17 @@ **To get information about a hub resource** -The following ``describe-hub`` example returns the subscription date for the specified hub resource. The hub resource is identified by its ARN. :: +The following ``describe-hub`` example returns the subscription date and other configuration settings for the specified hub resource. The hub resource is identified by its ARN. :: - aws securityhub describe-hub \ + aws securityhub describe-hub \ --hub-arn "arn:aws:securityhub:us-west-1:123456789012:hub/default" Output:: { "HubArn": "arn:aws:securityhub:us-west-1:123456789012:hub/default", - "SubscribedAt": "2019-11-19T23:15:10.046Z" + "SubscribedAt": "2019-11-19T23:15:10.046Z", + "AutoEnableControls": true, + "ControlFindingGenerator": "SECURITY_CONTROL" } -For more information, see `AWS::SecurityHub::Hub `__ in the *AWS CloudFormation User Guide*. +For more information, see `AWS::SecurityHub::Hub `__ in the *AWS CloudFormation User Guide*.