@aws-sdk/client-inspector2 3.477.0 → 3.478.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.
Files changed (41) hide show
  1. package/dist-cjs/pagination/ListAccountPermissionsPaginator.js +2 -24
  2. package/dist-cjs/pagination/ListCoveragePaginator.js +2 -24
  3. package/dist-cjs/pagination/ListCoverageStatisticsPaginator.js +2 -23
  4. package/dist-cjs/pagination/ListDelegatedAdminAccountsPaginator.js +2 -24
  5. package/dist-cjs/pagination/ListFiltersPaginator.js +2 -24
  6. package/dist-cjs/pagination/ListFindingAggregationsPaginator.js +2 -24
  7. package/dist-cjs/pagination/ListFindingsPaginator.js +2 -24
  8. package/dist-cjs/pagination/ListMembersPaginator.js +2 -24
  9. package/dist-cjs/pagination/ListUsageTotalsPaginator.js +2 -24
  10. package/dist-cjs/pagination/SearchVulnerabilitiesPaginator.js +2 -23
  11. package/dist-es/pagination/ListAccountPermissionsPaginator.js +2 -23
  12. package/dist-es/pagination/ListCoveragePaginator.js +2 -23
  13. package/dist-es/pagination/ListCoverageStatisticsPaginator.js +2 -22
  14. package/dist-es/pagination/ListDelegatedAdminAccountsPaginator.js +2 -23
  15. package/dist-es/pagination/ListFiltersPaginator.js +2 -23
  16. package/dist-es/pagination/ListFindingAggregationsPaginator.js +2 -23
  17. package/dist-es/pagination/ListFindingsPaginator.js +2 -23
  18. package/dist-es/pagination/ListMembersPaginator.js +2 -23
  19. package/dist-es/pagination/ListUsageTotalsPaginator.js +2 -23
  20. package/dist-es/pagination/SearchVulnerabilitiesPaginator.js +2 -22
  21. package/dist-types/pagination/ListAccountPermissionsPaginator.d.ts +1 -1
  22. package/dist-types/pagination/ListCoveragePaginator.d.ts +1 -1
  23. package/dist-types/pagination/ListCoverageStatisticsPaginator.d.ts +1 -1
  24. package/dist-types/pagination/ListDelegatedAdminAccountsPaginator.d.ts +1 -1
  25. package/dist-types/pagination/ListFiltersPaginator.d.ts +1 -1
  26. package/dist-types/pagination/ListFindingAggregationsPaginator.d.ts +1 -1
  27. package/dist-types/pagination/ListFindingsPaginator.d.ts +1 -1
  28. package/dist-types/pagination/ListMembersPaginator.d.ts +1 -1
  29. package/dist-types/pagination/ListUsageTotalsPaginator.d.ts +1 -1
  30. package/dist-types/pagination/SearchVulnerabilitiesPaginator.d.ts +1 -1
  31. package/dist-types/ts3.4/pagination/ListAccountPermissionsPaginator.d.ts +3 -3
  32. package/dist-types/ts3.4/pagination/ListCoveragePaginator.d.ts +3 -3
  33. package/dist-types/ts3.4/pagination/ListCoverageStatisticsPaginator.d.ts +3 -3
  34. package/dist-types/ts3.4/pagination/ListDelegatedAdminAccountsPaginator.d.ts +3 -3
  35. package/dist-types/ts3.4/pagination/ListFiltersPaginator.d.ts +3 -3
  36. package/dist-types/ts3.4/pagination/ListFindingAggregationsPaginator.d.ts +3 -3
  37. package/dist-types/ts3.4/pagination/ListFindingsPaginator.d.ts +3 -3
  38. package/dist-types/ts3.4/pagination/ListMembersPaginator.d.ts +3 -3
  39. package/dist-types/ts3.4/pagination/ListUsageTotalsPaginator.d.ts +3 -3
  40. package/dist-types/ts3.4/pagination/SearchVulnerabilitiesPaginator.d.ts +3 -3
  41. package/package.json +5 -5
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListAccountPermissions = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const ListAccountPermissionsCommand_1 = require("../commands/ListAccountPermissionsCommand");
5
6
  const Inspector2Client_1 = require("../Inspector2Client");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListAccountPermissionsCommand_1.ListAccountPermissionsCommand(input), ...args);
