Skip to content

Commit 5da8835

Browse files
author
awstools
committed
feat(client-qbusiness): Added APIs to manage QBusiness user subscriptions
1 parent 1b99b4f commit 5da8835

24 files changed

+1987
-283
lines changed

clients/client-qbusiness/README.md

+32
Original file line numberDiff line numberDiff line change
@@ -264,6 +264,14 @@ BatchPutDocument
264264

265265
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/qbusiness/command/BatchPutDocumentCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-qbusiness/Interface/BatchPutDocumentCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-qbusiness/Interface/BatchPutDocumentCommandOutput/)
266266

267+
</details>
268+
<details>
269+
<summary>
270+
CancelSubscription
271+
</summary>
272+
273+
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/qbusiness/command/CancelSubscriptionCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-qbusiness/Interface/CancelSubscriptionCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-qbusiness/Interface/CancelSubscriptionCommandOutput/)
274+
267275
</details>
268276
<details>
269277
<summary>
@@ -328,6 +336,14 @@ CreateRetriever
328336

329337
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/qbusiness/command/CreateRetrieverCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-qbusiness/Interface/CreateRetrieverCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-qbusiness/Interface/CreateRetrieverCommandOutput/)
330338

339+
</details>
340+
<details>
341+
<summary>
342+
CreateSubscription
343+
</summary>
344+
345+
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/qbusiness/command/CreateSubscriptionCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-qbusiness/Interface/CreateSubscriptionCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-qbusiness/Interface/CreateSubscriptionCommandOutput/)
346+
331347
</details>
332348
<details>
333349
<summary>
@@ -656,6 +672,14 @@ ListRetrievers
656672

657673
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/qbusiness/command/ListRetrieversCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-qbusiness/Interface/ListRetrieversCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-qbusiness/Interface/ListRetrieversCommandOutput/)
658674

675+
</details>
676+
<details>
677+
<summary>
678+
ListSubscriptions
679+
</summary>
680+
681+
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/qbusiness/command/ListSubscriptionsCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-qbusiness/Interface/ListSubscriptionsCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-qbusiness/Interface/ListSubscriptionsCommandOutput/)
682+
659683
</details>
660684
<details>
661685
<summary>
@@ -784,6 +808,14 @@ UpdateRetriever
784808

785809
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/qbusiness/command/UpdateRetrieverCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-qbusiness/Interface/UpdateRetrieverCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-qbusiness/Interface/UpdateRetrieverCommandOutput/)
786810

811+
</details>
812+
<details>
813+
<summary>
814+
UpdateSubscription
815+
</summary>
816+
817+
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/qbusiness/command/UpdateSubscriptionCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-qbusiness/Interface/UpdateSubscriptionCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-qbusiness/Interface/UpdateSubscriptionCommandOutput/)
818+
787819
</details>
788820
<details>
789821
<summary>

clients/client-qbusiness/src/QBusiness.ts

