@aws-sdk/client-bedrock-agent 3.476.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 (35) hide show
  1. package/dist-cjs/pagination/ListAgentActionGroupsPaginator.js +2 -24
  2. package/dist-cjs/pagination/ListAgentAliasesPaginator.js +2 -24
  3. package/dist-cjs/pagination/ListAgentKnowledgeBasesPaginator.js +2 -24
  4. package/dist-cjs/pagination/ListAgentVersionsPaginator.js +2 -24
  5. package/dist-cjs/pagination/ListAgentsPaginator.js +2 -24
  6. package/dist-cjs/pagination/ListDataSourcesPaginator.js +2 -24
  7. package/dist-cjs/pagination/ListIngestionJobsPaginator.js +2 -24
  8. package/dist-cjs/pagination/ListKnowledgeBasesPaginator.js +2 -24
  9. package/dist-cjs/protocols/Aws_restJson1.js +232 -546
  10. package/dist-es/pagination/ListAgentActionGroupsPaginator.js +2 -23
  11. package/dist-es/pagination/ListAgentAliasesPaginator.js +2 -23
  12. package/dist-es/pagination/ListAgentKnowledgeBasesPaginator.js +2 -23
  13. package/dist-es/pagination/ListAgentVersionsPaginator.js +2 -23
  14. package/dist-es/pagination/ListAgentsPaginator.js +2 -23
  15. package/dist-es/pagination/ListDataSourcesPaginator.js +2 -23
  16. package/dist-es/pagination/ListIngestionJobsPaginator.js +2 -23
  17. package/dist-es/pagination/ListKnowledgeBasesPaginator.js +2 -23
  18. package/dist-es/protocols/Aws_restJson1.js +233 -547
  19. package/dist-types/pagination/ListAgentActionGroupsPaginator.d.ts +1 -1
  20. package/dist-types/pagination/ListAgentAliasesPaginator.d.ts +1 -1
  21. package/dist-types/pagination/ListAgentKnowledgeBasesPaginator.d.ts +1 -1
  22. package/dist-types/pagination/ListAgentVersionsPaginator.d.ts +1 -1
  23. package/dist-types/pagination/ListAgentsPaginator.d.ts +1 -1
  24. package/dist-types/pagination/ListDataSourcesPaginator.d.ts +1 -1
  25. package/dist-types/pagination/ListIngestionJobsPaginator.d.ts +1 -1
  26. package/dist-types/pagination/ListKnowledgeBasesPaginator.d.ts +1 -1
  27. package/dist-types/ts3.4/pagination/ListAgentActionGroupsPaginator.d.ts +3 -3
  28. package/dist-types/ts3.4/pagination/ListAgentAliasesPaginator.d.ts +3 -3
  29. package/dist-types/ts3.4/pagination/ListAgentKnowledgeBasesPaginator.d.ts +3 -3
  30. package/dist-types/ts3.4/pagination/ListAgentVersionsPaginator.d.ts +3 -3
  31. package/dist-types/ts3.4/pagination/ListAgentsPaginator.d.ts +3 -3
  32. package/dist-types/ts3.4/pagination/ListDataSourcesPaginator.d.ts +3 -3
  33. package/dist-types/ts3.4/pagination/ListIngestionJobsPaginator.d.ts +3 -3
  34. package/dist-types/ts3.4/pagination/ListKnowledgeBasesPaginator.d.ts +3 -3
  35. package/package.json +7 -6
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListAgentActionGroups = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const BedrockAgentClient_1 = require("../BedrockAgentClient");
5
6
  const ListAgentActionGroupsCommand_1 = require("../commands/ListAgentActionGroupsCommand");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListAgentActionGroupsCommand_1.ListAgentActionGroupsCommand(input), ...args);