8
- };
9
- async function* paginateListAccountPermissions(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.nextToken = token;
15
- input["maxResults"] = config.pageSize;
16
- if (config.client instanceof Inspector2Client_1.Inspector2Client) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Inspector2 | Inspector2Client");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.nextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateListAccountPermissions = paginateListAccountPermissions;
7
+ exports.paginateListAccountPermissions = (0, core_1.createPaginator)(Inspector2Client_1.Inspector2Client, ListAccountPermissionsCommand_1.ListAccountPermissionsCommand, "nextToken", "nextToken", "maxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListCoverage = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const ListCoverageCommand_1 = require("../commands/ListCoverageCommand");
5
6
  const Inspector2Client_1 = require("../Inspector2Client");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListCoverageCommand_1.ListCoverageCommand(input), ...args);
8
- };
9
- async function* paginateListCoverage(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.nextToken = token;
15
- input["maxResults"] = config.pageSize;
16
- if (config.client instanceof Inspector2Client_1.Inspector2Client) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Inspector2 | Inspector2Client");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.nextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateListCoverage = paginateListCoverage;
7
+ exports.paginateListCoverage = (0, core_1.createPaginator)(Inspector2Client_1.Inspector2Client, ListCoverageCommand_1.ListCoverageCommand, "nextToken", "nextToken", "maxResults");
@@ -1,28 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListCoverageStatistics = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const ListCoverageStatisticsCommand_1 = require("../commands/ListCoverageStatisticsCommand");
5
6
  const Inspector2Client_1 = require("../Inspector2Client");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListCoverageStatisticsCommand_1.ListCoverageStatisticsCommand(input), ...args);
8
- };
9
- async function* paginateListCoverageStatistics(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.nextToken = token;
15
- if (config.client instanceof Inspector2Client_1.Inspector2Client) {
16
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
17
- }
18
- else {
19
- throw new Error("Invalid client, expected Inspector2 | Inspector2Client");
20
- }
21
- yield page;
22
- const prevToken = token;
23
- token = page.nextToken;
24
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
25
- }
26
- return undefined;
27
- }
28
- exports.paginateListCoverageStatistics = paginateListCoverageStatistics;
7
+ exports.paginateListCoverageStatistics = (0, core_1.createPaginator)(Inspector2Client_1.Inspector2Client, ListCoverageStatisticsCommand_1.ListCoverageStatisticsCommand, "nextToken", "nextToken", "");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListDelegatedAdminAccounts = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const ListDelegatedAdminAccountsCommand_1 = require("../commands/ListDelegatedAdminAccountsCommand");
5
6
  const Inspector2Client_1 = require("../Inspector2Client");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListDelegatedAdminAccountsCommand_1.ListDelegatedAdminAccountsCommand(input), ...args);
8
- };
9
- async function* paginateListDelegatedAdminAccounts(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.nextToken = token;
15
- input["maxResults"] = config.pageSize;
16
- if (config.client instanceof Inspector2Client_1.Inspector2Client) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Inspector2 | Inspector2Client");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.nextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateListDelegatedAdminAccounts = paginateListDelegatedAdminAccounts;
7
+ exports.paginateListDelegatedAdminAccounts = (0, core_1.createPaginator)(Inspector2Client_1.Inspector2Client, ListDelegatedAdminAccountsCommand_1.ListDelegatedAdminAccountsCommand, "nextToken", "nextToken", "maxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListFilters = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const ListFiltersCommand_1 = require("../commands/ListFiltersCommand");
5
6
  const Inspector2Client_1 = require("../Inspector2Client");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListFiltersCommand_1.ListFiltersCommand(input), ...args);
8
- };
9
- async function* paginateListFilters(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.nextToken = token;
15
- input["maxResults"] = config.pageSize;
16
- if (config.client instanceof Inspector2Client_1.Inspector2Client) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Inspector2 | Inspector2Client");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.nextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateListFilters = paginateListFilters;
7
+ exports.paginateListFilters = (0, core_1.createPaginator)(Inspector2Client_1.Inspector2Client, ListFiltersCommand_1.ListFiltersCommand, "nextToken", "nextToken", "maxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListFindingAggregations = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const ListFindingAggregationsCommand_1 = require("../commands/ListFindingAggregationsCommand");
5
6
  const Inspector2Client_1 = require("../Inspector2Client");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListFindingAggregationsCommand_1.ListFindingAggregationsCommand(input), ...args);
8
- };
9
- async function* paginateListFindingAggregations(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.nextToken = token;
15
- input["maxResults"] = config.pageSize;
16
- if (config.client instanceof Inspector2Client_1.Inspector2Client) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Inspector2 | Inspector2Client");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.nextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateListFindingAggregations = paginateListFindingAggregations;
7
+ exports.paginateListFindingAggregations = (0, core_1.createPaginator)(Inspector2Client_1.Inspector2Client, ListFindingAggregationsCommand_1.ListFindingAggregationsCommand, "nextToken", "nextToken", "maxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListFindings = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const ListFindingsCommand_1 = require("../commands/ListFindingsCommand");
5
6
  const Inspector2Client_1 = require("../Inspector2Client");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListFindingsCommand_1.ListFindingsCommand(input), ...args);
8
- };
9
- async function* paginateListFindings(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.nextToken = token;
15
- input["maxResults"] = config.pageSize;
16
- if (config.client instanceof Inspector2Client_1.Inspector2Client) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Inspector2 | Inspector2Client");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.nextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateListFindings = paginateListFindings;
7
+ exports.paginateListFindings = (0, core_1.createPaginator)(Inspector2Client_1.Inspector2Client, ListFindingsCommand_1.ListFindingsCommand, "nextToken", "nextToken", "maxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListMembers = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const ListMembersCommand_1 = require("../commands/ListMembersCommand");
5
6
  const Inspector2Client_1 = require("../Inspector2Client");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListMembersCommand_1.ListMembersCommand(input), ...args);
8
- };
9
- async function* paginateListMembers(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.nextToken = token;
15
- input["maxResults"] = config.pageSize;
16
- if (config.client instanceof Inspector2Client_1.Inspector2Client) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Inspector2 | Inspector2Client");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.nextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateListMembers = paginateListMembers;
7
+ exports.paginateListMembers = (0, core_1.createPaginator)(Inspector2Client_1.Inspector2Client, ListMembersCommand_1.ListMembersCommand, "nextToken", "nextToken", "maxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListUsageTotals = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const ListUsageTotalsCommand_1 = require("../commands/ListUsageTotalsCommand");
5
6
  const Inspector2Client_1 = require("../Inspector2Client");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListUsageTotalsCommand_1.ListUsageTotalsCommand(input), ...args);
8
- };
9
- async function* paginateListUsageTotals(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.nextToken = token;
15
- input["maxResults"] = config.pageSize;
16
- if (config.client instanceof Inspector2Client_1.Inspector2Client) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Inspector2 | Inspector2Client");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.nextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateListUsageTotals = paginateListUsageTotals;
7
+ exports.paginateListUsageTotals = (0, core_1.createPaginator)(Inspector2Client_1.Inspector2Client, ListUsageTotalsCommand_1.ListUsageTotalsCommand, "nextToken", "nextToken", "maxResults");
@@ -1,28 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateSearchVulnerabilities = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const SearchVulnerabilitiesCommand_1 = require("../commands/SearchVulnerabilitiesCommand");
5
6
  const Inspector2Client_1 = require("../Inspector2Client");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new SearchVulnerabilitiesCommand_1.SearchVulnerabilitiesCommand(input), ...args);
