@aws-sdk/client-bedrock-agent 3.577.0 → 3.582.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/index.js CHANGED
@@ -665,6 +665,7 @@ var se_CreateAgentCommand = /* @__PURE__ */ __name(async (input, context) => {
665
665
  customerEncryptionKeyArn: [],
666
666
  description: [],
667
667
  foundationModel: [],
668
+ guardrailConfiguration: (_) => (0, import_smithy_client._json)(_),
668
669
  idleSessionTTLInSeconds: [],
669
670
  instruction: [],
670
671
  promptOverrideConfiguration: (_) => se_PromptOverrideConfiguration(_, context),
@@ -1142,6 +1143,7 @@ var se_UpdateAgentCommand = /* @__PURE__ */ __name(async (input, context) => {
1142
1143
  customerEncryptionKeyArn: [],
1143
1144
  description: [],
1144
1145
  foundationModel: [],
1146
+ guardrailConfiguration: (_) => (0, import_smithy_client._json)(_),
1145
1147
  idleSessionTTLInSeconds: [],
1146
1148
  instruction: [],
1147
1149
  promptOverrideConfiguration: (_) => se_PromptOverrideConfiguration(_, context)
@@ -2006,6 +2008,7 @@ var de_Agent = /* @__PURE__ */ __name((output, context) => {
2006
2008
  description: import_smithy_client.expectString,
2007
2009
  failureReasons: import_smithy_client._json,
2008
2010
  foundationModel: import_smithy_client.expectString,
2011
+ guardrailConfiguration: import_smithy_client._json,
2009
2012
  idleSessionTTLInSeconds: import_smithy_client.expectInt32,
2010
2013
  instruction: import_smithy_client.expectString,
2011
2014
  preparedAt: (_) => (0, import_smithy_client.expectNonNull)((0, import_smithy_client.parseRfc3339DateTimeWithOffset)(_)),
@@ -2114,6 +2117,7 @@ var de_AgentSummary = /* @__PURE__ */ __name((output, context) => {
2114
2117
  agentName: import_smithy_client.expectString,
2115
2118
  agentStatus: import_smithy_client.expectString,
2116
2119
  description: import_smithy_client.expectString,
2120
+ guardrailConfiguration: import_smithy_client._json,
2117
2121
  latestAgentVersion: import_smithy_client.expectString,
2118
2122
  updatedAt: (_) => (0, import_smithy_client.expectNonNull)((0, import_smithy_client.parseRfc3339DateTimeWithOffset)(_))
2119
2123
  });
@@ -2130,6 +2134,7 @@ var de_AgentVersion = /* @__PURE__ */ __name((output, context) => {
2130
2134
  description: import_smithy_client.expectString,
2131
2135
  failureReasons: import_smithy_client._json,
2132
2136
  foundationModel: import_smithy_client.expectString,
2137
+ guardrailConfiguration: import_smithy_client._json,
2133
2138
  idleSessionTTLInSeconds: import_smithy_client.expectInt32,
2134
2139
  instruction: import_smithy_client.expectString,
2135
2140
  promptOverrideConfiguration: (_) => de_PromptOverrideConfiguration(_, context),
@@ -2151,6 +2156,7 @@ var de_AgentVersionSummary = /* @__PURE__ */ __name((output, context) => {
2151
2156
  agentVersion: import_smithy_client.expectString,
2152
2157
  createdAt: (_) => (0, import_smithy_client.expectNonNull)((0, import_smithy_client.parseRfc3339DateTimeWithOffset)(_)),
2153
2158
  description: import_smithy_client.expectString,
2159
+ guardrailConfiguration: import_smithy_client._json,
2154
2160
  updatedAt: (_) => (0, import_smithy_client.expectNonNull)((0, import_smithy_client.parseRfc3339DateTimeWithOffset)(_))
2155
2161
  });
2156
2162
  }, "de_AgentVersionSummary");
@@ -35,6 +35,7 @@ export const se_CreateAgentCommand = async (input, context) => {
35
35
  customerEncryptionKeyArn: [],
36
36
  description: [],
37
37
  foundationModel: [],
38
+ guardrailConfiguration: (_) => _json(_),
38
39
  idleSessionTTLInSeconds: [],
39
40
  instruction: [],
40
41
  promptOverrideConfiguration: (_) => se_PromptOverrideConfiguration(_, context),
@@ -482,6 +483,7 @@ export const se_UpdateAgentCommand = async (input, context) => {
482
483
  customerEncryptionKeyArn: [],
483
484
  description: [],
484
485
  foundationModel: [],
486
+ guardrailConfiguration: (_) => _json(_),
485
487
  idleSessionTTLInSeconds: [],
486
488
  instruction: [],
487
489
  promptOverrideConfiguration: (_) => se_PromptOverrideConfiguration(_, context),
@@ -1339,6 +1341,7 @@ const de_Agent = (output, context) => {
1339
1341
  description: __expectString,
1340
1342
  failureReasons: _json,
1341
1343
  foundationModel: __expectString,
1344
+ guardrailConfiguration: _json,
1342
1345
  idleSessionTTLInSeconds: __expectInt32,
1343
1346
  instruction: __expectString,
1344
1347
  preparedAt: (_) => __expectNonNull(__parseRfc3339DateTimeWithOffset(_)),
@@ -1455,6 +1458,7 @@ const de_AgentSummary = (output, context) => {
1455
1458
  agentName: __expectString,
1456
1459
  agentStatus: __expectString,
1457
1460
  description: __expectString,
1461
+ guardrailConfiguration: _json,
1458
1462
  latestAgentVersion: __expectString,
1459
1463
  updatedAt: (_) => __expectNonNull(__parseRfc3339DateTimeWithOffset(_)),
1460
1464
  });
@@ -1471,6 +1475,7 @@ const de_AgentVersion = (output, context) => {
1471
1475
  description: __expectString,
1472
1476
  failureReasons: _json,
1473
1477
  foundationModel: __expectString,
1478
+ guardrailConfiguration: _json,
1474
1479
  idleSessionTTLInSeconds: __expectInt32,
1475
1480
  instruction: __expectString,
1476
1481
  promptOverrideConfiguration: (_) => de_PromptOverrideConfiguration(_, context),
@@ -1494,6 +1499,7 @@ const de_AgentVersionSummary = (output, context) => {
1494
1499
  agentVersion: __expectString,
1495
1500
  createdAt: (_) => __expectNonNull(__parseRfc3339DateTimeWithOffset(_)),
1496
1501
  description: __expectString,
1502
+ guardrailConfiguration: _json,
1497
1503
  updatedAt: (_) => __expectNonNull(__parseRfc3339DateTimeWithOffset(_)),
1498
1504
  });
1499
1505
  };
@@ -89,6 +89,10 @@ declare const CreateAgentCommand_base: {
89
89
  * ],
90
90
  * overrideLambda: "STRING_VALUE",
91
91
  * },
92
+ * guardrailConfiguration: { // GuardrailConfiguration
93
+ * guardrailIdentifier: "STRING_VALUE",
94
+ * guardrailVersion: "STRING_VALUE",
95
+ * },
92
96
  * };
93
97
  * const command = new CreateAgentCommand(input);
94
98
  * const response = await client.send(command);
@@ -136,6 +140,10 @@ declare const CreateAgentCommand_base: {
136
140
  * // ],
137
141
  * // overrideLambda: "STRING_VALUE",
138
142
  * // },
143
+ * // guardrailConfiguration: { // GuardrailConfiguration
144
+ * // guardrailIdentifier: "STRING_VALUE",
145
+ * // guardrailVersion: "STRING_VALUE",
146
+ * // },
139
147
  * // },
140
148
  * // };
141
149
  *
@@ -82,6 +82,10 @@ declare const GetAgentCommand_base: {
82
82
  * // ],
83
83
  * // overrideLambda: "STRING_VALUE",
84
84
  * // },
85
+ * // guardrailConfiguration: { // GuardrailConfiguration
86
+ * // guardrailIdentifier: "STRING_VALUE",
87
+ * // guardrailVersion: "STRING_VALUE",
88
+ * // },
85
89
  * // },
86
90
  * // };
87
91
  *
@@ -81,6 +81,10 @@ declare const GetAgentVersionCommand_base: {
81
81
  * // ],
82
82
  * // overrideLambda: "STRING_VALUE",
83
83
  * // },
84
+ * // guardrailConfiguration: { // GuardrailConfiguration
85
+ * // guardrailIdentifier: "STRING_VALUE",
86
+ * // guardrailVersion: "STRING_VALUE",
87
+ * // },
84
88
  * // },
85
89
  * // };
86
90
  *
@@ -49,6 +49,10 @@ declare const ListAgentVersionsCommand_base: {
49
49
  * // createdAt: new Date("TIMESTAMP"), // required
50
50
  * // updatedAt: new Date("TIMESTAMP"), // required
51
51
  * // description: "STRING_VALUE",
52
+ * // guardrailConfiguration: { // GuardrailConfiguration
53
+ * // guardrailIdentifier: "STRING_VALUE",
54
+ * // guardrailVersion: "STRING_VALUE",
55
+ * // },
52
56
  * // },
53
57
  * // ],
54
58
  * // nextToken: "STRING_VALUE",
@@ -48,6 +48,10 @@ declare const ListAgentsCommand_base: {
48
48
  * // description: "STRING_VALUE",
49
49
  * // updatedAt: new Date("TIMESTAMP"), // required
50
50
  * // latestAgentVersion: "STRING_VALUE",
51
+ * // guardrailConfiguration: { // GuardrailConfiguration
52
+ * // guardrailIdentifier: "STRING_VALUE",
53
+ * // guardrailVersion: "STRING_VALUE",
54
+ * // },
51
55
  * // },
52
56
  * // ],
53
57
  * // nextToken: "STRING_VALUE",
@@ -63,6 +63,10 @@ declare const UpdateAgentCommand_base: {
63
63
  * ],
64
64
  * overrideLambda: "STRING_VALUE",
65
65
  * },
66
+ * guardrailConfiguration: { // GuardrailConfiguration
67
+ * guardrailIdentifier: "STRING_VALUE",
68
+ * guardrailVersion: "STRING_VALUE",
69
+ * },
66
70
  * };
67
71
  * const command = new UpdateAgentCommand(input);
68
72
  * const response = await client.send(command);
@@ -110,6 +114,10 @@ declare const UpdateAgentCommand_base: {
110
114
  * // ],
111
115
  * // overrideLambda: "STRING_VALUE",
112
116
  * // },
117
+ * // guardrailConfiguration: { // GuardrailConfiguration
118
+ * // guardrailIdentifier: "STRING_VALUE",
119
+ * // guardrailVersion: "STRING_VALUE",
120
+ * // },
113
121
  * // },
114
122
  * // };
115
123
  *
@@ -767,6 +767,22 @@ export declare const AgentStatus: {
767
767
  * @public
768
768
  */
769
769
  export type AgentStatus = (typeof AgentStatus)[keyof typeof AgentStatus];
770
+ /**
771
+ * <p>The details of the guardrails configuration.</p>
772
+ * @public
773
+ */
774
+ export interface GuardrailConfiguration {
775
+ /**
776
+ * <p>The guardrails identifier assigned to the guardrails configuration.</p>
777
+ * @public
778
+ */
779
+ guardrailIdentifier?: string;
780
+ /**
781
+ * <p>The guardrails version assigned to the guardrails configuration.</p>
782
+ * @public
783
+ */
784
+ guardrailVersion?: string;
785
+ }
770
786
  /**
771
787
  * <p>Contains inference parameters to use when the agent invokes a foundation model in the part of the agent sequence defined by the <code>promptType</code>. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/model-parameters.html">Inference parameters for foundation models</a>.</p>
772
788
  * @public
@@ -879,7 +895,7 @@ export interface PromptConfiguration {
879
895
  */
880
896
  promptState?: PromptState;
881
897
  /**
882
- * <p>Defines the prompt template with which to replace the default prompt template. You can use placeholder variables in the base prompt template to customize the prompt. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/prompt-placeholders.html">Prompt template placeholder variables</a>.</p>
898
+ * <p>Defines the prompt template with which to replace the default prompt template. You can use placeholder variables in the base prompt template to customize the prompt. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/prompt-placeholders.html">Prompt template placeholder variables</a>. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts-configure.html">Configure the prompt templates</a>.</p>
883
899
  * @public
884
900
  */
885
901
  basePromptTemplate?: string;
@@ -905,7 +921,7 @@ export interface PromptOverrideConfiguration {
905
921
  */
906
922
  promptConfigurations: PromptConfiguration[] | undefined;
907
923
  /**
908
- * <p>The ARN of the Lambda function to use when parsing the raw foundation model output in parts of the agent sequence. If you specify this field, at least one of the <code>promptConfigurations</code> must contain a <code>parserMode</code> value that is set to <code>OVERRIDDEN</code>.</p>
924
+ * <p>The ARN of the Lambda function to use when parsing the raw foundation model output in parts of the agent sequence. If you specify this field, at least one of the <code>promptConfigurations</code> must contain a <code>parserMode</code> value that is set to <code>OVERRIDDEN</code>. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/lambda-parser.html">Parser Lambda function in Agents for Amazon Bedrock</a>.</p>
909
925
  * @public
910
926
  */
911
927
  overrideLambda?: string;
@@ -1030,6 +1046,11 @@ export interface Agent {
1030
1046
  * @public
1031
1047
  */
1032
1048
  promptOverrideConfiguration?: PromptOverrideConfiguration;
1049
+ /**
1050
+ * <p>The guardrails configuration assigned to the agent.</p>
1051
+ * @public
1052
+ */
1053
+ guardrailConfiguration?: GuardrailConfiguration;
1033
1054
  }
1034
1055
  /**
1035
1056
  * <p>Contains details about the routing configuration of the alias.</p>
@@ -1343,6 +1364,11 @@ export interface CreateAgentRequest {
1343
1364
  * @public
1344
1365
  */
1345
1366
  promptOverrideConfiguration?: PromptOverrideConfiguration;
1367
+ /**
1368
+ * <p>The unique Guardrail configuration assigned to the agent when it is created.</p>
1369
+ * @public
1370
+ */
1371
+ guardrailConfiguration?: GuardrailConfiguration;
1346
1372
  }
1347
1373
  /**
1348
1374
  * @public
@@ -1454,6 +1480,11 @@ export interface AgentSummary {
1454
1480
  * @public
1455
1481
  */
1456
1482
  latestAgentVersion?: string;
1483
+ /**
1484
+ * <p>The details of the guardrails configuration in the agent summary.</p>
1485
+ * @public
1486
+ */
1487
+ guardrailConfiguration?: GuardrailConfiguration;
1457
1488
  }
1458
1489
  /**
1459
1490
  * @public
@@ -1555,6 +1586,11 @@ export interface UpdateAgentRequest {
1555
1586
  * @public
1556
1587
  */
1557
1588
  promptOverrideConfiguration?: PromptOverrideConfiguration;
1589
+ /**
1590
+ * <p>The unique Guardrail configuration assigned to the agent when it is updated.</p>
1591
+ * @public
1592
+ */
1593
+ guardrailConfiguration?: GuardrailConfiguration;
1558
1594
  }
1559
1595
  /**
1560
1596
  * @public
@@ -1652,6 +1688,11 @@ export interface AgentVersion {
1652
1688
  * @public
1653
1689
  */
1654
1690
  promptOverrideConfiguration?: PromptOverrideConfiguration;
1691
+ /**
1692
+ * <p>The guardrails configuration assigned to the agent version.</p>
1693
+ * @public
1694
+ */
1695
+ guardrailConfiguration?: GuardrailConfiguration;
1655
1696
  }
1656
1697
  /**
1657
1698
  * <p>Contains details about a version of an agent.</p>
@@ -1688,6 +1729,11 @@ export interface AgentVersionSummary {
1688
1729
  * @public
1689
1730
  */
1690
1731
  description?: string;
1732
+ /**
1733
+ * <p>The details of the guardrails configuration in the agent version summary.</p>
1734
+ * @public
1735
+ */
1736
+ guardrailConfiguration?: GuardrailConfiguration;
1691
1737
  }
1692
1738
  /**
1693
1739
  * @public
@@ -250,6 +250,10 @@ export declare const AgentStatus: {
250
250
  readonly VERSIONING: "VERSIONING";
251
251
  };
252
252
  export type AgentStatus = (typeof AgentStatus)[keyof typeof AgentStatus];
253
+ export interface GuardrailConfiguration {
254
+ guardrailIdentifier?: string;
255
+ guardrailVersion?: string;
256
+ }
253
257
  export interface InferenceConfiguration {
254
258
  temperature?: number;
255
259
  topP?: number;
@@ -305,6 +309,7 @@ export interface Agent {
305
309
  failureReasons?: string[];
306
310
  recommendedActions?: string[];
307
311
  promptOverrideConfiguration?: PromptOverrideConfiguration;
312
+ guardrailConfiguration?: GuardrailConfiguration;
308
313
  }
309
314
  export interface AgentAliasRoutingConfigurationListItem {
310
315
  agentVersion?: string;
@@ -379,6 +384,7 @@ export interface CreateAgentRequest {
379
384
  customerEncryptionKeyArn?: string;
380
385
  tags?: Record<string, string>;
381
386
  promptOverrideConfiguration?: PromptOverrideConfiguration;
387
+ guardrailConfiguration?: GuardrailConfiguration;
382
388
  }
383
389
  export interface CreateAgentResponse {
384
390
  agent: Agent | undefined;
@@ -408,6 +414,7 @@ export interface AgentSummary {
408
414
  description?: string;
409
415
  updatedAt: Date | undefined;
410
416
  latestAgentVersion?: string;
417
+ guardrailConfiguration?: GuardrailConfiguration;
411
418
  }
412
419
  export interface ListAgentsResponse {
413
420
  agentSummaries: AgentSummary[] | undefined;
@@ -432,6 +439,7 @@ export interface UpdateAgentRequest {
432
439
  agentResourceRoleArn: string | undefined;
433
440
  customerEncryptionKeyArn?: string;
434
441
  promptOverrideConfiguration?: PromptOverrideConfiguration;
442
+ guardrailConfiguration?: GuardrailConfiguration;
435
443
  }
436
444
  export interface UpdateAgentResponse {
437
445
  agent: Agent | undefined;
@@ -453,6 +461,7 @@ export interface AgentVersion {
453
461
  failureReasons?: string[];
454
462
  recommendedActions?: string[];
455
463
  promptOverrideConfiguration?: PromptOverrideConfiguration;
464
+ guardrailConfiguration?: GuardrailConfiguration;
456
465
  }
457
466
  export interface AgentVersionSummary {
458
467
  agentName: string | undefined;
@@ -461,6 +470,7 @@ export interface AgentVersionSummary {
461
470
  createdAt: Date | undefined;
462
471
  updatedAt: Date | undefined;
463
472
  description?: string;
473
+ guardrailConfiguration?: GuardrailConfiguration;
464
474
  }
465
475
  export interface CreateAgentAliasRequest {
466
476
  agentId: string | undefined;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@aws-sdk/client-bedrock-agent",
3
3
  "description": "AWS SDK for JavaScript Bedrock Agent Client for Node.js, Browser and React Native",
4
- "version": "3.577.0",
4
+ "version": "3.582.0",
5
5
  "scripts": {
6
6
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
7
7
  "build:cjs": "node ../../scripts/compilation/inline client-bedrock-agent",
@@ -20,10 +20,10 @@
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-sso-oidc": "3.577.0",
24
- "@aws-sdk/client-sts": "3.577.0",
25
- "@aws-sdk/core": "3.576.0",
26
- "@aws-sdk/credential-provider-node": "3.577.0",
23
+ "@aws-sdk/client-sso-oidc": "3.582.0",
24
+ "@aws-sdk/client-sts": "3.582.0",
25
+ "@aws-sdk/core": "3.582.0",
26
+ "@aws-sdk/credential-provider-node": "3.582.0",
27
27
  "@aws-sdk/middleware-host-header": "3.577.0",
28
28
  "@aws-sdk/middleware-logger": "3.577.0",
29
29
  "@aws-sdk/middleware-recursion-detection": "3.577.0",
@@ -34,26 +34,26 @@
34
34
  "@aws-sdk/util-user-agent-browser": "3.577.0",
35
35
  "@aws-sdk/util-user-agent-node": "3.577.0",
36
36
  "@smithy/config-resolver": "^3.0.0",
37
- "@smithy/core": "^2.0.0",
38
- "@smithy/fetch-http-handler": "^3.0.0",
37
+ "@smithy/core": "^2.0.1",
38
+ "@smithy/fetch-http-handler": "^3.0.1",
39
39
  "@smithy/hash-node": "^3.0.0",
40
40
  "@smithy/invalid-dependency": "^3.0.0",
41
41
  "@smithy/middleware-content-length": "^3.0.0",
42
42
  "@smithy/middleware-endpoint": "^3.0.0",
43
- "@smithy/middleware-retry": "^3.0.0",
43
+ "@smithy/middleware-retry": "^3.0.1",
44
44
  "@smithy/middleware-serde": "^3.0.0",
45
45
  "@smithy/middleware-stack": "^3.0.0",
46
46
  "@smithy/node-config-provider": "^3.0.0",
47
47
  "@smithy/node-http-handler": "^3.0.0",
48
48
  "@smithy/protocol-http": "^4.0.0",
49
- "@smithy/smithy-client": "^3.0.0",
49
+ "@smithy/smithy-client": "^3.0.1",
50
50
  "@smithy/types": "^3.0.0",
51
51
  "@smithy/url-parser": "^3.0.0",
52
52
  "@smithy/util-base64": "^3.0.0",
53
53
  "@smithy/util-body-length-browser": "^3.0.0",
54
54
  "@smithy/util-body-length-node": "^3.0.0",
55
- "@smithy/util-defaults-mode-browser": "^3.0.0",
56
- "@smithy/util-defaults-mode-node": "^3.0.0",
55
+ "@smithy/util-defaults-mode-browser": "^3.0.1",
56
+ "@smithy/util-defaults-mode-node": "^3.0.1",
57
57
  "@smithy/util-endpoints": "^2.0.0",
58
58
  "@smithy/util-middleware": "^3.0.0",
59
59
  "@smithy/util-retry": "^3.0.0",