Skip to content

Commit

Permalink
feat(client-kinesis-video): General Availability (GA) release of Kine…
Browse files Browse the repository at this point in the history
…sis Video Streams at Edge, enabling customers to provide a configuration for the Kinesis Video Streams EdgeAgent running on an on-premise IoT device. Customers can now locally record from cameras and stream videos to the cloud on a configured schedule.
  • Loading branch information
awstools committed Jun 27, 2023
1 parent b11ef46 commit 31ffd5a
Show file tree
Hide file tree
Showing 16 changed files with 1,963 additions and 1,079 deletions.
16 changes: 16 additions & 0 deletions clients/client-kinesis-video/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -218,6 +218,14 @@ CreateStream

[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-kinesis-video/classes/createstreamcommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-kinesis-video/interfaces/createstreamcommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-kinesis-video/interfaces/createstreamcommandoutput.html)

</details>
<details>
<summary>
DeleteEdgeConfiguration
</summary>

[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-kinesis-video/classes/deleteedgeconfigurationcommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-kinesis-video/interfaces/deleteedgeconfigurationcommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-kinesis-video/interfaces/deleteedgeconfigurationcommandoutput.html)

</details>
<details>
<summary>
Expand Down Expand Up @@ -306,6 +314,14 @@ GetSignalingChannelEndpoint

[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-kinesis-video/classes/getsignalingchannelendpointcommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-kinesis-video/interfaces/getsignalingchannelendpointcommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-kinesis-video/interfaces/getsignalingchannelendpointcommandoutput.html)

</details>
<details>
<summary>
ListEdgeAgentConfigurations
</summary>

[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-kinesis-video/classes/listedgeagentconfigurationscommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-kinesis-video/interfaces/listedgeagentconfigurationscommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-kinesis-video/interfaces/listedgeagentconfigurationscommandoutput.html)