8
- };
9
- async function* paginateSearchVulnerabilities(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.nextToken = token;
15
- if (config.client instanceof Inspector2Client_1.Inspector2Client) {
16
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
17
- }
18
- else {
19
- throw new Error("Invalid client, expected Inspector2 | Inspector2Client");
20
- }
21
- yield page;
22
- const prevToken = token;
23
- token = page.nextToken;
24
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
25
- }
26
- return undefined;
27
- }
28
- exports.paginateSearchVulnerabilities = paginateSearchVulnerabilities;
7
+ exports.paginateSearchVulnerabilities = (0, core_1.createPaginator)(Inspector2Client_1.Inspector2Client, SearchVulnerabilitiesCommand_1.SearchVulnerabilitiesCommand, "nextToken", "nextToken", "");
@@ -1,25 +1,4 @@
1
+ import { createPaginator } from "@smithy/core";
1
2
  import { ListAccountPermissionsCommand, } from "../commands/ListAccountPermissionsCommand";
2
3
  import { Inspector2Client } from "../Inspector2Client";
3
- const makePagedClientRequest = async (client, input, ...args) => {
4
- return await client.send(new ListAccountPermissionsCommand(input), ...args);
5
- };
6
- export async function* paginateListAccountPermissions(config, input, ...additionalArguments) {
7
- let token = config.startingToken || undefined;
8
- let hasNext = true;
9
- let page;
10
- while (hasNext) {
11
- input.nextToken = token;
12
- input["maxResults"] = config.pageSize;
13
- if (config.client instanceof Inspector2Client) {
14
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
15
- }
16
- else {
17
- throw new Error("Invalid client, expected Inspector2 | Inspector2Client");
18
- }
19
- yield page;
20
- const prevToken = token;
21
- token = page.nextToken;
22
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
23
- }
24
- return undefined;
25
- }
4
+ export const paginateListAccountPermissions = createPaginator(Inspector2Client, ListAccountPermissionsCommand, "nextToken", "nextToken", "maxResults");
@@ -1,25 +1,4 @@
1
+ import { createPaginator } from "@smithy/core";
1
2
  import { ListCoverageCommand, } from "../commands/ListCoverageCommand";
2
3
  import { Inspector2Client } from "../Inspector2Client";
