@aws-sdk/client-bedrock-runtime 3.941.0 → 3.946.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 +123 -335
- package/dist-cjs/runtimeConfig.browser.js +2 -2
- package/dist-cjs/runtimeConfig.js +8 -5
- package/dist-cjs/runtimeConfig.native.js +3 -1
- package/dist-es/BedrockRuntimeClient.js +3 -3
- package/dist-es/models/enums.js +19 -0
- package/dist-es/runtimeConfig.browser.js +2 -2
- package/dist-es/runtimeConfig.js +7 -4
- package/dist-es/runtimeConfig.native.js +3 -1
- package/dist-es/schemas/schemas_0.js +103 -335
- package/dist-types/BedrockRuntime.d.ts +1 -1
- package/dist-types/BedrockRuntimeClient.d.ts +13 -13
- package/dist-types/auth/httpAuthExtensionConfiguration.d.ts +2 -2
- package/dist-types/auth/httpAuthSchemeProvider.d.ts +2 -2
- package/dist-types/commands/ApplyGuardrailCommand.d.ts +3 -3
- package/dist-types/commands/ConverseCommand.d.ts +44 -12
- package/dist-types/commands/ConverseStreamCommand.d.ts +40 -8
- package/dist-types/commands/CountTokensCommand.d.ts +23 -7
- package/dist-types/commands/GetAsyncInvokeCommand.d.ts +3 -3
- package/dist-types/commands/InvokeModelCommand.d.ts +2 -2
- package/dist-types/commands/InvokeModelWithBidirectionalStreamCommand.d.ts +3 -3
- package/dist-types/commands/InvokeModelWithResponseStreamCommand.d.ts +3 -3
- package/dist-types/commands/ListAsyncInvokesCommand.d.ts +3 -3
- package/dist-types/commands/StartAsyncInvokeCommand.d.ts +3 -3
- package/dist-types/endpoint/EndpointParameters.d.ts +13 -1
- package/dist-types/endpoint/endpointResolver.d.ts +5 -2
- package/dist-types/extensionConfiguration.d.ts +4 -4
- package/dist-types/models/BedrockRuntimeServiceException.d.ts +1 -1
- package/dist-types/models/enums.d.ts +27 -0
- package/dist-types/models/errors.d.ts +1 -1
- package/dist-types/models/models_0.d.ts +208 -21
- package/dist-types/pagination/Interfaces.d.ts +1 -1
- package/dist-types/pagination/ListAsyncInvokesPaginator.d.ts +1 -1
- package/dist-types/runtimeConfig.browser.d.ts +1 -1
- package/dist-types/runtimeConfig.d.ts +2 -2
- package/dist-types/runtimeConfig.native.d.ts +1 -1
- package/dist-types/runtimeConfig.shared.d.ts +2 -2
- package/dist-types/runtimeExtensions.d.ts +1 -1
- package/dist-types/schemas/schemas_0.d.ts +6 -1
- package/dist-types/ts3.4/BedrockRuntimeClient.d.ts +3 -3
- package/dist-types/ts3.4/auth/httpAuthExtensionConfiguration.d.ts +1 -1
- package/dist-types/ts3.4/auth/httpAuthSchemeProvider.d.ts +1 -1
- package/dist-types/ts3.4/commands/InvokeModelWithResponseStreamCommand.d.ts +1 -1
- package/dist-types/ts3.4/models/BedrockRuntimeServiceException.d.ts +1 -1
- package/dist-types/ts3.4/models/enums.d.ts +20 -0
- package/dist-types/ts3.4/models/models_0.d.ts +113 -4
- package/dist-types/ts3.4/schemas/schemas_0.d.ts +5 -0
- package/package.json +14 -13
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { HttpHandlerOptions as __HttpHandlerOptions } from "@smithy/types";
|
|
1
|
+
import type { HttpHandlerOptions as __HttpHandlerOptions } from "@smithy/types";
|
|
2
2
|
import { BedrockRuntimeClient } from "./BedrockRuntimeClient";
|
|
3
3
|
import { ApplyGuardrailCommandInput, ApplyGuardrailCommandOutput } from "./commands/ApplyGuardrailCommand";
|
|
4
4
|
import { ConverseCommandInput, ConverseCommandOutput } from "./commands/ConverseCommand";
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { EventStreamInputConfig, EventStreamResolvedConfig } from "@aws-sdk/middleware-eventstream";
|
|
2
|
-
import { HostHeaderInputConfig, HostHeaderResolvedConfig } from "@aws-sdk/middleware-host-header";
|
|
3
|
-
import { UserAgentInputConfig, UserAgentResolvedConfig } from "@aws-sdk/middleware-user-agent";
|
|
4
|
-
import { WebSocketInputConfig, WebSocketResolvedConfig } from "@aws-sdk/middleware-websocket";
|
|
1
|
+
import { type EventStreamInputConfig, type EventStreamResolvedConfig } from "@aws-sdk/middleware-eventstream";
|
|
2
|
+
import { type HostHeaderInputConfig, type HostHeaderResolvedConfig } from "@aws-sdk/middleware-host-header";
|
|
3
|
+
import { type UserAgentInputConfig, type UserAgentResolvedConfig } from "@aws-sdk/middleware-user-agent";
|
|
4
|
+
import { type WebSocketInputConfig, type WebSocketResolvedConfig } from "@aws-sdk/middleware-websocket";
|
|
5
5
|
import { EventStreamPayloadHandlerProvider as __EventStreamPayloadHandlerProvider } from "@aws-sdk/types";
|
|
6
|
-
import { RegionInputConfig, RegionResolvedConfig } from "@smithy/config-resolver";
|
|
7
|
-
import { EventStreamSerdeInputConfig, EventStreamSerdeResolvedConfig } from "@smithy/eventstream-serde-config-resolver";
|
|
8
|
-
import { EndpointInputConfig, EndpointResolvedConfig } from "@smithy/middleware-endpoint";
|
|
9
|
-
import { RetryInputConfig, RetryResolvedConfig } from "@smithy/middleware-retry";
|
|
10
|
-
import { HttpHandlerUserInput as __HttpHandlerUserInput } from "@smithy/protocol-http";
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import { HttpAuthSchemeInputConfig, HttpAuthSchemeResolvedConfig } from "./auth/httpAuthSchemeProvider";
|
|
6
|
+
import { type RegionInputConfig, type RegionResolvedConfig } from "@smithy/config-resolver";
|
|
7
|
+
import { type EventStreamSerdeInputConfig, type EventStreamSerdeResolvedConfig } from "@smithy/eventstream-serde-config-resolver";
|
|
8
|
+
import { type EndpointInputConfig, type EndpointResolvedConfig } from "@smithy/middleware-endpoint";
|
|
9
|
+
import { type RetryInputConfig, type RetryResolvedConfig } from "@smithy/middleware-retry";
|
|
10
|
+
import type { HttpHandlerUserInput as __HttpHandlerUserInput } from "@smithy/protocol-http";
|
|
11
|
+
import { type DefaultsMode as __DefaultsMode, type SmithyConfiguration as __SmithyConfiguration, type SmithyResolvedConfiguration as __SmithyResolvedConfiguration, Client as __Client } from "@smithy/smithy-client";
|
|
12
|
+
import { type BodyLengthCalculator as __BodyLengthCalculator, type CheckOptionalClientConfig as __CheckOptionalClientConfig, type ChecksumConstructor as __ChecksumConstructor, type ClientProtocol, type Decoder as __Decoder, type Encoder as __Encoder, type EventStreamSerdeProvider as __EventStreamSerdeProvider, type HashConstructor as __HashConstructor, type HttpHandlerOptions as __HttpHandlerOptions, type HttpRequest, type HttpResponse, type Logger as __Logger, type Provider as __Provider, type StreamCollector as __StreamCollector, type UrlParser as __UrlParser, AwsCredentialIdentityProvider, Provider, UserAgent as __UserAgent } from "@smithy/types";
|
|
13
|
+
import { type HttpAuthSchemeInputConfig, type HttpAuthSchemeResolvedConfig } from "./auth/httpAuthSchemeProvider";
|
|
14
14
|
import { ApplyGuardrailCommandInput, ApplyGuardrailCommandOutput } from "./commands/ApplyGuardrailCommand";
|
|
15
15
|
import { ConverseCommandInput, ConverseCommandOutput } from "./commands/ConverseCommand";
|
|
16
16
|
import { ConverseStreamCommandInput, ConverseStreamCommandOutput } from "./commands/ConverseStreamCommand";
|
|
@@ -22,7 +22,7 @@ import { InvokeModelWithResponseStreamCommandInput, InvokeModelWithResponseStrea
|
|
|
22
22
|
import { ListAsyncInvokesCommandInput, ListAsyncInvokesCommandOutput } from "./commands/ListAsyncInvokesCommand";
|
|
23
23
|
import { StartAsyncInvokeCommandInput, StartAsyncInvokeCommandOutput } from "./commands/StartAsyncInvokeCommand";
|
|
24
24
|
import { ClientInputEndpointParameters, ClientResolvedEndpointParameters, EndpointParameters } from "./endpoint/EndpointParameters";
|
|
25
|
-
import { RuntimeExtension, RuntimeExtensionsConfig } from "./runtimeExtensions";
|
|
25
|
+
import { type RuntimeExtension, type RuntimeExtensionsConfig } from "./runtimeExtensions";
|
|
26
26
|
export { __Client };
|
|
27
27
|
/**
|
|
28
28
|
* @public
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { AwsCredentialIdentity, AwsCredentialIdentityProvider,
|
|
2
|
-
import { BedrockRuntimeHttpAuthSchemeProvider } from "./httpAuthSchemeProvider";
|
|
1
|
+
import { type HttpAuthScheme, AwsCredentialIdentity, AwsCredentialIdentityProvider, TokenIdentity, TokenIdentityProvider } from "@smithy/types";
|
|
2
|
+
import type { BedrockRuntimeHttpAuthSchemeProvider } from "./httpAuthSchemeProvider";
|
|
3
3
|
/**
|
|
4
4
|
* @internal
|
|
5
5
|
*/
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { AwsSdkSigV4AuthInputConfig, AwsSdkSigV4AuthResolvedConfig, AwsSdkSigV4PreviouslyResolved } from "@aws-sdk/core";
|
|
2
|
-
import {
|
|
3
|
-
import { BedrockRuntimeClientResolvedConfig } from "../BedrockRuntimeClient";
|
|
2
|
+
import { type HttpAuthScheme, type HttpAuthSchemeParameters, type HttpAuthSchemeParametersProvider, type HttpAuthSchemeProvider, type Provider, HandlerExecutionContext, TokenIdentity, TokenIdentityProvider } from "@smithy/types";
|
|
3
|
+
import { type BedrockRuntimeClientResolvedConfig } from "../BedrockRuntimeClient";
|
|
4
4
|
/**
|
|
5
5
|
* @internal
|
|
6
6
|
*/
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Command as $Command } from "@smithy/smithy-client";
|
|
2
|
-
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
3
|
-
import { BedrockRuntimeClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BedrockRuntimeClient";
|
|
4
|
-
import { ApplyGuardrailRequest, ApplyGuardrailResponse } from "../models/models_0";
|
|
2
|
+
import type { MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
3
|
+
import type { BedrockRuntimeClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BedrockRuntimeClient";
|
|
4
|
+
import type { ApplyGuardrailRequest, ApplyGuardrailResponse } from "../models/models_0";
|
|
5
5
|
/**
|
|
6
6
|
* @public
|
|
7
7
|
*/
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Command as $Command } from "@smithy/smithy-client";
|
|
2
|
-
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
3
|
-
import { BedrockRuntimeClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BedrockRuntimeClient";
|
|
4
|
-
import { ConverseRequest, ConverseResponse } from "../models/models_0";
|
|
2
|
+
import type { MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
3
|
+
import type { BedrockRuntimeClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BedrockRuntimeClient";
|
|
4
|
+
import type { ConverseRequest, ConverseResponse } from "../models/models_0";
|
|
5
5
|
/**
|
|
6
6
|
* @public
|
|
7
7
|
*/
|
|
@@ -53,6 +53,9 @@ declare const ConverseCommand_base: {
|
|
|
53
53
|
* bucketOwner: "STRING_VALUE",
|
|
54
54
|
* },
|
|
55
55
|
* },
|
|
56
|
+
* error: { // ErrorBlock
|
|
57
|
+
* message: "STRING_VALUE",
|
|
58
|
+
* },
|
|
56
59
|
* },
|
|
57
60
|
* document: { // DocumentBlock
|
|
58
61
|
* format: "pdf" || "csv" || "doc" || "docx" || "xls" || "xlsx" || "html" || "txt" || "md",
|
|
@@ -85,6 +88,19 @@ declare const ConverseCommand_base: {
|
|
|
85
88
|
* },
|
|
86
89
|
* },
|
|
87
90
|
* },
|
|
91
|
+
* audio: { // AudioBlock
|
|
92
|
+
* format: "mp3" || "opus" || "wav" || "aac" || "flac" || "mp4" || "ogg" || "mkv" || "mka" || "x-aac" || "m4a" || "mpeg" || "mpga" || "pcm" || "webm", // required
|
|
93
|
+
* source: { // AudioSource Union: only one key present
|
|
94
|
+
* bytes: new Uint8Array(), // e.g. Buffer.from("") or new TextEncoder().encode("")
|
|
95
|
+
* s3Location: {
|
|
96
|
+
* uri: "STRING_VALUE", // required
|
|
97
|
+
* bucketOwner: "STRING_VALUE",
|
|
98
|
+
* },
|
|
99
|
+
* },
|
|
100
|
+
* error: {
|
|
101
|
+
* message: "STRING_VALUE",
|
|
102
|
+
* },
|
|
103
|
+
* },
|
|
88
104
|
* toolUse: { // ToolUseBlock
|
|
89
105
|
* toolUseId: "STRING_VALUE", // required
|
|
90
106
|
* name: "STRING_VALUE", // required
|
|
@@ -106,16 +122,16 @@ declare const ConverseCommand_base: {
|
|
|
106
122
|
* bucketOwner: "STRING_VALUE",
|
|
107
123
|
* },
|
|
108
124
|
* },
|
|
125
|
+
* error: {
|
|
126
|
+
* message: "STRING_VALUE",
|
|
127
|
+
* },
|
|
109
128
|
* },
|
|
110
129
|
* document: {
|
|
111
130
|
* format: "pdf" || "csv" || "doc" || "docx" || "xls" || "xlsx" || "html" || "txt" || "md",
|
|
112
131
|
* name: "STRING_VALUE", // required
|
|
113
132
|
* source: {// Union: only one key present
|
|
114
133
|
* bytes: new Uint8Array(), // e.g. Buffer.from("") or new TextEncoder().encode("")
|
|
115
|
-
* s3Location:
|
|
116
|
-
* uri: "STRING_VALUE", // required
|
|
117
|
-
* bucketOwner: "STRING_VALUE",
|
|
118
|
-
* },
|
|
134
|
+
* s3Location: "<S3Location>",
|
|
119
135
|
* text: "STRING_VALUE",
|
|
120
136
|
* content: [
|
|
121
137
|
* {// Union: only one key present
|
|
@@ -332,6 +348,9 @@ declare const ConverseCommand_base: {
|
|
|
332
348
|
* // bucketOwner: "STRING_VALUE",
|
|
333
349
|
* // },
|
|
334
350
|
* // },
|
|
351
|
+
* // error: { // ErrorBlock
|
|
352
|
+
* // message: "STRING_VALUE",
|
|
353
|
+
* // },
|
|
335
354
|
* // },
|
|
336
355
|
* // document: { // DocumentBlock
|
|
337
356
|
* // format: "pdf" || "csv" || "doc" || "docx" || "xls" || "xlsx" || "html" || "txt" || "md",
|
|
@@ -364,6 +383,19 @@ declare const ConverseCommand_base: {
|
|
|
364
383
|
* // },
|
|
365
384
|
* // },
|
|
366
385
|
* // },
|
|
386
|
+
* // audio: { // AudioBlock
|
|
387
|
+
* // format: "mp3" || "opus" || "wav" || "aac" || "flac" || "mp4" || "ogg" || "mkv" || "mka" || "x-aac" || "m4a" || "mpeg" || "mpga" || "pcm" || "webm", // required
|
|
388
|
+
* // source: { // AudioSource Union: only one key present
|
|
389
|
+
* // bytes: new Uint8Array(),
|
|
390
|
+
* // s3Location: {
|
|
391
|
+
* // uri: "STRING_VALUE", // required
|
|
392
|
+
* // bucketOwner: "STRING_VALUE",
|
|
393
|
+
* // },
|
|
394
|
+
* // },
|
|
395
|
+
* // error: {
|
|
396
|
+
* // message: "STRING_VALUE",
|
|
397
|
+
* // },
|
|
398
|
+
* // },
|
|
367
399
|
* // toolUse: { // ToolUseBlock
|
|
368
400
|
* // toolUseId: "STRING_VALUE", // required
|
|
369
401
|
* // name: "STRING_VALUE", // required
|
|
@@ -385,16 +417,16 @@ declare const ConverseCommand_base: {
|
|
|
385
417
|
* // bucketOwner: "STRING_VALUE",
|
|
386
418
|
* // },
|
|
387
419
|
* // },
|
|
420
|
+
* // error: {
|
|
421
|
+
* // message: "STRING_VALUE",
|
|
422
|
+
* // },
|
|
388
423
|
* // },
|
|
389
424
|
* // document: {
|
|
390
425
|
* // format: "pdf" || "csv" || "doc" || "docx" || "xls" || "xlsx" || "html" || "txt" || "md",
|
|
391
426
|
* // name: "STRING_VALUE", // required
|
|
392
427
|
* // source: {// Union: only one key present
|
|
393
428
|
* // bytes: new Uint8Array(),
|
|
394
|
-
* // s3Location:
|
|
395
|
-
* // uri: "STRING_VALUE", // required
|
|
396
|
-
* // bucketOwner: "STRING_VALUE",
|
|
397
|
-
* // },
|
|
429
|
+
* // s3Location: "<S3Location>",
|
|
398
430
|
* // text: "STRING_VALUE",
|
|
399
431
|
* // content: [
|
|
400
432
|
* // {// Union: only one key present
|
|
@@ -515,7 +547,7 @@ declare const ConverseCommand_base: {
|
|
|
515
547
|
* // ],
|
|
516
548
|
* // },
|
|
517
549
|
* // },
|
|
518
|
-
* // stopReason: "end_turn" || "tool_use" || "max_tokens" || "stop_sequence" || "guardrail_intervened" || "content_filtered" || "model_context_window_exceeded", // required
|
|
550
|
+
* // stopReason: "end_turn" || "tool_use" || "max_tokens" || "stop_sequence" || "guardrail_intervened" || "content_filtered" || "malformed_model_output" || "malformed_tool_use" || "model_context_window_exceeded", // required
|
|
519
551
|
* // usage: { // TokenUsage
|
|
520
552
|
* // inputTokens: Number("int"), // required
|
|
521
553
|
* // outputTokens: Number("int"), // required
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Command as $Command } from "@smithy/smithy-client";
|
|
2
|
-
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
3
|
-
import { BedrockRuntimeClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BedrockRuntimeClient";
|
|
4
|
-
import { ConverseStreamRequest, ConverseStreamResponse } from "../models/models_0";
|
|
2
|
+
import type { MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
3
|
+
import type { BedrockRuntimeClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BedrockRuntimeClient";
|
|
4
|
+
import type { ConverseStreamRequest, ConverseStreamResponse } from "../models/models_0";
|
|
5
5
|
/**
|
|
6
6
|
* @public
|
|
7
7
|
*/
|
|
@@ -53,6 +53,9 @@ declare const ConverseStreamCommand_base: {
|
|
|
53
53
|
* bucketOwner: "STRING_VALUE",
|
|
54
54
|
* },
|
|
55
55
|
* },
|
|
56
|
+
* error: { // ErrorBlock
|
|
57
|
+
* message: "STRING_VALUE",
|
|
58
|
+
* },
|
|
56
59
|
* },
|
|
57
60
|
* document: { // DocumentBlock
|
|
58
61
|
* format: "pdf" || "csv" || "doc" || "docx" || "xls" || "xlsx" || "html" || "txt" || "md",
|
|
@@ -85,6 +88,19 @@ declare const ConverseStreamCommand_base: {
|
|
|
85
88
|
* },
|
|
86
89
|
* },
|
|
87
90
|
* },
|
|
91
|
+
* audio: { // AudioBlock
|
|
92
|
+
* format: "mp3" || "opus" || "wav" || "aac" || "flac" || "mp4" || "ogg" || "mkv" || "mka" || "x-aac" || "m4a" || "mpeg" || "mpga" || "pcm" || "webm", // required
|
|
93
|
+
* source: { // AudioSource Union: only one key present
|
|
94
|
+
* bytes: new Uint8Array(), // e.g. Buffer.from("") or new TextEncoder().encode("")
|
|
95
|
+
* s3Location: {
|
|
96
|
+
* uri: "STRING_VALUE", // required
|
|
97
|
+
* bucketOwner: "STRING_VALUE",
|
|
98
|
+
* },
|
|
99
|
+
* },
|
|
100
|
+
* error: {
|
|
101
|
+
* message: "STRING_VALUE",
|
|
102
|
+
* },
|
|
103
|
+
* },
|
|
88
104
|
* toolUse: { // ToolUseBlock
|
|
89
105
|
* toolUseId: "STRING_VALUE", // required
|
|
90
106
|
* name: "STRING_VALUE", // required
|
|
@@ -106,16 +122,16 @@ declare const ConverseStreamCommand_base: {
|
|
|
106
122
|
* bucketOwner: "STRING_VALUE",
|
|
107
123
|
* },
|
|
108
124
|
* },
|
|
125
|
+
* error: {
|
|
126
|
+
* message: "STRING_VALUE",
|
|
127
|
+
* },
|
|
109
128
|
* },
|
|
110
129
|
* document: {
|
|
111
130
|
* format: "pdf" || "csv" || "doc" || "docx" || "xls" || "xlsx" || "html" || "txt" || "md",
|
|
112
131
|
* name: "STRING_VALUE", // required
|
|
113
132
|
* source: {// Union: only one key present
|
|
114
133
|
* bytes: new Uint8Array(), // e.g. Buffer.from("") or new TextEncoder().encode("")
|
|
115
|
-
* s3Location:
|
|
116
|
-
* uri: "STRING_VALUE", // required
|
|
117
|
-
* bucketOwner: "STRING_VALUE",
|
|
118
|
-
* },
|
|
134
|
+
* s3Location: "<S3Location>",
|
|
119
135
|
* text: "STRING_VALUE",
|
|
120
136
|
* content: [
|
|
121
137
|
* {// Union: only one key present
|
|
@@ -334,6 +350,9 @@ declare const ConverseStreamCommand_base: {
|
|
|
334
350
|
* // type: "STRING_VALUE",
|
|
335
351
|
* // status: "success" || "error",
|
|
336
352
|
* // },
|
|
353
|
+
* // image: { // ImageBlockStart
|
|
354
|
+
* // format: "png" || "jpeg" || "gif" || "webp", // required
|
|
355
|
+
* // },
|
|
337
356
|
* // },
|
|
338
357
|
* // contentBlockIndex: Number("int"), // required
|
|
339
358
|
* // },
|
|
@@ -346,6 +365,7 @@ declare const ConverseStreamCommand_base: {
|
|
|
346
365
|
* // toolResult: [ // ToolResultBlocksDelta
|
|
347
366
|
* // { // ToolResultBlockDelta Union: only one key present
|
|
348
367
|
* // text: "STRING_VALUE",
|
|
368
|
+
* // json: "DOCUMENT_VALUE",
|
|
349
369
|
* // },
|
|
350
370
|
* // ],
|
|
351
371
|
* // reasoningContent: { // ReasoningContentBlockDelta Union: only one key present
|
|
@@ -388,6 +408,18 @@ declare const ConverseStreamCommand_base: {
|
|
|
388
408
|
* // },
|
|
389
409
|
* // },
|
|
390
410
|
* // },
|
|
411
|
+
* // image: { // ImageBlockDelta
|
|
412
|
+
* // source: { // ImageSource Union: only one key present
|
|
413
|
+
* // bytes: new Uint8Array(),
|
|
414
|
+
* // s3Location: { // S3Location
|
|
415
|
+
* // uri: "STRING_VALUE", // required
|
|
416
|
+
* // bucketOwner: "STRING_VALUE",
|
|
417
|
+
* // },
|
|
418
|
+
* // },
|
|
419
|
+
* // error: { // ErrorBlock
|
|
420
|
+
* // message: "STRING_VALUE",
|
|
421
|
+
* // },
|
|
422
|
+
* // },
|
|
391
423
|
* // },
|
|
392
424
|
* // contentBlockIndex: Number("int"), // required
|
|
393
425
|
* // },
|
|
@@ -395,7 +427,7 @@ declare const ConverseStreamCommand_base: {
|
|
|
395
427
|
* // contentBlockIndex: Number("int"), // required
|
|
396
428
|
* // },
|
|
397
429
|
* // messageStop: { // MessageStopEvent
|
|
398
|
-
* // stopReason: "end_turn" || "tool_use" || "max_tokens" || "stop_sequence" || "guardrail_intervened" || "content_filtered" || "model_context_window_exceeded", // required
|
|
430
|
+
* // stopReason: "end_turn" || "tool_use" || "max_tokens" || "stop_sequence" || "guardrail_intervened" || "content_filtered" || "malformed_model_output" || "malformed_tool_use" || "model_context_window_exceeded", // required
|
|
399
431
|
* // additionalModelResponseFields: "DOCUMENT_VALUE",
|
|
400
432
|
* // },
|
|
401
433
|
* // metadata: { // ConverseStreamMetadataEvent
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Command as $Command } from "@smithy/smithy-client";
|
|
2
|
-
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
3
|
-
import { BedrockRuntimeClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BedrockRuntimeClient";
|
|
4
|
-
import { CountTokensRequest, CountTokensResponse } from "../models/models_0";
|
|
2
|
+
import type { MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
3
|
+
import type { BedrockRuntimeClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BedrockRuntimeClient";
|
|
4
|
+
import type { CountTokensRequest, CountTokensResponse } from "../models/models_0";
|
|
5
5
|
/**
|
|
6
6
|
* @public
|
|
7
7
|
*/
|
|
@@ -58,6 +58,9 @@ declare const CountTokensCommand_base: {
|
|
|
58
58
|
* bucketOwner: "STRING_VALUE",
|
|
59
59
|
* },
|
|
60
60
|
* },
|
|
61
|
+
* error: { // ErrorBlock
|
|
62
|
+
* message: "STRING_VALUE",
|
|
63
|
+
* },
|
|
61
64
|
* },
|
|
62
65
|
* document: { // DocumentBlock
|
|
63
66
|
* format: "pdf" || "csv" || "doc" || "docx" || "xls" || "xlsx" || "html" || "txt" || "md",
|
|
@@ -90,6 +93,19 @@ declare const CountTokensCommand_base: {
|
|
|
90
93
|
* },
|
|
91
94
|
* },
|
|
92
95
|
* },
|
|
96
|
+
* audio: { // AudioBlock
|
|
97
|
+
* format: "mp3" || "opus" || "wav" || "aac" || "flac" || "mp4" || "ogg" || "mkv" || "mka" || "x-aac" || "m4a" || "mpeg" || "mpga" || "pcm" || "webm", // required
|
|
98
|
+
* source: { // AudioSource Union: only one key present
|
|
99
|
+
* bytes: new Uint8Array(), // e.g. Buffer.from("") or new TextEncoder().encode("")
|
|
100
|
+
* s3Location: {
|
|
101
|
+
* uri: "STRING_VALUE", // required
|
|
102
|
+
* bucketOwner: "STRING_VALUE",
|
|
103
|
+
* },
|
|
104
|
+
* },
|
|
105
|
+
* error: {
|
|
106
|
+
* message: "STRING_VALUE",
|
|
107
|
+
* },
|
|
108
|
+
* },
|
|
93
109
|
* toolUse: { // ToolUseBlock
|
|
94
110
|
* toolUseId: "STRING_VALUE", // required
|
|
95
111
|
* name: "STRING_VALUE", // required
|
|
@@ -111,16 +127,16 @@ declare const CountTokensCommand_base: {
|
|
|
111
127
|
* bucketOwner: "STRING_VALUE",
|
|
112
128
|
* },
|
|
113
129
|
* },
|
|
130
|
+
* error: {
|
|
131
|
+
* message: "STRING_VALUE",
|
|
132
|
+
* },
|
|
114
133
|
* },
|
|
115
134
|
* document: {
|
|
116
135
|
* format: "pdf" || "csv" || "doc" || "docx" || "xls" || "xlsx" || "html" || "txt" || "md",
|
|
117
136
|
* name: "STRING_VALUE", // required
|
|
118
137
|
* source: {// Union: only one key present
|
|
119
138
|
* bytes: new Uint8Array(), // e.g. Buffer.from("") or new TextEncoder().encode("")
|
|
120
|
-
* s3Location:
|
|
121
|
-
* uri: "STRING_VALUE", // required
|
|
122
|
-
* bucketOwner: "STRING_VALUE",
|
|
123
|
-
* },
|
|
139
|
+
* s3Location: "<S3Location>",
|
|
124
140
|
* text: "STRING_VALUE",
|
|
125
141
|
* content: [
|
|
126
142
|
* {// Union: only one key present
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Command as $Command } from "@smithy/smithy-client";
|
|
2
|
-
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
3
|
-
import { BedrockRuntimeClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BedrockRuntimeClient";
|
|
4
|
-
import { GetAsyncInvokeRequest, GetAsyncInvokeResponse } from "../models/models_0";
|
|
2
|
+
import type { MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
3
|
+
import type { BedrockRuntimeClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BedrockRuntimeClient";
|
|
4
|
+
import type { GetAsyncInvokeRequest, GetAsyncInvokeResponse } from "../models/models_0";
|
|
5
5
|
/**
|
|
6
6
|
* @public
|
|
7
7
|
*/
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Command as $Command } from "@smithy/smithy-client";
|
|
2
|
-
import { BlobPayloadInputTypes, MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
2
|
+
import type { BlobPayloadInputTypes, MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
3
3
|
import { Uint8ArrayBlobAdapter } from "@smithy/util-stream";
|
|
4
|
-
import { BedrockRuntimeClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BedrockRuntimeClient";
|
|
4
|
+
import type { BedrockRuntimeClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BedrockRuntimeClient";
|
|
5
5
|
import { InvokeModelRequest, InvokeModelResponse } from "../models/models_0";
|
|
6
6
|
/**
|
|
7
7
|
* @public
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Command as $Command } from "@smithy/smithy-client";
|
|
2
|
-
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
3
|
-
import { BedrockRuntimeClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BedrockRuntimeClient";
|
|
4
|
-
import { InvokeModelWithBidirectionalStreamRequest, InvokeModelWithBidirectionalStreamResponse } from "../models/models_0";
|
|
2
|
+
import type { MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
3
|
+
import type { BedrockRuntimeClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BedrockRuntimeClient";
|
|
4
|
+
import type { InvokeModelWithBidirectionalStreamRequest, InvokeModelWithBidirectionalStreamResponse } from "../models/models_0";
|
|
5
5
|
/**
|
|
6
6
|
* @public
|
|
7
7
|
*/
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Command as $Command } from "@smithy/smithy-client";
|
|
2
|
-
import { BlobPayloadInputTypes, MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
3
|
-
import { BedrockRuntimeClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BedrockRuntimeClient";
|
|
4
|
-
import {
|
|
2
|
+
import type { BlobPayloadInputTypes, MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
3
|
+
import type { BedrockRuntimeClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BedrockRuntimeClient";
|
|
4
|
+
import { type InvokeModelWithResponseStreamResponse, InvokeModelWithResponseStreamRequest } from "../models/models_0";
|
|
5
5
|
/**
|
|
6
6
|
* @public
|
|
7
7
|
*/
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Command as $Command } from "@smithy/smithy-client";
|
|
2
|
-
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
3
|
-
import { BedrockRuntimeClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BedrockRuntimeClient";
|
|
4
|
-
import { ListAsyncInvokesRequest, ListAsyncInvokesResponse } from "../models/models_0";
|
|
2
|
+
import type { MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
3
|
+
import type { BedrockRuntimeClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BedrockRuntimeClient";
|
|
4
|
+
import type { ListAsyncInvokesRequest, ListAsyncInvokesResponse } from "../models/models_0";
|
|
5
5
|
/**
|
|
6
6
|
* @public
|
|
7
7
|
*/
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Command as $Command } from "@smithy/smithy-client";
|
|
2
|
-
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
3
|
-
import { BedrockRuntimeClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BedrockRuntimeClient";
|
|
4
|
-
import { StartAsyncInvokeRequest, StartAsyncInvokeResponse } from "../models/models_0";
|
|
2
|
+
import type { MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
3
|
+
import type { BedrockRuntimeClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BedrockRuntimeClient";
|
|
4
|
+
import type { StartAsyncInvokeRequest, StartAsyncInvokeResponse } from "../models/models_0";
|
|
5
5
|
/**
|
|
6
6
|
* @public
|
|
7
7
|
*/
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Endpoint, EndpointParameters as __EndpointParameters, EndpointV2, Provider } from "@smithy/types";
|
|
1
|
+
import type { Endpoint, EndpointParameters as __EndpointParameters, EndpointV2, Provider } from "@smithy/types";
|
|
2
2
|
/**
|
|
3
3
|
* @public
|
|
4
4
|
*/
|
|
@@ -8,10 +8,19 @@ export interface ClientInputEndpointParameters {
|
|
|
8
8
|
useFipsEndpoint?: boolean | undefined | Provider<boolean | undefined>;
|
|
9
9
|
endpoint?: string | Provider<string> | Endpoint | Provider<Endpoint> | EndpointV2 | Provider<EndpointV2>;
|
|
10
10
|
}
|
|
11
|
+
/**
|
|
12
|
+
* @public
|
|
13
|
+
*/
|
|
11
14
|
export type ClientResolvedEndpointParameters = Omit<ClientInputEndpointParameters, "endpoint"> & {
|
|
12
15
|
defaultSigningName: string;
|
|
13
16
|
};
|
|
17
|
+
/**
|
|
18
|
+
* @internal
|
|
19
|
+
*/
|
|
14
20
|
export declare const resolveClientEndpointParameters: <T>(options: T & ClientInputEndpointParameters) => T & ClientResolvedEndpointParameters;
|
|
21
|
+
/**
|
|
22
|
+
* @internal
|
|
23
|
+
*/
|
|
15
24
|
export declare const commonParams: {
|
|
16
25
|
readonly UseFIPS: {
|
|
17
26
|
readonly type: "builtInParams";
|
|
@@ -30,6 +39,9 @@ export declare const commonParams: {
|
|
|
30
39
|
readonly name: "useDualstackEndpoint";
|
|
31
40
|
};
|
|
32
41
|
};
|
|
42
|
+
/**
|
|
43
|
+
* @internal
|
|
44
|
+
*/
|
|
33
45
|
export interface EndpointParameters extends __EndpointParameters {
|
|
34
46
|
Region?: string | undefined;
|
|
35
47
|
UseDualStack?: boolean | undefined;
|
|
@@ -1,5 +1,8 @@
|
|
|
1
|
-
import { EndpointV2, Logger } from "@smithy/types";
|
|
2
|
-
import { EndpointParameters } from "./EndpointParameters";
|
|
1
|
+
import type { EndpointV2, Logger } from "@smithy/types";
|
|
2
|
+
import type { EndpointParameters } from "./EndpointParameters";
|
|
3
|
+
/**
|
|
4
|
+
* @internal
|
|
5
|
+
*/
|
|
3
6
|
export declare const defaultEndpointResolver: (endpointParams: EndpointParameters, context?: {
|
|
4
7
|
logger?: Logger;
|
|
5
8
|
}) => EndpointV2;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { AwsRegionExtensionConfiguration } from "@aws-sdk/types";
|
|
2
|
-
import { HttpHandlerExtensionConfiguration } from "@smithy/protocol-http";
|
|
3
|
-
import { DefaultExtensionConfiguration } from "@smithy/types";
|
|
4
|
-
import { HttpAuthExtensionConfiguration } from "./auth/httpAuthExtensionConfiguration";
|
|
1
|
+
import type { AwsRegionExtensionConfiguration } from "@aws-sdk/types";
|
|
2
|
+
import type { HttpHandlerExtensionConfiguration } from "@smithy/protocol-http";
|
|
3
|
+
import type { DefaultExtensionConfiguration } from "@smithy/types";
|
|
4
|
+
import type { HttpAuthExtensionConfiguration } from "./auth/httpAuthExtensionConfiguration";
|
|
5
5
|
/**
|
|
6
6
|
* @internal
|
|
7
7
|
*/
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { type ServiceExceptionOptions as __ServiceExceptionOptions, ServiceException as __ServiceException } from "@smithy/smithy-client";
|
|
2
2
|
export type { __ServiceExceptionOptions };
|
|
3
3
|
export { __ServiceException };
|
|
4
4
|
/**
|
|
@@ -325,6 +325,31 @@ export declare const GuardrailTrace: {
|
|
|
325
325
|
* @public
|
|
326
326
|
*/
|
|
327
327
|
export type GuardrailTrace = (typeof GuardrailTrace)[keyof typeof GuardrailTrace];
|
|
328
|
+
/**
|
|
329
|
+
* @public
|
|
330
|
+
* @enum
|
|
331
|
+
*/
|
|
332
|
+
export declare const AudioFormat: {
|
|
333
|
+
readonly AAC: "aac";
|
|
334
|
+
readonly FLAC: "flac";
|
|
335
|
+
readonly M4A: "m4a";
|
|
336
|
+
readonly MKA: "mka";
|
|
337
|
+
readonly MKV: "mkv";
|
|
338
|
+
readonly MP3: "mp3";
|
|
339
|
+
readonly MP4: "mp4";
|
|
340
|
+
readonly MPEG: "mpeg";
|
|
341
|
+
readonly MPGA: "mpga";
|
|
342
|
+
readonly OGG: "ogg";
|
|
343
|
+
readonly OPUS: "opus";
|
|
344
|
+
readonly PCM: "pcm";
|
|
345
|
+
readonly WAV: "wav";
|
|
346
|
+
readonly WEBM: "webm";
|
|
347
|
+
readonly X_AAC: "x-aac";
|
|
348
|
+
};
|
|
349
|
+
/**
|
|
350
|
+
* @public
|
|
351
|
+
*/
|
|
352
|
+
export type AudioFormat = (typeof AudioFormat)[keyof typeof AudioFormat];
|
|
328
353
|
/**
|
|
329
354
|
* @public
|
|
330
355
|
* @enum
|
|
@@ -482,6 +507,8 @@ export declare const StopReason: {
|
|
|
482
507
|
readonly CONTENT_FILTERED: "content_filtered";
|
|
483
508
|
readonly END_TURN: "end_turn";
|
|
484
509
|
readonly GUARDRAIL_INTERVENED: "guardrail_intervened";
|
|
510
|
+
readonly MALFORMED_MODEL_OUTPUT: "malformed_model_output";
|
|
511
|
+
readonly MALFORMED_TOOL_USE: "malformed_tool_use";
|
|
485
512
|
readonly MAX_TOKENS: "max_tokens";
|
|
486
513
|
readonly MODEL_CONTEXT_WINDOW_EXCEEDED: "model_context_window_exceeded";
|
|
487
514
|
readonly STOP_SEQUENCE: "stop_sequence";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ExceptionOptionType as __ExceptionOptionType } from "@smithy/smithy-client";
|
|
1
|
+
import type { ExceptionOptionType as __ExceptionOptionType } from "@smithy/smithy-client";
|
|
2
2
|
import { BedrockRuntimeServiceException as __BaseException } from "./BedrockRuntimeServiceException";
|
|
3
3
|
/**
|
|
4
4
|
* <p>The request is denied because you do not have sufficient permissions to perform the requested action. For troubleshooting this error, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/troubleshooting-api-error-codes.html#ts-access-denied">AccessDeniedException</a> in the Amazon Bedrock User Guide</p>
|