8
- };
9
- async function* paginateListAgentActionGroups(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 BedrockAgentClient_1.BedrockAgentClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected BedrockAgent | BedrockAgentClient");
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.paginateListAgentActionGroups = paginateListAgentActionGroups;
7
+ exports.paginateListAgentActionGroups = (0, core_1.createPaginator)(BedrockAgentClient_1.BedrockAgentClient, ListAgentActionGroupsCommand_1.ListAgentActionGroupsCommand, "nextToken", "nextToken", "maxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListAgentAliases = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const BedrockAgentClient_1 = require("../BedrockAgentClient");
5
6
  const ListAgentAliasesCommand_1 = require("../commands/ListAgentAliasesCommand");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListAgentAliasesCommand_1.ListAgentAliasesCommand(input), ...args);
8
- };
9
- async function* paginateListAgentAliases(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 BedrockAgentClient_1.BedrockAgentClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected BedrockAgent | BedrockAgentClient");
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.paginateListAgentAliases = paginateListAgentAliases;
7
+ exports.paginateListAgentAliases = (0, core_1.createPaginator)(BedrockAgentClient_1.BedrockAgentClient, ListAgentAliasesCommand_1.ListAgentAliasesCommand, "nextToken", "nextToken", "maxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListAgentKnowledgeBases = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const BedrockAgentClient_1 = require("../BedrockAgentClient");
5
6
  const ListAgentKnowledgeBasesCommand_1 = require("../commands/ListAgentKnowledgeBasesCommand");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListAgentKnowledgeBasesCommand_1.ListAgentKnowledgeBasesCommand(input), ...args);
8
- };
9
- async function* paginateListAgentKnowledgeBases(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 BedrockAgentClient_1.BedrockAgentClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected BedrockAgent | BedrockAgentClient");
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.paginateListAgentKnowledgeBases = paginateListAgentKnowledgeBases;
7
+ exports.paginateListAgentKnowledgeBases = (0, core_1.createPaginator)(BedrockAgentClient_1.BedrockAgentClient, ListAgentKnowledgeBasesCommand_1.ListAgentKnowledgeBasesCommand, "nextToken", "nextToken", "maxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListAgentVersions = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const BedrockAgentClient_1 = require("../BedrockAgentClient");
5
6
  const ListAgentVersionsCommand_1 = require("../commands/ListAgentVersionsCommand");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListAgentVersionsCommand_1.ListAgentVersionsCommand(input), ...args);
8
- };
9
- async function* paginateListAgentVersions(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 BedrockAgentClient_1.BedrockAgentClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected BedrockAgent | BedrockAgentClient");
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.paginateListAgentVersions = paginateListAgentVersions;
7
+ exports.paginateListAgentVersions = (0, core_1.createPaginator)(BedrockAgentClient_1.BedrockAgentClient, ListAgentVersionsCommand_1.ListAgentVersionsCommand, "nextToken", "nextToken", "maxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListAgents = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const BedrockAgentClient_1 = require("../BedrockAgentClient");
5
6
  const ListAgentsCommand_1 = require("../commands/ListAgentsCommand");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListAgentsCommand_1.ListAgentsCommand(input), ...args);
8
- };
9
- async function* paginateListAgents(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 BedrockAgentClient_1.BedrockAgentClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected BedrockAgent | BedrockAgentClient");
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.paginateListAgents = paginateListAgents;
7
+ exports.paginateListAgents = (0, core_1.createPaginator)(BedrockAgentClient_1.BedrockAgentClient, ListAgentsCommand_1.ListAgentsCommand, "nextToken", "nextToken", "maxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListDataSources = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const BedrockAgentClient_1 = require("../BedrockAgentClient");
5
6
  const ListDataSourcesCommand_1 = require("../commands/ListDataSourcesCommand");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListDataSourcesCommand_1.ListDataSourcesCommand(input), ...args);
8
- };
9
- async function* paginateListDataSources(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 BedrockAgentClient_1.BedrockAgentClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected BedrockAgent | BedrockAgentClient");
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.paginateListDataSources = paginateListDataSources;
7
+ exports.paginateListDataSources = (0, core_1.createPaginator)(BedrockAgentClient_1.BedrockAgentClient, ListDataSourcesCommand_1.ListDataSourcesCommand, "nextToken", "nextToken", "maxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListIngestionJobs = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const BedrockAgentClient_1 = require("../BedrockAgentClient");
5
6
  const ListIngestionJobsCommand_1 = require("../commands/ListIngestionJobsCommand");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListIngestionJobsCommand_1.ListIngestionJobsCommand(input), ...args);
8
- };
9
- async function* paginateListIngestionJobs(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 BedrockAgentClient_1.BedrockAgentClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected BedrockAgent | BedrockAgentClient");
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.paginateListIngestionJobs = paginateListIngestionJobs;
7
+ exports.paginateListIngestionJobs = (0, core_1.createPaginator)(BedrockAgentClient_1.BedrockAgentClient, ListIngestionJobsCommand_1.ListIngestionJobsCommand, "nextToken", "nextToken", "maxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListKnowledgeBases = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const BedrockAgentClient_1 = require("../BedrockAgentClient");
5
6
  const ListKnowledgeBasesCommand_1 = require("../commands/ListKnowledgeBasesCommand");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListKnowledgeBasesCommand_1.ListKnowledgeBasesCommand(input), ...args);
8
- };
9
- async function* paginateListKnowledgeBases(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 BedrockAgentClient_1.BedrockAgentClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected BedrockAgent | BedrockAgentClient");
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.paginateListKnowledgeBases = paginateListKnowledgeBases;
7
+ exports.paginateListKnowledgeBases = (0, core_1.createPaginator)(BedrockAgentClient_1.BedrockAgentClient, ListKnowledgeBasesCommand_1.ListKnowledgeBasesCommand, "nextToken", "nextToken", "maxResults");