3
- const makePagedClientRequest = async (client, input, ...args) => {
4
- return await client.send(new ListCoverageCommand(input), ...args);
5
- };
6
- export async function* paginateListCoverage(config, input, ...additionalArguments) {
7
- let token = config.startingToken || undefined;
8
- let hasNext = true;
9
- let page;
10
- while (hasNext) {
11
- input.nextToken = token;
12
- input["maxResults"] = config.pageSize;
13
- if (config.client instanceof Inspector2Client) {
14
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
15
- }
16
- else {
17
- throw new Error("Invalid client, expected Inspector2 | Inspector2Client");
18
- }
19
- yield page;
20
- const prevToken = token;
21
- token = page.nextToken;
22
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
23
- }
24
- return undefined;
25
- }
4
+ export const paginateListCoverage = createPaginator(Inspector2Client, ListCoverageCommand, "nextToken", "nextToken", "maxResults");
@@ -1,24 +1,4 @@
1
+ import { createPaginator } from "@smithy/core";
1
2
  import { ListCoverageStatisticsCommand, } from "../commands/ListCoverageStatisticsCommand";
2
3
  import { Inspector2Client } from "../Inspector2Client";
3
- const makePagedClientRequest = async (client, input, ...args) => {
4
- return await client.send(new ListCoverageStatisticsCommand(input), ...args);
5
- };
6
- export async function* paginateListCoverageStatistics(config, input, ...additionalArguments) {
7
- let token = config.startingToken || undefined;
8
- let hasNext = true;
9
- let page;
10
- while (hasNext) {
11
- input.nextToken = token;
12
- if (config.client instanceof Inspector2Client) {
13
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
14
- }
15
- else {
16
- throw new Error("Invalid client, expected Inspector2 | Inspector2Client");
17
- }
18
- yield page;
19
- const prevToken = token;
20
- token = page.nextToken;
21
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
22
- }
23
- return undefined;
24
- }
4
+ export const paginateListCoverageStatistics = createPaginator(Inspector2Client, ListCoverageStatisticsCommand, "nextToken", "nextToken", "");
@@ -1,25 +1,4 @@
1
+ import { createPaginator } from "@smithy/core";
1
2
  import { ListDelegatedAdminAccountsCommand, } from "../commands/ListDelegatedAdminAccountsCommand";
2
3
  import { Inspector2Client } from "../Inspector2Client";
3
- const makePagedClientRequest = async (client, input, ...args) => {
4
- return await client.send(new ListDelegatedAdminAccountsCommand(input), ...args);
5
- };
6
- export async function* paginateListDelegatedAdminAccounts(config, input, ...additionalArguments) {
7
- let token = config.startingToken || undefined;
8
- let hasNext = true;
9
- let page;
10
- while (hasNext) {
11
- input.nextToken = token;
12
- input["maxResults"] = config.pageSize;
13
- if (config.client instanceof Inspector2Client) {
14
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
15
- }
16
- else {
17
- throw new Error("Invalid client, expected Inspector2 | Inspector2Client");
18
- }
19
- yield page;
20
- const prevToken = token;
21
- token = page.nextToken;
22
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
23
- }
24
- return undefined;
25
- }
4
+ export const paginateListDelegatedAdminAccounts = createPaginator(Inspector2Client, ListDelegatedAdminAccountsCommand, "nextToken", "nextToken", "maxResults");
@@ -1,25 +1,4 @@
1
+ import { createPaginator } from "@smithy/core";
1
2
  import { ListFiltersCommand } from "../commands/ListFiltersCommand";
2
3
  import { Inspector2Client } from "../Inspector2Client";
3
- const makePagedClientRequest = async (client, input, ...args) => {
4
- return await client.send(new ListFiltersCommand(input), ...args);
5
- };
6
- export async function* paginateListFilters(config, input, ...additionalArguments) {
7
- let token = config.startingToken || undefined;
8
- let hasNext = true;
9
- let page;
10
- while (hasNext) {
11
- input.nextToken = token;
12
- input["maxResults"] = config.pageSize;
13
- if (config.client instanceof Inspector2Client) {
14
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
15
- }
16
- else {
17
- throw new Error("Invalid client, expected Inspector2 | Inspector2Client");
18
- }
19
- yield page;
20
- const prevToken = token;
21
- token = page.nextToken;
22
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
23
- }
24
- return undefined;
25
- }
4
+ export const paginateListFilters = createPaginator(Inspector2Client, ListFiltersCommand, "nextToken", "nextToken", "maxResults");
@@ -1,25 +1,4 @@
1
+ import { createPaginator } from "@smithy/core";
1
2
  import { ListFindingAggregationsCommand, } from "../commands/ListFindingAggregationsCommand";
2
3
  import { Inspector2Client } from "../Inspector2Client";
3
- const makePagedClientRequest = async (client, input, ...args) => {
4
- return await client.send(new ListFindingAggregationsCommand(input), ...args);
5
- };
6
- export async function* paginateListFindingAggregations(config, input, ...additionalArguments) {
7
- let token = config.startingToken || undefined;
8
- let hasNext = true;
9
- let page;
10
- while (hasNext) {
11
- input.nextToken = token;
12
- input["maxResults"] = config.pageSize;
13
- if (config.client instanceof Inspector2Client) {
14
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
15
- }
16
- else {
17
- throw new Error("Invalid client, expected Inspector2 | Inspector2Client");
18
- }
19
- yield page;
20
- const prevToken = token;
21
- token = page.nextToken;
22
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
23
- }
24
- return undefined;
25
- }
4
+ export const paginateListFindingAggregations = createPaginator(Inspector2Client, ListFindingAggregationsCommand, "nextToken", "nextToken", "maxResults");
@@ -1,25 +1,4 @@
1
+ import { createPaginator } from "@smithy/core";
1
2
  import { ListFindingsCommand, } from "../commands/ListFindingsCommand";
