diff --git a/clients/client-chime-sdk-messaging/package.json b/clients/client-chime-sdk-messaging/package.json index a70ae6dabac9..0ff7e2c199cf 100644 --- a/clients/client-chime-sdk-messaging/package.json +++ b/clients/client-chime-sdk-messaging/package.json @@ -26,6 +26,7 @@ "@aws-sdk/hash-node": "*", "@aws-sdk/invalid-dependency": "*", "@aws-sdk/middleware-content-length": "*", + "@aws-sdk/middleware-endpoint": "*", "@aws-sdk/middleware-host-header": "*", "@aws-sdk/middleware-logger": "*", "@aws-sdk/middleware-recursion-detection": "*", diff --git a/clients/client-chime-sdk-messaging/src/ChimeSDKMessaging.ts b/clients/client-chime-sdk-messaging/src/ChimeSDKMessaging.ts index 60d63c16cc39..acf0276816e1 100644 --- a/clients/client-chime-sdk-messaging/src/ChimeSDKMessaging.ts +++ b/clients/client-chime-sdk-messaging/src/ChimeSDKMessaging.ts @@ -1816,8 +1816,7 @@ export class ChimeSDKMessaging extends ChimeSDKMessagingClient { } /** - *

Allows an AppInstanceUser to search the channels that they belong to. The AppInstanceUser can search by membership or external ID. - * An AppInstanceAdmin can search across all channels within the AppInstance.

+ *

Allows ChimeBearer to search channels by channel members. AppInstanceUsers can search across the channels that they belong to. AppInstanceAdmins can search across all channels.

*/ public searchChannels( args: SearchChannelsCommandInput, diff --git a/clients/client-chime-sdk-messaging/src/ChimeSDKMessagingClient.ts b/clients/client-chime-sdk-messaging/src/ChimeSDKMessagingClient.ts index e2d37d364892..d0e94a22f615 100644 --- a/clients/client-chime-sdk-messaging/src/ChimeSDKMessagingClient.ts +++ b/clients/client-chime-sdk-messaging/src/ChimeSDKMessagingClient.ts @@ -1,13 +1,7 @@ // smithy-typescript generated code -import { - EndpointsInputConfig, - EndpointsResolvedConfig, - RegionInputConfig, - RegionResolvedConfig, - resolveEndpointsConfig, - resolveRegionConfig, -} from "@aws-sdk/config-resolver"; +import { RegionInputConfig, RegionResolvedConfig, resolveRegionConfig } from "@aws-sdk/config-resolver"; import { getContentLengthPlugin } from "@aws-sdk/middleware-content-length"; +import { EndpointInputConfig, EndpointResolvedConfig, resolveEndpointConfig } from "@aws-sdk/middleware-endpoint"; import { getHostHeaderPlugin, HostHeaderInputConfig, @@ -41,13 +35,13 @@ import { Credentials as __Credentials, Decoder as __Decoder, Encoder as __Encoder, + EndpointV2 as __EndpointV2, Hash as __Hash, HashConstructor as __HashConstructor, HttpHandlerOptions as __HttpHandlerOptions, Logger as __Logger, Provider as __Provider, Provider, - RegionInfoProvider, StreamCollector as __StreamCollector, UrlParser as __UrlParser, UserAgent as __UserAgent, @@ -184,6 +178,12 @@ import { UpdateChannelReadMarkerCommandInput, UpdateChannelReadMarkerCommandOutput, } from "./commands/UpdateChannelReadMarkerCommand"; +import { + ClientInputEndpointParameters, + ClientResolvedEndpointParameters, + EndpointParameters, + resolveClientEndpointParameters, +} from "./endpoint/EndpointParameters"; import { getRuntimeConfig as __getRuntimeConfig } from "./runtimeConfig"; export type ServiceInputTypes = @@ -393,12 +393,6 @@ export interface ClientDefaults extends Partial<__SmithyResolvedConfiguration<__ */ credentialDefaultProvider?: (input: any) => __Provider<__Credentials>; - /** - * Fetch related hostname, signing name or signing region with given region. - * @internal - */ - regionInfoProvider?: RegionInfoProvider; - /** * The provider populating default tracking information to be sent with `user-agent`, `x-amz-user-agent` header * @internal @@ -414,11 +408,12 @@ export interface ClientDefaults extends Partial<__SmithyResolvedConfiguration<__ type ChimeSDKMessagingClientConfigType = Partial<__SmithyConfiguration<__HttpHandlerOptions>> & ClientDefaults & RegionInputConfig & - EndpointsInputConfig & + EndpointInputConfig & RetryInputConfig & HostHeaderInputConfig & AwsAuthInputConfig & - UserAgentInputConfig; + UserAgentInputConfig & + ClientInputEndpointParameters; /** * The configuration interface of ChimeSDKMessagingClient class constructor that set the region, credentials and other options. */ @@ -427,11 +422,12 @@ export interface ChimeSDKMessagingClientConfig extends ChimeSDKMessagingClientCo type ChimeSDKMessagingClientResolvedConfigType = __SmithyResolvedConfiguration<__HttpHandlerOptions> & Required & RegionResolvedConfig & - EndpointsResolvedConfig & + EndpointResolvedConfig & RetryResolvedConfig & HostHeaderResolvedConfig & AwsAuthResolvedConfig & - UserAgentResolvedConfig; + UserAgentResolvedConfig & + ClientResolvedEndpointParameters; /** * The resolved configuration interface of ChimeSDKMessagingClient class. This is resolved and normalized from the {@link ChimeSDKMessagingClientConfig | constructor configuration interface}. */ @@ -456,14 +452,15 @@ export class ChimeSDKMessagingClient extends __Client< constructor(configuration: ChimeSDKMessagingClientConfig) { const _config_0 = __getRuntimeConfig(configuration); - const _config_1 = resolveRegionConfig(_config_0); - const _config_2 = resolveEndpointsConfig(_config_1); - const _config_3 = resolveRetryConfig(_config_2); - const _config_4 = resolveHostHeaderConfig(_config_3); - const _config_5 = resolveAwsAuthConfig(_config_4); - const _config_6 = resolveUserAgentConfig(_config_5); - super(_config_6); - this.config = _config_6; + const _config_1 = resolveClientEndpointParameters(_config_0); + const _config_2 = resolveRegionConfig(_config_1); + const _config_3 = resolveEndpointConfig(_config_2); + const _config_4 = resolveRetryConfig(_config_3); + const _config_5 = resolveHostHeaderConfig(_config_4); + const _config_6 = resolveAwsAuthConfig(_config_5); + const _config_7 = resolveUserAgentConfig(_config_6); + super(_config_7); + this.config = _config_7; this.middlewareStack.use(getRetryPlugin(this.config)); this.middlewareStack.use(getContentLengthPlugin(this.config)); this.middlewareStack.use(getHostHeaderPlugin(this.config)); diff --git a/clients/client-chime-sdk-messaging/src/commands/AssociateChannelFlowCommand.ts b/clients/client-chime-sdk-messaging/src/commands/AssociateChannelFlowCommand.ts index 7b0204c0ce17..63b933ed6903 100644 --- a/clients/client-chime-sdk-messaging/src/commands/AssociateChannelFlowCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/AssociateChannelFlowCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -57,6 +58,15 @@ export class AssociateChannelFlowCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: AssociateChannelFlowCommandInput) { // Start section: command_constructor super(); @@ -72,6 +82,9 @@ export class AssociateChannelFlowCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, AssociateChannelFlowCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/BatchCreateChannelMembershipCommand.ts b/clients/client-chime-sdk-messaging/src/commands/BatchCreateChannelMembershipCommand.ts index b8a6504780d0..7e226adb54f1 100644 --- a/clients/client-chime-sdk-messaging/src/commands/BatchCreateChannelMembershipCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/BatchCreateChannelMembershipCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -58,6 +59,15 @@ export class BatchCreateChannelMembershipCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: BatchCreateChannelMembershipCommandInput) { // Start section: command_constructor super(); @@ -73,6 +83,9 @@ export class BatchCreateChannelMembershipCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, BatchCreateChannelMembershipCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/ChannelFlowCallbackCommand.ts b/clients/client-chime-sdk-messaging/src/commands/ChannelFlowCallbackCommand.ts index 08831fed17bb..1cd1412b0239 100644 --- a/clients/client-chime-sdk-messaging/src/commands/ChannelFlowCallbackCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/ChannelFlowCallbackCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -68,6 +69,15 @@ export class ChannelFlowCallbackCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: ChannelFlowCallbackCommandInput) { // Start section: command_constructor super(); @@ -83,6 +93,9 @@ export class ChannelFlowCallbackCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, ChannelFlowCallbackCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/CreateChannelBanCommand.ts b/clients/client-chime-sdk-messaging/src/commands/CreateChannelBanCommand.ts index 21a7cca0e4ea..9122526ae962 100644 --- a/clients/client-chime-sdk-messaging/src/commands/CreateChannelBanCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/CreateChannelBanCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -67,6 +68,15 @@ export class CreateChannelBanCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: CreateChannelBanCommandInput) { // Start section: command_constructor super(); @@ -82,6 +92,9 @@ export class CreateChannelBanCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, CreateChannelBanCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/CreateChannelCommand.ts b/clients/client-chime-sdk-messaging/src/commands/CreateChannelCommand.ts index 5389de152180..9928a5eb5fda 100644 --- a/clients/client-chime-sdk-messaging/src/commands/CreateChannelCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/CreateChannelCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -66,6 +67,15 @@ export class CreateChannelCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: CreateChannelCommandInput) { // Start section: command_constructor super(); @@ -81,6 +91,7 @@ export class CreateChannelCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(getEndpointPlugin(configuration, CreateChannelCommand.getEndpointParameterInstructions())); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/CreateChannelFlowCommand.ts b/clients/client-chime-sdk-messaging/src/commands/CreateChannelFlowCommand.ts index 69eb7c2b596c..9507789ec655 100644 --- a/clients/client-chime-sdk-messaging/src/commands/CreateChannelFlowCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/CreateChannelFlowCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -77,6 +78,15 @@ export class CreateChannelFlowCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: CreateChannelFlowCommandInput) { // Start section: command_constructor super(); @@ -92,6 +102,9 @@ export class CreateChannelFlowCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, CreateChannelFlowCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/CreateChannelMembershipCommand.ts b/clients/client-chime-sdk-messaging/src/commands/CreateChannelMembershipCommand.ts index 7f9481ff761a..e92bb77f53b8 100644 --- a/clients/client-chime-sdk-messaging/src/commands/CreateChannelMembershipCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/CreateChannelMembershipCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -93,6 +94,15 @@ export class CreateChannelMembershipCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: CreateChannelMembershipCommandInput) { // Start section: command_constructor super(); @@ -108,6 +118,9 @@ export class CreateChannelMembershipCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, CreateChannelMembershipCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/CreateChannelModeratorCommand.ts b/clients/client-chime-sdk-messaging/src/commands/CreateChannelModeratorCommand.ts index e9248a4d2980..c683041299a9 100644 --- a/clients/client-chime-sdk-messaging/src/commands/CreateChannelModeratorCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/CreateChannelModeratorCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -80,6 +81,15 @@ export class CreateChannelModeratorCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: CreateChannelModeratorCommandInput) { // Start section: command_constructor super(); @@ -95,6 +105,9 @@ export class CreateChannelModeratorCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, CreateChannelModeratorCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/DeleteChannelBanCommand.ts b/clients/client-chime-sdk-messaging/src/commands/DeleteChannelBanCommand.ts index 4f0907172c9e..c46144c4cca5 100644 --- a/clients/client-chime-sdk-messaging/src/commands/DeleteChannelBanCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/DeleteChannelBanCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -57,6 +58,15 @@ export class DeleteChannelBanCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: DeleteChannelBanCommandInput) { // Start section: command_constructor super(); @@ -72,6 +82,9 @@ export class DeleteChannelBanCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, DeleteChannelBanCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/DeleteChannelCommand.ts b/clients/client-chime-sdk-messaging/src/commands/DeleteChannelCommand.ts index 15ee81587966..75d9cb240f69 100644 --- a/clients/client-chime-sdk-messaging/src/commands/DeleteChannelCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/DeleteChannelCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -58,6 +59,15 @@ export class DeleteChannelCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: DeleteChannelCommandInput) { // Start section: command_constructor super(); @@ -73,6 +83,7 @@ export class DeleteChannelCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(getEndpointPlugin(configuration, DeleteChannelCommand.getEndpointParameterInstructions())); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/DeleteChannelFlowCommand.ts b/clients/client-chime-sdk-messaging/src/commands/DeleteChannelFlowCommand.ts index 5b7a000ffa2a..6671645783b0 100644 --- a/clients/client-chime-sdk-messaging/src/commands/DeleteChannelFlowCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/DeleteChannelFlowCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -55,6 +56,15 @@ export class DeleteChannelFlowCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: DeleteChannelFlowCommandInput) { // Start section: command_constructor super(); @@ -70,6 +80,9 @@ export class DeleteChannelFlowCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, DeleteChannelFlowCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/DeleteChannelMembershipCommand.ts b/clients/client-chime-sdk-messaging/src/commands/DeleteChannelMembershipCommand.ts index 032d9cc56c95..78bc9a3d71dd 100644 --- a/clients/client-chime-sdk-messaging/src/commands/DeleteChannelMembershipCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/DeleteChannelMembershipCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -57,6 +58,15 @@ export class DeleteChannelMembershipCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: DeleteChannelMembershipCommandInput) { // Start section: command_constructor super(); @@ -72,6 +82,9 @@ export class DeleteChannelMembershipCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, DeleteChannelMembershipCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/DeleteChannelMessageCommand.ts b/clients/client-chime-sdk-messaging/src/commands/DeleteChannelMessageCommand.ts index e1849e1e6a09..cabccd0aa6a1 100644 --- a/clients/client-chime-sdk-messaging/src/commands/DeleteChannelMessageCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/DeleteChannelMessageCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -59,6 +60,15 @@ export class DeleteChannelMessageCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: DeleteChannelMessageCommandInput) { // Start section: command_constructor super(); @@ -74,6 +84,9 @@ export class DeleteChannelMessageCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, DeleteChannelMessageCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/DeleteChannelModeratorCommand.ts b/clients/client-chime-sdk-messaging/src/commands/DeleteChannelModeratorCommand.ts index d193ed4fd67e..891cae29d338 100644 --- a/clients/client-chime-sdk-messaging/src/commands/DeleteChannelModeratorCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/DeleteChannelModeratorCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -57,6 +58,15 @@ export class DeleteChannelModeratorCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: DeleteChannelModeratorCommandInput) { // Start section: command_constructor super(); @@ -72,6 +82,9 @@ export class DeleteChannelModeratorCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, DeleteChannelModeratorCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/DescribeChannelBanCommand.ts b/clients/client-chime-sdk-messaging/src/commands/DescribeChannelBanCommand.ts index 01647e49c1e7..287d94d201d6 100644 --- a/clients/client-chime-sdk-messaging/src/commands/DescribeChannelBanCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/DescribeChannelBanCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -63,6 +64,15 @@ export class DescribeChannelBanCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: DescribeChannelBanCommandInput) { // Start section: command_constructor super(); @@ -78,6 +88,9 @@ export class DescribeChannelBanCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, DescribeChannelBanCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/DescribeChannelCommand.ts b/clients/client-chime-sdk-messaging/src/commands/DescribeChannelCommand.ts index 4830b0f9c572..6511f0ad2dae 100644 --- a/clients/client-chime-sdk-messaging/src/commands/DescribeChannelCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/DescribeChannelCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -64,6 +65,15 @@ export class DescribeChannelCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: DescribeChannelCommandInput) { // Start section: command_constructor super(); @@ -79,6 +89,9 @@ export class DescribeChannelCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, DescribeChannelCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/DescribeChannelFlowCommand.ts b/clients/client-chime-sdk-messaging/src/commands/DescribeChannelFlowCommand.ts index 984582b19635..7c47e40cb69f 100644 --- a/clients/client-chime-sdk-messaging/src/commands/DescribeChannelFlowCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/DescribeChannelFlowCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -56,6 +57,15 @@ export class DescribeChannelFlowCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: DescribeChannelFlowCommandInput) { // Start section: command_constructor super(); @@ -71,6 +81,9 @@ export class DescribeChannelFlowCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, DescribeChannelFlowCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/DescribeChannelMembershipCommand.ts b/clients/client-chime-sdk-messaging/src/commands/DescribeChannelMembershipCommand.ts index 4c640e1021e0..974a8e5d4c3c 100644 --- a/clients/client-chime-sdk-messaging/src/commands/DescribeChannelMembershipCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/DescribeChannelMembershipCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -61,6 +62,15 @@ export class DescribeChannelMembershipCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: DescribeChannelMembershipCommandInput) { // Start section: command_constructor super(); @@ -76,6 +86,9 @@ export class DescribeChannelMembershipCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, DescribeChannelMembershipCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/DescribeChannelMembershipForAppInstanceUserCommand.ts b/clients/client-chime-sdk-messaging/src/commands/DescribeChannelMembershipForAppInstanceUserCommand.ts index a7cb1844c675..5f0fd2a4d228 100644 --- a/clients/client-chime-sdk-messaging/src/commands/DescribeChannelMembershipForAppInstanceUserCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/DescribeChannelMembershipForAppInstanceUserCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -66,6 +67,15 @@ export class DescribeChannelMembershipForAppInstanceUserCommand extends $Command // 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" }, + }; + } + constructor(readonly input: DescribeChannelMembershipForAppInstanceUserCommandInput) { // Start section: command_constructor super(); @@ -84,6 +94,12 @@ export class DescribeChannelMembershipForAppInstanceUserCommand extends $Command DescribeChannelMembershipForAppInstanceUserCommandOutput > { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin( + configuration, + DescribeChannelMembershipForAppInstanceUserCommand.getEndpointParameterInstructions() + ) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/DescribeChannelModeratedByAppInstanceUserCommand.ts b/clients/client-chime-sdk-messaging/src/commands/DescribeChannelModeratedByAppInstanceUserCommand.ts index 63ea365f7727..704cceceb2b8 100644 --- a/clients/client-chime-sdk-messaging/src/commands/DescribeChannelModeratedByAppInstanceUserCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/DescribeChannelModeratedByAppInstanceUserCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -66,6 +67,15 @@ export class DescribeChannelModeratedByAppInstanceUserCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: DescribeChannelModeratedByAppInstanceUserCommandInput) { // Start section: command_constructor super(); @@ -84,6 +94,12 @@ export class DescribeChannelModeratedByAppInstanceUserCommand extends $Command< DescribeChannelModeratedByAppInstanceUserCommandOutput > { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin( + configuration, + DescribeChannelModeratedByAppInstanceUserCommand.getEndpointParameterInstructions() + ) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/DescribeChannelModeratorCommand.ts b/clients/client-chime-sdk-messaging/src/commands/DescribeChannelModeratorCommand.ts index d51b47d2ee55..943ffde46e41 100644 --- a/clients/client-chime-sdk-messaging/src/commands/DescribeChannelModeratorCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/DescribeChannelModeratorCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -61,6 +62,15 @@ export class DescribeChannelModeratorCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: DescribeChannelModeratorCommandInput) { // Start section: command_constructor super(); @@ -76,6 +86,9 @@ export class DescribeChannelModeratorCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, DescribeChannelModeratorCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/DisassociateChannelFlowCommand.ts b/clients/client-chime-sdk-messaging/src/commands/DisassociateChannelFlowCommand.ts index 03f8896d61eb..c848703a9fa1 100644 --- a/clients/client-chime-sdk-messaging/src/commands/DisassociateChannelFlowCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/DisassociateChannelFlowCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -56,6 +57,15 @@ export class DisassociateChannelFlowCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: DisassociateChannelFlowCommandInput) { // Start section: command_constructor super(); @@ -71,6 +81,9 @@ export class DisassociateChannelFlowCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, DisassociateChannelFlowCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/GetChannelMembershipPreferencesCommand.ts b/clients/client-chime-sdk-messaging/src/commands/GetChannelMembershipPreferencesCommand.ts index 002a9dc1ec53..500825c58d99 100644 --- a/clients/client-chime-sdk-messaging/src/commands/GetChannelMembershipPreferencesCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/GetChannelMembershipPreferencesCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -60,6 +61,15 @@ export class GetChannelMembershipPreferencesCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: GetChannelMembershipPreferencesCommandInput) { // Start section: command_constructor super(); @@ -75,6 +85,9 @@ export class GetChannelMembershipPreferencesCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, GetChannelMembershipPreferencesCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/GetChannelMessageCommand.ts b/clients/client-chime-sdk-messaging/src/commands/GetChannelMessageCommand.ts index 3e5340716e9d..1ff3463b32f2 100644 --- a/clients/client-chime-sdk-messaging/src/commands/GetChannelMessageCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/GetChannelMessageCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -62,6 +63,15 @@ export class GetChannelMessageCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: GetChannelMessageCommandInput) { // Start section: command_constructor super(); @@ -77,6 +87,9 @@ export class GetChannelMessageCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, GetChannelMessageCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/GetChannelMessageStatusCommand.ts b/clients/client-chime-sdk-messaging/src/commands/GetChannelMessageStatusCommand.ts index 246ff4cbb752..62de8cce612a 100644 --- a/clients/client-chime-sdk-messaging/src/commands/GetChannelMessageStatusCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/GetChannelMessageStatusCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -92,6 +93,15 @@ export class GetChannelMessageStatusCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: GetChannelMessageStatusCommandInput) { // Start section: command_constructor super(); @@ -107,6 +117,9 @@ export class GetChannelMessageStatusCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, GetChannelMessageStatusCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/GetMessagingSessionEndpointCommand.ts b/clients/client-chime-sdk-messaging/src/commands/GetMessagingSessionEndpointCommand.ts index eab2fd5ad7f3..31ca1a7f7e73 100644 --- a/clients/client-chime-sdk-messaging/src/commands/GetMessagingSessionEndpointCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/GetMessagingSessionEndpointCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -58,6 +59,15 @@ export class GetMessagingSessionEndpointCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: GetMessagingSessionEndpointCommandInput) { // Start section: command_constructor super(); @@ -73,6 +83,9 @@ export class GetMessagingSessionEndpointCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, GetMessagingSessionEndpointCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/ListChannelBansCommand.ts b/clients/client-chime-sdk-messaging/src/commands/ListChannelBansCommand.ts index 0419dfc1554f..d420581782a9 100644 --- a/clients/client-chime-sdk-messaging/src/commands/ListChannelBansCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/ListChannelBansCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -62,6 +63,15 @@ export class ListChannelBansCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: ListChannelBansCommandInput) { // Start section: command_constructor super(); @@ -77,6 +87,9 @@ export class ListChannelBansCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, ListChannelBansCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/ListChannelFlowsCommand.ts b/clients/client-chime-sdk-messaging/src/commands/ListChannelFlowsCommand.ts index 8c0b2d7efaa3..2be0d7f94549 100644 --- a/clients/client-chime-sdk-messaging/src/commands/ListChannelFlowsCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/ListChannelFlowsCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -56,6 +57,15 @@ export class ListChannelFlowsCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: ListChannelFlowsCommandInput) { // Start section: command_constructor super(); @@ -71,6 +81,9 @@ export class ListChannelFlowsCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, ListChannelFlowsCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/ListChannelMembershipsCommand.ts b/clients/client-chime-sdk-messaging/src/commands/ListChannelMembershipsCommand.ts index 1cf3a9914637..c3b5d43ebd7d 100644 --- a/clients/client-chime-sdk-messaging/src/commands/ListChannelMembershipsCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/ListChannelMembershipsCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -65,6 +66,15 @@ export class ListChannelMembershipsCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: ListChannelMembershipsCommandInput) { // Start section: command_constructor super(); @@ -80,6 +90,9 @@ export class ListChannelMembershipsCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, ListChannelMembershipsCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/ListChannelMembershipsForAppInstanceUserCommand.ts b/clients/client-chime-sdk-messaging/src/commands/ListChannelMembershipsForAppInstanceUserCommand.ts index 06669f45b58e..41e6c39948c4 100644 --- a/clients/client-chime-sdk-messaging/src/commands/ListChannelMembershipsForAppInstanceUserCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/ListChannelMembershipsForAppInstanceUserCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -66,6 +67,15 @@ export class ListChannelMembershipsForAppInstanceUserCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: ListChannelMembershipsForAppInstanceUserCommandInput) { // Start section: command_constructor super(); @@ -84,6 +94,12 @@ export class ListChannelMembershipsForAppInstanceUserCommand extends $Command< ListChannelMembershipsForAppInstanceUserCommandOutput > { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin( + configuration, + ListChannelMembershipsForAppInstanceUserCommand.getEndpointParameterInstructions() + ) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/ListChannelMessagesCommand.ts b/clients/client-chime-sdk-messaging/src/commands/ListChannelMessagesCommand.ts index a720a8328d9e..38771b432894 100644 --- a/clients/client-chime-sdk-messaging/src/commands/ListChannelMessagesCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/ListChannelMessagesCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -66,6 +67,15 @@ export class ListChannelMessagesCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: ListChannelMessagesCommandInput) { // Start section: command_constructor super(); @@ -81,6 +91,9 @@ export class ListChannelMessagesCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, ListChannelMessagesCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/ListChannelModeratorsCommand.ts b/clients/client-chime-sdk-messaging/src/commands/ListChannelModeratorsCommand.ts index 094c19fce4f0..b42bc34b0220 100644 --- a/clients/client-chime-sdk-messaging/src/commands/ListChannelModeratorsCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/ListChannelModeratorsCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -61,6 +62,15 @@ export class ListChannelModeratorsCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: ListChannelModeratorsCommandInput) { // Start section: command_constructor super(); @@ -76,6 +86,9 @@ export class ListChannelModeratorsCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, ListChannelModeratorsCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/ListChannelsAssociatedWithChannelFlowCommand.ts b/clients/client-chime-sdk-messaging/src/commands/ListChannelsAssociatedWithChannelFlowCommand.ts index 7bc74fa4f11f..205aa55d0fb6 100644 --- a/clients/client-chime-sdk-messaging/src/commands/ListChannelsAssociatedWithChannelFlowCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/ListChannelsAssociatedWithChannelFlowCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -59,6 +60,15 @@ export class ListChannelsAssociatedWithChannelFlowCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: ListChannelsAssociatedWithChannelFlowCommandInput) { // Start section: command_constructor super(); @@ -74,6 +84,9 @@ export class ListChannelsAssociatedWithChannelFlowCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, ListChannelsAssociatedWithChannelFlowCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/ListChannelsCommand.ts b/clients/client-chime-sdk-messaging/src/commands/ListChannelsCommand.ts index e9cc828bfb68..72e11ce713b8 100644 --- a/clients/client-chime-sdk-messaging/src/commands/ListChannelsCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/ListChannelsCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -77,6 +78,15 @@ export class ListChannelsCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: ListChannelsCommandInput) { // Start section: command_constructor super(); @@ -92,6 +102,7 @@ export class ListChannelsCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(getEndpointPlugin(configuration, ListChannelsCommand.getEndpointParameterInstructions())); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/ListChannelsModeratedByAppInstanceUserCommand.ts b/clients/client-chime-sdk-messaging/src/commands/ListChannelsModeratedByAppInstanceUserCommand.ts index b2cfa5910133..7e8041dad9dc 100644 --- a/clients/client-chime-sdk-messaging/src/commands/ListChannelsModeratedByAppInstanceUserCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/ListChannelsModeratedByAppInstanceUserCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -65,6 +66,15 @@ export class ListChannelsModeratedByAppInstanceUserCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: ListChannelsModeratedByAppInstanceUserCommandInput) { // Start section: command_constructor super(); @@ -80,6 +90,9 @@ export class ListChannelsModeratedByAppInstanceUserCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, ListChannelsModeratedByAppInstanceUserCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/ListSubChannelsCommand.ts b/clients/client-chime-sdk-messaging/src/commands/ListSubChannelsCommand.ts index 8df27efee4f4..319ace04d15c 100644 --- a/clients/client-chime-sdk-messaging/src/commands/ListSubChannelsCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/ListSubChannelsCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -56,6 +57,15 @@ export class ListSubChannelsCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: ListSubChannelsCommandInput) { // Start section: command_constructor super(); @@ -71,6 +81,9 @@ export class ListSubChannelsCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, ListSubChannelsCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/ListTagsForResourceCommand.ts b/clients/client-chime-sdk-messaging/src/commands/ListTagsForResourceCommand.ts index dc947aa42941..cdcd83907e60 100644 --- a/clients/client-chime-sdk-messaging/src/commands/ListTagsForResourceCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/ListTagsForResourceCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -56,6 +57,15 @@ export class ListTagsForResourceCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: ListTagsForResourceCommandInput) { // Start section: command_constructor super(); @@ -71,6 +81,9 @@ export class ListTagsForResourceCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, ListTagsForResourceCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/PutChannelMembershipPreferencesCommand.ts b/clients/client-chime-sdk-messaging/src/commands/PutChannelMembershipPreferencesCommand.ts index 4e256fad530b..68dbed881f98 100644 --- a/clients/client-chime-sdk-messaging/src/commands/PutChannelMembershipPreferencesCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/PutChannelMembershipPreferencesCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -60,6 +61,15 @@ export class PutChannelMembershipPreferencesCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: PutChannelMembershipPreferencesCommandInput) { // Start section: command_constructor super(); @@ -75,6 +85,9 @@ export class PutChannelMembershipPreferencesCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, PutChannelMembershipPreferencesCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/RedactChannelMessageCommand.ts b/clients/client-chime-sdk-messaging/src/commands/RedactChannelMessageCommand.ts index 2abde1447e57..f3beb10de377 100644 --- a/clients/client-chime-sdk-messaging/src/commands/RedactChannelMessageCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/RedactChannelMessageCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -63,6 +64,15 @@ export class RedactChannelMessageCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: RedactChannelMessageCommandInput) { // Start section: command_constructor super(); @@ -78,6 +88,9 @@ export class RedactChannelMessageCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, RedactChannelMessageCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/SearchChannelsCommand.ts b/clients/client-chime-sdk-messaging/src/commands/SearchChannelsCommand.ts index 9930c28b9eb3..b84a63a75f71 100644 --- a/clients/client-chime-sdk-messaging/src/commands/SearchChannelsCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/SearchChannelsCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -32,8 +33,7 @@ export interface SearchChannelsCommandInput extends SearchChannelsRequest {} export interface SearchChannelsCommandOutput extends SearchChannelsResponse, __MetadataBearer {} /** - *

Allows an AppInstanceUser to search the channels that they belong to. The AppInstanceUser can search by membership or external ID. - * An AppInstanceAdmin can search across all channels within the AppInstance.

+ *

Allows ChimeBearer to search channels by channel members. AppInstanceUsers can search across the channels that they belong to. AppInstanceAdmins can search across all channels.

* @example * Use a bare-bones client and the command you need to make an API call. * ```javascript @@ -57,6 +57,15 @@ export class SearchChannelsCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: SearchChannelsCommandInput) { // Start section: command_constructor super(); @@ -72,6 +81,9 @@ export class SearchChannelsCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, SearchChannelsCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/SendChannelMessageCommand.ts b/clients/client-chime-sdk-messaging/src/commands/SendChannelMessageCommand.ts index 55e162b00059..12ef9930900e 100644 --- a/clients/client-chime-sdk-messaging/src/commands/SendChannelMessageCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/SendChannelMessageCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -65,6 +66,15 @@ export class SendChannelMessageCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: SendChannelMessageCommandInput) { // Start section: command_constructor super(); @@ -80,6 +90,9 @@ export class SendChannelMessageCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, SendChannelMessageCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/TagResourceCommand.ts b/clients/client-chime-sdk-messaging/src/commands/TagResourceCommand.ts index 166221d74468..8ca67757c14b 100644 --- a/clients/client-chime-sdk-messaging/src/commands/TagResourceCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/TagResourceCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -51,6 +52,15 @@ export class TagResourceCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: TagResourceCommandInput) { // Start section: command_constructor super(); @@ -66,6 +76,7 @@ export class TagResourceCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(getEndpointPlugin(configuration, TagResourceCommand.getEndpointParameterInstructions())); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/UntagResourceCommand.ts b/clients/client-chime-sdk-messaging/src/commands/UntagResourceCommand.ts index 5491858a2a99..ef77969b0bab 100644 --- a/clients/client-chime-sdk-messaging/src/commands/UntagResourceCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/UntagResourceCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -51,6 +52,15 @@ export class UntagResourceCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: UntagResourceCommandInput) { // Start section: command_constructor super(); @@ -66,6 +76,7 @@ export class UntagResourceCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(getEndpointPlugin(configuration, UntagResourceCommand.getEndpointParameterInstructions())); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/UpdateChannelCommand.ts b/clients/client-chime-sdk-messaging/src/commands/UpdateChannelCommand.ts index 66dd4ad4a38c..3978fa7114b9 100644 --- a/clients/client-chime-sdk-messaging/src/commands/UpdateChannelCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/UpdateChannelCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -63,6 +64,15 @@ export class UpdateChannelCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: UpdateChannelCommandInput) { // Start section: command_constructor super(); @@ -78,6 +88,7 @@ export class UpdateChannelCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(getEndpointPlugin(configuration, UpdateChannelCommand.getEndpointParameterInstructions())); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/UpdateChannelFlowCommand.ts b/clients/client-chime-sdk-messaging/src/commands/UpdateChannelFlowCommand.ts index bf64eac28006..d6887b04965f 100644 --- a/clients/client-chime-sdk-messaging/src/commands/UpdateChannelFlowCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/UpdateChannelFlowCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -56,6 +57,15 @@ export class UpdateChannelFlowCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: UpdateChannelFlowCommandInput) { // Start section: command_constructor super(); @@ -71,6 +81,9 @@ export class UpdateChannelFlowCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, UpdateChannelFlowCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/UpdateChannelMessageCommand.ts b/clients/client-chime-sdk-messaging/src/commands/UpdateChannelMessageCommand.ts index 27f36ce524cf..7fca2bb177ab 100644 --- a/clients/client-chime-sdk-messaging/src/commands/UpdateChannelMessageCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/UpdateChannelMessageCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -62,6 +63,15 @@ export class UpdateChannelMessageCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: UpdateChannelMessageCommandInput) { // Start section: command_constructor super(); @@ -77,6 +87,9 @@ export class UpdateChannelMessageCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, UpdateChannelMessageCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/commands/UpdateChannelReadMarkerCommand.ts b/clients/client-chime-sdk-messaging/src/commands/UpdateChannelReadMarkerCommand.ts index 41c74aacd269..bedbe57f25c6 100644 --- a/clients/client-chime-sdk-messaging/src/commands/UpdateChannelReadMarkerCommand.ts +++ b/clients/client-chime-sdk-messaging/src/commands/UpdateChannelReadMarkerCommand.ts @@ -1,4 +1,5 @@ // smithy-typescript generated code +import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; import { Command as $Command } from "@aws-sdk/smithy-client"; @@ -62,6 +63,15 @@ export class UpdateChannelReadMarkerCommand extends $Command< // 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" }, + }; + } + constructor(readonly input: UpdateChannelReadMarkerCommandInput) { // Start section: command_constructor super(); @@ -77,6 +87,9 @@ export class UpdateChannelReadMarkerCommand extends $Command< options?: __HttpHandlerOptions ): Handler { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use( + getEndpointPlugin(configuration, UpdateChannelReadMarkerCommand.getEndpointParameterInstructions()) + ); const stack = clientStack.concat(this.middlewareStack); diff --git a/clients/client-chime-sdk-messaging/src/endpoint/EndpointParameters.ts b/clients/client-chime-sdk-messaging/src/endpoint/EndpointParameters.ts new file mode 100644 index 000000000000..730fc812f001 --- /dev/null +++ b/clients/client-chime-sdk-messaging/src/endpoint/EndpointParameters.ts @@ -0,0 +1,31 @@ +// smithy-typescript generated code +import { EndpointParameters as __EndpointParameters, Provider } from "@aws-sdk/types"; + +export interface ClientInputEndpointParameters { + region?: string | Provider; + useDualstackEndpoint?: boolean | Provider; + useFipsEndpoint?: boolean | Provider; + endpoint?: string | Provider; +} + +export type ClientResolvedEndpointParameters = ClientInputEndpointParameters & { + defaultSigningName: string; +}; + +export const resolveClientEndpointParameters = ( + options: T & ClientInputEndpointParameters +): T & ClientResolvedEndpointParameters => { + return { + ...options, + useDualstackEndpoint: options.useDualstackEndpoint ?? false, + useFipsEndpoint: options.useFipsEndpoint ?? false, + defaultSigningName: "chime", + }; +}; + +export interface EndpointParameters extends __EndpointParameters { + Region: string; + UseDualStack?: boolean; + UseFIPS?: boolean; + Endpoint?: string; +} diff --git a/clients/client-chime-sdk-messaging/src/endpoint/endpointResolver.ts b/clients/client-chime-sdk-messaging/src/endpoint/endpointResolver.ts new file mode 100644 index 000000000000..34538a4ce53a --- /dev/null +++ b/clients/client-chime-sdk-messaging/src/endpoint/endpointResolver.ts @@ -0,0 +1,16 @@ +// smithy-typescript generated code +import { EndpointV2, Logger } from "@aws-sdk/types"; +import { EndpointParams, resolveEndpoint } from "@aws-sdk/util-endpoints"; + +import { EndpointParameters } from "../endpoint/EndpointParameters"; +import { ruleSet } from "../endpoint/ruleset"; + +export const defaultEndpointResolver = ( + endpointParams: EndpointParameters, + context: { logger?: Logger } = {} +): EndpointV2 => { + return resolveEndpoint(ruleSet, { + endpointParams: endpointParams as EndpointParams, + logger: context.logger, + }); +}; diff --git a/clients/client-chime-sdk-messaging/src/endpoint/ruleset.ts b/clients/client-chime-sdk-messaging/src/endpoint/ruleset.ts new file mode 100644 index 000000000000..5e4ec3097ae7 --- /dev/null +++ b/clients/client-chime-sdk-messaging/src/endpoint/ruleset.ts @@ -0,0 +1,320 @@ +// smithy-typescript generated code +import { RuleSetObject } from "@aws-sdk/util-endpoints"; + +export const ruleSet: RuleSetObject = { + version: "1.0", + parameters: { + Region: { + builtIn: "AWS::Region", + required: true, + documentation: "The AWS region used to dispatch the request.", + type: "String", + }, + UseDualStack: { + builtIn: "AWS::UseDualStack", + required: true, + default: false, + documentation: + "When true, use the dual-stack endpoint. If the configured endpoint does not support dual-stack, dispatching the request MAY return an error.", + type: "Boolean", + }, + UseFIPS: { + builtIn: "AWS::UseFIPS", + required: true, + default: false, + documentation: + "When true, send this request to the FIPS-compliant regional endpoint. If the configured endpoint does not have a FIPS compliant endpoint, dispatching the request will return an error.", + type: "Boolean", + }, + Endpoint: { + builtIn: "SDK::Endpoint", + required: false, + documentation: "Override the endpoint used to send this request", + type: "String", + }, + }, + rules: [ + { + conditions: [ + { + fn: "aws.partition", + argv: [ + { + ref: "Region", + }, + ], + assign: "PartitionResult", + }, + ], + type: "tree", + rules: [ + { + conditions: [ + { + fn: "isSet", + argv: [ + { + ref: "Endpoint", + }, + ], + }, + { + fn: "parseURL", + argv: [ + { + ref: "Endpoint", + }, + ], + assign: "url", + }, + ], + type: "tree", + rules: [ + { + conditions: [ + { + fn: "booleanEquals", + argv: [ + { + ref: "UseFIPS", + }, + true, + ], + }, + ], + error: "Invalid Configuration: FIPS and custom endpoint are not supported", + type: "error", + }, + { + conditions: [], + type: "tree", + rules: [ + { + conditions: [ + { + fn: "booleanEquals", + argv: [ + { + ref: "UseDualStack", + }, + true, + ], + }, + ], + error: "Invalid Configuration: Dualstack and custom endpoint are not supported", + type: "error", + }, + { + conditions: [], + endpoint: { + url: { + ref: "Endpoint", + }, + properties: {}, + headers: {}, + }, + type: "endpoint", + }, + ], + }, + ], + }, + { + conditions: [ + { + fn: "booleanEquals", + argv: [ + { + ref: "UseFIPS", + }, + true, + ], + }, + { + fn: "booleanEquals", + argv: [ + { + ref: "UseDualStack", + }, + true, + ], + }, + ], + type: "tree", + rules: [ + { + conditions: [ + { + fn: "booleanEquals", + argv: [ + true, + { + fn: "getAttr", + argv: [ + { + ref: "PartitionResult", + }, + "supportsFIPS", + ], + }, + ], + }, + { + fn: "booleanEquals", + argv: [ + true, + { + fn: "getAttr", + argv: [ + { + ref: "PartitionResult", + }, + "supportsDualStack", + ], + }, + ], + }, + ], + type: "tree", + rules: [ + { + conditions: [], + endpoint: { + url: "https://messaging-chime-fips.{Region}.{PartitionResult#dualStackDnsSuffix}", + properties: {}, + headers: {}, + }, + type: "endpoint", + }, + ], + }, + { + conditions: [], + error: "FIPS and DualStack are enabled, but this partition does not support one or both", + type: "error", + }, + ], + }, + { + conditions: [ + { + fn: "booleanEquals", + argv: [ + { + ref: "UseFIPS", + }, + true, + ], + }, + ], + type: "tree", + rules: [ + { + conditions: [ + { + fn: "booleanEquals", + argv: [ + true, + { + fn: "getAttr", + argv: [ + { + ref: "PartitionResult", + }, + "supportsFIPS", + ], + }, + ], + }, + ], + type: "tree", + rules: [ + { + conditions: [], + type: "tree", + rules: [ + { + conditions: [], + endpoint: { + url: "https://messaging-chime-fips.{Region}.{PartitionResult#dnsSuffix}", + properties: {}, + headers: {}, + }, + type: "endpoint", + }, + ], + }, + ], + }, + { + conditions: [], + error: "FIPS is enabled but this partition does not support FIPS", + type: "error", + }, + ], + }, + { + conditions: [ + { + fn: "booleanEquals", + argv: [ + { + ref: "UseDualStack", + }, + true, + ], + }, + ], + type: "tree", + rules: [ + { + conditions: [ + { + fn: "booleanEquals", + argv: [ + true, + { + fn: "getAttr", + argv: [ + { + ref: "PartitionResult", + }, + "supportsDualStack", + ], + }, + ], + }, + ], + type: "tree", + rules: [ + { + conditions: [], + endpoint: { + url: "https://messaging-chime.{Region}.{PartitionResult#dualStackDnsSuffix}", + properties: {}, + headers: {}, + }, + type: "endpoint", + }, + ], + }, + { + conditions: [], + error: "DualStack is enabled but this partition does not support DualStack", + type: "error", + }, + ], + }, + { + conditions: [], + endpoint: { + url: "https://messaging-chime.{Region}.{PartitionResult#dnsSuffix}", + properties: {}, + headers: {}, + }, + type: "endpoint", + }, + ], + }, + ], +}; diff --git a/clients/client-chime-sdk-messaging/src/endpoints.ts b/clients/client-chime-sdk-messaging/src/endpoints.ts deleted file mode 100644 index 51c94e818a3a..000000000000 --- a/clients/client-chime-sdk-messaging/src/endpoints.ts +++ /dev/null @@ -1,147 +0,0 @@ -// smithy-typescript generated code -import { getRegionInfo, PartitionHash, RegionHash } from "@aws-sdk/config-resolver"; -import { RegionInfoProvider, RegionInfoProviderOptions } from "@aws-sdk/types"; - -const regionHash: RegionHash = { - "us-east-1": { - variants: [ - { - hostname: "messaging-chime-fips.us-east-1.amazonaws.com", - tags: ["fips"], - }, - ], - }, -}; - -const partitionHash: PartitionHash = { - aws: { - regions: [ - "af-south-1", - "ap-east-1", - "ap-northeast-1", - "ap-northeast-2", - "ap-northeast-3", - "ap-south-1", - "ap-southeast-1", - "ap-southeast-2", - "ap-southeast-3", - "ca-central-1", - "eu-central-1", - "eu-north-1", - "eu-south-1", - "eu-west-1", - "eu-west-2", - "eu-west-3", - "me-central-1", - "me-south-1", - "sa-east-1", - "us-east-1", - "us-east-1-fips", - "us-east-2", - "us-west-1", - "us-west-2", - ], - regionRegex: "^(us|eu|ap|sa|ca|me|af)\\-\\w+\\-\\d+$", - variants: [ - { - hostname: "messaging-chime.{region}.amazonaws.com", - tags: [], - }, - { - hostname: "messaging-chime-fips.{region}.amazonaws.com", - tags: ["fips"], - }, - { - hostname: "messaging-chime-fips.{region}.api.aws", - tags: ["dualstack", "fips"], - }, - { - hostname: "messaging-chime.{region}.api.aws", - tags: ["dualstack"], - }, - ], - }, - "aws-cn": { - regions: ["cn-north-1", "cn-northwest-1"], - regionRegex: "^cn\\-\\w+\\-\\d+$", - variants: [ - { - hostname: "messaging-chime.{region}.amazonaws.com.cn", - tags: [], - }, - { - hostname: "messaging-chime-fips.{region}.amazonaws.com.cn", - tags: ["fips"], - }, - { - hostname: "messaging-chime-fips.{region}.api.amazonwebservices.com.cn", - tags: ["dualstack", "fips"], - }, - { - hostname: "messaging-chime.{region}.api.amazonwebservices.com.cn", - tags: ["dualstack"], - }, - ], - }, - "aws-iso": { - regions: ["us-iso-east-1", "us-iso-west-1"], - regionRegex: "^us\\-iso\\-\\w+\\-\\d+$", - variants: [ - { - hostname: "messaging-chime.{region}.c2s.ic.gov", - tags: [], - }, - { - hostname: "messaging-chime-fips.{region}.c2s.ic.gov", - tags: ["fips"], - }, - ], - }, - "aws-iso-b": { - regions: ["us-isob-east-1"], - regionRegex: "^us\\-isob\\-\\w+\\-\\d+$", - variants: [ - { - hostname: "messaging-chime.{region}.sc2s.sgov.gov", - tags: [], - }, - { - hostname: "messaging-chime-fips.{region}.sc2s.sgov.gov", - tags: ["fips"], - }, - ], - }, - "aws-us-gov": { - regions: ["us-gov-east-1", "us-gov-west-1"], - regionRegex: "^us\\-gov\\-\\w+\\-\\d+$", - variants: [ - { - hostname: "messaging-chime.{region}.amazonaws.com", - tags: [], - }, - { - hostname: "messaging-chime-fips.{region}.amazonaws.com", - tags: ["fips"], - }, - { - hostname: "messaging-chime-fips.{region}.api.aws", - tags: ["dualstack", "fips"], - }, - { - hostname: "messaging-chime.{region}.api.aws", - tags: ["dualstack"], - }, - ], - }, -}; - -export const defaultRegionInfoProvider: RegionInfoProvider = async ( - region: string, - options?: RegionInfoProviderOptions -) => - getRegionInfo(region, { - ...options, - signingService: "chime", - regionHash, - partitionHash, - }); diff --git a/clients/client-chime-sdk-messaging/src/models/models_0.ts b/clients/client-chime-sdk-messaging/src/models/models_0.ts index 52621bfc576e..9c353666b577 100644 --- a/clients/client-chime-sdk-messaging/src/models/models_0.ts +++ b/clients/client-chime-sdk-messaging/src/models/models_0.ts @@ -833,7 +833,7 @@ export interface ChannelSummary { Metadata?: string; /** - *

The time at which the last message in a channel was sent.

+ *

The time at which the last persistent message in a channel was sent.

*/ LastMessageTimestamp?: Date; } diff --git a/clients/client-chime-sdk-messaging/src/runtimeConfig.shared.ts b/clients/client-chime-sdk-messaging/src/runtimeConfig.shared.ts index 70064e5440ce..bd93aa9b5a90 100644 --- a/clients/client-chime-sdk-messaging/src/runtimeConfig.shared.ts +++ b/clients/client-chime-sdk-messaging/src/runtimeConfig.shared.ts @@ -3,7 +3,7 @@ import { Logger as __Logger } from "@aws-sdk/types"; import { parseUrl } from "@aws-sdk/url-parser"; import { ChimeSDKMessagingClientConfig } from "./ChimeSDKMessagingClient"; -import { defaultRegionInfoProvider } from "./endpoints"; +import { defaultEndpointResolver } from "./endpoint/endpointResolver"; /** * @internal @@ -11,8 +11,8 @@ import { defaultRegionInfoProvider } from "./endpoints"; export const getRuntimeConfig = (config: ChimeSDKMessagingClientConfig) => ({ apiVersion: "2021-05-15", disableHostPrefix: config?.disableHostPrefix ?? false, + endpointProvider: config?.endpointProvider ?? defaultEndpointResolver, logger: config?.logger ?? ({} as __Logger), - regionInfoProvider: config?.regionInfoProvider ?? defaultRegionInfoProvider, serviceId: config?.serviceId ?? "Chime SDK Messaging", urlParser: config?.urlParser ?? parseUrl, }); diff --git a/codegen/sdk-codegen/aws-models/chime-sdk-messaging.json b/codegen/sdk-codegen/aws-models/chime-sdk-messaging.json index f5eff5ed1f25..4de5a5ced15f 100644 --- a/codegen/sdk-codegen/aws-models/chime-sdk-messaging.json +++ b/codegen/sdk-codegen/aws-models/chime-sdk-messaging.json @@ -1,5 +1,5 @@ { - "smithy": "1.0", + "smithy": "2.0", "metadata": { "suppressions": [ { @@ -30,22 +30,26 @@ }, "shapes": { "com.amazonaws.chimesdkmessaging#AllowNotifications": { - "type": "string", - "traits": { - "smithy.api#enum": [ - { - "value": "ALL", - "name": "ALL" - }, - { - "value": "NONE", - "name": "NONE" - }, - { - "value": "FILTERED", - "name": "FILTERED" + "type": "enum", + "members": { + "ALL": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "ALL" + } + }, + "NONE": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "NONE" } - ] + }, + "FILTERED": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "FILTERED" + } + } } }, "com.amazonaws.chimesdkmessaging#AppInstanceUserMembershipSummary": { @@ -610,6 +614,7 @@ "DeleteResource": { "target": "com.amazonaws.chimesdkmessaging#NonNullableBoolean", "traits": { + "smithy.api#default": false, "smithy.api#documentation": "

When a processor determines that a message needs to be DENIED, pass this parameter with a value of true.

" } }, @@ -642,7 +647,6 @@ "com.amazonaws.chimesdkmessaging#ChannelFlowExecutionOrder": { "type": "integer", "traits": { - "smithy.api#box": {}, "smithy.api#range": { "min": 1, "max": 3 @@ -815,18 +819,20 @@ } }, "com.amazonaws.chimesdkmessaging#ChannelMembershipType": { - "type": "string", - "traits": { - "smithy.api#enum": [ - { - "value": "DEFAULT", - "name": "DEFAULT" - }, - { - "value": "HIDDEN", - "name": "HIDDEN" + "type": "enum", + "members": { + "DEFAULT": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "DEFAULT" + } + }, + "HIDDEN": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "HIDDEN" } - ] + } } }, "com.amazonaws.chimesdkmessaging#ChannelMessage": { @@ -889,6 +895,7 @@ "Redacted": { "target": "com.amazonaws.chimesdkmessaging#NonNullableBoolean", "traits": { + "smithy.api#default": false, "smithy.api#documentation": "

Hides the content of a message.

" } }, @@ -967,41 +974,49 @@ } }, "com.amazonaws.chimesdkmessaging#ChannelMessagePersistenceType": { - "type": "string", - "traits": { - "smithy.api#enum": [ - { - "value": "PERSISTENT", - "name": "PERSISTENT" - }, - { - "value": "NON_PERSISTENT", - "name": "NON_PERSISTENT" + "type": "enum", + "members": { + "PERSISTENT": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "PERSISTENT" } - ] + }, + "NON_PERSISTENT": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "NON_PERSISTENT" + } + } } }, "com.amazonaws.chimesdkmessaging#ChannelMessageStatus": { - "type": "string", - "traits": { - "smithy.api#enum": [ - { - "value": "SENT", - "name": "SENT" - }, - { - "value": "PENDING", - "name": "PENDING" - }, - { - "value": "FAILED", - "name": "FAILED" - }, - { - "value": "DENIED", - "name": "DENIED" + "type": "enum", + "members": { + "SENT": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "SENT" } - ] + }, + "PENDING": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "PENDING" + } + }, + "FAILED": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "FAILED" + } + }, + "DENIED": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "DENIED" + } + } } }, "com.amazonaws.chimesdkmessaging#ChannelMessageStatusStructure": { @@ -1078,6 +1093,7 @@ "Redacted": { "target": "com.amazonaws.chimesdkmessaging#NonNullableBoolean", "traits": { + "smithy.api#default": false, "smithy.api#documentation": "

Indicates whether a message was redacted.

" } }, @@ -1105,33 +1121,37 @@ } }, "com.amazonaws.chimesdkmessaging#ChannelMessageType": { - "type": "string", - "traits": { - "smithy.api#enum": [ - { - "value": "STANDARD", - "name": "STANDARD" - }, - { - "value": "CONTROL", - "name": "CONTROL" + "type": "enum", + "members": { + "STANDARD": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "STANDARD" } - ] + }, + "CONTROL": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "CONTROL" + } + } } }, "com.amazonaws.chimesdkmessaging#ChannelMode": { - "type": "string", - "traits": { - "smithy.api#enum": [ - { - "value": "UNRESTRICTED", - "name": "UNRESTRICTED" - }, - { - "value": "RESTRICTED", - "name": "RESTRICTED" + "type": "enum", + "members": { + "UNRESTRICTED": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "UNRESTRICTED" } - ] + }, + "RESTRICTED": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "RESTRICTED" + } + } } }, "com.amazonaws.chimesdkmessaging#ChannelModeratedByAppInstanceUserSummary": { @@ -1219,18 +1239,20 @@ } }, "com.amazonaws.chimesdkmessaging#ChannelPrivacy": { - "type": "string", - "traits": { - "smithy.api#enum": [ - { - "value": "PUBLIC", - "name": "PUBLIC" - }, - { - "value": "PRIVATE", - "name": "PRIVATE" + "type": "enum", + "members": { + "PUBLIC": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "PUBLIC" } - ] + }, + "PRIVATE": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "PRIVATE" + } + } } }, "com.amazonaws.chimesdkmessaging#ChannelSummary": { @@ -1269,7 +1291,7 @@ "LastMessageTimestamp": { "target": "com.amazonaws.chimesdkmessaging#Timestamp", "traits": { - "smithy.api#documentation": "

The time at which the last message in a channel was sent.

" + "smithy.api#documentation": "

The time at which the last persistent message in a channel was sent.

" } } }, @@ -1295,21 +1317,6 @@ }, "com.amazonaws.chimesdkmessaging#ChimeMessagingService": { "type": "service", - "traits": { - "aws.api#service": { - "sdkId": "Chime SDK Messaging", - "arnNamespace": "chime", - "cloudFormationName": "ChimeSDKMessaging", - "cloudTrailEventSource": "chimesdkmessaging.amazonaws.com", - "endpointPrefix": "messaging-chime" - }, - "aws.auth#sigv4": { - "name": "chime" - }, - "aws.protocols#restJson1": {}, - "smithy.api#documentation": "

The Amazon Chime SDK Messaging APIs in this section allow software developers to send\n and receive messages in custom messaging applications. These APIs depend on the frameworks\n provided by the Amazon Chime SDK Identity APIs. For more information about the messaging\n APIs, see Amazon Chime SDK messaging.

", - "smithy.api#title": "Amazon Chime SDK Messaging" - }, "version": "2021-05-15", "operations": [ { @@ -1453,7 +1460,484 @@ { "target": "com.amazonaws.chimesdkmessaging#UpdateChannelReadMarker" } - ] + ], + "traits": { + "aws.api#service": { + "sdkId": "Chime SDK Messaging", + "arnNamespace": "chime", + "cloudFormationName": "ChimeSDKMessaging", + "cloudTrailEventSource": "chimesdkmessaging.amazonaws.com", + "endpointPrefix": "messaging-chime" + }, + "aws.auth#sigv4": { + "name": "chime" + }, + "aws.protocols#restJson1": {}, + "smithy.api#documentation": "

The Amazon Chime SDK Messaging APIs in this section allow software developers to send\n and receive messages in custom messaging applications. These APIs depend on the frameworks\n provided by the Amazon Chime SDK Identity APIs. For more information about the messaging\n APIs, see Amazon Chime SDK messaging.

", + "smithy.api#title": "Amazon Chime SDK Messaging", + "smithy.rules#endpointRuleSet": { + "version": "1.0", + "parameters": { + "Region": { + "builtIn": "AWS::Region", + "required": true, + "documentation": "The AWS region used to dispatch the request.", + "type": "String" + }, + "UseDualStack": { + "builtIn": "AWS::UseDualStack", + "required": true, + "default": false, + "documentation": "When true, use the dual-stack endpoint. If the configured endpoint does not support dual-stack, dispatching the request MAY return an error.", + "type": "Boolean" + }, + "UseFIPS": { + "builtIn": "AWS::UseFIPS", + "required": true, + "default": false, + "documentation": "When true, send this request to the FIPS-compliant regional endpoint. If the configured endpoint does not have a FIPS compliant endpoint, dispatching the request will return an error.", + "type": "Boolean" + }, + "Endpoint": { + "builtIn": "SDK::Endpoint", + "required": false, + "documentation": "Override the endpoint used to send this request", + "type": "String" + } + }, + "rules": [ + { + "conditions": [ + { + "fn": "aws.partition", + "argv": [ + { + "ref": "Region" + } + ], + "assign": "PartitionResult" + } + ], + "type": "tree", + "rules": [ + { + "conditions": [ + { + "fn": "isSet", + "argv": [ + { + "ref": "Endpoint" + } + ] + }, + { + "fn": "parseURL", + "argv": [ + { + "ref": "Endpoint" + } + ], + "assign": "url" + } + ], + "type": "tree", + "rules": [ + { + "conditions": [ + { + "fn": "booleanEquals", + "argv": [ + { + "ref": "UseFIPS" + }, + true + ] + } + ], + "error": "Invalid Configuration: FIPS and custom endpoint are not supported", + "type": "error" + }, + { + "conditions": [], + "type": "tree", + "rules": [ + { + "conditions": [ + { + "fn": "booleanEquals", + "argv": [ + { + "ref": "UseDualStack" + }, + true + ] + } + ], + "error": "Invalid Configuration: Dualstack and custom endpoint are not supported", + "type": "error" + }, + { + "conditions": [], + "endpoint": { + "url": { + "ref": "Endpoint" + }, + "properties": {}, + "headers": {} + }, + "type": "endpoint" + } + ] + } + ] + }, + { + "conditions": [ + { + "fn": "booleanEquals", + "argv": [ + { + "ref": "UseFIPS" + }, + true + ] + }, + { + "fn": "booleanEquals", + "argv": [ + { + "ref": "UseDualStack" + }, + true + ] + } + ], + "type": "tree", + "rules": [ + { + "conditions": [ + { + "fn": "booleanEquals", + "argv": [ + true, + { + "fn": "getAttr", + "argv": [ + { + "ref": "PartitionResult" + }, + "supportsFIPS" + ] + } + ] + }, + { + "fn": "booleanEquals", + "argv": [ + true, + { + "fn": "getAttr", + "argv": [ + { + "ref": "PartitionResult" + }, + "supportsDualStack" + ] + } + ] + } + ], + "type": "tree", + "rules": [ + { + "conditions": [], + "endpoint": { + "url": "https://messaging-chime-fips.{Region}.{PartitionResult#dualStackDnsSuffix}", + "properties": {}, + "headers": {} + }, + "type": "endpoint" + } + ] + }, + { + "conditions": [], + "error": "FIPS and DualStack are enabled, but this partition does not support one or both", + "type": "error" + } + ] + }, + { + "conditions": [ + { + "fn": "booleanEquals", + "argv": [ + { + "ref": "UseFIPS" + }, + true + ] + } + ], + "type": "tree", + "rules": [ + { + "conditions": [ + { + "fn": "booleanEquals", + "argv": [ + true, + { + "fn": "getAttr", + "argv": [ + { + "ref": "PartitionResult" + }, + "supportsFIPS" + ] + } + ] + } + ], + "type": "tree", + "rules": [ + { + "conditions": [], + "type": "tree", + "rules": [ + { + "conditions": [], + "endpoint": { + "url": "https://messaging-chime-fips.{Region}.{PartitionResult#dnsSuffix}", + "properties": {}, + "headers": {} + }, + "type": "endpoint" + } + ] + } + ] + }, + { + "conditions": [], + "error": "FIPS is enabled but this partition does not support FIPS", + "type": "error" + } + ] + }, + { + "conditions": [ + { + "fn": "booleanEquals", + "argv": [ + { + "ref": "UseDualStack" + }, + true + ] + } + ], + "type": "tree", + "rules": [ + { + "conditions": [ + { + "fn": "booleanEquals", + "argv": [ + true, + { + "fn": "getAttr", + "argv": [ + { + "ref": "PartitionResult" + }, + "supportsDualStack" + ] + } + ] + } + ], + "type": "tree", + "rules": [ + { + "conditions": [], + "endpoint": { + "url": "https://messaging-chime.{Region}.{PartitionResult#dualStackDnsSuffix}", + "properties": {}, + "headers": {} + }, + "type": "endpoint" + } + ] + }, + { + "conditions": [], + "error": "DualStack is enabled but this partition does not support DualStack", + "type": "error" + } + ] + }, + { + "conditions": [], + "endpoint": { + "url": "https://messaging-chime.{Region}.{PartitionResult#dnsSuffix}", + "properties": {}, + "headers": {} + }, + "type": "endpoint" + } + ] + } + ] + }, + "smithy.rules#endpointTests": { + "testCases": [ + { + "documentation": "For region eu-central-1 with FIPS enabled and DualStack enabled", + "expect": { + "endpoint": { + "url": "https://messaging-chime-fips.eu-central-1.api.aws" + } + }, + "params": { + "UseFIPS": true, + "Region": "eu-central-1", + "UseDualStack": true + } + }, + { + "documentation": "For region eu-central-1 with FIPS enabled and DualStack disabled", + "expect": { + "endpoint": { + "url": "https://messaging-chime-fips.eu-central-1.amazonaws.com" + } + }, + "params": { + "UseFIPS": true, + "Region": "eu-central-1", + "UseDualStack": false + } + }, + { + "documentation": "For region eu-central-1 with FIPS disabled and DualStack enabled", + "expect": { + "endpoint": { + "url": "https://messaging-chime.eu-central-1.api.aws" + } + }, + "params": { + "UseFIPS": false, + "Region": "eu-central-1", + "UseDualStack": true + } + }, + { + "documentation": "For region eu-central-1 with FIPS disabled and DualStack disabled", + "expect": { + "endpoint": { + "url": "https://messaging-chime.eu-central-1.amazonaws.com" + } + }, + "params": { + "UseFIPS": false, + "Region": "eu-central-1", + "UseDualStack": false + } + }, + { + "documentation": "For region us-east-1 with FIPS enabled and DualStack enabled", + "expect": { + "endpoint": { + "url": "https://messaging-chime-fips.us-east-1.api.aws" + } + }, + "params": { + "UseFIPS": true, + "Region": "us-east-1", + "UseDualStack": true + } + }, + { + "documentation": "For region us-east-1 with FIPS enabled and DualStack disabled", + "expect": { + "endpoint": { + "url": "https://messaging-chime-fips.us-east-1.amazonaws.com" + } + }, + "params": { + "UseFIPS": true, + "Region": "us-east-1", + "UseDualStack": false + } + }, + { + "documentation": "For region us-east-1 with FIPS disabled and DualStack enabled", + "expect": { + "endpoint": { + "url": "https://messaging-chime.us-east-1.api.aws" + } + }, + "params": { + "UseFIPS": false, + "Region": "us-east-1", + "UseDualStack": true + } + }, + { + "documentation": "For region us-east-1 with FIPS disabled and DualStack disabled", + "expect": { + "endpoint": { + "url": "https://messaging-chime.us-east-1.amazonaws.com" + } + }, + "params": { + "UseFIPS": false, + "Region": "us-east-1", + "UseDualStack": false + } + }, + { + "documentation": "For custom endpoint with fips disabled and dualstack disabled", + "expect": { + "endpoint": { + "url": "https://example.com" + } + }, + "params": { + "UseFIPS": false, + "Region": "us-east-1", + "UseDualStack": false, + "Endpoint": "https://example.com" + } + }, + { + "documentation": "For custom endpoint with fips enabled and dualstack disabled", + "expect": { + "error": "Invalid Configuration: FIPS and custom endpoint are not supported" + }, + "params": { + "UseFIPS": true, + "Region": "us-east-1", + "UseDualStack": false, + "Endpoint": "https://example.com" + } + }, + { + "documentation": "For custom endpoint with fips disabled and dualstack enabled", + "expect": { + "error": "Invalid Configuration: Dualstack and custom endpoint are not supported" + }, + "params": { + "UseFIPS": false, + "Region": "us-east-1", + "UseDualStack": true, + "Endpoint": "https://example.com" + } + } + ], + "version": "1.0" + } + } }, "com.amazonaws.chimesdkmessaging#ClientRequestToken": { "type": "string", @@ -3041,85 +3525,115 @@ } }, "com.amazonaws.chimesdkmessaging#ErrorCode": { - "type": "string", - "traits": { - "smithy.api#enum": [ - { - "value": "BadRequest", - "name": "BadRequest" - }, - { - "value": "Conflict", - "name": "Conflict" - }, - { - "value": "Forbidden", - "name": "Forbidden" - }, - { - "value": "NotFound", - "name": "NotFound" - }, - { - "value": "PreconditionFailed", - "name": "PreconditionFailed" - }, - { - "value": "ResourceLimitExceeded", - "name": "ResourceLimitExceeded" - }, - { - "value": "ServiceFailure", - "name": "ServiceFailure" - }, - { - "value": "AccessDenied", - "name": "AccessDenied" - }, - { - "value": "ServiceUnavailable", - "name": "ServiceUnavailable" - }, - { - "value": "Throttled", - "name": "Throttled" - }, - { - "value": "Throttling", - "name": "Throttling" - }, - { - "value": "Unauthorized", - "name": "Unauthorized" - }, - { - "value": "Unprocessable", - "name": "Unprocessable" - }, - { - "value": "VoiceConnectorGroupAssociationsExist", - "name": "VoiceConnectorGroupAssociationsExist" - }, - { - "value": "PhoneNumberAssociationsExist", - "name": "PhoneNumberAssociationsExist" + "type": "enum", + "members": { + "BadRequest": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "BadRequest" + } + }, + "Conflict": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "Conflict" + } + }, + "Forbidden": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "Forbidden" } - ] + }, + "NotFound": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "NotFound" + } + }, + "PreconditionFailed": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "PreconditionFailed" + } + }, + "ResourceLimitExceeded": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "ResourceLimitExceeded" + } + }, + "ServiceFailure": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "ServiceFailure" + } + }, + "AccessDenied": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "AccessDenied" + } + }, + "ServiceUnavailable": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "ServiceUnavailable" + } + }, + "Throttled": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "Throttled" + } + }, + "Throttling": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "Throttling" + } + }, + "Unauthorized": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "Unauthorized" + } + }, + "Unprocessable": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "Unprocessable" + } + }, + "VoiceConnectorGroupAssociationsExist": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "VoiceConnectorGroupAssociationsExist" + } + }, + "PhoneNumberAssociationsExist": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "PhoneNumberAssociationsExist" + } + } } }, "com.amazonaws.chimesdkmessaging#FallbackAction": { - "type": "string", - "traits": { - "smithy.api#enum": [ - { - "value": "CONTINUE", - "name": "CONTINUE" - }, - { - "value": "ABORT", - "name": "ABORT" + "type": "enum", + "members": { + "CONTINUE": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "CONTINUE" + } + }, + "ABORT": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "ABORT" } - ] + } } }, "com.amazonaws.chimesdkmessaging#FilterRule": { @@ -3478,14 +3992,14 @@ } }, "com.amazonaws.chimesdkmessaging#InvocationType": { - "type": "string", - "traits": { - "smithy.api#enum": [ - { - "value": "ASYNC", - "name": "ASYNC" + "type": "enum", + "members": { + "ASYNC": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "ASYNC" } - ] + } } }, "com.amazonaws.chimesdkmessaging#LambdaConfiguration": { @@ -4591,7 +5105,6 @@ "com.amazonaws.chimesdkmessaging#MaxResults": { "type": "integer", "traits": { - "smithy.api#box": {}, "smithy.api#range": { "min": 1, "max": 50 @@ -4601,7 +5114,6 @@ "com.amazonaws.chimesdkmessaging#MaximumSubChannels": { "type": "integer", "traits": { - "smithy.api#box": {}, "smithy.api#range": { "min": 2 } @@ -4626,10 +5138,7 @@ } }, "com.amazonaws.chimesdkmessaging#MembershipCount": { - "type": "integer", - "traits": { - "smithy.api#box": {} - } + "type": "integer" }, "com.amazonaws.chimesdkmessaging#MessageAttributeMap": { "type": "map", @@ -4720,7 +5229,6 @@ "com.amazonaws.chimesdkmessaging#MinimumMembershipPercentage": { "type": "integer", "traits": { - "smithy.api#box": {}, "smithy.api#range": { "min": 1, "max": 40 @@ -4760,7 +5268,10 @@ } }, "com.amazonaws.chimesdkmessaging#NonNullableBoolean": { - "type": "boolean" + "type": "boolean", + "traits": { + "smithy.api#default": false + } }, "com.amazonaws.chimesdkmessaging#NotFoundException": { "type": "structure", @@ -4911,18 +5422,20 @@ } }, "com.amazonaws.chimesdkmessaging#PushNotificationType": { - "type": "string", - "traits": { - "smithy.api#enum": [ - { - "value": "DEFAULT", - "name": "DEFAULT" - }, - { - "value": "VOIP", - "name": "VOIP" + "type": "enum", + "members": { + "DEFAULT": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "DEFAULT" } - ] + }, + "VOIP": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "VOIP" + } + } } }, "com.amazonaws.chimesdkmessaging#PutChannelMembershipPreferences": { @@ -5178,7 +5691,7 @@ } ], "traits": { - "smithy.api#documentation": "

Allows an AppInstanceUser to search the channels that they belong to. The AppInstanceUser can search by membership or external ID. \n An AppInstanceAdmin can search across all channels within the AppInstance.

", + "smithy.api#documentation": "

Allows ChimeBearer to search channels by channel members. AppInstanceUsers can search across the channels that they belong to. AppInstanceAdmins can search across all channels.

", "smithy.api#http": { "method": "POST", "uri": "/channels?operation=search", @@ -5271,29 +5784,31 @@ } }, "com.amazonaws.chimesdkmessaging#SearchFieldKey": { - "type": "string", - "traits": { - "smithy.api#enum": [ - { - "value": "MEMBERS", - "name": "MEMBERS" + "type": "enum", + "members": { + "MEMBERS": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "MEMBERS" } - ] + } } }, "com.amazonaws.chimesdkmessaging#SearchFieldOperator": { - "type": "string", - "traits": { - "smithy.api#enum": [ - { - "value": "EQUALS", - "name": "EQUALS" - }, - { - "value": "INCLUDES", - "name": "INCLUDES" + "type": "enum", + "members": { + "EQUALS": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "EQUALS" } - ] + }, + "INCLUDES": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "INCLUDES" + } + } } }, "com.amazonaws.chimesdkmessaging#SearchFieldValue": { @@ -5506,18 +6021,20 @@ } }, "com.amazonaws.chimesdkmessaging#SortOrder": { - "type": "string", - "traits": { - "smithy.api#enum": [ - { - "value": "ASCENDING", - "name": "ASCENDING" - }, - { - "value": "DESCENDING", - "name": "DESCENDING" + "type": "enum", + "members": { + "ASCENDING": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "ASCENDING" + } + }, + "DESCENDING": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "DESCENDING" } - ] + } } }, "com.amazonaws.chimesdkmessaging#StatusDetail": { @@ -5697,7 +6214,6 @@ "com.amazonaws.chimesdkmessaging#TargetMembershipsPerSubChannel": { "type": "integer", "traits": { - "smithy.api#box": {}, "smithy.api#range": { "min": 2 }