Skip to content

Commit 0bfe6e2

Browse files
author
awstools
committed
feat(client-quicksight): Add StartDashboardSnapshotJobSchedule API. RestoreAnalysis now supports restoring analysis to folders.
1 parent e0b3fe4 commit 0bfe6e2

17 files changed

+427
-19
lines changed

clients/client-quicksight/README.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1351,6 +1351,14 @@ StartDashboardSnapshotJob
13511351

13521352
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/quicksight/command/StartDashboardSnapshotJobCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-quicksight/Interface/StartDashboardSnapshotJobCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-quicksight/Interface/StartDashboardSnapshotJobCommandOutput/)
13531353

1354+
</details>
1355+
<details>
1356+
<summary>
1357+
StartDashboardSnapshotJobSchedule
1358+
</summary>
1359+
1360+
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/quicksight/command/StartDashboardSnapshotJobScheduleCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-quicksight/Interface/StartDashboardSnapshotJobScheduleCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-quicksight/Interface/StartDashboardSnapshotJobScheduleCommandOutput/)
1361+
13541362
</details>
13551363
<details>
13561364
<summary>

clients/client-quicksight/src/QuickSight.ts

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -669,6 +669,11 @@ import {
669669
StartDashboardSnapshotJobCommandInput,
670670
StartDashboardSnapshotJobCommandOutput,
671671
} from "./commands/StartDashboardSnapshotJobCommand";
672+
import {
673+
StartDashboardSnapshotJobScheduleCommand,
674+
StartDashboardSnapshotJobScheduleCommandInput,
675+
StartDashboardSnapshotJobScheduleCommandOutput,
676+
} from "./commands/StartDashboardSnapshotJobScheduleCommand";
672677
import { TagResourceCommand, TagResourceCommandInput, TagResourceCommandOutput } from "./commands/TagResourceCommand";
673678
import {
674679
UntagResourceCommand,
@@ -980,6 +985,7 @@ const commands = {
980985
StartAssetBundleExportJobCommand,
981986
StartAssetBundleImportJobCommand,
982987
StartDashboardSnapshotJobCommand,
988+
StartDashboardSnapshotJobScheduleCommand,
983989
TagResourceCommand,
984990
UntagResourceCommand,
985991
UpdateAccountCustomizationCommand,
@@ -3235,6 +3241,23 @@ export interface QuickSight {
32353241
cb: (err: any, data?: StartDashboardSnapshotJobCommandOutput) => void
32363242
): void;
32373243

3244+
/**
3245+
* @see {@link StartDashboardSnapshotJobScheduleCommand}
3246+
*/
3247+
startDashboardSnapshotJobSchedule(
3248+
args: StartDashboardSnapshotJobScheduleCommandInput,
3249+
options?: __HttpHandlerOptions
3250+
): Promise<StartDashboardSnapshotJobScheduleCommandOutput>;
3251+
startDashboardSnapshotJobSchedule(
3252+
args: StartDashboardSnapshotJobScheduleCommandInput,
3253+
cb: (err: any, data?: StartDashboardSnapshotJobScheduleCommandOutput) => void
3254+
): void;
3255+
startDashboardSnapshotJobSchedule(
3256+
args: StartDashboardSnapshotJobScheduleCommandInput,
3257+
options: __HttpHandlerOptions,
3258+
cb: (err: any, data?: StartDashboardSnapshotJobScheduleCommandOutput) => void
3259+
): void;
3260+
32383261
/**
32393262
* @see {@link TagResourceCommand}
32403263
*/

clients/client-quicksight/src/QuickSightClient.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -433,6 +433,10 @@ import {
433433
StartDashboardSnapshotJobCommandInput,
434434
StartDashboardSnapshotJobCommandOutput,
435435
} from "./commands/StartDashboardSnapshotJobCommand";
436+
import {
437+
StartDashboardSnapshotJobScheduleCommandInput,
438+
StartDashboardSnapshotJobScheduleCommandOutput,
439+
} from "./commands/StartDashboardSnapshotJobScheduleCommand";
436440
import { TagResourceCommandInput, TagResourceCommandOutput } from "./commands/TagResourceCommand";
437441
import { UntagResourceCommandInput, UntagResourceCommandOutput } from "./commands/UntagResourceCommand";
438442
import {
@@ -700,6 +704,7 @@ export type ServiceInputTypes =
700704
| StartAssetBundleExportJobCommandInput
701705
| StartAssetBundleImportJobCommandInput
702706
| StartDashboardSnapshotJobCommandInput
707+
| StartDashboardSnapshotJobScheduleCommandInput
703708
| TagResourceCommandInput
704709
| UntagResourceCommandInput
705710
| UpdateAccountCustomizationCommandInput
@@ -885,6 +890,7 @@ export type ServiceOutputTypes =
885890
| StartAssetBundleExportJobCommandOutput
886891
| StartAssetBundleImportJobCommandOutput
887892
| StartDashboardSnapshotJobCommandOutput
893+
| StartDashboardSnapshotJobScheduleCommandOutput
888894
| TagResourceCommandOutput
889895
| UntagResourceCommandOutput
890896
| UpdateAccountCustomizationCommandOutput

clients/client-quicksight/src/commands/DescribeAnalysisPermissionsCommand.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ export interface DescribeAnalysisPermissionsCommandOutput
4949
* // { // DescribeAnalysisPermissionsResponse
5050
* // AnalysisId: "STRING_VALUE",
5151
* // AnalysisArn: "STRING_VALUE",
52-
* // Permissions: [ // ResourcePermissionList
52+
* // Permissions: [ // UpdateResourcePermissionList
5353
* // { // ResourcePermission
5454
* // Principal: "STRING_VALUE", // required
5555
* // Actions: [ // ActionList // required

clients/client-quicksight/src/commands/DescribeDashboardPermissionsCommand.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ export interface DescribeDashboardPermissionsCommandOutput
4949
* // { // DescribeDashboardPermissionsResponse
5050
* // DashboardId: "STRING_VALUE",
5151
* // DashboardArn: "STRING_VALUE",
52-
* // Permissions: [ // ResourcePermissionList
52+
* // Permissions: [ // UpdateResourcePermissionList
5353
* // { // ResourcePermission
5454
* // Principal: "STRING_VALUE", // required
5555
* // Actions: [ // ActionList // required
@@ -60,7 +60,7 @@ export interface DescribeDashboardPermissionsCommandOutput
6060
* // Status: Number("int"),
6161
* // RequestId: "STRING_VALUE",
6262
* // LinkSharingConfiguration: { // LinkSharingConfiguration
63-
* // Permissions: [
63+
* // Permissions: [ // ResourcePermissionList
6464
* // {
6565
* // Principal: "STRING_VALUE", // required
6666
* // Actions: [ // required

clients/client-quicksight/src/commands/DescribeTemplatePermissionsCommand.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ export interface DescribeTemplatePermissionsCommandOutput
4949
* // { // DescribeTemplatePermissionsResponse
5050
* // TemplateId: "STRING_VALUE",
5151
* // TemplateArn: "STRING_VALUE",
52-
* // Permissions: [ // ResourcePermissionList
52+
* // Permissions: [ // UpdateResourcePermissionList
5353
* // { // ResourcePermission
5454
* // Principal: "STRING_VALUE", // required
5555
* // Actions: [ // ActionList // required

clients/client-quicksight/src/commands/DescribeThemePermissionsCommand.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ export interface DescribeThemePermissionsCommandOutput extends DescribeThemePerm
4444
* // { // DescribeThemePermissionsResponse
4545
* // ThemeId: "STRING_VALUE",
4646
* // ThemeArn: "STRING_VALUE",
47-
* // Permissions: [ // ResourcePermissionList
47+
* // Permissions: [ // UpdateResourcePermissionList
4848
* // { // ResourcePermission
4949
* // Principal: "STRING_VALUE", // required
5050
* // Actions: [ // ActionList // required

clients/client-quicksight/src/commands/RestoreAnalysisCommand.ts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ export interface RestoreAnalysisCommandOutput extends RestoreAnalysisResponse, _
3838
* const input = { // RestoreAnalysisRequest
3939
* AwsAccountId: "STRING_VALUE", // required
4040
* AnalysisId: "STRING_VALUE", // required
41+
* RestoreToFolders: true || false,
4142
* };
4243
* const command = new RestoreAnalysisCommand(input);
4344
* const response = await client.send(command);
@@ -46,6 +47,9 @@ export interface RestoreAnalysisCommandOutput extends RestoreAnalysisResponse, _
4647
* // Arn: "STRING_VALUE",
4748
* // AnalysisId: "STRING_VALUE",
4849
* // RequestId: "STRING_VALUE",
50+
* // RestorationFailedFolderArns: [ // FolderArnList
51+
* // "STRING_VALUE",
52+
* // ],
4953
* // };
5054
*
5155
* ```
@@ -65,6 +69,12 @@ export interface RestoreAnalysisCommandOutput extends RestoreAnalysisResponse, _
6569
* @throws {@link InvalidParameterValueException} (client fault)
6670
* <p>One or more parameters has a value that isn't valid.</p>
6771
*
72+
* @throws {@link LimitExceededException} (client fault)
73+
* <p>A limit is exceeded.</p>
74+
*
75+
* @throws {@link PreconditionNotMetException} (client fault)
76+
* <p>One or more preconditions aren't met.</p>
77+
*
6878
* @throws {@link ResourceNotFoundException} (client fault)
6979
* <p>One or more resources can't be found.</p>
7080
*
Lines changed: 132 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,132 @@
1+
// smithy-typescript generated code
2+
import { getEndpointPlugin } from "@smithy/middleware-endpoint";
3+
import { getSerdePlugin } from "@smithy/middleware-serde";
4+
import { Command as $Command } from "@smithy/smithy-client";
5+
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
6+
7+
import { commonParams } from "../endpoint/EndpointParameters";
8+
import {
9+
StartDashboardSnapshotJobScheduleRequest,
10+
StartDashboardSnapshotJobScheduleResponse,
11+
} from "../models/models_4";
12+
import {
13+
de_StartDashboardSnapshotJobScheduleCommand,
14+
se_StartDashboardSnapshotJobScheduleCommand,
15+
} from "../protocols/Aws_restJson1";
16+
import { QuickSightClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../QuickSightClient";
17+
18+
/**
19+
* @public
20+
*/
21+
export type { __MetadataBearer };
22+
export { $Command };
23+
/**
24+
* @public
25+
*
26+
* The input for {@link StartDashboardSnapshotJobScheduleCommand}.
27+
*/
28+
export interface StartDashboardSnapshotJobScheduleCommandInput extends StartDashboardSnapshotJobScheduleRequest {}
29+
/**
30+
* @public
31+
*
32+
* The output of {@link StartDashboardSnapshotJobScheduleCommand}.
33+
*/
34+
export interface StartDashboardSnapshotJobScheduleCommandOutput
35+
extends StartDashboardSnapshotJobScheduleResponse,
36+
__MetadataBearer {}
37+
38+
/**
39+
* <p>Starts an asynchronous job that runs an existing dashboard schedule and sends the dashboard snapshot through email. </p>
40+
* <p>Only one job can run simultaneously in a given schedule. Repeated requests are skipped with a <code>202</code> HTTP status code.</p>
41+
* <p>For more information, see <a href="https://docs.aws.amazon.com/quicksight/latest/user/sending-reports.html">Scheduling and sending Amazon QuickSight reports by email</a> and <a href="https://docs.aws.amazon.com/quicksight/latest/user/email-reports-from-dashboard.html">Configuring email report settings for a Amazon QuickSight dashboard</a> in the <i>Amazon QuickSight User Guide</i>.</p>
42+
* @example
43+
* Use a bare-bones client and the command you need to make an API call.
44+
* ```javascript
45+
* import { QuickSightClient, StartDashboardSnapshotJobScheduleCommand } from "@aws-sdk/client-quicksight"; // ES Modules import
46+
* // const { QuickSightClient, StartDashboardSnapshotJobScheduleCommand } = require("@aws-sdk/client-quicksight"); // CommonJS import
47+
* const client = new QuickSightClient(config);
48+
* const input = { // StartDashboardSnapshotJobScheduleRequest
49+
* AwsAccountId: "STRING_VALUE", // required
50+
* DashboardId: "STRING_VALUE", // required
51+
* ScheduleId: "STRING_VALUE", // required
52+
* };
53+
* const command = new StartDashboardSnapshotJobScheduleCommand(input);
54+
* const response = await client.send(command);
55+
* // { // StartDashboardSnapshotJobScheduleResponse
56+
* // RequestId: "STRING_VALUE",
57+
* // Status: Number("int"),
58+
* // };
59+
*
60+
* ```
61+
*
62+
* @param StartDashboardSnapshotJobScheduleCommandInput - {@link StartDashboardSnapshotJobScheduleCommandInput}
63+
* @returns {@link StartDashboardSnapshotJobScheduleCommandOutput}
64+
* @see {@link StartDashboardSnapshotJobScheduleCommandInput} for command's `input` shape.
65+
* @see {@link StartDashboardSnapshotJobScheduleCommandOutput} for command's `response` shape.
66+
* @see {@link QuickSightClientResolvedConfig | config} for QuickSightClient's `config` shape.
67+
*
68+
* @throws {@link AccessDeniedException} (client fault)
69+
* <p>You don't have access to this item. The provided credentials couldn't be
70+
* validated. You might not be authorized to carry out the request. Make sure that your
71+
* account is authorized to use the Amazon QuickSight service, that your policies have the
72+
* correct permissions, and that you are using the correct credentials.</p>
73+
*
74+
* @throws {@link InternalFailureException} (server fault)
75+
* <p>An internal failure occurred.</p>
76+
*
77+
* @throws {@link InvalidParameterValueException} (client fault)
78+
* <p>One or more parameters has a value that isn't valid.</p>
79+
*
80+
* @throws {@link LimitExceededException} (client fault)
81+
* <p>A limit is exceeded.</p>
82+
*
83+
* @throws {@link ResourceNotFoundException} (client fault)
84+
* <p>One or more resources can't be found.</p>
85+
*
86+
* @throws {@link ThrottlingException} (client fault)
87+
* <p>Access is throttled.</p>
88+
*
89+
* @throws {@link UnsupportedUserEditionException} (client fault)
90+
* <p>This error indicates that you are calling an operation on an Amazon QuickSight
91+
* subscription where the edition doesn't include support for that operation. Amazon
92+
* Amazon QuickSight currently has Standard Edition and Enterprise Edition. Not every operation and
93+
* capability is available in every edition.</p>
94+
*
95+
* @throws {@link QuickSightServiceException}
96+
* <p>Base exception class for all service exceptions from QuickSight service.</p>
97+
*
98+
* @public
99+
*/
100+
export class StartDashboardSnapshotJobScheduleCommand extends $Command
101+
.classBuilder<
102+
StartDashboardSnapshotJobScheduleCommandInput,
103+
StartDashboardSnapshotJobScheduleCommandOutput,
104+
QuickSightClientResolvedConfig,
105+
ServiceInputTypes,
106+
ServiceOutputTypes
107+
>()
108+
.ep(commonParams)
109+
.m(function (this: any, Command: any, cs: any, config: QuickSightClientResolvedConfig, o: any) {
110+
return [
111+
getSerdePlugin(config, this.serialize, this.deserialize),
112+
getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
113+
];
114+
})
115+
.s("QuickSight_20180401", "StartDashboardSnapshotJobSchedule", {})
116+
.n("QuickSightClient", "StartDashboardSnapshotJobScheduleCommand")
117+
.f(void 0, void 0)
118+
.ser(se_StartDashboardSnapshotJobScheduleCommand)
119+
.de(de_StartDashboardSnapshotJobScheduleCommand)
120+
.build() {
121+
/** @internal type navigation helper, not in runtime. */
122+
protected declare static __types: {
123+
api: {
124+
input: StartDashboardSnapshotJobScheduleRequest;
125+
output: StartDashboardSnapshotJobScheduleResponse;
126+
};
127+
sdk: {
128+
input: StartDashboardSnapshotJobScheduleCommandInput;
129+
output: StartDashboardSnapshotJobScheduleCommandOutput;
130+
};
131+
};
132+
}

clients/client-quicksight/src/commands/UpdateAnalysisPermissionsCommand.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ export interface UpdateAnalysisPermissionsCommandOutput extends UpdateAnalysisPe
6060
* // { // UpdateAnalysisPermissionsResponse
6161
* // AnalysisArn: "STRING_VALUE",
6262
* // AnalysisId: "STRING_VALUE",
63-
* // Permissions: [ // ResourcePermissionList
63+
* // Permissions: [ // UpdateResourcePermissionList
6464
* // { // ResourcePermission
6565
* // Principal: "STRING_VALUE", // required
6666
* // Actions: [ // ActionList // required

clients/client-quicksight/src/commands/UpdateDashboardPermissionsCommand.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ export interface UpdateDashboardPermissionsCommandOutput extends UpdateDashboard
7676
* // { // UpdateDashboardPermissionsResponse
7777
* // DashboardArn: "STRING_VALUE",
7878
* // DashboardId: "STRING_VALUE",
79-
* // Permissions: [ // ResourcePermissionList
79+
* // Permissions: [ // UpdateResourcePermissionList
8080
* // { // ResourcePermission
8181
* // Principal: "STRING_VALUE", // required
8282
* // Actions: [ // ActionList // required
@@ -87,7 +87,7 @@ export interface UpdateDashboardPermissionsCommandOutput extends UpdateDashboard
8787
* // RequestId: "STRING_VALUE",
8888
* // Status: Number("int"),
8989
* // LinkSharingConfiguration: { // LinkSharingConfiguration
90-
* // Permissions: [
90+
* // Permissions: [ // ResourcePermissionList
9191
* // {
9292
* // Principal: "STRING_VALUE", // required
9393
* // Actions: [ // required

clients/client-quicksight/src/commands/UpdateTemplatePermissionsCommand.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ export interface UpdateTemplatePermissionsCommandOutput extends UpdateTemplatePe
6060
* // { // UpdateTemplatePermissionsResponse
6161
* // TemplateId: "STRING_VALUE",
6262
* // TemplateArn: "STRING_VALUE",
63-
* // Permissions: [ // ResourcePermissionList
63+
* // Permissions: [ // UpdateResourcePermissionList
6464
* // { // ResourcePermission
6565
* // Principal: "STRING_VALUE", // required
6666
* // Actions: [ // ActionList // required

clients/client-quicksight/src/commands/UpdateThemePermissionsCommand.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ export interface UpdateThemePermissionsCommandOutput extends UpdateThemePermissi
153153
* // { // UpdateThemePermissionsResponse
154154
* // ThemeId: "STRING_VALUE",
155155
* // ThemeArn: "STRING_VALUE",
156-
* // Permissions: [ // ResourcePermissionList
156+
* // Permissions: [ // UpdateResourcePermissionList
157157
* // { // ResourcePermission
158158
* // Principal: "STRING_VALUE", // required
159159
* // Actions: [ // ActionList // required

clients/client-quicksight/src/commands/index.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -142,6 +142,7 @@ export * from "./SearchGroupsCommand";
142142
export * from "./StartAssetBundleExportJobCommand";
143143
export * from "./StartAssetBundleImportJobCommand";
144144
export * from "./StartDashboardSnapshotJobCommand";
145+
export * from "./StartDashboardSnapshotJobScheduleCommand";
145146
export * from "./TagResourceCommand";
146147
export * from "./UntagResourceCommand";
147148
export * from "./UpdateAccountCustomizationCommand";

0 commit comments

Comments
 (0)