2
3
  import { Inspector2Client } from "../Inspector2Client";
3
- const makePagedClientRequest = async (client, input, ...args) => {
4
- return await client.send(new ListFindingsCommand(input), ...args);
5
- };
6
- export async function* paginateListFindings(config, input, ...additionalArguments) {
7
- let token = config.startingToken || undefined;
8
- let hasNext = true;
9
- let page;
10
- while (hasNext) {
11
- input.nextToken = token;
12
- input["maxResults"] = config.pageSize;
13
- if (config.client instanceof Inspector2Client) {
14
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
15
- }
16
- else {
17
- throw new Error("Invalid client, expected Inspector2 | Inspector2Client");
18
- }
19
- yield page;
20
- const prevToken = token;
21
- token = page.nextToken;
22
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
23
- }
24
- return undefined;
25
- }
4
+ export const paginateListFindings = createPaginator(Inspector2Client, ListFindingsCommand, "nextToken", "nextToken", "maxResults");
@@ -1,25 +1,4 @@
1
+ import { createPaginator } from "@smithy/core";
1
2
  import { ListMembersCommand } from "../commands/ListMembersCommand";
2
3
  import { Inspector2Client } from "../Inspector2Client";
3
- const makePagedClientRequest = async (client, input, ...args) => {
4
- return await client.send(new ListMembersCommand(input), ...args);
5
- };
6
- export async function* paginateListMembers(config, input, ...additionalArguments) {
7
- let token = config.startingToken || undefined;
8
- let hasNext = true;
9
- let page;
10
- while (hasNext) {
11
- input.nextToken = token;
12
- input["maxResults"] = config.pageSize;
13
- if (config.client instanceof Inspector2Client) {
14
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
15
- }
16
- else {
17
- throw new Error("Invalid client, expected Inspector2 | Inspector2Client");
18
- }
19
- yield page;
20
- const prevToken = token;
21
- token = page.nextToken;
22
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
23
- }
24
- return undefined;
25
- }
4
+ export const paginateListMembers = createPaginator(Inspector2Client, ListMembersCommand, "nextToken", "nextToken", "maxResults");
@@ -1,25 +1,4 @@
1
+ import { createPaginator } from "@smithy/core";
1
2
  import { ListUsageTotalsCommand, } from "../commands/ListUsageTotalsCommand";
2
3
  import { Inspector2Client } from "../Inspector2Client";
3
- const makePagedClientRequest = async (client, input, ...args) => {
4
- return await client.send(new ListUsageTotalsCommand(input), ...args);
5
- };
6
- export async function* paginateListUsageTotals(config, input, ...additionalArguments) {
7
- let token = config.startingToken || undefined;
8
- let hasNext = true;
9
- let page;
10
- while (hasNext) {
11
- input.nextToken = token;
12
- input["maxResults"] = config.pageSize;
13
- if (config.client instanceof Inspector2Client) {
14
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
15
- }
16
- else {
17
- throw new Error("Invalid client, expected Inspector2 | Inspector2Client");
18
- }
19
- yield page;
20
- const prevToken = token;
21
- token = page.nextToken;
22
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
23
- }
24
- return undefined;
25
- }
4
+ export const paginateListUsageTotals = createPaginator(Inspector2Client, ListUsageTotalsCommand, "nextToken", "nextToken", "maxResults");
@@ -1,24 +1,4 @@
1
+ import { createPaginator } from "@smithy/core";
1
2
  import { SearchVulnerabilitiesCommand, } from "../commands/SearchVulnerabilitiesCommand";
2
3
  import { Inspector2Client } from "../Inspector2Client";
3
- const makePagedClientRequest = async (client, input, ...args) => {
4
- return await client.send(new SearchVulnerabilitiesCommand(input), ...args);
5
- };
6
- export async function* paginateSearchVulnerabilities(config, input, ...additionalArguments) {
7
- let token = config.startingToken || undefined;
8
- let hasNext = true;
9
- let page;
10
- while (hasNext) {
11
- input.nextToken = token;
12
- if (config.client instanceof Inspector2Client) {
13
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
14
- }
15
- else {
16
- throw new Error("Invalid client, expected Inspector2 | Inspector2Client");
17
- }
18
- yield page;
19
- const prevToken = token;
20
- token = page.nextToken;
21
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
22
- }
23
- return undefined;
24
- }
4
+ export const paginateSearchVulnerabilities = createPaginator(Inspector2Client, SearchVulnerabilitiesCommand, "nextToken", "nextToken", "");
@@ -4,4 +4,4 @@ import { Inspector2PaginationConfiguration } from "./Interfaces";
4
4
  /**
5
5
  * @public
6
6
  */