</details>
<details>
<summary>
Expand Down
46 changes: 46 additions & 0 deletions clients/client-kinesis-video/src/KinesisVideo.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,11 @@ import {
CreateStreamCommandInput,
CreateStreamCommandOutput,
} from "./commands/CreateStreamCommand";
import {
DeleteEdgeConfigurationCommand,
DeleteEdgeConfigurationCommandInput,
DeleteEdgeConfigurationCommandOutput,
} from "./commands/DeleteEdgeConfigurationCommand";
import {
DeleteSignalingChannelCommand,
DeleteSignalingChannelCommandInput,
Expand Down Expand Up @@ -67,6 +72,11 @@ import {
GetSignalingChannelEndpointCommandInput,
GetSignalingChannelEndpointCommandOutput,
} from "./commands/GetSignalingChannelEndpointCommand";
import {
ListEdgeAgentConfigurationsCommand,
ListEdgeAgentConfigurationsCommandInput,
ListEdgeAgentConfigurationsCommandOutput,
} from "./commands/ListEdgeAgentConfigurationsCommand";
import {
ListSignalingChannelsCommand,
ListSignalingChannelsCommandInput,
Expand Down Expand Up @@ -131,6 +141,7 @@ import { KinesisVideoClient, KinesisVideoClientConfig } from "./KinesisVideoClie
const commands = {
CreateSignalingChannelCommand,
CreateStreamCommand,
DeleteEdgeConfigurationCommand,
DeleteSignalingChannelCommand,
DeleteStreamCommand,
DescribeEdgeConfigurationCommand,
Expand All @@ -142,6 +153,7 @@ const commands = {
DescribeStreamCommand,
GetDataEndpointCommand,
GetSignalingChannelEndpointCommand,
ListEdgeAgentConfigurationsCommand,
ListSignalingChannelsCommand,
ListStreamsCommand,
ListTagsForResourceCommand,
Expand Down Expand Up @@ -188,6 +200,23 @@ export interface KinesisVideo {
cb: (err: any, data?: CreateStreamCommandOutput) => void
): void;

/**
* @see {@link DeleteEdgeConfigurationCommand}
*/
deleteEdgeConfiguration(
args: DeleteEdgeConfigurationCommandInput,
options?: __HttpHandlerOptions
): Promise<DeleteEdgeConfigurationCommandOutput>;
deleteEdgeConfiguration(
args: DeleteEdgeConfigurationCommandInput,
cb: (err: any, data?: DeleteEdgeConfigurationCommandOutput) => void
): void;
deleteEdgeConfiguration(
args: DeleteEdgeConfigurationCommandInput,
options: __HttpHandlerOptions,
cb: (err: any, data?: DeleteEdgeConfigurationCommandOutput) => void
): void;

/**
* @see {@link DeleteSignalingChannelCommand}
*/
Expand Down Expand Up @@ -363,6 +392,23 @@ export interface KinesisVideo {
cb: (err: any, data?: GetSignalingChannelEndpointCommandOutput) => void
): void;

/**
* @see {@link ListEdgeAgentConfigurationsCommand}
*/
listEdgeAgentConfigurations(
args: ListEdgeAgentConfigurationsCommandInput,
options?: __HttpHandlerOptions
): Promise<ListEdgeAgentConfigurationsCommandOutput>;
listEdgeAgentConfigurations(
args: ListEdgeAgentConfigurationsCommandInput,
cb: (err: any, data?: ListEdgeAgentConfigurationsCommandOutput) => void
): void;
listEdgeAgentConfigurations(
args: ListEdgeAgentConfigurationsCommandInput,
options: __HttpHandlerOptions,
cb: (err: any, data?: ListEdgeAgentConfigurationsCommandOutput) => void
): void;

/**
* @see {@link ListSignalingChannelsCommand}
*/
Expand Down
12 changes: 12 additions & 0 deletions clients/client-kinesis-video/src/KinesisVideoClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,10 @@ import {
CreateSignalingChannelCommandOutput,
} from "./commands/CreateSignalingChannelCommand";
import { CreateStreamCommandInput, CreateStreamCommandOutput } from "./commands/CreateStreamCommand";
import {
DeleteEdgeConfigurationCommandInput,
DeleteEdgeConfigurationCommandOutput,
} from "./commands/DeleteEdgeConfigurationCommand";
import {
DeleteSignalingChannelCommandInput,
DeleteSignalingChannelCommandOutput,
Expand Down Expand Up @@ -91,6 +95,10 @@ import {
GetSignalingChannelEndpointCommandInput,
GetSignalingChannelEndpointCommandOutput,
} from "./commands/GetSignalingChannelEndpointCommand";
import {
ListEdgeAgentConfigurationsCommandInput,
ListEdgeAgentConfigurationsCommandOutput,
} from "./commands/ListEdgeAgentConfigurationsCommand";
import {
ListSignalingChannelsCommandInput,
ListSignalingChannelsCommandOutput,
Expand Down Expand Up @@ -146,6 +154,7 @@ export { __Client };
export type ServiceInputTypes =
| CreateSignalingChannelCommandInput
| CreateStreamCommandInput
| DeleteEdgeConfigurationCommandInput
| DeleteSignalingChannelCommandInput
| DeleteStreamCommandInput
| DescribeEdgeConfigurationCommandInput
Expand All @@ -157,6 +166,7 @@ export type ServiceInputTypes =
| DescribeStreamCommandInput
| GetDataEndpointCommandInput
| GetSignalingChannelEndpointCommandInput
| ListEdgeAgentConfigurationsCommandInput
| ListSignalingChannelsCommandInput
| ListStreamsCommandInput
| ListTagsForResourceCommandInput
Expand All @@ -179,6 +189,7 @@ export type ServiceInputTypes =
export type ServiceOutputTypes =
| CreateSignalingChannelCommandOutput
| CreateStreamCommandOutput
| DeleteEdgeConfigurationCommandOutput
| DeleteSignalingChannelCommandOutput
| DeleteStreamCommandOutput
| DescribeEdgeConfigurationCommandOutput
Expand All @@ -190,6 +201,7 @@ export type ServiceOutputTypes =
| DescribeStreamCommandOutput
| GetDataEndpointCommandOutput
| GetSignalingChannelEndpointCommandOutput
| ListEdgeAgentConfigurationsCommandOutput
| ListSignalingChannelsCommandOutput
| ListStreamsCommandOutput
| ListTagsForResourceCommandOutput
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,160 @@
// smithy-typescript generated code
import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint";
import { getSerdePlugin } from "@aws-sdk/middleware-serde";
import { Command as $Command } from "@aws-sdk/smithy-client";
import {
FinalizeHandlerArguments,
Handler,
HandlerExecutionContext,
HttpHandlerOptions as __HttpHandlerOptions,
MetadataBearer as __MetadataBearer,
MiddlewareStack,
} from "@aws-sdk/types";
import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@smithy/protocol-http";
import { SerdeContext as __SerdeContext } from "@smithy/types";

import { KinesisVideoClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../KinesisVideoClient";
import { DeleteEdgeConfigurationInput, DeleteEdgeConfigurationOutput } from "../models/models_0";
import { de_DeleteEdgeConfigurationCommand, se_DeleteEdgeConfigurationCommand } from "../protocols/Aws_restJson1";

/**
* @public
*/
export { __MetadataBearer, $Command };
/**
* @public
*
* The input for {@link DeleteEdgeConfigurationCommand}.
*/
export interface DeleteEdgeConfigurationCommandInput extends DeleteEdgeConfigurationInput {}
/**
* @public
*
* The output of {@link DeleteEdgeConfigurationCommand}.
*/
export interface DeleteEdgeConfigurationCommandOutput extends DeleteEdgeConfigurationOutput, __MetadataBearer {}

/**
* @public
* <p>An asynchronous API that deletes a stream’s existing edge configuration, as well as the corresponding media from the Edge Agent.</p>
* <p>When you invoke this API, the sync status is set to <code>DELETING</code>. A deletion process starts, in which active edge jobs are stopped and all media is deleted from the edge device. The time to delete varies, depending on the total amount of stored media. If the deletion process fails, the sync status changes to <code>DELETE_FAILED</code>. You will need to re-try the deletion.</p>
* <p>When the deletion process has completed successfully, the edge configuration is no longer accessible.</p>
* @example
* Use a bare-bones client and the command you need to make an API call.
* ```javascript
* import { KinesisVideoClient, DeleteEdgeConfigurationCommand } from "@aws-sdk/client-kinesis-video"; // ES Modules import
* // const { KinesisVideoClient, DeleteEdgeConfigurationCommand } = require("@aws-sdk/client-kinesis-video"); // CommonJS import
* const client = new KinesisVideoClient(config);
* const input = { // DeleteEdgeConfigurationInput
* StreamName: "STRING_VALUE",
* StreamARN: "STRING_VALUE",
* };
* const command = new DeleteEdgeConfigurationCommand(input);
* const response = await client.send(command);
* // {};
*
* ```
*
* @param DeleteEdgeConfigurationCommandInput - {@link DeleteEdgeConfigurationCommandInput}
* @returns {@link DeleteEdgeConfigurationCommandOutput}
* @see {@link DeleteEdgeConfigurationCommandInput} for command's `input` shape.
* @see {@link DeleteEdgeConfigurationCommandOutput} for command's `response` shape.
* @see {@link KinesisVideoClientResolvedConfig | config} for KinesisVideoClient's `config` shape.
*
* @throws {@link AccessDeniedException} (client fault)
* <p>You do not have required permissions to perform this operation.</p>
*
* @throws {@link ClientLimitExceededException} (client fault)
* <p>Kinesis Video Streams has throttled the request because you have exceeded the limit of
* allowed client calls. Try making the call later.</p>
*
* @throws {@link InvalidArgumentException} (client fault)
* <p>The value for this input parameter is invalid.</p>
*
* @throws {@link ResourceNotFoundException} (client fault)
* <p>Amazon Kinesis Video Streams can't find the stream that you specified.</p>
*
* @throws {@link StreamEdgeConfigurationNotFoundException} (client fault)
* <p>The Exception rendered when the Amazon Kinesis Video Stream can't find a stream's edge configuration
* that you specified. </p>
*
* @throws {@link KinesisVideoServiceException}
* <p>Base exception class for all service exceptions from KinesisVideo service.</p>
*
*/
export class DeleteEdgeConfigurationCommand extends $Command<
DeleteEdgeConfigurationCommandInput,
DeleteEdgeConfigurationCommandOutput,
KinesisVideoClientResolvedConfig
> {
// Start section: command_properties
// End section: command_properties

public static getEndpointParameterInstructions(): EndpointParameterInstructions {
return {
UseFIPS: { type: "builtInParams", name: "useFipsEndpoint" },
Endpoint: { type: "builtInParams", name: "endpoint" },
Region: { type: "builtInParams", name: "region" },
UseDualStack: { type: "builtInParams", name: "useDualstackEndpoint" },
};
}

/**
* @public
*/
constructor(readonly input: DeleteEdgeConfigurationCommandInput) {
// Start section: command_constructor
super();
// End section: command_constructor
}

/**
* @internal
*/
resolveMiddleware(
clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>,
configuration: KinesisVideoClientResolvedConfig,
options?: __HttpHandlerOptions
): Handler<DeleteEdgeConfigurationCommandInput, DeleteEdgeConfigurationCommandOutput> {
this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
this.middlewareStack.use(
getEndpointPlugin(configuration, DeleteEdgeConfigurationCommand.getEndpointParameterInstructions())
);

const stack = clientStack.concat(this.middlewareStack);

const { logger } = configuration;
const clientName = "KinesisVideoClient";
const commandName = "DeleteEdgeConfigurationCommand";
const handlerExecutionContext: HandlerExecutionContext = {
logger,
clientName,
commandName,
inputFilterSensitiveLog: (_: any) => _,
outputFilterSensitiveLog: (_: any) => _,
};
const { requestHandler } = configuration;
return stack.resolve(
(request: FinalizeHandlerArguments<any>) =>
requestHandler.handle(request.request as __HttpRequest, options || {}),
handlerExecutionContext
);
}

/**
* @internal
*/
private serialize(input: DeleteEdgeConfigurationCommandInput, context: __SerdeContext): Promise<__HttpRequest> {
return se_DeleteEdgeConfigurationCommand(input, context);
}

/**
* @internal
*/
private deserialize(output: __HttpResponse, context: __SerdeContext): Promise<DeleteEdgeConfigurationCommandOutput> {
return de_DeleteEdgeConfigurationCommand(output, context);
}

// Start section: command_body_extra
// End section: command_body_extra
}
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,11 @@ export interface DescribeEdgeConfigurationCommandOutput extends DescribeEdgeConf

/**
* @public
* <p>Describes a stream’s edge configuration that was set using the <code>StartEdgeConfigurationUpdate</code> API.
* Use this API to get the status of the configuration if the configuration is in sync with the
* Edge Agent.</p>
* <p>Describes a stream’s edge configuration that was set using the
* <code>StartEdgeConfigurationUpdate</code> API and the latest status of the edge
* agent's recorder and uploader jobs. Use this API to get the status of the configuration
* to determine if the configuration is in sync with the Edge Agent. Use this API to
* evaluate the health of the Edge Agent.</p>
* @example
* Use a bare-bones client and the command you need to make an API call.
* ```javascript
Expand All @@ -60,7 +62,7 @@ export interface DescribeEdgeConfigurationCommandOutput extends DescribeEdgeConf
* // StreamARN: "STRING_VALUE",
* // CreationTime: new Date("TIMESTAMP"),
* // LastUpdatedTime: new Date("TIMESTAMP"),
* // SyncStatus: "SYNCING" || "ACKNOWLEDGED" || "IN_SYNC" || "SYNC_FAILED" || "DELETING" || "DELETE_FAILED",
* // SyncStatus: "SYNCING" || "ACKNOWLEDGED" || "IN_SYNC" || "SYNC_FAILED" || "DELETING" || "DELETE_FAILED" || "DELETING_ACKNOWLEDGED",
* // FailedStatusDetails: "STRING_VALUE",
* // EdgeConfig: { // EdgeConfig
* // HubDeviceArn: "STRING_VALUE", // required
Expand Down Expand Up @@ -89,6 +91,20 @@ export interface DescribeEdgeConfigurationCommandOutput extends DescribeEdgeConf
* // DeleteAfterUpload: true || false,
* // },
* // },
* // EdgeAgentStatus: { // EdgeAgentStatus
* // LastRecorderStatus: { // LastRecorderStatus
* // JobStatusDetails: "STRING_VALUE",
* // LastCollectedTime: new Date("TIMESTAMP"),
* // LastUpdatedTime: new Date("TIMESTAMP"),
* // RecorderStatus: "SUCCESS" || "USER_ERROR" || "SYSTEM_ERROR",
* // },
* // LastUploaderStatus: { // LastUploaderStatus
* // JobStatusDetails: "STRING_VALUE",
* // LastCollectedTime: new Date("TIMESTAMP"),
* // LastUpdatedTime: new Date("TIMESTAMP"),
* // UploaderStatus: "SUCCESS" || "USER_ERROR" || "SYSTEM_ERROR",
* // },
* // },
* // };
*
* ```
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,7 @@ export interface DescribeMappedResourceConfigurationCommandOutput

/**
* @public
* <p>Returns the most current information about the stream. Either streamName or streamARN should be provided in the input.</p>
* <p>Returns the most current information about the stream. The <code>streamName</code>
* <p>Returns the most current information about the stream. The <code>streamName</code>
* or <code>streamARN</code> should be provided in the input.</p>
* @example
* Use a bare-bones client and the command you need to make an API call.
Expand Down
Loading

0 comments on commit 31ffd5a

Please sign in to comment.