+92
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,11 @@ import {
1717
BatchPutDocumentCommandInput,
1818
BatchPutDocumentCommandOutput,
1919
} from "./commands/BatchPutDocumentCommand";
20+
import {
21+
CancelSubscriptionCommand,
22+
CancelSubscriptionCommandInput,
23+
CancelSubscriptionCommandOutput,
24+
} from "./commands/CancelSubscriptionCommand";
2025
import { ChatCommand, ChatCommandInput, ChatCommandOutput } from "./commands/ChatCommand";
2126
import { ChatSyncCommand, ChatSyncCommandInput, ChatSyncCommandOutput } from "./commands/ChatSyncCommand";
2227
import {
@@ -45,6 +50,11 @@ import {
4550
CreateRetrieverCommandInput,
4651
CreateRetrieverCommandOutput,
4752
} from "./commands/CreateRetrieverCommand";
53+
import {
54+
CreateSubscriptionCommand,
55+
CreateSubscriptionCommandInput,
56+
CreateSubscriptionCommandOutput,
57+
} from "./commands/CreateSubscriptionCommand";
4858
import { CreateUserCommand, CreateUserCommandInput, CreateUserCommandOutput } from "./commands/CreateUserCommand";
4959
import {
5060
CreateWebExperienceCommand,
@@ -198,6 +208,11 @@ import {
198208
ListRetrieversCommandInput,
199209
ListRetrieversCommandOutput,
200210
} from "./commands/ListRetrieversCommand";
211+
import {
212+
ListSubscriptionsCommand,
213+
ListSubscriptionsCommandInput,
214+
ListSubscriptionsCommandOutput,
215+
} from "./commands/ListSubscriptionsCommand";
201216
import {
202217
ListTagsForResourceCommand,
203218
ListTagsForResourceCommandInput,
@@ -262,6 +277,11 @@ import {
262277
UpdateRetrieverCommandInput,
263278
UpdateRetrieverCommandOutput,
264279
} from "./commands/UpdateRetrieverCommand";
280+
import {
281+
UpdateSubscriptionCommand,
282+
UpdateSubscriptionCommandInput,
283+
UpdateSubscriptionCommandOutput,
284+
} from "./commands/UpdateSubscriptionCommand";
265285
import { UpdateUserCommand, UpdateUserCommandInput, UpdateUserCommandOutput } from "./commands/UpdateUserCommand";
266286
import {
267287
UpdateWebExperienceCommand,
@@ -274,6 +294,7 @@ const commands = {
274294
AssociatePermissionCommand,
275295
BatchDeleteDocumentCommand,
276296
BatchPutDocumentCommand,
297+
CancelSubscriptionCommand,
277298
ChatCommand,
278299
ChatSyncCommand,
279300
CreateApplicationCommand,
@@ -282,6 +303,7 @@ const commands = {
282303
CreateIndexCommand,
283304
CreatePluginCommand,
284305
CreateRetrieverCommand,
306+
CreateSubscriptionCommand,
285307
CreateUserCommand,
286308
CreateWebExperienceCommand,
287309
DeleteApplicationCommand,
@@ -323,6 +345,7 @@ const commands = {
323345
ListPluginTypeActionsCommand,
324346
ListPluginTypeMetadataCommand,
325347
ListRetrieversCommand,
348+
ListSubscriptionsCommand,
326349
ListTagsForResourceCommand,
327350
ListWebExperiencesCommand,
328351
PutFeedbackCommand,
@@ -339,6 +362,7 @@ const commands = {
339362
UpdateIndexCommand,
340363
UpdatePluginCommand,
341364
UpdateRetrieverCommand,
365+
UpdateSubscriptionCommand,
342366
UpdateUserCommand,
343367
UpdateWebExperienceCommand,
344368
};
@@ -395,6 +419,23 @@ export interface QBusiness {
395419
cb: (err: any, data?: BatchPutDocumentCommandOutput) => void
396420
): void;
397421

422+
/**
423+
* @see {@link CancelSubscriptionCommand}
424+
*/
425+
cancelSubscription(
426+
args: CancelSubscriptionCommandInput,
427+
options?: __HttpHandlerOptions
428+
): Promise<CancelSubscriptionCommandOutput>;
429+
cancelSubscription(
430+
args: CancelSubscriptionCommandInput,
431+
cb: (err: any, data?: CancelSubscriptionCommandOutput) => void
432+
): void;
433+
cancelSubscription(
434+
args: CancelSubscriptionCommandInput,
435+
options: __HttpHandlerOptions,
436+
cb: (err: any, data?: CancelSubscriptionCommandOutput) => void
437+
): void;
438+
398439
/**
399440
* @see {@link ChatCommand}
400441
*/
@@ -500,6 +541,23 @@ export interface QBusiness {
500541
cb: (err: any, data?: CreateRetrieverCommandOutput) => void
501542
): void;
502543

544+
/**
545+
* @see {@link CreateSubscriptionCommand}
546+
*/
547+
createSubscription(
548+
args: CreateSubscriptionCommandInput,
549+
options?: __HttpHandlerOptions
550+
): Promise<CreateSubscriptionCommandOutput>;
551+
createSubscription(
552+
args: CreateSubscriptionCommandInput,
553+
cb: (err: any, data?: CreateSubscriptionCommandOutput) => void
554+
): void;
555+
createSubscription(
556+
args: CreateSubscriptionCommandInput,
557+
options: __HttpHandlerOptions,
558+
cb: (err: any, data?: CreateSubscriptionCommandOutput) => void
559+
): void;
560+
503561
/**
504562
* @see {@link CreateUserCommand}
505563
*/
@@ -1073,6 +1131,23 @@ export interface QBusiness {
10731131
cb: (err: any, data?: ListRetrieversCommandOutput) => void
10741132
): void;
10751133

1134+
/**
1135+
* @see {@link ListSubscriptionsCommand}
1136+
*/
1137+
listSubscriptions(
1138+
args: ListSubscriptionsCommandInput,
1139+
options?: __HttpHandlerOptions
1140+
): Promise<ListSubscriptionsCommandOutput>;
1141+
listSubscriptions(
1142+
args: ListSubscriptionsCommandInput,
1143+
cb: (err: any, data?: ListSubscriptionsCommandOutput) => void
1144+
): void;
1145+
listSubscriptions(
1146+
args: ListSubscriptionsCommandInput,
1147+
options: __HttpHandlerOptions,
1148+
cb: (err: any, data?: ListSubscriptionsCommandOutput) => void
1149+
): void;
1150+
10761151
/**
10771152
* @see {@link ListTagsForResourceCommand}
10781153
*/
@@ -1306,6 +1381,23 @@ export interface QBusiness {
13061381
cb: (err: any, data?: UpdateRetrieverCommandOutput) => void
13071382
): void;
13081383

1384+
/**
1385+
* @see {@link UpdateSubscriptionCommand}
1386+
*/
1387+
updateSubscription(
1388+
args: UpdateSubscriptionCommandInput,
1389+
options?: __HttpHandlerOptions
1390+
): Promise<UpdateSubscriptionCommandOutput>;
1391+
updateSubscription(
1392+
args: UpdateSubscriptionCommandInput,
1393+
cb: (err: any, data?: UpdateSubscriptionCommandOutput) => void
1394+
): void;
1395+
updateSubscription(
1396+
args: UpdateSubscriptionCommandInput,
1397+
options: __HttpHandlerOptions,
1398+
cb: (err: any, data?: UpdateSubscriptionCommandOutput) => void
1399+
): void;
1400+
13091401
/**
13101402
* @see {@link UpdateUserCommand}
13111403
*/

clients/client-qbusiness/src/QBusinessClient.ts

+12
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,7 @@ import {
7474
BatchDeleteDocumentCommandOutput,
7575
} from "./commands/BatchDeleteDocumentCommand";
7676
import { BatchPutDocumentCommandInput, BatchPutDocumentCommandOutput } from "./commands/BatchPutDocumentCommand";
77+
import { CancelSubscriptionCommandInput, CancelSubscriptionCommandOutput } from "./commands/CancelSubscriptionCommand";
7778
import { ChatCommandInput, ChatCommandOutput } from "./commands/ChatCommand";
7879
import { ChatSyncCommandInput, ChatSyncCommandOutput } from "./commands/ChatSyncCommand";
7980
import { CreateApplicationCommandInput, CreateApplicationCommandOutput } from "./commands/CreateApplicationCommand";
@@ -82,6 +83,7 @@ import { CreateDataSourceCommandInput, CreateDataSourceCommandOutput } from "./c
8283
import { CreateIndexCommandInput, CreateIndexCommandOutput } from "./commands/CreateIndexCommand";
8384
import { CreatePluginCommandInput, CreatePluginCommandOutput } from "./commands/CreatePluginCommand";
8485
import { CreateRetrieverCommandInput, CreateRetrieverCommandOutput } from "./commands/CreateRetrieverCommand";
86+
import { CreateSubscriptionCommandInput, CreateSubscriptionCommandOutput } from "./commands/CreateSubscriptionCommand";
8587
import { CreateUserCommandInput, CreateUserCommandOutput } from "./commands/CreateUserCommand";
8688
import {
8789
CreateWebExperienceCommandInput,
@@ -147,6 +149,7 @@ import {
147149
ListPluginTypeMetadataCommandOutput,
148150
} from "./commands/ListPluginTypeMetadataCommand";
149151
import { ListRetrieversCommandInput, ListRetrieversCommandOutput } from "./commands/ListRetrieversCommand";
152+
import { ListSubscriptionsCommandInput, ListSubscriptionsCommandOutput } from "./commands/ListSubscriptionsCommand";
150153
import {
151154
ListTagsForResourceCommandInput,
152155
ListTagsForResourceCommandOutput,
@@ -178,6 +181,7 @@ import { UpdateDataSourceCommandInput, UpdateDataSourceCommandOutput } from "./c
178181
import { UpdateIndexCommandInput, UpdateIndexCommandOutput } from "./commands/UpdateIndexCommand";
179182
import { UpdatePluginCommandInput, UpdatePluginCommandOutput } from "./commands/UpdatePluginCommand";
180183
import { UpdateRetrieverCommandInput, UpdateRetrieverCommandOutput } from "./commands/UpdateRetrieverCommand";
184+
import { UpdateSubscriptionCommandInput, UpdateSubscriptionCommandOutput } from "./commands/UpdateSubscriptionCommand";
181185
import { UpdateUserCommandInput, UpdateUserCommandOutput } from "./commands/UpdateUserCommand";
182186
import {
183187
UpdateWebExperienceCommandInput,
@@ -201,6 +205,7 @@ export type ServiceInputTypes =
201205
| AssociatePermissionCommandInput
202206
| BatchDeleteDocumentCommandInput
203207
| BatchPutDocumentCommandInput
208+
| CancelSubscriptionCommandInput
204209
| ChatCommandInput
205210
| ChatSyncCommandInput
206211
| CreateApplicationCommandInput
@@ -209,6 +214,7 @@ export type ServiceInputTypes =
209214
| CreateIndexCommandInput
210215
| CreatePluginCommandInput
211216
| CreateRetrieverCommandInput
217+
| CreateSubscriptionCommandInput
212218
| CreateUserCommandInput
213219
| CreateWebExperienceCommandInput
214220
| DeleteApplicationCommandInput
@@ -250,6 +256,7 @@ export type ServiceInputTypes =
250256
| ListPluginTypeMetadataCommandInput
251257
| ListPluginsCommandInput
252258
| ListRetrieversCommandInput
259+
| ListSubscriptionsCommandInput
253260
| ListTagsForResourceCommandInput
254261
| ListWebExperiencesCommandInput
255262
| PutFeedbackCommandInput
@@ -266,6 +273,7 @@ export type ServiceInputTypes =
266273
| UpdateIndexCommandInput
267274
| UpdatePluginCommandInput
268275
| UpdateRetrieverCommandInput
276+
| UpdateSubscriptionCommandInput
269277
| UpdateUserCommandInput
270278
| UpdateWebExperienceCommandInput;
271279

@@ -276,6 +284,7 @@ export type ServiceOutputTypes =
276284
| AssociatePermissionCommandOutput
277285
| BatchDeleteDocumentCommandOutput
278286
| BatchPutDocumentCommandOutput
287+
| CancelSubscriptionCommandOutput
279288
| ChatCommandOutput
280289
| ChatSyncCommandOutput
281290
| CreateApplicationCommandOutput
@@ -284,6 +293,7 @@ export type ServiceOutputTypes =
284293
| CreateIndexCommandOutput
285294
| CreatePluginCommandOutput
286295
| CreateRetrieverCommandOutput
296+
| CreateSubscriptionCommandOutput
287297
| CreateUserCommandOutput
288298
| CreateWebExperienceCommandOutput
289299
| DeleteApplicationCommandOutput
@@ -325,6 +335,7 @@ export type ServiceOutputTypes =
325335
| ListPluginTypeMetadataCommandOutput
326336
| ListPluginsCommandOutput
327337
| ListRetrieversCommandOutput
338+
| ListSubscriptionsCommandOutput
328339
| ListTagsForResourceCommandOutput
329340
| ListWebExperiencesCommandOutput
330341
| PutFeedbackCommandOutput
@@ -341,6 +352,7 @@ export type ServiceOutputTypes =
341352
| UpdateIndexCommandOutput
342353
| UpdatePluginCommandOutput
343354
| UpdateRetrieverCommandOutput
355+
| UpdateSubscriptionCommandOutput
344356
| UpdateUserCommandOutput
345357
| UpdateWebExperienceCommandOutput;
346358

clients/client-qbusiness/src/commands/AssociatePermissionCommand.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,9 @@ export interface AssociatePermissionCommandInput extends AssociatePermissionRequ
2828
export interface AssociatePermissionCommandOutput extends AssociatePermissionResponse, __MetadataBearer {}
2929

3030
/**
31-
* <p>Adds or updates a permission policy for a Q Business application, allowing cross-account access for an ISV.
32-
* This operation creates a new policy statement for the specified Q Business application.
33-
* The policy statement defines the IAM actions that the ISV is allowed to perform on the Q Business application's resources.</p>
31+
* <p>Adds or updates a permission policy for a Amazon Q Business application, allowing cross-account access for an ISV.
32+
* This operation creates a new policy statement for the specified Amazon Q Business application.
33+
* The policy statement defines the IAM actions that the ISV is allowed to perform on the Amazon Q Business application's resources.</p>
3434
* @example
3535
* Use a bare-bones client and the command you need to make an API call.
3636
* ```javascript

0 commit comments

Comments
 (0)