7
- export declare function paginateListAccountPermissions(config: Inspector2PaginationConfiguration, input: ListAccountPermissionsCommandInput, ...additionalArguments: any): Paginator<ListAccountPermissionsCommandOutput>;
7
+ export declare const paginateListAccountPermissions: (config: Inspector2PaginationConfiguration, input: ListAccountPermissionsCommandInput, ...rest: any[]) => Paginator<ListAccountPermissionsCommandOutput>;
@@ -4,4 +4,4 @@ import { Inspector2PaginationConfiguration } from "./Interfaces";
4
4
  /**
5
5
  * @public
6
6
  */
7
- export declare function paginateListCoverage(config: Inspector2PaginationConfiguration, input: ListCoverageCommandInput, ...additionalArguments: any): Paginator<ListCoverageCommandOutput>;
7
+ export declare const paginateListCoverage: (config: Inspector2PaginationConfiguration, input: ListCoverageCommandInput, ...rest: any[]) => Paginator<ListCoverageCommandOutput>;
@@ -4,4 +4,4 @@ import { Inspector2PaginationConfiguration } from "./Interfaces";
4
4
  /**
5
5
  * @public
6
6
  */
7
- export declare function paginateListCoverageStatistics(config: Inspector2PaginationConfiguration, input: ListCoverageStatisticsCommandInput, ...additionalArguments: any): Paginator<ListCoverageStatisticsCommandOutput>;
7
+ export declare const paginateListCoverageStatistics: (config: Inspector2PaginationConfiguration, input: ListCoverageStatisticsCommandInput, ...rest: any[]) => Paginator<ListCoverageStatisticsCommandOutput>;
@@ -4,4 +4,4 @@ import { Inspector2PaginationConfiguration } from "./Interfaces";
4
4
  /**
5
5
  * @public
6
6
  */
7
- export declare function paginateListDelegatedAdminAccounts(config: Inspector2PaginationConfiguration, input: ListDelegatedAdminAccountsCommandInput, ...additionalArguments: any): Paginator<ListDelegatedAdminAccountsCommandOutput>;
7
+ export declare const paginateListDelegatedAdminAccounts: (config: Inspector2PaginationConfiguration, input: ListDelegatedAdminAccountsCommandInput, ...rest: any[]) => Paginator<ListDelegatedAdminAccountsCommandOutput>;
@@ -4,4 +4,4 @@ import { Inspector2PaginationConfiguration } from "./Interfaces";
4
4
  /**
5
5
  * @public
6
6
  */
7
- export declare function paginateListFilters(config: Inspector2PaginationConfiguration, input: ListFiltersCommandInput, ...additionalArguments: any): Paginator<ListFiltersCommandOutput>;
7
+ export declare const paginateListFilters: (config: Inspector2PaginationConfiguration, input: ListFiltersCommandInput, ...rest: any[]) => Paginator<ListFiltersCommandOutput>;
@@ -4,4 +4,4 @@ import { Inspector2PaginationConfiguration } from "./Interfaces";
4
4
  /**
5
5
  * @public
6
6
  */
7
- export declare function paginateListFindingAggregations(config: Inspector2PaginationConfiguration, input: ListFindingAggregationsCommandInput, ...additionalArguments: any): Paginator<ListFindingAggregationsCommandOutput>;
7
+ export declare const paginateListFindingAggregations: (config: Inspector2PaginationConfiguration, input: ListFindingAggregationsCommandInput, ...rest: any[]) => Paginator<ListFindingAggregationsCommandOutput>;
@@ -4,4 +4,4 @@ import { Inspector2PaginationConfiguration } from "./Interfaces";
4
4
  /**
5
5
  * @public
6
6
  */
7
- export declare function paginateListFindings(config: Inspector2PaginationConfiguration, input: ListFindingsCommandInput, ...additionalArguments: any): Paginator<ListFindingsCommandOutput>;
7
+ export declare const paginateListFindings: (config: Inspector2PaginationConfiguration, input: ListFindingsCommandInput, ...rest: any[]) => Paginator<ListFindingsCommandOutput>;
@@ -4,4 +4,4 @@ import { Inspector2PaginationConfiguration } from "./Interfaces";
4
4
  /**
5
5
  * @public
6
6
  */
7
- export declare function paginateListMembers(config: Inspector2PaginationConfiguration, input: ListMembersCommandInput, ...additionalArguments: any): Paginator<ListMembersCommandOutput>;
7
+ export declare const paginateListMembers: (config: Inspector2PaginationConfiguration, input: ListMembersCommandInput, ...rest: any[]) => Paginator<ListMembersCommandOutput>;
@@ -4,4 +4,4 @@ import { Inspector2PaginationConfiguration } from "./Interfaces";
4
4
  /**
5
5
  * @public
6
6
  */
