@aws-sdk/client-personalize 3.211.0 → 3.213.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist-cjs/Personalize.js +90 -0
- package/dist-cjs/commands/CreateMetricAttributionCommand.js +46 -0
- package/dist-cjs/commands/DeleteMetricAttributionCommand.js +46 -0
- package/dist-cjs/commands/DescribeMetricAttributionCommand.js +46 -0
- package/dist-cjs/commands/ListMetricAttributionMetricsCommand.js +46 -0
- package/dist-cjs/commands/ListMetricAttributionsCommand.js +46 -0
- package/dist-cjs/commands/UpdateMetricAttributionCommand.js +46 -0
- package/dist-cjs/commands/index.js +6 -0
- package/dist-cjs/models/models_0.js +64 -4
- package/dist-cjs/pagination/ListMetricAttributionMetricsPaginator.js +36 -0
- package/dist-cjs/pagination/ListMetricAttributionsPaginator.js +36 -0
- package/dist-cjs/pagination/index.js +2 -0
- package/dist-cjs/protocols/Aws_json1_1.js +499 -31
- package/dist-es/Personalize.js +90 -0
- package/dist-es/commands/CreateMetricAttributionCommand.js +42 -0
- package/dist-es/commands/DeleteMetricAttributionCommand.js +42 -0
- package/dist-es/commands/DescribeMetricAttributionCommand.js +42 -0
- package/dist-es/commands/ListMetricAttributionMetricsCommand.js +42 -0
- package/dist-es/commands/ListMetricAttributionsCommand.js +42 -0
- package/dist-es/commands/UpdateMetricAttributionCommand.js +42 -0
- package/dist-es/commands/index.js +6 -0
- package/dist-es/models/models_0.js +45 -0
- package/dist-es/pagination/ListMetricAttributionMetricsPaginator.js +32 -0
- package/dist-es/pagination/ListMetricAttributionsPaginator.js +32 -0
- package/dist-es/pagination/index.js +2 -0
- package/dist-es/protocols/Aws_json1_1.js +484 -28
- package/dist-types/Personalize.d.ts +44 -0
- package/dist-types/PersonalizeClient.d.ts +8 -2
- package/dist-types/commands/CreateMetricAttributionCommand.d.ts +39 -0
- package/dist-types/commands/DeleteMetricAttributionCommand.d.ts +37 -0
- package/dist-types/commands/DescribeMetricAttributionCommand.d.ts +37 -0
- package/dist-types/commands/ListMetricAttributionMetricsCommand.d.ts +37 -0
- package/dist-types/commands/ListMetricAttributionsCommand.d.ts +37 -0
- package/dist-types/commands/UpdateMetricAttributionCommand.d.ts +37 -0
- package/dist-types/commands/index.d.ts +6 -0
- package/dist-types/models/models_0.d.ts +295 -0
- package/dist-types/pagination/ListMetricAttributionMetricsPaginator.d.ts +4 -0
- package/dist-types/pagination/ListMetricAttributionsPaginator.d.ts +4 -0
- package/dist-types/pagination/index.d.ts +2 -0
- package/dist-types/protocols/Aws_json1_1.d.ts +18 -0
- package/dist-types/ts3.4/Personalize.d.ts +102 -0
- package/dist-types/ts3.4/PersonalizeClient.d.ts +36 -0
- package/dist-types/ts3.4/commands/CreateMetricAttributionCommand.d.ts +41 -0
- package/dist-types/ts3.4/commands/DeleteMetricAttributionCommand.d.ts +37 -0
- package/dist-types/ts3.4/commands/DescribeMetricAttributionCommand.d.ts +41 -0
- package/dist-types/ts3.4/commands/ListMetricAttributionMetricsCommand.d.ts +41 -0
- package/dist-types/ts3.4/commands/ListMetricAttributionsCommand.d.ts +41 -0
- package/dist-types/ts3.4/commands/UpdateMetricAttributionCommand.d.ts +41 -0
- package/dist-types/ts3.4/commands/index.d.ts +6 -0
- package/dist-types/ts3.4/models/models_0.d.ts +122 -0
- package/dist-types/ts3.4/pagination/ListMetricAttributionMetricsPaginator.d.ts +11 -0
- package/dist-types/ts3.4/pagination/ListMetricAttributionsPaginator.d.ts +11 -0
- package/dist-types/ts3.4/pagination/index.d.ts +2 -0
- package/dist-types/ts3.4/protocols/Aws_json1_1.d.ts +72 -0
- package/package.json +28 -28
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.paginateListMetricAttributionMetrics = void 0;
|
|
4
|
+
const ListMetricAttributionMetricsCommand_1 = require("../commands/ListMetricAttributionMetricsCommand");
|
|
5
|
+
const Personalize_1 = require("../Personalize");
|
|
6
|
+
const PersonalizeClient_1 = require("../PersonalizeClient");
|
|
7
|
+
const makePagedClientRequest = async (client, input, ...args) => {
|
|
8
|
+
return await client.send(new ListMetricAttributionMetricsCommand_1.ListMetricAttributionMetricsCommand(input), ...args);
|
|
9
|
+
};
|
|
10
|
+
const makePagedRequest = async (client, input, ...args) => {
|
|
11
|
+
return await client.listMetricAttributionMetrics(input, ...args);
|
|
12
|
+
};
|
|
13
|
+
async function* paginateListMetricAttributionMetrics(config, input, ...additionalArguments) {
|
|
14
|
+
let token = config.startingToken || undefined;
|
|
15
|
+
let hasNext = true;
|
|
16
|
+
let page;
|
|
17
|
+
while (hasNext) {
|
|
18
|
+
input.nextToken = token;
|
|
19
|
+
input["maxResults"] = config.pageSize;
|
|
20
|
+
if (config.client instanceof Personalize_1.Personalize) {
|
|
21
|
+
page = await makePagedRequest(config.client, input, ...additionalArguments);
|
|
22
|
+
}
|
|
23
|
+
else if (config.client instanceof PersonalizeClient_1.PersonalizeClient) {
|
|
24
|
+
page = await makePagedClientRequest(config.client, input, ...additionalArguments);
|
|
25
|
+
}
|
|
26
|
+
else {
|
|
27
|
+
throw new Error("Invalid client, expected Personalize | PersonalizeClient");
|
|
28
|
+
}
|
|
29
|
+
yield page;
|
|
30
|
+
const prevToken = token;
|
|
31
|
+
token = page.nextToken;
|
|
32
|
+
hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
|
|
33
|
+
}
|
|
34
|
+
return undefined;
|
|
35
|
+
}
|
|
36
|
+
exports.paginateListMetricAttributionMetrics = paginateListMetricAttributionMetrics;
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.paginateListMetricAttributions = void 0;
|
|
4
|
+
const ListMetricAttributionsCommand_1 = require("../commands/ListMetricAttributionsCommand");
|
|
5
|
+
const Personalize_1 = require("../Personalize");
|
|
6
|
+
const PersonalizeClient_1 = require("../PersonalizeClient");
|
|
7
|
+
const makePagedClientRequest = async (client, input, ...args) => {
|
|
8
|
+
return await client.send(new ListMetricAttributionsCommand_1.ListMetricAttributionsCommand(input), ...args);
|
|
9
|
+
};
|
|
10
|
+
const makePagedRequest = async (client, input, ...args) => {
|
|
11
|
+
return await client.listMetricAttributions(input, ...args);
|
|
12
|
+
};
|
|
13
|
+
async function* paginateListMetricAttributions(config, input, ...additionalArguments) {
|
|
14
|
+
let token = config.startingToken || undefined;
|
|
15
|
+
let hasNext = true;
|
|
16
|
+
let page;
|
|
17
|
+
while (hasNext) {
|
|
18
|
+
input.nextToken = token;
|
|
19
|
+
input["maxResults"] = config.pageSize;
|
|
20
|
+
if (config.client instanceof Personalize_1.Personalize) {
|
|
21
|
+
page = await makePagedRequest(config.client, input, ...additionalArguments);
|
|
22
|
+
}
|
|
23
|
+
else if (config.client instanceof PersonalizeClient_1.PersonalizeClient) {
|
|
24
|
+
page = await makePagedClientRequest(config.client, input, ...additionalArguments);
|
|
25
|
+
}
|
|
26
|
+
else {
|
|
27
|
+
throw new Error("Invalid client, expected Personalize | PersonalizeClient");
|
|
28
|
+
}
|
|
29
|
+
yield page;
|
|
30
|
+
const prevToken = token;
|
|
31
|
+
token = page.nextToken;
|
|
32
|
+
hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
|
|
33
|
+
}
|
|
34
|
+
return undefined;
|
|
35
|
+
}
|
|
36
|
+
exports.paginateListMetricAttributions = paginateListMetricAttributions;
|
|
@@ -11,6 +11,8 @@ tslib_1.__exportStar(require("./ListDatasetImportJobsPaginator"), exports);
|
|
|
11
11
|
tslib_1.__exportStar(require("./ListDatasetsPaginator"), exports);
|
|
12
12
|
tslib_1.__exportStar(require("./ListEventTrackersPaginator"), exports);
|
|
13
13
|
tslib_1.__exportStar(require("./ListFiltersPaginator"), exports);
|
|
14
|
+
tslib_1.__exportStar(require("./ListMetricAttributionMetricsPaginator"), exports);
|
|
15
|
+
tslib_1.__exportStar(require("./ListMetricAttributionsPaginator"), exports);
|
|
14
16
|
tslib_1.__exportStar(require("./ListRecipesPaginator"), exports);
|
|
15
17
|
tslib_1.__exportStar(require("./ListRecommendersPaginator"), exports);
|
|
16
18
|
tslib_1.__exportStar(require("./ListSchemasPaginator"), exports);
|