@aws-sdk/client-bedrock-agentcore 3.908.0 → 3.909.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/README.md +8 -0
- package/dist-cjs/index.js +86 -6
- package/dist-es/BedrockAgentCore.js +2 -0
- package/dist-es/commands/CompleteResourceTokenAuthCommand.js +23 -0
- package/dist-es/commands/index.js +1 -0
- package/dist-es/models/models_0.js +28 -0
- package/dist-es/protocols/Aws_restJson1.js +36 -6
- package/dist-types/BedrockAgentCore.d.ts +7 -0
- package/dist-types/BedrockAgentCoreClient.d.ts +3 -2
- package/dist-types/commands/CompleteResourceTokenAuthCommand.d.ts +94 -0
- package/dist-types/commands/GetResourceOauth2TokenCommand.d.ts +4 -0
- package/dist-types/commands/InvokeAgentRuntimeCommand.d.ts +1 -0
- package/dist-types/commands/index.d.ts +1 -0
- package/dist-types/models/models_0.d.ts +107 -0
- package/dist-types/protocols/Aws_restJson1.d.ts +9 -0
- package/dist-types/ts3.4/BedrockAgentCore.d.ts +17 -0
- package/dist-types/ts3.4/BedrockAgentCoreClient.d.ts +6 -0
- package/dist-types/ts3.4/commands/CompleteResourceTokenAuthCommand.d.ts +51 -0
- package/dist-types/ts3.4/commands/index.d.ts +1 -0
- package/dist-types/ts3.4/models/models_0.d.ts +48 -0
- package/dist-types/ts3.4/protocols/Aws_restJson1.d.ts +12 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -226,6 +226,14 @@ BatchUpdateMemoryRecords
|
|
|
226
226
|
|
|
227
227
|
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/bedrock-agentcore/command/BatchUpdateMemoryRecordsCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-bedrock-agentcore/Interface/BatchUpdateMemoryRecordsCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-bedrock-agentcore/Interface/BatchUpdateMemoryRecordsCommandOutput/)
|
|
228
228
|
|
|
229
|
+
</details>
|
|
230
|
+
<details>
|
|
231
|
+
<summary>
|
|
232
|
+
CompleteResourceTokenAuth
|
|
233
|
+
</summary>
|
|
234
|
+
|
|
235
|
+
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/bedrock-agentcore/command/CompleteResourceTokenAuthCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-bedrock-agentcore/Interface/CompleteResourceTokenAuthCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-bedrock-agentcore/Interface/CompleteResourceTokenAuthCommandOutput/)
|
|
236
|
+
|
|
229
237
|
</details>
|
|
230
238
|
<details>
|
|
231
239
|
<summary>
|
package/dist-cjs/index.js
CHANGED
|
@@ -259,10 +259,24 @@ const CodeInterpreterSessionStatus = {
|
|
|
259
259
|
READY: "READY",
|
|
260
260
|
TERMINATED: "TERMINATED",
|
|
261
261
|
};
|
|
262
|
+
exports.UserIdentifier = void 0;
|
|
263
|
+
(function (UserIdentifier) {
|
|
264
|
+
UserIdentifier.visit = (value, visitor) => {
|
|
265
|
+
if (value.userToken !== undefined)
|
|
266
|
+
return visitor.userToken(value.userToken);
|
|
267
|
+
if (value.userId !== undefined)
|
|
268
|
+
return visitor.userId(value.userId);
|
|
269
|
+
return visitor._(value.$unknown[0], value.$unknown[1]);
|
|
270
|
+
};
|
|
271
|
+
})(exports.UserIdentifier || (exports.UserIdentifier = {}));
|
|
262
272
|
const Oauth2FlowType = {
|
|
263
273
|
M2M: "M2M",
|
|
264
274
|
USER_FEDERATION: "USER_FEDERATION",
|
|
265
275
|
};
|
|
276
|
+
const SessionStatus = {
|
|
277
|
+
FAILED: "FAILED",
|
|
278
|
+
IN_PROGRESS: "IN_PROGRESS",
|
|
279
|
+
};
|
|
266
280
|
const ProgrammingLanguage = {
|
|
267
281
|
JAVASCRIPT: "javascript",
|
|
268
282
|
PYTHON: "python",
|
|
@@ -427,6 +441,18 @@ const InvokeAgentRuntimeResponseFilterSensitiveLog = (obj) => ({
|
|
|
427
441
|
...obj,
|
|
428
442
|
...(obj.response && { response: smithyClient.SENSITIVE_STRING }),
|
|
429
443
|
});
|
|
444
|
+
const UserIdentifierFilterSensitiveLog = (obj) => {
|
|
445
|
+
if (obj.userToken !== undefined)
|
|
446
|
+
return { userToken: smithyClient.SENSITIVE_STRING };
|
|
447
|
+
if (obj.userId !== undefined)
|
|
448
|
+
return { userId: obj.userId };
|
|
449
|
+
if (obj.$unknown !== undefined)
|
|
450
|
+
return { [obj.$unknown[0]]: "UNKNOWN" };
|
|
451
|
+
};
|
|
452
|
+
const CompleteResourceTokenAuthRequestFilterSensitiveLog = (obj) => ({
|
|
453
|
+
...obj,
|
|
454
|
+
...(obj.userIdentifier && { userIdentifier: UserIdentifierFilterSensitiveLog(obj.userIdentifier) }),
|
|
455
|
+
});
|
|
430
456
|
const GetResourceApiKeyRequestFilterSensitiveLog = (obj) => ({
|
|
431
457
|
...obj,
|
|
432
458
|
...(obj.workloadIdentityToken && { workloadIdentityToken: smithyClient.SENSITIVE_STRING }),
|
|
@@ -439,9 +465,11 @@ const GetResourceOauth2TokenRequestFilterSensitiveLog = (obj) => ({
|
|
|
439
465
|
...obj,
|
|
440
466
|
...(obj.workloadIdentityToken && { workloadIdentityToken: smithyClient.SENSITIVE_STRING }),
|
|
441
467
|
...(obj.customParameters && { customParameters: smithyClient.SENSITIVE_STRING }),
|
|
468
|
+
...(obj.customState && { customState: smithyClient.SENSITIVE_STRING }),
|
|
442
469
|
});
|
|
443
470
|
const GetResourceOauth2TokenResponseFilterSensitiveLog = (obj) => ({
|
|
444
471
|
...obj,
|
|
472
|
+
...(obj.authorizationUrl && { authorizationUrl: smithyClient.SENSITIVE_STRING }),
|
|
445
473
|
...(obj.accessToken && { accessToken: smithyClient.SENSITIVE_STRING }),
|
|
446
474
|
});
|
|
447
475
|
const GetWorkloadAccessTokenResponseFilterSensitiveLog = (obj) => ({
|
|
@@ -638,6 +666,20 @@ const se_BatchUpdateMemoryRecordsCommand = async (input, context) => {
|
|
|
638
666
|
b.m("POST").h(headers).b(body);
|
|
639
667
|
return b.build();
|
|
640
668
|
};
|
|
669
|
+
const se_CompleteResourceTokenAuthCommand = async (input, context) => {
|
|
670
|
+
const b = core.requestBuilder(input, context);
|
|
671
|
+
const headers = {
|
|
672
|
+
"content-type": "application/json",
|
|
673
|
+
};
|
|
674
|
+
b.bp("/identities/CompleteResourceTokenAuth");
|
|
675
|
+
let body;
|
|
676
|
+
body = JSON.stringify(smithyClient.take(input, {
|
|
677
|
+
sessionUri: [],
|
|
678
|
+
userIdentifier: (_) => smithyClient._json(_),
|
|
679
|
+
}));
|
|
680
|
+
b.m("POST").h(headers).b(body);
|
|
681
|
+
return b.build();
|
|
682
|
+
};
|
|
641
683
|
const se_CreateEventCommand = async (input, context) => {
|
|
642
684
|
const b = core.requestBuilder(input, context);
|
|
643
685
|
const headers = {
|
|
@@ -763,11 +805,13 @@ const se_GetResourceOauth2TokenCommand = async (input, context) => {
|
|
|
763
805
|
let body;
|
|
764
806
|
body = JSON.stringify(smithyClient.take(input, {
|
|
765
807
|
customParameters: (_) => smithyClient._json(_),
|
|
808
|
+
customState: [],
|
|
766
809
|
forceAuthentication: [],
|
|
767
810
|
oauth2Flow: [],
|
|
768
811
|
resourceCredentialProviderName: [],
|
|
769
812
|
resourceOauth2ReturnUrl: [],
|
|
770
813
|
scopes: (_) => smithyClient._json(_),
|
|
814
|
+
sessionUri: [],
|
|
771
815
|
workloadIdentityToken: [],
|
|
772
816
|
}));
|
|
773
817
|
b.m("POST").h(headers).b(body);
|
|
@@ -832,6 +876,7 @@ const se_InvokeAgentRuntimeCommand = async (input, context) => {
|
|
|
832
876
|
b.p("agentRuntimeArn", () => input.agentRuntimeArn, "{agentRuntimeArn}", false);
|
|
833
877
|
const query = smithyClient.map({
|
|
834
878
|
[_q]: [, input[_q]],
|
|
879
|
+
[_aI]: [, input[_aI]],
|
|
835
880
|
});
|
|
836
881
|
let body;
|
|
837
882
|
if (input.payload !== undefined) {
|
|
@@ -1130,6 +1175,16 @@ const de_BatchUpdateMemoryRecordsCommand = async (output, context) => {
|
|
|
1130
1175
|
Object.assign(contents, doc);
|
|
1131
1176
|
return contents;
|
|
1132
1177
|
};
|
|
1178
|
+
const de_CompleteResourceTokenAuthCommand = async (output, context) => {
|
|
1179
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1180
|
+
return de_CommandError(output, context);
|
|
1181
|
+
}
|
|
1182
|
+
const contents = smithyClient.map({
|
|
1183
|
+
$metadata: deserializeMetadata(output),
|
|
1184
|
+
});
|
|
1185
|
+
await smithyClient.collectBody(output.body, context);
|
|
1186
|
+
return contents;
|
|
1187
|
+
};
|
|
1133
1188
|
const de_CreateEventCommand = async (output, context) => {
|
|
1134
1189
|
if (output.statusCode !== 201 && output.statusCode >= 300) {
|
|
1135
1190
|
return de_CommandError(output, context);
|
|
@@ -1283,6 +1338,8 @@ const de_GetResourceOauth2TokenCommand = async (output, context) => {
|
|
|
1283
1338
|
const doc = smithyClient.take(data, {
|
|
1284
1339
|
accessToken: smithyClient.expectString,
|
|
1285
1340
|
authorizationUrl: smithyClient.expectString,
|
|
1341
|
+
sessionStatus: smithyClient.expectString,
|
|
1342
|
+
sessionUri: smithyClient.expectString,
|
|
1286
1343
|
});
|
|
1287
1344
|
Object.assign(contents, doc);
|
|
1288
1345
|
return contents;
|
|
@@ -1590,21 +1647,21 @@ const de_CommandError = async (output, context) => {
|
|
|
1590
1647
|
case "ValidationException":
|
|
1591
1648
|
case "com.amazonaws.bedrockagentcore#ValidationException":
|
|
1592
1649
|
throw await de_ValidationExceptionRes(parsedOutput);
|
|
1593
|
-
case "InvalidInputException":
|
|
1594
|
-
case "com.amazonaws.bedrockagentcore#InvalidInputException":
|
|
1595
|
-
throw await de_InvalidInputExceptionRes(parsedOutput);
|
|
1596
1650
|
case "InternalServerException":
|
|
1597
1651
|
case "com.amazonaws.bedrockagentcore#InternalServerException":
|
|
1598
1652
|
throw await de_InternalServerExceptionRes(parsedOutput);
|
|
1599
|
-
case "RuntimeClientError":
|
|
1600
|
-
case "com.amazonaws.bedrockagentcore#RuntimeClientError":
|
|
1601
|
-
throw await de_RuntimeClientErrorRes(parsedOutput);
|
|
1602
1653
|
case "ThrottlingException":
|
|
1603
1654
|
case "com.amazonaws.bedrockagentcore#ThrottlingException":
|
|
1604
1655
|
throw await de_ThrottlingExceptionRes(parsedOutput);
|
|
1605
1656
|
case "UnauthorizedException":
|
|
1606
1657
|
case "com.amazonaws.bedrockagentcore#UnauthorizedException":
|
|
1607
1658
|
throw await de_UnauthorizedExceptionRes(parsedOutput);
|
|
1659
|
+
case "InvalidInputException":
|
|
1660
|
+
case "com.amazonaws.bedrockagentcore#InvalidInputException":
|
|
1661
|
+
throw await de_InvalidInputExceptionRes(parsedOutput);
|
|
1662
|
+
case "RuntimeClientError":
|
|
1663
|
+
case "com.amazonaws.bedrockagentcore#RuntimeClientError":
|
|
1664
|
+
throw await de_RuntimeClientErrorRes(parsedOutput);
|
|
1608
1665
|
case "ConflictException":
|
|
1609
1666
|
case "com.amazonaws.bedrockagentcore#ConflictException":
|
|
1610
1667
|
throw await de_ConflictExceptionRes(parsedOutput);
|
|
@@ -2129,6 +2186,7 @@ const deserializeMetadata = (output) => ({
|
|
|
2129
2186
|
});
|
|
2130
2187
|
const collectBodyString = (streamBody, context) => smithyClient.collectBody(streamBody, context).then((body) => context.utf8Encoder(body));
|
|
2131
2188
|
const _a = "accept";
|
|
2189
|
+
const _aI = "accountId";
|
|
2132
2190
|
const _b = "baggage";
|
|
2133
2191
|
const _cT = "contentType";
|
|
2134
2192
|
const _ct = "content-type";
|
|
@@ -2201,6 +2259,23 @@ class BatchUpdateMemoryRecordsCommand extends smithyClient.Command
|
|
|
2201
2259
|
.build() {
|
|
2202
2260
|
}
|
|
2203
2261
|
|
|
2262
|
+
class CompleteResourceTokenAuthCommand extends smithyClient.Command
|
|
2263
|
+
.classBuilder()
|
|
2264
|
+
.ep(commonParams)
|
|
2265
|
+
.m(function (Command, cs, config, o) {
|
|
2266
|
+
return [
|
|
2267
|
+
middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
|
|
2268
|
+
middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
|
|
2269
|
+
];
|
|
2270
|
+
})
|
|
2271
|
+
.s("AmazonBedrockAgentCore", "CompleteResourceTokenAuth", {})
|
|
2272
|
+
.n("BedrockAgentCoreClient", "CompleteResourceTokenAuthCommand")
|
|
2273
|
+
.f(CompleteResourceTokenAuthRequestFilterSensitiveLog, void 0)
|
|
2274
|
+
.ser(se_CompleteResourceTokenAuthCommand)
|
|
2275
|
+
.de(de_CompleteResourceTokenAuthCommand)
|
|
2276
|
+
.build() {
|
|
2277
|
+
}
|
|
2278
|
+
|
|
2204
2279
|
class CreateEventCommand extends smithyClient.Command
|
|
2205
2280
|
.classBuilder()
|
|
2206
2281
|
.ep(commonParams)
|
|
@@ -2685,6 +2760,7 @@ const commands = {
|
|
|
2685
2760
|
BatchCreateMemoryRecordsCommand,
|
|
2686
2761
|
BatchDeleteMemoryRecordsCommand,
|
|
2687
2762
|
BatchUpdateMemoryRecordsCommand,
|
|
2763
|
+
CompleteResourceTokenAuthCommand,
|
|
2688
2764
|
CreateEventCommand,
|
|
2689
2765
|
DeleteEventCommand,
|
|
2690
2766
|
DeleteMemoryRecordCommand,
|
|
@@ -2749,6 +2825,8 @@ exports.BedrockAgentCoreServiceException = BedrockAgentCoreServiceException;
|
|
|
2749
2825
|
exports.BrowserSessionStatus = BrowserSessionStatus;
|
|
2750
2826
|
exports.CodeInterpreterSessionStatus = CodeInterpreterSessionStatus;
|
|
2751
2827
|
exports.CodeInterpreterStreamOutputFilterSensitiveLog = CodeInterpreterStreamOutputFilterSensitiveLog;
|
|
2828
|
+
exports.CompleteResourceTokenAuthCommand = CompleteResourceTokenAuthCommand;
|
|
2829
|
+
exports.CompleteResourceTokenAuthRequestFilterSensitiveLog = CompleteResourceTokenAuthRequestFilterSensitiveLog;
|
|
2752
2830
|
exports.ConflictException = ConflictException;
|
|
2753
2831
|
exports.ContentBlockType = ContentBlockType;
|
|
2754
2832
|
exports.ContentFilterSensitiveLog = ContentFilterSensitiveLog;
|
|
@@ -2816,6 +2894,7 @@ exports.RuntimeClientError = RuntimeClientError;
|
|
|
2816
2894
|
exports.SearchCriteriaFilterSensitiveLog = SearchCriteriaFilterSensitiveLog;
|
|
2817
2895
|
exports.ServiceException = ServiceException;
|
|
2818
2896
|
exports.ServiceQuotaExceededException = ServiceQuotaExceededException;
|
|
2897
|
+
exports.SessionStatus = SessionStatus;
|
|
2819
2898
|
exports.StartBrowserSessionCommand = StartBrowserSessionCommand;
|
|
2820
2899
|
exports.StartCodeInterpreterSessionCommand = StartCodeInterpreterSessionCommand;
|
|
2821
2900
|
exports.StopBrowserSessionCommand = StopBrowserSessionCommand;
|
|
@@ -2828,6 +2907,7 @@ exports.ToolArgumentsFilterSensitiveLog = ToolArgumentsFilterSensitiveLog;
|
|
|
2828
2907
|
exports.ToolName = ToolName;
|
|
2829
2908
|
exports.UnauthorizedException = UnauthorizedException;
|
|
2830
2909
|
exports.UpdateBrowserStreamCommand = UpdateBrowserStreamCommand;
|
|
2910
|
+
exports.UserIdentifierFilterSensitiveLog = UserIdentifierFilterSensitiveLog;
|
|
2831
2911
|
exports.ValidationException = ValidationException;
|
|
2832
2912
|
exports.ValidationExceptionReason = ValidationExceptionReason;
|
|
2833
2913
|
exports.paginateListActors = paginateListActors;
|
|
@@ -3,6 +3,7 @@ import { BedrockAgentCoreClient } from "./BedrockAgentCoreClient";
|
|
|
3
3
|
import { BatchCreateMemoryRecordsCommand, } from "./commands/BatchCreateMemoryRecordsCommand";
|
|
4
4
|
import { BatchDeleteMemoryRecordsCommand, } from "./commands/BatchDeleteMemoryRecordsCommand";
|
|
5
5
|
import { BatchUpdateMemoryRecordsCommand, } from "./commands/BatchUpdateMemoryRecordsCommand";
|
|
6
|
+
import { CompleteResourceTokenAuthCommand, } from "./commands/CompleteResourceTokenAuthCommand";
|
|
6
7
|
import { CreateEventCommand } from "./commands/CreateEventCommand";
|
|
7
8
|
import { DeleteEventCommand } from "./commands/DeleteEventCommand";
|
|
8
9
|
import { DeleteMemoryRecordCommand, } from "./commands/DeleteMemoryRecordCommand";
|
|
@@ -35,6 +36,7 @@ const commands = {
|
|
|
35
36
|
BatchCreateMemoryRecordsCommand,
|
|
36
37
|
BatchDeleteMemoryRecordsCommand,
|
|
37
38
|
BatchUpdateMemoryRecordsCommand,
|
|
39
|
+
CompleteResourceTokenAuthCommand,
|
|
38
40
|
CreateEventCommand,
|
|
39
41
|
DeleteEventCommand,
|
|
40
42
|
DeleteMemoryRecordCommand,
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { getEndpointPlugin } from "@smithy/middleware-endpoint";
|
|
2
|
+
import { getSerdePlugin } from "@smithy/middleware-serde";
|
|
3
|
+
import { Command as $Command } from "@smithy/smithy-client";
|
|
4
|
+
import { commonParams } from "../endpoint/EndpointParameters";
|
|
5
|
+
import { CompleteResourceTokenAuthRequestFilterSensitiveLog, } from "../models/models_0";
|
|
6
|
+
import { de_CompleteResourceTokenAuthCommand, se_CompleteResourceTokenAuthCommand } from "../protocols/Aws_restJson1";
|
|
7
|
+
export { $Command };
|
|
8
|
+
export class CompleteResourceTokenAuthCommand extends $Command
|
|
9
|
+
.classBuilder()
|
|
10
|
+
.ep(commonParams)
|
|
11
|
+
.m(function (Command, cs, config, o) {
|
|
12
|
+
return [
|
|
13
|
+
getSerdePlugin(config, this.serialize, this.deserialize),
|
|
14
|
+
getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
|
|
15
|
+
];
|
|
16
|
+
})
|
|
17
|
+
.s("AmazonBedrockAgentCore", "CompleteResourceTokenAuth", {})
|
|
18
|
+
.n("BedrockAgentCoreClient", "CompleteResourceTokenAuthCommand")
|
|
19
|
+
.f(CompleteResourceTokenAuthRequestFilterSensitiveLog, void 0)
|
|
20
|
+
.ser(se_CompleteResourceTokenAuthCommand)
|
|
21
|
+
.de(de_CompleteResourceTokenAuthCommand)
|
|
22
|
+
.build() {
|
|
23
|
+
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
export * from "./BatchCreateMemoryRecordsCommand";
|
|
2
2
|
export * from "./BatchDeleteMemoryRecordsCommand";
|
|
3
3
|
export * from "./BatchUpdateMemoryRecordsCommand";
|
|
4
|
+
export * from "./CompleteResourceTokenAuthCommand";
|
|
4
5
|
export * from "./CreateEventCommand";
|
|
5
6
|
export * from "./DeleteEventCommand";
|
|
6
7
|
export * from "./DeleteMemoryRecordCommand";
|
|
@@ -139,10 +139,24 @@ export const CodeInterpreterSessionStatus = {
|
|
|
139
139
|
READY: "READY",
|
|
140
140
|
TERMINATED: "TERMINATED",
|
|
141
141
|
};
|
|
142
|
+
export var UserIdentifier;
|
|
143
|
+
(function (UserIdentifier) {
|
|
144
|
+
UserIdentifier.visit = (value, visitor) => {
|
|
145
|
+
if (value.userToken !== undefined)
|
|
146
|
+
return visitor.userToken(value.userToken);
|
|
147
|
+
if (value.userId !== undefined)
|
|
148
|
+
return visitor.userId(value.userId);
|
|
149
|
+
return visitor._(value.$unknown[0], value.$unknown[1]);
|
|
150
|
+
};
|
|
151
|
+
})(UserIdentifier || (UserIdentifier = {}));
|
|
142
152
|
export const Oauth2FlowType = {
|
|
143
153
|
M2M: "M2M",
|
|
144
154
|
USER_FEDERATION: "USER_FEDERATION",
|
|
145
155
|
};
|
|
156
|
+
export const SessionStatus = {
|
|
157
|
+
FAILED: "FAILED",
|
|
158
|
+
IN_PROGRESS: "IN_PROGRESS",
|
|
159
|
+
};
|
|
146
160
|
export const ProgrammingLanguage = {
|
|
147
161
|
JAVASCRIPT: "javascript",
|
|
148
162
|
PYTHON: "python",
|
|
@@ -307,6 +321,18 @@ export const InvokeAgentRuntimeResponseFilterSensitiveLog = (obj) => ({
|
|
|
307
321
|
...obj,
|
|
308
322
|
...(obj.response && { response: SENSITIVE_STRING }),
|
|
309
323
|
});
|
|
324
|
+
export const UserIdentifierFilterSensitiveLog = (obj) => {
|
|
325
|
+
if (obj.userToken !== undefined)
|
|
326
|
+
return { userToken: SENSITIVE_STRING };
|
|
327
|
+
if (obj.userId !== undefined)
|
|
328
|
+
return { userId: obj.userId };
|
|
329
|
+
if (obj.$unknown !== undefined)
|
|
330
|
+
return { [obj.$unknown[0]]: "UNKNOWN" };
|
|
331
|
+
};
|
|
332
|
+
export const CompleteResourceTokenAuthRequestFilterSensitiveLog = (obj) => ({
|
|
333
|
+
...obj,
|
|
334
|
+
...(obj.userIdentifier && { userIdentifier: UserIdentifierFilterSensitiveLog(obj.userIdentifier) }),
|
|
335
|
+
});
|
|
310
336
|
export const GetResourceApiKeyRequestFilterSensitiveLog = (obj) => ({
|
|
311
337
|
...obj,
|
|
312
338
|
...(obj.workloadIdentityToken && { workloadIdentityToken: SENSITIVE_STRING }),
|
|
@@ -319,9 +345,11 @@ export const GetResourceOauth2TokenRequestFilterSensitiveLog = (obj) => ({
|
|
|
319
345
|
...obj,
|
|
320
346
|
...(obj.workloadIdentityToken && { workloadIdentityToken: SENSITIVE_STRING }),
|
|
321
347
|
...(obj.customParameters && { customParameters: SENSITIVE_STRING }),
|
|
348
|
+
...(obj.customState && { customState: SENSITIVE_STRING }),
|
|
322
349
|
});
|
|
323
350
|
export const GetResourceOauth2TokenResponseFilterSensitiveLog = (obj) => ({
|
|
324
351
|
...obj,
|
|
352
|
+
...(obj.authorizationUrl && { authorizationUrl: SENSITIVE_STRING }),
|
|
325
353
|
...(obj.accessToken && { accessToken: SENSITIVE_STRING }),
|
|
326
354
|
});
|
|
327
355
|
export const GetWorkloadAccessTokenResponseFilterSensitiveLog = (obj) => ({
|
|
@@ -47,6 +47,20 @@ export const se_BatchUpdateMemoryRecordsCommand = async (input, context) => {
|
|
|
47
47
|
b.m("POST").h(headers).b(body);
|
|
48
48
|
return b.build();
|
|
49
49
|
};
|
|
50
|
+
export const se_CompleteResourceTokenAuthCommand = async (input, context) => {
|
|
51
|
+
const b = rb(input, context);
|
|
52
|
+
const headers = {
|
|
53
|
+
"content-type": "application/json",
|
|
54
|
+
};
|
|
55
|
+
b.bp("/identities/CompleteResourceTokenAuth");
|
|
56
|
+
let body;
|
|
57
|
+
body = JSON.stringify(take(input, {
|
|
58
|
+
sessionUri: [],
|
|
59
|
+
userIdentifier: (_) => _json(_),
|
|
60
|
+
}));
|
|
61
|
+
b.m("POST").h(headers).b(body);
|
|
62
|
+
return b.build();
|
|
63
|
+
};
|
|
50
64
|
export const se_CreateEventCommand = async (input, context) => {
|
|
51
65
|
const b = rb(input, context);
|
|
52
66
|
const headers = {
|
|
@@ -172,11 +186,13 @@ export const se_GetResourceOauth2TokenCommand = async (input, context) => {
|
|
|
172
186
|
let body;
|
|
173
187
|
body = JSON.stringify(take(input, {
|
|
174
188
|
customParameters: (_) => _json(_),
|
|
189
|
+
customState: [],
|
|
175
190
|
forceAuthentication: [],
|
|
176
191
|
oauth2Flow: [],
|
|
177
192
|
resourceCredentialProviderName: [],
|
|
178
193
|
resourceOauth2ReturnUrl: [],
|
|
179
194
|
scopes: (_) => _json(_),
|
|
195
|
+
sessionUri: [],
|
|
180
196
|
workloadIdentityToken: [],
|
|
181
197
|
}));
|
|
182
198
|
b.m("POST").h(headers).b(body);
|
|
@@ -241,6 +257,7 @@ export const se_InvokeAgentRuntimeCommand = async (input, context) => {
|
|
|
241
257
|
b.p("agentRuntimeArn", () => input.agentRuntimeArn, "{agentRuntimeArn}", false);
|
|
242
258
|
const query = map({
|
|
243
259
|
[_q]: [, input[_q]],
|
|
260
|
+
[_aI]: [, input[_aI]],
|
|
244
261
|
});
|
|
245
262
|
let body;
|
|
246
263
|
if (input.payload !== undefined) {
|
|
@@ -539,6 +556,16 @@ export const de_BatchUpdateMemoryRecordsCommand = async (output, context) => {
|
|
|
539
556
|
Object.assign(contents, doc);
|
|
540
557
|
return contents;
|
|
541
558
|
};
|
|
559
|
+
export const de_CompleteResourceTokenAuthCommand = async (output, context) => {
|
|
560
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
561
|
+
return de_CommandError(output, context);
|
|
562
|
+
}
|
|
563
|
+
const contents = map({
|
|
564
|
+
$metadata: deserializeMetadata(output),
|
|
565
|
+
});
|
|
566
|
+
await collectBody(output.body, context);
|
|
567
|
+
return contents;
|
|
568
|
+
};
|
|
542
569
|
export const de_CreateEventCommand = async (output, context) => {
|
|
543
570
|
if (output.statusCode !== 201 && output.statusCode >= 300) {
|
|
544
571
|
return de_CommandError(output, context);
|
|
@@ -692,6 +719,8 @@ export const de_GetResourceOauth2TokenCommand = async (output, context) => {
|
|
|
692
719
|
const doc = take(data, {
|
|
693
720
|
accessToken: __expectString,
|
|
694
721
|
authorizationUrl: __expectString,
|
|
722
|
+
sessionStatus: __expectString,
|
|
723
|
+
sessionUri: __expectString,
|
|
695
724
|
});
|
|
696
725
|
Object.assign(contents, doc);
|
|
697
726
|
return contents;
|
|
@@ -999,21 +1028,21 @@ const de_CommandError = async (output, context) => {
|
|
|
999
1028
|
case "ValidationException":
|
|
1000
1029
|
case "com.amazonaws.bedrockagentcore#ValidationException":
|
|
1001
1030
|
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1002
|
-
case "InvalidInputException":
|
|
1003
|
-
case "com.amazonaws.bedrockagentcore#InvalidInputException":
|
|
1004
|
-
throw await de_InvalidInputExceptionRes(parsedOutput, context);
|
|
1005
1031
|
case "InternalServerException":
|
|
1006
1032
|
case "com.amazonaws.bedrockagentcore#InternalServerException":
|
|
1007
1033
|
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1008
|
-
case "RuntimeClientError":
|
|
1009
|
-
case "com.amazonaws.bedrockagentcore#RuntimeClientError":
|
|
1010
|
-
throw await de_RuntimeClientErrorRes(parsedOutput, context);
|
|
1011
1034
|
case "ThrottlingException":
|
|
1012
1035
|
case "com.amazonaws.bedrockagentcore#ThrottlingException":
|
|
1013
1036
|
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
1014
1037
|
case "UnauthorizedException":
|
|
1015
1038
|
case "com.amazonaws.bedrockagentcore#UnauthorizedException":
|
|
1016
1039
|
throw await de_UnauthorizedExceptionRes(parsedOutput, context);
|
|
1040
|
+
case "InvalidInputException":
|
|
1041
|
+
case "com.amazonaws.bedrockagentcore#InvalidInputException":
|
|
1042
|
+
throw await de_InvalidInputExceptionRes(parsedOutput, context);
|
|
1043
|
+
case "RuntimeClientError":
|
|
1044
|
+
case "com.amazonaws.bedrockagentcore#RuntimeClientError":
|
|
1045
|
+
throw await de_RuntimeClientErrorRes(parsedOutput, context);
|
|
1017
1046
|
case "ConflictException":
|
|
1018
1047
|
case "com.amazonaws.bedrockagentcore#ConflictException":
|
|
1019
1048
|
throw await de_ConflictExceptionRes(parsedOutput, context);
|
|
@@ -1541,6 +1570,7 @@ const deserializeMetadata = (output) => ({
|
|
|
1541
1570
|
});
|
|
1542
1571
|
const collectBodyString = (streamBody, context) => collectBody(streamBody, context).then((body) => context.utf8Encoder(body));
|
|
1543
1572
|
const _a = "accept";
|
|
1573
|
+
const _aI = "accountId";
|
|
1544
1574
|
const _b = "baggage";
|
|
1545
1575
|
const _cT = "contentType";
|
|
1546
1576
|
const _ct = "content-type";
|
|
@@ -3,6 +3,7 @@ import { BedrockAgentCoreClient } from "./BedrockAgentCoreClient";
|
|
|
3
3
|
import { BatchCreateMemoryRecordsCommandInput, BatchCreateMemoryRecordsCommandOutput } from "./commands/BatchCreateMemoryRecordsCommand";
|
|
4
4
|
import { BatchDeleteMemoryRecordsCommandInput, BatchDeleteMemoryRecordsCommandOutput } from "./commands/BatchDeleteMemoryRecordsCommand";
|
|
5
5
|
import { BatchUpdateMemoryRecordsCommandInput, BatchUpdateMemoryRecordsCommandOutput } from "./commands/BatchUpdateMemoryRecordsCommand";
|
|
6
|
+
import { CompleteResourceTokenAuthCommandInput, CompleteResourceTokenAuthCommandOutput } from "./commands/CompleteResourceTokenAuthCommand";
|
|
6
7
|
import { CreateEventCommandInput, CreateEventCommandOutput } from "./commands/CreateEventCommand";
|
|
7
8
|
import { DeleteEventCommandInput, DeleteEventCommandOutput } from "./commands/DeleteEventCommand";
|
|
8
9
|
import { DeleteMemoryRecordCommandInput, DeleteMemoryRecordCommandOutput } from "./commands/DeleteMemoryRecordCommand";
|
|
@@ -50,6 +51,12 @@ export interface BedrockAgentCore {
|
|
|
50
51
|
batchUpdateMemoryRecords(args: BatchUpdateMemoryRecordsCommandInput, options?: __HttpHandlerOptions): Promise<BatchUpdateMemoryRecordsCommandOutput>;
|
|
51
52
|
batchUpdateMemoryRecords(args: BatchUpdateMemoryRecordsCommandInput, cb: (err: any, data?: BatchUpdateMemoryRecordsCommandOutput) => void): void;
|
|
52
53
|
batchUpdateMemoryRecords(args: BatchUpdateMemoryRecordsCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: BatchUpdateMemoryRecordsCommandOutput) => void): void;
|
|
54
|
+
/**
|
|
55
|
+
* @see {@link CompleteResourceTokenAuthCommand}
|
|
56
|
+
*/
|
|
57
|
+
completeResourceTokenAuth(args: CompleteResourceTokenAuthCommandInput, options?: __HttpHandlerOptions): Promise<CompleteResourceTokenAuthCommandOutput>;
|
|
58
|
+
completeResourceTokenAuth(args: CompleteResourceTokenAuthCommandInput, cb: (err: any, data?: CompleteResourceTokenAuthCommandOutput) => void): void;
|
|
59
|
+
completeResourceTokenAuth(args: CompleteResourceTokenAuthCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: CompleteResourceTokenAuthCommandOutput) => void): void;
|
|
53
60
|
/**
|
|
54
61
|
* @see {@link CreateEventCommand}
|
|
55
62
|
*/
|
|
@@ -11,6 +11,7 @@ import { HttpAuthSchemeInputConfig, HttpAuthSchemeResolvedConfig } from "./auth/
|
|
|
11
11
|
import { BatchCreateMemoryRecordsCommandInput, BatchCreateMemoryRecordsCommandOutput } from "./commands/BatchCreateMemoryRecordsCommand";
|
|
12
12
|
import { BatchDeleteMemoryRecordsCommandInput, BatchDeleteMemoryRecordsCommandOutput } from "./commands/BatchDeleteMemoryRecordsCommand";
|
|
13
13
|
import { BatchUpdateMemoryRecordsCommandInput, BatchUpdateMemoryRecordsCommandOutput } from "./commands/BatchUpdateMemoryRecordsCommand";
|
|
14
|
+
import { CompleteResourceTokenAuthCommandInput, CompleteResourceTokenAuthCommandOutput } from "./commands/CompleteResourceTokenAuthCommand";
|
|
14
15
|
import { CreateEventCommandInput, CreateEventCommandOutput } from "./commands/CreateEventCommand";
|
|
15
16
|
import { DeleteEventCommandInput, DeleteEventCommandOutput } from "./commands/DeleteEventCommand";
|
|
16
17
|
import { DeleteMemoryRecordCommandInput, DeleteMemoryRecordCommandOutput } from "./commands/DeleteMemoryRecordCommand";
|
|
@@ -45,11 +46,11 @@ export { __Client };
|
|
|
45
46
|
/**
|
|
46
47
|
* @public
|
|
47
48
|
*/
|
|
48
|
-
export type ServiceInputTypes = BatchCreateMemoryRecordsCommandInput | BatchDeleteMemoryRecordsCommandInput | BatchUpdateMemoryRecordsCommandInput | CreateEventCommandInput | DeleteEventCommandInput | DeleteMemoryRecordCommandInput | GetAgentCardCommandInput | GetBrowserSessionCommandInput | GetCodeInterpreterSessionCommandInput | GetEventCommandInput | GetMemoryRecordCommandInput | GetResourceApiKeyCommandInput | GetResourceOauth2TokenCommandInput | GetWorkloadAccessTokenCommandInput | GetWorkloadAccessTokenForJWTCommandInput | GetWorkloadAccessTokenForUserIdCommandInput | InvokeAgentRuntimeCommandInput | InvokeCodeInterpreterCommandInput | ListActorsCommandInput | ListBrowserSessionsCommandInput | ListCodeInterpreterSessionsCommandInput | ListEventsCommandInput | ListMemoryRecordsCommandInput | ListSessionsCommandInput | RetrieveMemoryRecordsCommandInput | StartBrowserSessionCommandInput | StartCodeInterpreterSessionCommandInput | StopBrowserSessionCommandInput | StopCodeInterpreterSessionCommandInput | StopRuntimeSessionCommandInput | UpdateBrowserStreamCommandInput;
|
|
49
|
+
export type ServiceInputTypes = BatchCreateMemoryRecordsCommandInput | BatchDeleteMemoryRecordsCommandInput | BatchUpdateMemoryRecordsCommandInput | CompleteResourceTokenAuthCommandInput | CreateEventCommandInput | DeleteEventCommandInput | DeleteMemoryRecordCommandInput | GetAgentCardCommandInput | GetBrowserSessionCommandInput | GetCodeInterpreterSessionCommandInput | GetEventCommandInput | GetMemoryRecordCommandInput | GetResourceApiKeyCommandInput | GetResourceOauth2TokenCommandInput | GetWorkloadAccessTokenCommandInput | GetWorkloadAccessTokenForJWTCommandInput | GetWorkloadAccessTokenForUserIdCommandInput | InvokeAgentRuntimeCommandInput | InvokeCodeInterpreterCommandInput | ListActorsCommandInput | ListBrowserSessionsCommandInput | ListCodeInterpreterSessionsCommandInput | ListEventsCommandInput | ListMemoryRecordsCommandInput | ListSessionsCommandInput | RetrieveMemoryRecordsCommandInput | StartBrowserSessionCommandInput | StartCodeInterpreterSessionCommandInput | StopBrowserSessionCommandInput | StopCodeInterpreterSessionCommandInput | StopRuntimeSessionCommandInput | UpdateBrowserStreamCommandInput;
|
|
49
50
|
/**
|
|
50
51
|
* @public
|
|
51
52
|
*/
|
|
52
|
-
export type ServiceOutputTypes = BatchCreateMemoryRecordsCommandOutput | BatchDeleteMemoryRecordsCommandOutput | BatchUpdateMemoryRecordsCommandOutput | CreateEventCommandOutput | DeleteEventCommandOutput | DeleteMemoryRecordCommandOutput | GetAgentCardCommandOutput | GetBrowserSessionCommandOutput | GetCodeInterpreterSessionCommandOutput | GetEventCommandOutput | GetMemoryRecordCommandOutput | GetResourceApiKeyCommandOutput | GetResourceOauth2TokenCommandOutput | GetWorkloadAccessTokenCommandOutput | GetWorkloadAccessTokenForJWTCommandOutput | GetWorkloadAccessTokenForUserIdCommandOutput | InvokeAgentRuntimeCommandOutput | InvokeCodeInterpreterCommandOutput | ListActorsCommandOutput | ListBrowserSessionsCommandOutput | ListCodeInterpreterSessionsCommandOutput | ListEventsCommandOutput | ListMemoryRecordsCommandOutput | ListSessionsCommandOutput | RetrieveMemoryRecordsCommandOutput | StartBrowserSessionCommandOutput | StartCodeInterpreterSessionCommandOutput | StopBrowserSessionCommandOutput | StopCodeInterpreterSessionCommandOutput | StopRuntimeSessionCommandOutput | UpdateBrowserStreamCommandOutput;
|
|
53
|
+
export type ServiceOutputTypes = BatchCreateMemoryRecordsCommandOutput | BatchDeleteMemoryRecordsCommandOutput | BatchUpdateMemoryRecordsCommandOutput | CompleteResourceTokenAuthCommandOutput | CreateEventCommandOutput | DeleteEventCommandOutput | DeleteMemoryRecordCommandOutput | GetAgentCardCommandOutput | GetBrowserSessionCommandOutput | GetCodeInterpreterSessionCommandOutput | GetEventCommandOutput | GetMemoryRecordCommandOutput | GetResourceApiKeyCommandOutput | GetResourceOauth2TokenCommandOutput | GetWorkloadAccessTokenCommandOutput | GetWorkloadAccessTokenForJWTCommandOutput | GetWorkloadAccessTokenForUserIdCommandOutput | InvokeAgentRuntimeCommandOutput | InvokeCodeInterpreterCommandOutput | ListActorsCommandOutput | ListBrowserSessionsCommandOutput | ListCodeInterpreterSessionsCommandOutput | ListEventsCommandOutput | ListMemoryRecordsCommandOutput | ListSessionsCommandOutput | RetrieveMemoryRecordsCommandOutput | StartBrowserSessionCommandOutput | StartCodeInterpreterSessionCommandOutput | StopBrowserSessionCommandOutput | StopCodeInterpreterSessionCommandOutput | StopRuntimeSessionCommandOutput | UpdateBrowserStreamCommandOutput;
|
|
53
54
|
/**
|
|
54
55
|
* @public
|
|
55
56
|
*/
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
import { Command as $Command } from "@smithy/smithy-client";
|
|
2
|
+
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
3
|
+
import { BedrockAgentCoreClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BedrockAgentCoreClient";
|
|
4
|
+
import { CompleteResourceTokenAuthRequest, CompleteResourceTokenAuthResponse } from "../models/models_0";
|
|
5
|
+
/**
|
|
6
|
+
* @public
|
|
7
|
+
*/
|
|
8
|
+
export type { __MetadataBearer };
|
|
9
|
+
export { $Command };
|
|
10
|
+
/**
|
|
11
|
+
* @public
|
|
12
|
+
*
|
|
13
|
+
* The input for {@link CompleteResourceTokenAuthCommand}.
|
|
14
|
+
*/
|
|
15
|
+
export interface CompleteResourceTokenAuthCommandInput extends CompleteResourceTokenAuthRequest {
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* @public
|
|
19
|
+
*
|
|
20
|
+
* The output of {@link CompleteResourceTokenAuthCommand}.
|
|
21
|
+
*/
|
|
22
|
+
export interface CompleteResourceTokenAuthCommandOutput extends CompleteResourceTokenAuthResponse, __MetadataBearer {
|
|
23
|
+
}
|
|
24
|
+
declare const CompleteResourceTokenAuthCommand_base: {
|
|
25
|
+
new (input: CompleteResourceTokenAuthCommandInput): import("@smithy/smithy-client").CommandImpl<CompleteResourceTokenAuthCommandInput, CompleteResourceTokenAuthCommandOutput, BedrockAgentCoreClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
|
|
26
|
+
new (input: CompleteResourceTokenAuthCommandInput): import("@smithy/smithy-client").CommandImpl<CompleteResourceTokenAuthCommandInput, CompleteResourceTokenAuthCommandOutput, BedrockAgentCoreClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
|
|
27
|
+
getEndpointParameterInstructions(): import("@smithy/middleware-endpoint").EndpointParameterInstructions;
|
|
28
|
+
};
|
|
29
|
+
/**
|
|
30
|
+
* <p>Confirms the user authentication session for obtaining OAuth2.0 tokens for a resource.</p>
|
|
31
|
+
* @example
|
|
32
|
+
* Use a bare-bones client and the command you need to make an API call.
|
|
33
|
+
* ```javascript
|
|
34
|
+
* import { BedrockAgentCoreClient, CompleteResourceTokenAuthCommand } from "@aws-sdk/client-bedrock-agentcore"; // ES Modules import
|
|
35
|
+
* // const { BedrockAgentCoreClient, CompleteResourceTokenAuthCommand } = require("@aws-sdk/client-bedrock-agentcore"); // CommonJS import
|
|
36
|
+
* // import type { BedrockAgentCoreClientConfig } from "@aws-sdk/client-bedrock-agentcore";
|
|
37
|
+
* const config = {}; // type is BedrockAgentCoreClientConfig
|
|
38
|
+
* const client = new BedrockAgentCoreClient(config);
|
|
39
|
+
* const input = { // CompleteResourceTokenAuthRequest
|
|
40
|
+
* userIdentifier: { // UserIdentifier Union: only one key present
|
|
41
|
+
* userToken: "STRING_VALUE",
|
|
42
|
+
* userId: "STRING_VALUE",
|
|
43
|
+
* },
|
|
44
|
+
* sessionUri: "STRING_VALUE", // required
|
|
45
|
+
* };
|
|
46
|
+
* const command = new CompleteResourceTokenAuthCommand(input);
|
|
47
|
+
* const response = await client.send(command);
|
|
48
|
+
* // {};
|
|
49
|
+
*
|
|
50
|
+
* ```
|
|
51
|
+
*
|
|
52
|
+
* @param CompleteResourceTokenAuthCommandInput - {@link CompleteResourceTokenAuthCommandInput}
|
|
53
|
+
* @returns {@link CompleteResourceTokenAuthCommandOutput}
|
|
54
|
+
* @see {@link CompleteResourceTokenAuthCommandInput} for command's `input` shape.
|
|
55
|
+
* @see {@link CompleteResourceTokenAuthCommandOutput} for command's `response` shape.
|
|
56
|
+
* @see {@link BedrockAgentCoreClientResolvedConfig | config} for BedrockAgentCoreClient's `config` shape.
|
|
57
|
+
*
|
|
58
|
+
* @throws {@link AccessDeniedException} (client fault)
|
|
59
|
+
* <p>The exception that occurs when you do not have sufficient permissions to perform an action. Verify that your IAM policy includes the necessary permissions for the operation you are trying to perform.</p>
|
|
60
|
+
*
|
|
61
|
+
* @throws {@link InternalServerException} (server fault)
|
|
62
|
+
* <p>The exception that occurs when the service encounters an unexpected internal error. This is a temporary condition that will resolve itself with retries. We recommend implementing exponential backoff retry logic in your application.</p>
|
|
63
|
+
*
|
|
64
|
+
* @throws {@link ResourceNotFoundException} (client fault)
|
|
65
|
+
* <p>The exception that occurs when the specified resource does not exist. This can happen when using an invalid identifier or when trying to access a resource that has been deleted.</p>
|
|
66
|
+
*
|
|
67
|
+
* @throws {@link ThrottlingException} (client fault)
|
|
68
|
+
* <p>The exception that occurs when the request was denied due to request throttling. This happens when you exceed the allowed request rate for an operation. Reduce the frequency of requests or implement exponential backoff retry logic in your application.</p>
|
|
69
|
+
*
|
|
70
|
+
* @throws {@link UnauthorizedException} (client fault)
|
|
71
|
+
* <p>This exception is thrown when the JWT bearer token is invalid or not found for OAuth bearer token based access</p>
|
|
72
|
+
*
|
|
73
|
+
* @throws {@link ValidationException} (client fault)
|
|
74
|
+
* <p>The exception that occurs when the input fails to satisfy the constraints specified by the service. Check the error message for details about which input parameter is invalid and correct your request.</p>
|
|
75
|
+
*
|
|
76
|
+
* @throws {@link BedrockAgentCoreServiceException}
|
|
77
|
+
* <p>Base exception class for all service exceptions from BedrockAgentCore service.</p>
|
|
78
|
+
*
|
|
79
|
+
*
|
|
80
|
+
* @public
|
|
81
|
+
*/
|
|
82
|
+
export declare class CompleteResourceTokenAuthCommand extends CompleteResourceTokenAuthCommand_base {
|
|
83
|
+
/** @internal type navigation helper, not in runtime. */
|
|
84
|
+
protected static __types: {
|
|
85
|
+
api: {
|
|
86
|
+
input: CompleteResourceTokenAuthRequest;
|
|
87
|
+
output: {};
|
|
88
|
+
};
|
|
89
|
+
sdk: {
|
|
90
|
+
input: CompleteResourceTokenAuthCommandInput;
|
|
91
|
+
output: CompleteResourceTokenAuthCommandOutput;
|
|
92
|
+
};
|
|
93
|
+
};
|
|
94
|
+
}
|
|
@@ -43,17 +43,21 @@ declare const GetResourceOauth2TokenCommand_base: {
|
|
|
43
43
|
* "STRING_VALUE",
|
|
44
44
|
* ],
|
|
45
45
|
* oauth2Flow: "USER_FEDERATION" || "M2M", // required
|
|
46
|
+
* sessionUri: "STRING_VALUE",
|
|
46
47
|
* resourceOauth2ReturnUrl: "STRING_VALUE",
|
|
47
48
|
* forceAuthentication: true || false,
|
|
48
49
|
* customParameters: { // CustomRequestParametersType
|
|
49
50
|
* "<keys>": "STRING_VALUE",
|
|
50
51
|
* },
|
|
52
|
+
* customState: "STRING_VALUE",
|
|
51
53
|
* };
|
|
52
54
|
* const command = new GetResourceOauth2TokenCommand(input);
|
|
53
55
|
* const response = await client.send(command);
|
|
54
56
|
* // { // GetResourceOauth2TokenResponse
|
|
55
57
|
* // authorizationUrl: "STRING_VALUE",
|
|
56
58
|
* // accessToken: "STRING_VALUE",
|
|
59
|
+
* // sessionUri: "STRING_VALUE",
|
|
60
|
+
* // sessionStatus: "IN_PROGRESS" || "FAILED",
|
|
57
61
|
* // };
|
|
58
62
|
*
|
|
59
63
|
* ```
|
|
@@ -56,6 +56,7 @@ declare const InvokeAgentRuntimeCommand_base: {
|
|
|
56
56
|
* baggage: "STRING_VALUE",
|
|
57
57
|
* agentRuntimeArn: "STRING_VALUE", // required
|
|
58
58
|
* qualifier: "STRING_VALUE",
|
|
59
|
+
* accountId: "STRING_VALUE",
|
|
59
60
|
* payload: new Uint8Array(), // e.g. Buffer.from("") or new TextEncoder().encode("") // required
|
|
60
61
|
* };
|
|
61
62
|
* const command = new InvokeAgentRuntimeCommand(input);
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
export * from "./BatchCreateMemoryRecordsCommand";
|
|
2
2
|
export * from "./BatchDeleteMemoryRecordsCommand";
|
|
3
3
|
export * from "./BatchUpdateMemoryRecordsCommand";
|
|
4
|
+
export * from "./CompleteResourceTokenAuthCommand";
|
|
4
5
|
export * from "./CreateEventCommand";
|
|
5
6
|
export * from "./DeleteEventCommand";
|
|
6
7
|
export * from "./DeleteMemoryRecordCommand";
|
|
@@ -233,6 +233,11 @@ export interface InvokeAgentRuntimeRequest {
|
|
|
233
233
|
* @public
|
|
234
234
|
*/
|
|
235
235
|
qualifier?: string | undefined;
|
|
236
|
+
/**
|
|
237
|
+
* <p>The identifier of the Amazon Web Services account for the agent runtime resource.</p>
|
|
238
|
+
* @public
|
|
239
|
+
*/
|
|
240
|
+
accountId?: string | undefined;
|
|
236
241
|
/**
|
|
237
242
|
* <p>The input data to send to the agent runtime. The format of this data depends on the specific agent configuration and must match the specified content type. For most agents, this is a JSON object containing the user's request.</p>
|
|
238
243
|
* @public
|
|
@@ -1036,6 +1041,68 @@ export interface StopCodeInterpreterSessionResponse {
|
|
|
1036
1041
|
*/
|
|
1037
1042
|
lastUpdatedAt: Date | undefined;
|
|
1038
1043
|
}
|
|
1044
|
+
/**
|
|
1045
|
+
* <p>The OAuth2.0 token or user ID that was used to generate the workload access token used for initiating the user authorization flow to retrieve OAuth2.0 tokens.</p>
|
|
1046
|
+
* @public
|
|
1047
|
+
*/
|
|
1048
|
+
export type UserIdentifier = UserIdentifier.UserIdMember | UserIdentifier.UserTokenMember | UserIdentifier.$UnknownMember;
|
|
1049
|
+
/**
|
|
1050
|
+
* @public
|
|
1051
|
+
*/
|
|
1052
|
+
export declare namespace UserIdentifier {
|
|
1053
|
+
/**
|
|
1054
|
+
* <p>The OAuth2.0 token issued by the user’s identity provider</p>
|
|
1055
|
+
* @public
|
|
1056
|
+
*/
|
|
1057
|
+
interface UserTokenMember {
|
|
1058
|
+
userToken: string;
|
|
1059
|
+
userId?: never;
|
|
1060
|
+
$unknown?: never;
|
|
1061
|
+
}
|
|
1062
|
+
/**
|
|
1063
|
+
* <p>The ID of the user for whom you have retrieved a workload access token for</p>
|
|
1064
|
+
* @public
|
|
1065
|
+
*/
|
|
1066
|
+
interface UserIdMember {
|
|
1067
|
+
userToken?: never;
|
|
1068
|
+
userId: string;
|
|
1069
|
+
$unknown?: never;
|
|
1070
|
+
}
|
|
1071
|
+
/**
|
|
1072
|
+
* @public
|
|
1073
|
+
*/
|
|
1074
|
+
interface $UnknownMember {
|
|
1075
|
+
userToken?: never;
|
|
1076
|
+
userId?: never;
|
|
1077
|
+
$unknown: [string, any];
|
|
1078
|
+
}
|
|
1079
|
+
interface Visitor<T> {
|
|
1080
|
+
userToken: (value: string) => T;
|
|
1081
|
+
userId: (value: string) => T;
|
|
1082
|
+
_: (name: string, value: any) => T;
|
|
1083
|
+
}
|
|
1084
|
+
const visit: <T>(value: UserIdentifier, visitor: Visitor<T>) => T;
|
|
1085
|
+
}
|
|
1086
|
+
/**
|
|
1087
|
+
* @public
|
|
1088
|
+
*/
|
|
1089
|
+
export interface CompleteResourceTokenAuthRequest {
|
|
1090
|
+
/**
|
|
1091
|
+
* <p>The OAuth2.0 token or user ID that was used to generate the workload access token used for initiating the user authorization flow to retrieve OAuth2.0 tokens.</p>
|
|
1092
|
+
* @public
|
|
1093
|
+
*/
|
|
1094
|
+
userIdentifier: UserIdentifier | undefined;
|
|
1095
|
+
/**
|
|
1096
|
+
* <p>Unique identifier for the user's authentication session for retrieving OAuth2 tokens. This ID tracks the authorization flow state across multiple requests and responses during the OAuth2 authentication process.</p>
|
|
1097
|
+
* @public
|
|
1098
|
+
*/
|
|
1099
|
+
sessionUri: string | undefined;
|
|
1100
|
+
}
|
|
1101
|
+
/**
|
|
1102
|
+
* @public
|
|
1103
|
+
*/
|
|
1104
|
+
export interface CompleteResourceTokenAuthResponse {
|
|
1105
|
+
}
|
|
1039
1106
|
/**
|
|
1040
1107
|
* @public
|
|
1041
1108
|
*/
|
|
@@ -1097,6 +1164,11 @@ export interface GetResourceOauth2TokenRequest {
|
|
|
1097
1164
|
* @public
|
|
1098
1165
|
*/
|
|
1099
1166
|
oauth2Flow: Oauth2FlowType | undefined;
|
|
1167
|
+
/**
|
|
1168
|
+
* <p>Unique identifier for the user's authentication session for retrieving OAuth2 tokens. This ID tracks the authorization flow state across multiple requests and responses during the OAuth2 authentication process.</p>
|
|
1169
|
+
* @public
|
|
1170
|
+
*/
|
|
1171
|
+
sessionUri?: string | undefined;
|
|
1100
1172
|
/**
|
|
1101
1173
|
* <p>The callback URL to redirect to after the OAuth 2.0 token retrieval is complete. This URL must be one of the provided URLs configured for the workload identity.</p>
|
|
1102
1174
|
* @public
|
|
@@ -1112,7 +1184,24 @@ export interface GetResourceOauth2TokenRequest {
|
|
|
1112
1184
|
* @public
|
|
1113
1185
|
*/
|
|
1114
1186
|
customParameters?: Record<string, string> | undefined;
|
|
1187
|
+
/**
|
|
1188
|
+
* <p>An opaque string that will be sent back to the callback URL provided in resourceOauth2ReturnUrl. This state should be used to protect the callback URL of your application against CSRF attacks by ensuring the response corresponds to the original request.</p>
|
|
1189
|
+
* @public
|
|
1190
|
+
*/
|
|
1191
|
+
customState?: string | undefined;
|
|
1115
1192
|
}
|
|
1193
|
+
/**
|
|
1194
|
+
* @public
|
|
1195
|
+
* @enum
|
|
1196
|
+
*/
|
|
1197
|
+
export declare const SessionStatus: {
|
|
1198
|
+
readonly FAILED: "FAILED";
|
|
1199
|
+
readonly IN_PROGRESS: "IN_PROGRESS";
|
|
1200
|
+
};
|
|
1201
|
+
/**
|
|
1202
|
+
* @public
|
|
1203
|
+
*/
|
|
1204
|
+
export type SessionStatus = (typeof SessionStatus)[keyof typeof SessionStatus];
|
|
1116
1205
|
/**
|
|
1117
1206
|
* @public
|
|
1118
1207
|
*/
|
|
@@ -1127,6 +1216,16 @@ export interface GetResourceOauth2TokenResponse {
|
|
|
1127
1216
|
* @public
|
|
1128
1217
|
*/
|
|
1129
1218
|
accessToken?: string | undefined;
|
|
1219
|
+
/**
|
|
1220
|
+
* <p>Unique identifier for the user's authorization session for retrieving OAuth2 tokens. This matches the sessionId from the request and can be used to track the session state.</p>
|
|
1221
|
+
* @public
|
|
1222
|
+
*/
|
|
1223
|
+
sessionUri?: string | undefined;
|
|
1224
|
+
/**
|
|
1225
|
+
* <p>Status indicating whether the user's authorization session is in progress or has failed. This helps determine the next steps in the OAuth2 authentication flow.</p>
|
|
1226
|
+
* @public
|
|
1227
|
+
*/
|
|
1228
|
+
sessionStatus?: SessionStatus | undefined;
|
|
1130
1229
|
}
|
|
1131
1230
|
/**
|
|
1132
1231
|
* @public
|
|
@@ -2797,6 +2896,14 @@ export declare const InvokeAgentRuntimeRequestFilterSensitiveLog: (obj: InvokeAg
|
|
|
2797
2896
|
* @internal
|
|
2798
2897
|
*/
|
|
2799
2898
|
export declare const InvokeAgentRuntimeResponseFilterSensitiveLog: (obj: InvokeAgentRuntimeResponse) => any;
|
|
2899
|
+
/**
|
|
2900
|
+
* @internal
|
|
2901
|
+
*/
|
|
2902
|
+
export declare const UserIdentifierFilterSensitiveLog: (obj: UserIdentifier) => any;
|
|
2903
|
+
/**
|
|
2904
|
+
* @internal
|
|
2905
|
+
*/
|
|
2906
|
+
export declare const CompleteResourceTokenAuthRequestFilterSensitiveLog: (obj: CompleteResourceTokenAuthRequest) => any;
|
|
2800
2907
|
/**
|
|
2801
2908
|
* @internal
|
|
2802
2909
|
*/
|
|
@@ -3,6 +3,7 @@ import { EventStreamSerdeContext as __EventStreamSerdeContext, SdkStreamSerdeCon
|
|
|
3
3
|
import { BatchCreateMemoryRecordsCommandInput, BatchCreateMemoryRecordsCommandOutput } from "../commands/BatchCreateMemoryRecordsCommand";
|
|
4
4
|
import { BatchDeleteMemoryRecordsCommandInput, BatchDeleteMemoryRecordsCommandOutput } from "../commands/BatchDeleteMemoryRecordsCommand";
|
|
5
5
|
import { BatchUpdateMemoryRecordsCommandInput, BatchUpdateMemoryRecordsCommandOutput } from "../commands/BatchUpdateMemoryRecordsCommand";
|
|
6
|
+
import { CompleteResourceTokenAuthCommandInput, CompleteResourceTokenAuthCommandOutput } from "../commands/CompleteResourceTokenAuthCommand";
|
|
6
7
|
import { CreateEventCommandInput, CreateEventCommandOutput } from "../commands/CreateEventCommand";
|
|
7
8
|
import { DeleteEventCommandInput, DeleteEventCommandOutput } from "../commands/DeleteEventCommand";
|
|
8
9
|
import { DeleteMemoryRecordCommandInput, DeleteMemoryRecordCommandOutput } from "../commands/DeleteMemoryRecordCommand";
|
|
@@ -43,6 +44,10 @@ export declare const se_BatchDeleteMemoryRecordsCommand: (input: BatchDeleteMemo
|
|
|
43
44
|
* serializeAws_restJson1BatchUpdateMemoryRecordsCommand
|
|
44
45
|
*/
|
|
45
46
|
export declare const se_BatchUpdateMemoryRecordsCommand: (input: BatchUpdateMemoryRecordsCommandInput, context: __SerdeContext) => Promise<__HttpRequest>;
|
|
47
|
+
/**
|
|
48
|
+
* serializeAws_restJson1CompleteResourceTokenAuthCommand
|
|
49
|
+
*/
|
|
50
|
+
export declare const se_CompleteResourceTokenAuthCommand: (input: CompleteResourceTokenAuthCommandInput, context: __SerdeContext) => Promise<__HttpRequest>;
|
|
46
51
|
/**
|
|
47
52
|
* serializeAws_restJson1CreateEventCommand
|
|
48
53
|
*/
|
|
@@ -167,6 +172,10 @@ export declare const de_BatchDeleteMemoryRecordsCommand: (output: __HttpResponse
|
|
|
167
172
|
* deserializeAws_restJson1BatchUpdateMemoryRecordsCommand
|
|
168
173
|
*/
|
|
169
174
|
export declare const de_BatchUpdateMemoryRecordsCommand: (output: __HttpResponse, context: __SerdeContext) => Promise<BatchUpdateMemoryRecordsCommandOutput>;
|
|
175
|
+
/**
|
|
176
|
+
* deserializeAws_restJson1CompleteResourceTokenAuthCommand
|
|
177
|
+
*/
|
|
178
|
+
export declare const de_CompleteResourceTokenAuthCommand: (output: __HttpResponse, context: __SerdeContext) => Promise<CompleteResourceTokenAuthCommandOutput>;
|
|
170
179
|
/**
|
|
171
180
|
* deserializeAws_restJson1CreateEventCommand
|
|
172
181
|
*/
|
|
@@ -12,6 +12,10 @@ import {
|
|
|
12
12
|
BatchUpdateMemoryRecordsCommandInput,
|
|
13
13
|
BatchUpdateMemoryRecordsCommandOutput,
|
|
14
14
|
} from "./commands/BatchUpdateMemoryRecordsCommand";
|
|
15
|
+
import {
|
|
16
|
+
CompleteResourceTokenAuthCommandInput,
|
|
17
|
+
CompleteResourceTokenAuthCommandOutput,
|
|
18
|
+
} from "./commands/CompleteResourceTokenAuthCommand";
|
|
15
19
|
import {
|
|
16
20
|
CreateEventCommandInput,
|
|
17
21
|
CreateEventCommandOutput,
|
|
@@ -164,6 +168,19 @@ export interface BedrockAgentCore {
|
|
|
164
168
|
options: __HttpHandlerOptions,
|
|
165
169
|
cb: (err: any, data?: BatchUpdateMemoryRecordsCommandOutput) => void
|
|
166
170
|
): void;
|
|
171
|
+
completeResourceTokenAuth(
|
|
172
|
+
args: CompleteResourceTokenAuthCommandInput,
|
|
173
|
+
options?: __HttpHandlerOptions
|
|
174
|
+
): Promise<CompleteResourceTokenAuthCommandOutput>;
|
|
175
|
+
completeResourceTokenAuth(
|
|
176
|
+
args: CompleteResourceTokenAuthCommandInput,
|
|
177
|
+
cb: (err: any, data?: CompleteResourceTokenAuthCommandOutput) => void
|
|
178
|
+
): void;
|
|
179
|
+
completeResourceTokenAuth(
|
|
180
|
+
args: CompleteResourceTokenAuthCommandInput,
|
|
181
|
+
options: __HttpHandlerOptions,
|
|
182
|
+
cb: (err: any, data?: CompleteResourceTokenAuthCommandOutput) => void
|
|
183
|
+
): void;
|
|
167
184
|
createEvent(
|
|
168
185
|
args: CreateEventCommandInput,
|
|
169
186
|
options?: __HttpHandlerOptions
|
|
@@ -63,6 +63,10 @@ import {
|
|
|
63
63
|
BatchUpdateMemoryRecordsCommandInput,
|
|
64
64
|
BatchUpdateMemoryRecordsCommandOutput,
|
|
65
65
|
} from "./commands/BatchUpdateMemoryRecordsCommand";
|
|
66
|
+
import {
|
|
67
|
+
CompleteResourceTokenAuthCommandInput,
|
|
68
|
+
CompleteResourceTokenAuthCommandOutput,
|
|
69
|
+
} from "./commands/CompleteResourceTokenAuthCommand";
|
|
66
70
|
import {
|
|
67
71
|
CreateEventCommandInput,
|
|
68
72
|
CreateEventCommandOutput,
|
|
@@ -186,6 +190,7 @@ export type ServiceInputTypes =
|
|
|
186
190
|
| BatchCreateMemoryRecordsCommandInput
|
|
187
191
|
| BatchDeleteMemoryRecordsCommandInput
|
|
188
192
|
| BatchUpdateMemoryRecordsCommandInput
|
|
193
|
+
| CompleteResourceTokenAuthCommandInput
|
|
189
194
|
| CreateEventCommandInput
|
|
190
195
|
| DeleteEventCommandInput
|
|
191
196
|
| DeleteMemoryRecordCommandInput
|
|
@@ -218,6 +223,7 @@ export type ServiceOutputTypes =
|
|
|
218
223
|
| BatchCreateMemoryRecordsCommandOutput
|
|
219
224
|
| BatchDeleteMemoryRecordsCommandOutput
|
|
220
225
|
| BatchUpdateMemoryRecordsCommandOutput
|
|
226
|
+
| CompleteResourceTokenAuthCommandOutput
|
|
221
227
|
| CreateEventCommandOutput
|
|
222
228
|
| DeleteEventCommandOutput
|
|
223
229
|
| DeleteMemoryRecordCommandOutput
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { Command as $Command } from "@smithy/smithy-client";
|
|
2
|
+
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
3
|
+
import {
|
|
4
|
+
BedrockAgentCoreClientResolvedConfig,
|
|
5
|
+
ServiceInputTypes,
|
|
6
|
+
ServiceOutputTypes,
|
|
7
|
+
} from "../BedrockAgentCoreClient";
|
|
8
|
+
import {
|
|
9
|
+
CompleteResourceTokenAuthRequest,
|
|
10
|
+
CompleteResourceTokenAuthResponse,
|
|
11
|
+
} from "../models/models_0";
|
|
12
|
+
export { __MetadataBearer };
|
|
13
|
+
export { $Command };
|
|
14
|
+
export interface CompleteResourceTokenAuthCommandInput
|
|
15
|
+
extends CompleteResourceTokenAuthRequest {}
|
|
16
|
+
export interface CompleteResourceTokenAuthCommandOutput
|
|
17
|
+
extends CompleteResourceTokenAuthResponse,
|
|
18
|
+
__MetadataBearer {}
|
|
19
|
+
declare const CompleteResourceTokenAuthCommand_base: {
|
|
20
|
+
new (
|
|
21
|
+
input: CompleteResourceTokenAuthCommandInput
|
|
22
|
+
): import("@smithy/smithy-client").CommandImpl<
|
|
23
|
+
CompleteResourceTokenAuthCommandInput,
|
|
24
|
+
CompleteResourceTokenAuthCommandOutput,
|
|
25
|
+
BedrockAgentCoreClientResolvedConfig,
|
|
26
|
+
ServiceInputTypes,
|
|
27
|
+
ServiceOutputTypes
|
|
28
|
+
>;
|
|
29
|
+
new (
|
|
30
|
+
input: CompleteResourceTokenAuthCommandInput
|
|
31
|
+
): import("@smithy/smithy-client").CommandImpl<
|
|
32
|
+
CompleteResourceTokenAuthCommandInput,
|
|
33
|
+
CompleteResourceTokenAuthCommandOutput,
|
|
34
|
+
BedrockAgentCoreClientResolvedConfig,
|
|
35
|
+
ServiceInputTypes,
|
|
36
|
+
ServiceOutputTypes
|
|
37
|
+
>;
|
|
38
|
+
getEndpointParameterInstructions(): import("@smithy/middleware-endpoint").EndpointParameterInstructions;
|
|
39
|
+
};
|
|
40
|
+
export declare class CompleteResourceTokenAuthCommand extends CompleteResourceTokenAuthCommand_base {
|
|
41
|
+
protected static __types: {
|
|
42
|
+
api: {
|
|
43
|
+
input: CompleteResourceTokenAuthRequest;
|
|
44
|
+
output: {};
|
|
45
|
+
};
|
|
46
|
+
sdk: {
|
|
47
|
+
input: CompleteResourceTokenAuthCommandInput;
|
|
48
|
+
output: CompleteResourceTokenAuthCommandOutput;
|
|
49
|
+
};
|
|
50
|
+
};
|
|
51
|
+
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
export * from "./BatchCreateMemoryRecordsCommand";
|
|
2
2
|
export * from "./BatchDeleteMemoryRecordsCommand";
|
|
3
3
|
export * from "./BatchUpdateMemoryRecordsCommand";
|
|
4
|
+
export * from "./CompleteResourceTokenAuthCommand";
|
|
4
5
|
export * from "./CreateEventCommand";
|
|
5
6
|
export * from "./DeleteEventCommand";
|
|
6
7
|
export * from "./DeleteMemoryRecordCommand";
|
|
@@ -92,6 +92,7 @@ export interface InvokeAgentRuntimeRequest {
|
|
|
92
92
|
baggage?: string | undefined;
|
|
93
93
|
agentRuntimeArn: string | undefined;
|
|
94
94
|
qualifier?: string | undefined;
|
|
95
|
+
accountId?: string | undefined;
|
|
95
96
|
payload: Uint8Array | undefined;
|
|
96
97
|
}
|
|
97
98
|
export interface InvokeAgentRuntimeResponse {
|
|
@@ -310,6 +311,38 @@ export interface StopCodeInterpreterSessionResponse {
|
|
|
310
311
|
sessionId: string | undefined;
|
|
311
312
|
lastUpdatedAt: Date | undefined;
|
|
312
313
|
}
|
|
314
|
+
export type UserIdentifier =
|
|
315
|
+
| UserIdentifier.UserIdMember
|
|
316
|
+
| UserIdentifier.UserTokenMember
|
|
317
|
+
| UserIdentifier.$UnknownMember;
|
|
318
|
+
export declare namespace UserIdentifier {
|
|
319
|
+
interface UserTokenMember {
|
|
320
|
+
userToken: string;
|
|
321
|
+
userId?: never;
|
|
322
|
+
$unknown?: never;
|
|
323
|
+
}
|
|
324
|
+
interface UserIdMember {
|
|
325
|
+
userToken?: never;
|
|
326
|
+
userId: string;
|
|
327
|
+
$unknown?: never;
|
|
328
|
+
}
|
|
329
|
+
interface $UnknownMember {
|
|
330
|
+
userToken?: never;
|
|
331
|
+
userId?: never;
|
|
332
|
+
$unknown: [string, any];
|
|
333
|
+
}
|
|
334
|
+
interface Visitor<T> {
|
|
335
|
+
userToken: (value: string) => T;
|
|
336
|
+
userId: (value: string) => T;
|
|
337
|
+
_: (name: string, value: any) => T;
|
|
338
|
+
}
|
|
339
|
+
const visit: <T>(value: UserIdentifier, visitor: Visitor<T>) => T;
|
|
340
|
+
}
|
|
341
|
+
export interface CompleteResourceTokenAuthRequest {
|
|
342
|
+
userIdentifier: UserIdentifier | undefined;
|
|
343
|
+
sessionUri: string | undefined;
|
|
344
|
+
}
|
|
345
|
+
export interface CompleteResourceTokenAuthResponse {}
|
|
313
346
|
export interface GetResourceApiKeyRequest {
|
|
314
347
|
workloadIdentityToken: string | undefined;
|
|
315
348
|
resourceCredentialProviderName: string | undefined;
|
|
@@ -328,13 +361,22 @@ export interface GetResourceOauth2TokenRequest {
|
|
|
328
361
|
resourceCredentialProviderName: string | undefined;
|
|
329
362
|
scopes: string[] | undefined;
|
|
330
363
|
oauth2Flow: Oauth2FlowType | undefined;
|
|
364
|
+
sessionUri?: string | undefined;
|
|
331
365
|
resourceOauth2ReturnUrl?: string | undefined;
|
|
332
366
|
forceAuthentication?: boolean | undefined;
|
|
333
367
|
customParameters?: Record<string, string> | undefined;
|
|
368
|
+
customState?: string | undefined;
|
|
334
369
|
}
|
|
370
|
+
export declare const SessionStatus: {
|
|
371
|
+
readonly FAILED: "FAILED";
|
|
372
|
+
readonly IN_PROGRESS: "IN_PROGRESS";
|
|
373
|
+
};
|
|
374
|
+
export type SessionStatus = (typeof SessionStatus)[keyof typeof SessionStatus];
|
|
335
375
|
export interface GetResourceOauth2TokenResponse {
|
|
336
376
|
authorizationUrl?: string | undefined;
|
|
337
377
|
accessToken?: string | undefined;
|
|
378
|
+
sessionUri?: string | undefined;
|
|
379
|
+
sessionStatus?: SessionStatus | undefined;
|
|
338
380
|
}
|
|
339
381
|
export interface GetWorkloadAccessTokenRequest {
|
|
340
382
|
workloadName: string | undefined;
|
|
@@ -943,6 +985,12 @@ export declare const InvokeAgentRuntimeRequestFilterSensitiveLog: (
|
|
|
943
985
|
export declare const InvokeAgentRuntimeResponseFilterSensitiveLog: (
|
|
944
986
|
obj: InvokeAgentRuntimeResponse
|
|
945
987
|
) => any;
|
|
988
|
+
export declare const UserIdentifierFilterSensitiveLog: (
|
|
989
|
+
obj: UserIdentifier
|
|
990
|
+
) => any;
|
|
991
|
+
export declare const CompleteResourceTokenAuthRequestFilterSensitiveLog: (
|
|
992
|
+
obj: CompleteResourceTokenAuthRequest
|
|
993
|
+
) => any;
|
|
946
994
|
export declare const GetResourceApiKeyRequestFilterSensitiveLog: (
|
|
947
995
|
obj: GetResourceApiKeyRequest
|
|
948
996
|
) => any;
|
|
@@ -19,6 +19,10 @@ import {
|
|
|
19
19
|
BatchUpdateMemoryRecordsCommandInput,
|
|
20
20
|
BatchUpdateMemoryRecordsCommandOutput,
|
|
21
21
|
} from "../commands/BatchUpdateMemoryRecordsCommand";
|
|
22
|
+
import {
|
|
23
|
+
CompleteResourceTokenAuthCommandInput,
|
|
24
|
+
CompleteResourceTokenAuthCommandOutput,
|
|
25
|
+
} from "../commands/CompleteResourceTokenAuthCommand";
|
|
22
26
|
import {
|
|
23
27
|
CreateEventCommandInput,
|
|
24
28
|
CreateEventCommandOutput,
|
|
@@ -143,6 +147,10 @@ export declare const se_BatchUpdateMemoryRecordsCommand: (
|
|
|
143
147
|
input: BatchUpdateMemoryRecordsCommandInput,
|
|
144
148
|
context: __SerdeContext
|
|
145
149
|
) => Promise<__HttpRequest>;
|
|
150
|
+
export declare const se_CompleteResourceTokenAuthCommand: (
|
|
151
|
+
input: CompleteResourceTokenAuthCommandInput,
|
|
152
|
+
context: __SerdeContext
|
|
153
|
+
) => Promise<__HttpRequest>;
|
|
146
154
|
export declare const se_CreateEventCommand: (
|
|
147
155
|
input: CreateEventCommandInput,
|
|
148
156
|
context: __SerdeContext
|
|
@@ -267,6 +275,10 @@ export declare const de_BatchUpdateMemoryRecordsCommand: (
|
|
|
267
275
|
output: __HttpResponse,
|
|
268
276
|
context: __SerdeContext
|
|
269
277
|
) => Promise<BatchUpdateMemoryRecordsCommandOutput>;
|
|
278
|
+
export declare const de_CompleteResourceTokenAuthCommand: (
|
|
279
|
+
output: __HttpResponse,
|
|
280
|
+
context: __SerdeContext
|
|
281
|
+
) => Promise<CompleteResourceTokenAuthCommandOutput>;
|
|
270
282
|
export declare const de_CreateEventCommand: (
|
|
271
283
|
output: __HttpResponse,
|
|
272
284
|
context: __SerdeContext
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aws-sdk/client-bedrock-agentcore",
|
|
3
3
|
"description": "AWS SDK for JavaScript Bedrock Agentcore Client for Node.js, Browser and React Native",
|
|
4
|
-
"version": "3.
|
|
4
|
+
"version": "3.909.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-agentcore",
|