7
- export declare function paginateListUsageTotals(config: Inspector2PaginationConfiguration, input: ListUsageTotalsCommandInput, ...additionalArguments: any): Paginator<ListUsageTotalsCommandOutput>;
7
+ export declare const paginateListUsageTotals: (config: Inspector2PaginationConfiguration, input: ListUsageTotalsCommandInput, ...rest: any[]) => Paginator<ListUsageTotalsCommandOutput>;
@@ -4,4 +4,4 @@ import { Inspector2PaginationConfiguration } from "./Interfaces";
4
4
  /**
5
5
  * @public
6
6
  */
7
- export declare function paginateSearchVulnerabilities(config: Inspector2PaginationConfiguration, input: SearchVulnerabilitiesCommandInput, ...additionalArguments: any): Paginator<SearchVulnerabilitiesCommandOutput>;
7
+ export declare const paginateSearchVulnerabilities: (config: Inspector2PaginationConfiguration, input: SearchVulnerabilitiesCommandInput, ...rest: any[]) => Paginator<SearchVulnerabilitiesCommandOutput>;
@@ -4,8 +4,8 @@ import {
4
4
  ListAccountPermissionsCommandOutput,
5
5
  } from "../commands/ListAccountPermissionsCommand";
6
6
  import { Inspector2PaginationConfiguration } from "./Interfaces";
7
- export declare function paginateListAccountPermissions(
7
+ export declare const paginateListAccountPermissions: (
8
8
  config: Inspector2PaginationConfiguration,
9
9
  input: ListAccountPermissionsCommandInput,
10
- ...additionalArguments: any
11
- ): Paginator<ListAccountPermissionsCommandOutput>;
10
+ ...rest: any[]
11
+ ) => Paginator<ListAccountPermissionsCommandOutput>;
@@ -4,8 +4,8 @@ import {
4
4
  ListCoverageCommandOutput,
5
5
  } from "../commands/ListCoverageCommand";
6
6
  import { Inspector2PaginationConfiguration } from "./Interfaces";
7
- export declare function paginateListCoverage(
7
+ export declare const paginateListCoverage: (
8
8
  config: Inspector2PaginationConfiguration,
9
9
  input: ListCoverageCommandInput,
10
- ...additionalArguments: any
11
- ): Paginator<ListCoverageCommandOutput>;
10
+ ...rest: any[]
11
+ ) => Paginator<ListCoverageCommandOutput>;
@@ -4,8 +4,8 @@ import {
4
4
  ListCoverageStatisticsCommandOutput,
5
5
  } from "../commands/ListCoverageStatisticsCommand";
6
6
  import { Inspector2PaginationConfiguration } from "./Interfaces";
7
- export declare function paginateListCoverageStatistics(
7
+ export declare const paginateListCoverageStatistics: (
8
8
  config: Inspector2PaginationConfiguration,
9
9
  input: ListCoverageStatisticsCommandInput,
10
- ...additionalArguments: any
11
- ): Paginator<ListCoverageStatisticsCommandOutput>;
10
+ ...rest: any[]
11
+ ) => Paginator<ListCoverageStatisticsCommandOutput>;
@@ -4,8 +4,8 @@ import {
4
4
  ListDelegatedAdminAccountsCommandOutput,
5
5
  } from "../commands/ListDelegatedAdminAccountsCommand";
6
6
  import { Inspector2PaginationConfiguration } from "./Interfaces";
7
- export declare function paginateListDelegatedAdminAccounts(
7
+ export declare const paginateListDelegatedAdminAccounts: (
8
8
  config: Inspector2PaginationConfiguration,
9
9
  input: ListDelegatedAdminAccountsCommandInput,
10
- ...additionalArguments: any
11
- ): Paginator<ListDelegatedAdminAccountsCommandOutput>;
10
+ ...rest: any[]
11
+ ) => Paginator<ListDelegatedAdminAccountsCommandOutput>;
@@ -4,8 +4,8 @@ import {
4
4
  ListFiltersCommandOutput,
5
5
  } from "../commands/ListFiltersCommand";
6
6
  import { Inspector2PaginationConfiguration } from "./Interfaces";
7
- export declare function paginateListFilters(
7
+ export declare const paginateListFilters: (
8
8
  config: Inspector2PaginationConfiguration,
9
9
  input: ListFiltersCommandInput,
10
- ...additionalArguments: any
11
- ): Paginator<ListFiltersCommandOutput>;
10
+ ...rest: any[]
11
+ ) => Paginator<ListFiltersCommandOutput>;
@@ -4,8 +4,8 @@ import {
4
4
  ListFindingAggregationsCommandOutput,
5
5
  } from "../commands/ListFindingAggregationsCommand";
6
6
  import { Inspector2PaginationConfiguration } from "./Interfaces";
7
- export declare function paginateListFindingAggregations(
7
+ export declare const paginateListFindingAggregations: (
8
8
  config: Inspector2PaginationConfiguration,
9
9
  input: ListFindingAggregationsCommandInput,
10
- ...additionalArguments: any
11
- ): Paginator<ListFindingAggregationsCommandOutput>;
10
+ ...rest: any[]
11
+ ) => Paginator<ListFindingAggregationsCommandOutput>;
@@ -4,8 +4,8 @@ import {
4
4
  ListFindingsCommandOutput,
5
5
  } from "../commands/ListFindingsCommand";
6
6
  import { Inspector2PaginationConfiguration } from "./Interfaces";
7
- export declare function paginateListFindings(
7
+ export declare const paginateListFindings: (
8
8
  config: Inspector2PaginationConfiguration,
9
9
  input: ListFindingsCommandInput,
10
- ...additionalArguments: any
11
- ): Paginator<ListFindingsCommandOutput>;
10
+ ...rest: any[]
11
+ ) => Paginator<ListFindingsCommandOutput>;
@@ -4,8 +4,8 @@ import {
4
4
  ListMembersCommandOutput,
5
5
  } from "../commands/ListMembersCommand";
6
6
  import { Inspector2PaginationConfiguration } from "./Interfaces";
7
- export declare function paginateListMembers(
7
+ export declare const paginateListMembers: (
8
8
  config: Inspector2PaginationConfiguration,
9
9
  input: ListMembersCommandInput,
10
- ...additionalArguments: any
11
- ): Paginator<ListMembersCommandOutput>;
10
+ ...rest: any[]
11
+ ) => Paginator<ListMembersCommandOutput>;
@@ -4,8 +4,8 @@ import {
4
4
  ListUsageTotalsCommandOutput,
5
5
  } from "../commands/ListUsageTotalsCommand";
6
6
  import { Inspector2PaginationConfiguration } from "./Interfaces";
7
- export declare function paginateListUsageTotals(
7
+ export declare const paginateListUsageTotals: (
8
8
  config: Inspector2PaginationConfiguration,
9
9
  input: ListUsageTotalsCommandInput,
10
- ...additionalArguments: any
11
- ): Paginator<ListUsageTotalsCommandOutput>;
10
+ ...rest: any[]
11
+ ) => Paginator<ListUsageTotalsCommandOutput>;
@@ -4,8 +4,8 @@ import {
4
4
  SearchVulnerabilitiesCommandOutput,
5
5
  } from "../commands/SearchVulnerabilitiesCommand";
6
6
  import { Inspector2PaginationConfiguration } from "./Interfaces";
7
- export declare function paginateSearchVulnerabilities(
7
+ export declare const paginateSearchVulnerabilities: (
8
8
  config: Inspector2PaginationConfiguration,
9
9
  input: SearchVulnerabilitiesCommandInput,
10
- ...additionalArguments: any
11
- ): Paginator<SearchVulnerabilitiesCommandOutput>;
10
+ ...rest: any[]
11
+ ) => Paginator<SearchVulnerabilitiesCommandOutput>;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@aws-sdk/client-inspector2",
3
3
  "description": "AWS SDK for JavaScript Inspector2 Client for Node.js, Browser and React Native",
4
- "version": "3.477.0",
4
+ "version": "3.478.0",
5
5
  "scripts": {
6
6
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
7
7
  "build:cjs": "tsc -p tsconfig.cjs.json",
@@ -20,17 +20,17 @@
20
20
  "dependencies": {
21
21
  "@aws-crypto/sha256-browser": "3.0.0",
22
22
  "@aws-crypto/sha256-js": "3.0.0",
23
- "@aws-sdk/client-sts": "3.477.0",
23
+ "@aws-sdk/client-sts": "3.478.0",
24
24
  "@aws-sdk/core": "3.477.0",
25
- "@aws-sdk/credential-provider-node": "3.477.0",
25
+ "@aws-sdk/credential-provider-node": "3.478.0",
26
26
  "@aws-sdk/middleware-host-header": "3.468.0",
27
27
  "@aws-sdk/middleware-logger": "3.468.0",
28
28
  "@aws-sdk/middleware-recursion-detection": "3.468.0",
29
29
  "@aws-sdk/middleware-signing": "3.468.0",
30
- "@aws-sdk/middleware-user-agent": "3.470.0",
30
+ "@aws-sdk/middleware-user-agent": "3.478.0",
31
31
  "@aws-sdk/region-config-resolver": "3.470.0",
32
32
  "@aws-sdk/types": "3.468.0",
33
- "@aws-sdk/util-endpoints": "3.470.0",
33
+ "@aws-sdk/util-endpoints": "3.478.0",
34
34
  "@aws-sdk/util-user-agent-browser": "3.468.0",
35
35
  "@aws-sdk/util-user-agent-node": "3.470.0",
36
36
  "@smithy/config-resolver": "^2.0.21",