@aws-sdk/client-lex-runtime-v2 3.34.0 → 3.37.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (138) hide show
  1. package/CHANGELOG.md +47 -0
  2. package/{dist/cjs → dist-cjs}/LexRuntimeV2.js +1 -5
  3. package/{dist/cjs → dist-cjs}/LexRuntimeV2Client.js +10 -19
  4. package/dist-cjs/commands/DeleteSessionCommand.js +36 -0
  5. package/{dist/cjs → dist-cjs}/commands/GetSessionCommand.js +2 -35
  6. package/{dist/cjs → dist-cjs}/commands/PutSessionCommand.js +2 -29
  7. package/{dist/cjs → dist-cjs}/commands/RecognizeTextCommand.js +2 -31
  8. package/dist-cjs/commands/RecognizeUtteranceCommand.js +36 -0
  9. package/dist-cjs/commands/StartConversationCommand.js +38 -0
  10. package/{dist/cjs → dist-cjs}/endpoints.js +1 -2
  11. package/{dist/cjs → dist-cjs}/index.js +0 -1
  12. package/{dist/cjs → dist-cjs}/models/index.js +0 -1
  13. package/{dist/cjs → dist-cjs}/models/models_0.js +2 -145
  14. package/{dist/cjs → dist-cjs}/protocols/Aws_restJson1.js +1 -7
  15. package/{dist/cjs → dist-cjs}/runtimeConfig.browser.js +1 -5
  16. package/{dist/cjs → dist-cjs}/runtimeConfig.js +1 -5
  17. package/{dist/cjs → dist-cjs}/runtimeConfig.native.js +0 -4
  18. package/{dist/cjs → dist-cjs}/runtimeConfig.shared.js +1 -5
  19. package/{dist/es → dist-es}/LexRuntimeV2.js +1 -2
  20. package/{dist/es → dist-es}/LexRuntimeV2Client.js +1 -2
  21. package/{dist/es → dist-es}/commands/DeleteSessionCommand.js +2 -3
  22. package/{dist/es → dist-es}/commands/GetSessionCommand.js +2 -3
  23. package/{dist/es → dist-es}/commands/PutSessionCommand.js +2 -3
  24. package/{dist/es → dist-es}/commands/RecognizeTextCommand.js +2 -3
  25. package/{dist/es → dist-es}/commands/RecognizeUtteranceCommand.js +2 -3
  26. package/{dist/es → dist-es}/commands/StartConversationCommand.js +2 -3
  27. package/{dist/es → dist-es}/endpoints.js +1 -2
  28. package/{dist/types/index.d.ts → dist-es/index.js} +0 -0
  29. package/{dist/types/models/index.d.ts → dist-es/models/index.js} +0 -0
  30. package/{dist/es → dist-es}/models/models_0.js +2 -1
  31. package/{dist/es → dist-es}/protocols/Aws_restJson1.js +1 -2
  32. package/{dist/es → dist-es}/runtimeConfig.browser.js +1 -2
  33. package/{dist/es → dist-es}/runtimeConfig.js +1 -2
  34. package/{dist/es → dist-es}/runtimeConfig.native.js +0 -1
  35. package/{dist/es → dist-es}/runtimeConfig.shared.js +1 -2
  36. package/{dist/types/ts3.4 → dist-types}/LexRuntimeV2.d.ts +223 -139
  37. package/{dist/types → dist-types}/LexRuntimeV2Client.d.ts +7 -7
  38. package/{dist/types → dist-types}/commands/DeleteSessionCommand.d.ts +2 -2
  39. package/{dist/types → dist-types}/commands/GetSessionCommand.d.ts +2 -2
  40. package/{dist/types → dist-types}/commands/PutSessionCommand.d.ts +2 -2
  41. package/{dist/types → dist-types}/commands/RecognizeTextCommand.d.ts +28 -2
  42. package/{dist/types → dist-types}/commands/RecognizeUtteranceCommand.d.ts +28 -2
  43. package/{dist/types → dist-types}/commands/StartConversationCommand.d.ts +34 -2
  44. package/{dist/types → dist-types}/endpoints.d.ts +0 -0
  45. package/{index.ts → dist-types/index.d.ts} +0 -0
  46. package/{models/index.ts → dist-types/models/index.d.ts} +0 -0
  47. package/{dist/types → dist-types}/models/models_0.d.ts +15 -9
  48. package/{dist/types → dist-types}/protocols/Aws_restJson1.d.ts +2 -2
  49. package/{dist/types → dist-types}/runtimeConfig.browser.d.ts +0 -0
  50. package/{dist/types → dist-types}/runtimeConfig.d.ts +1 -1
  51. package/{dist/types → dist-types}/runtimeConfig.native.d.ts +0 -0
  52. package/{dist/types → dist-types}/runtimeConfig.shared.d.ts +0 -0
  53. package/dist-types/ts3.4/LexRuntimeV2.d.ts +35 -0
  54. package/{dist/types → dist-types}/ts3.4/LexRuntimeV2Client.d.ts +33 -103
  55. package/dist-types/ts3.4/commands/DeleteSessionCommand.d.ts +17 -0
  56. package/dist-types/ts3.4/commands/GetSessionCommand.d.ts +17 -0
  57. package/dist-types/ts3.4/commands/PutSessionCommand.d.ts +17 -0
  58. package/dist-types/ts3.4/commands/RecognizeTextCommand.d.ts +17 -0
  59. package/dist-types/ts3.4/commands/RecognizeUtteranceCommand.d.ts +24 -0
  60. package/dist-types/ts3.4/commands/StartConversationCommand.d.ts +17 -0
  61. package/{dist/types → dist-types}/ts3.4/endpoints.d.ts +0 -0
  62. package/{dist/types → dist-types}/ts3.4/index.d.ts +0 -0
  63. package/{dist/types → dist-types}/ts3.4/models/index.d.ts +0 -0
  64. package/dist-types/ts3.4/models/models_0.d.ts +348 -0
  65. package/{dist/types → dist-types}/ts3.4/protocols/Aws_restJson1.d.ts +2 -2
  66. package/{dist/types → dist-types}/ts3.4/runtimeConfig.browser.d.ts +1 -3
  67. package/{dist/types → dist-types}/ts3.4/runtimeConfig.d.ts +2 -4
  68. package/{dist/types → dist-types}/ts3.4/runtimeConfig.native.d.ts +1 -3
  69. package/{dist/types → dist-types}/ts3.4/runtimeConfig.shared.d.ts +1 -3
  70. package/package.json +50 -47
  71. package/LexRuntimeV2.ts +0 -299
  72. package/LexRuntimeV2Client.ts +0 -282
  73. package/commands/DeleteSessionCommand.ts +0 -107
  74. package/commands/GetSessionCommand.ts +0 -102
  75. package/commands/PutSessionCommand.ts +0 -96
  76. package/commands/RecognizeTextCommand.ts +0 -98
  77. package/commands/RecognizeUtteranceCommand.ts +0 -139
  78. package/commands/StartConversationCommand.ts +0 -130
  79. package/dist/cjs/LexRuntimeV2.js.map +0 -1
  80. package/dist/cjs/LexRuntimeV2Client.js.map +0 -1
  81. package/dist/cjs/commands/DeleteSessionCommand.js +0 -74
  82. package/dist/cjs/commands/DeleteSessionCommand.js.map +0 -1
  83. package/dist/cjs/commands/GetSessionCommand.js.map +0 -1
  84. package/dist/cjs/commands/PutSessionCommand.js.map +0 -1
  85. package/dist/cjs/commands/RecognizeTextCommand.js.map +0 -1
  86. package/dist/cjs/commands/RecognizeUtteranceCommand.js +0 -97
  87. package/dist/cjs/commands/RecognizeUtteranceCommand.js.map +0 -1
  88. package/dist/cjs/commands/StartConversationCommand.js +0 -90
  89. package/dist/cjs/commands/StartConversationCommand.js.map +0 -1
  90. package/dist/cjs/endpoints.js.map +0 -1
  91. package/dist/cjs/index.js.map +0 -1
  92. package/dist/cjs/models/index.js.map +0 -1
  93. package/dist/cjs/models/models_0.js.map +0 -1
  94. package/dist/cjs/package.json +0 -96
  95. package/dist/cjs/protocols/Aws_restJson1.js.map +0 -1
  96. package/dist/cjs/runtimeConfig.browser.js.map +0 -1
  97. package/dist/cjs/runtimeConfig.js.map +0 -1
  98. package/dist/cjs/runtimeConfig.native.js.map +0 -1
  99. package/dist/cjs/runtimeConfig.shared.js.map +0 -1
  100. package/dist/es/LexRuntimeV2.js.map +0 -1
  101. package/dist/es/LexRuntimeV2Client.js.map +0 -1
  102. package/dist/es/commands/DeleteSessionCommand.js.map +0 -1
  103. package/dist/es/commands/GetSessionCommand.js.map +0 -1
  104. package/dist/es/commands/PutSessionCommand.js.map +0 -1
  105. package/dist/es/commands/RecognizeTextCommand.js.map +0 -1
  106. package/dist/es/commands/RecognizeUtteranceCommand.js.map +0 -1
  107. package/dist/es/commands/StartConversationCommand.js.map +0 -1
  108. package/dist/es/endpoints.js.map +0 -1
  109. package/dist/es/index.js +0 -10
  110. package/dist/es/index.js.map +0 -1
  111. package/dist/es/models/index.js +0 -2
  112. package/dist/es/models/index.js.map +0 -1
  113. package/dist/es/models/models_0.js.map +0 -1
  114. package/dist/es/package.json +0 -96
  115. package/dist/es/protocols/Aws_restJson1.js.map +0 -1
  116. package/dist/es/runtimeConfig.browser.js.map +0 -1
  117. package/dist/es/runtimeConfig.js.map +0 -1
  118. package/dist/es/runtimeConfig.native.js.map +0 -1
  119. package/dist/es/runtimeConfig.shared.js.map +0 -1
  120. package/dist/types/LexRuntimeV2.d.ts +0 -139
  121. package/dist/types/ts3.4/commands/DeleteSessionCommand.d.ts +0 -48
  122. package/dist/types/ts3.4/commands/GetSessionCommand.d.ts +0 -43
  123. package/dist/types/ts3.4/commands/PutSessionCommand.d.ts +0 -37
  124. package/dist/types/ts3.4/commands/RecognizeTextCommand.d.ts +0 -39
  125. package/dist/types/ts3.4/commands/RecognizeUtteranceCommand.d.ts +0 -82
  126. package/dist/types/ts3.4/commands/StartConversationCommand.d.ts +0 -62
  127. package/dist/types/ts3.4/models/models_0.d.ts +0 -2035
  128. package/endpoints.ts +0 -57
  129. package/jest.config.js +0 -4
  130. package/models/models_0.ts +0 -2458
  131. package/protocols/Aws_restJson1.ts +0 -2458
  132. package/runtimeConfig.browser.ts +0 -45
  133. package/runtimeConfig.native.ts +0 -20
  134. package/runtimeConfig.shared.ts +0 -16
  135. package/runtimeConfig.ts +0 -49
  136. package/tsconfig.es.json +0 -10
  137. package/tsconfig.json +0 -31
  138. package/tsconfig.types.json +0 -8
@@ -1,39 +0,0 @@
1
- import { LexRuntimeV2ClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../LexRuntimeV2Client";
2
- import { RecognizeTextRequest, RecognizeTextResponse } from "../models/models_0";
3
- import { Command as $Command } from "@aws-sdk/smithy-client";
4
- import { Handler, MiddlewareStack, HttpHandlerOptions as __HttpHandlerOptions, MetadataBearer as __MetadataBearer } from "@aws-sdk/types";
5
- export interface RecognizeTextCommandInput extends RecognizeTextRequest {
6
- }
7
- export interface RecognizeTextCommandOutput extends RecognizeTextResponse, __MetadataBearer {
8
- }
9
- /**
10
- * <p>Sends user input to Amazon Lex V2. Client applications use this API to send
11
- * requests to Amazon Lex V2 at runtime. Amazon Lex V2 then interprets the user input
12
- * using the machine learning model that it build for the bot.</p>
13
- * <p>In response, Amazon Lex V2 returns the next message to convey to the user
14
- * and an optional response card to display.</p>
15
- * @example
16
- * Use a bare-bones client and the command you need to make an API call.
17
- * ```javascript
18
- * import { LexRuntimeV2Client, RecognizeTextCommand } from "@aws-sdk/client-lex-runtime-v2"; // ES Modules import
19
- * // const { LexRuntimeV2Client, RecognizeTextCommand } = require("@aws-sdk/client-lex-runtime-v2"); // CommonJS import
20
- * const client = new LexRuntimeV2Client(config);
21
- * const command = new RecognizeTextCommand(input);
22
- * const response = await client.send(command);
23
- * ```
24
- *
25
- * @see {@link RecognizeTextCommandInput} for command's `input` shape.
26
- * @see {@link RecognizeTextCommandOutput} for command's `response` shape.
27
- * @see {@link LexRuntimeV2ClientResolvedConfig | config} for command's `input` shape.
28
- *
29
- */
30
- export declare class RecognizeTextCommand extends $Command<RecognizeTextCommandInput, RecognizeTextCommandOutput, LexRuntimeV2ClientResolvedConfig> {
31
- readonly input: RecognizeTextCommandInput;
32
- constructor(input: RecognizeTextCommandInput);
33
- /**
34
- * @internal
35
- */
36
- resolveMiddleware(clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>, configuration: LexRuntimeV2ClientResolvedConfig, options?: __HttpHandlerOptions): Handler<RecognizeTextCommandInput, RecognizeTextCommandOutput>;
37
- private serialize;
38
- private deserialize;
39
- }
@@ -1,82 +0,0 @@
1
- /// <reference types="node" />
2
- import { LexRuntimeV2ClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../LexRuntimeV2Client";
3
- import { RecognizeUtteranceRequest, RecognizeUtteranceResponse } from "../models/models_0";
4
- import { Command as $Command } from "@aws-sdk/smithy-client";
5
- import { Handler, MiddlewareStack, HttpHandlerOptions as __HttpHandlerOptions, MetadataBearer as __MetadataBearer } from "@aws-sdk/types";
6
- declare type RecognizeUtteranceCommandInputType = Pick<RecognizeUtteranceRequest, Exclude<keyof RecognizeUtteranceRequest, "inputStream">> & {
7
- /**
8
- * For *`RecognizeUtteranceRequest["inputStream"]`*, see {@link RecognizeUtteranceRequest.inputStream}.
9
- */
10
- inputStream?: RecognizeUtteranceRequest["inputStream"] | string | Uint8Array | Buffer;
11
- };
12
- /**
13
- * This interface extends from `RecognizeUtteranceRequest` interface. There are more parameters than `inputStream` defined in {@link RecognizeUtteranceRequest}
14
- */
15
- export interface RecognizeUtteranceCommandInput extends RecognizeUtteranceCommandInputType {
16
- }
17
- export interface RecognizeUtteranceCommandOutput extends RecognizeUtteranceResponse, __MetadataBearer {
18
- }
19
- /**
20
- * <p>Sends user input to Amazon Lex V2. You can send text or speech. Clients use
21
- * this API to send text and audio requests to Amazon Lex V2 at runtime. Amazon Lex V2
22
- * interprets the user input using the machine learning model built for
23
- * the bot.</p>
24
- * <p>The following request fields must be compressed with gzip and then
25
- * base64 encoded before you send them to Amazon Lex V2. </p>
26
- * <ul>
27
- * <li>
28
- * <p>requestAttributes</p>
29
- * </li>
30
- * <li>
31
- * <p>sessionState</p>
32
- * </li>
33
- * </ul>
34
- * <p>The following response fields are compressed using gzip and then
35
- * base64 encoded by Amazon Lex V2. Before you can use these fields, you must
36
- * decode and decompress them. </p>
37
- * <ul>
38
- * <li>
39
- * <p>inputTranscript</p>
40
- * </li>
41
- * <li>
42
- * <p>interpretations</p>
43
- * </li>
44
- * <li>
45
- * <p>messages</p>
46
- * </li>
47
- * <li>
48
- * <p>requestAttributes</p>
49
- * </li>
50
- * <li>
51
- * <p>sessionState</p>
52
- * </li>
53
- * </ul>
54
- * <p>The example contains a Java application that compresses and encodes
55
- * a Java object to send to Amazon Lex V2, and a second that decodes and
56
- * decompresses a response from Amazon Lex V2.</p>
57
- * @example
58
- * Use a bare-bones client and the command you need to make an API call.
59
- * ```javascript
60
- * import { LexRuntimeV2Client, RecognizeUtteranceCommand } from "@aws-sdk/client-lex-runtime-v2"; // ES Modules import
61
- * // const { LexRuntimeV2Client, RecognizeUtteranceCommand } = require("@aws-sdk/client-lex-runtime-v2"); // CommonJS import
62
- * const client = new LexRuntimeV2Client(config);
63
- * const command = new RecognizeUtteranceCommand(input);
64
- * const response = await client.send(command);
65
- * ```
66
- *
67
- * @see {@link RecognizeUtteranceCommandInput} for command's `input` shape.
68
- * @see {@link RecognizeUtteranceCommandOutput} for command's `response` shape.
69
- * @see {@link LexRuntimeV2ClientResolvedConfig | config} for command's `input` shape.
70
- *
71
- */
72
- export declare class RecognizeUtteranceCommand extends $Command<RecognizeUtteranceCommandInput, RecognizeUtteranceCommandOutput, LexRuntimeV2ClientResolvedConfig> {
73
- readonly input: RecognizeUtteranceCommandInput;
74
- constructor(input: RecognizeUtteranceCommandInput);
75
- /**
76
- * @internal
77
- */
78
- resolveMiddleware(clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>, configuration: LexRuntimeV2ClientResolvedConfig, options?: __HttpHandlerOptions): Handler<RecognizeUtteranceCommandInput, RecognizeUtteranceCommandOutput>;
79
- private serialize;
80
- private deserialize;
81
- }
82
- export {};
@@ -1,62 +0,0 @@
1
- import { LexRuntimeV2ClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../LexRuntimeV2Client";
2
- import { StartConversationRequest, StartConversationResponse } from "../models/models_0";
3
- import { Command as $Command } from "@aws-sdk/smithy-client";
4
- import { Handler, MiddlewareStack, HttpHandlerOptions as __HttpHandlerOptions, MetadataBearer as __MetadataBearer } from "@aws-sdk/types";
5
- export interface StartConversationCommandInput extends StartConversationRequest {
6
- }
7
- export interface StartConversationCommandOutput extends StartConversationResponse, __MetadataBearer {
8
- }
9
- /**
10
- * <p>Starts an HTTP/2 bidirectional event stream that enables you to send
11
- * audio, text, or DTMF input in real time. After your application starts
12
- * a conversation, users send input to Amazon Lex V2 as a stream of events. Amazon Lex V2
13
- * processes the incoming events and responds with streaming text or audio
14
- * events.
15
- * </p>
16
- * <p>Audio input must be in the following format: <code>audio/lpcm
17
- * sample-rate=8000 sample-size-bits=16 channel-count=1;
18
- * is-big-endian=false</code>.</p>
19
- * <p>The <code>StartConversation</code> operation is supported only in
20
- * the following SDKs: </p>
21
- * <ul>
22
- * <li>
23
- * <p>
24
- * <a href="https://docs.aws.amazon.com/goto/SdkForCpp/runtime.lex.v2-2020-08-07/StartConversation">AWS SDK for C++</a>
25
- * </p>
26
- * </li>
27
- * <li>
28
- * <p>
29
- * <a href="https://docs.aws.amazon.com/goto/SdkForJavaV2/runtime.lex.v2-2020-08-07/StartConversation">AWS SDK for Java V2</a>
30
- * </p>
31
- * </li>
32
- * <li>
33
- * <p>
34
- * <a href="https://docs.aws.amazon.com/goto/SdkForRubyV3/runtime.lex.v2-2020-08-07/StartConversation">AWS SDK for Ruby V3</a>
35
- * </p>
36
- * </li>
37
- * </ul>
38
- * @example
39
- * Use a bare-bones client and the command you need to make an API call.
40
- * ```javascript
41
- * import { LexRuntimeV2Client, StartConversationCommand } from "@aws-sdk/client-lex-runtime-v2"; // ES Modules import
42
- * // const { LexRuntimeV2Client, StartConversationCommand } = require("@aws-sdk/client-lex-runtime-v2"); // CommonJS import
43
- * const client = new LexRuntimeV2Client(config);
44
- * const command = new StartConversationCommand(input);
45
- * const response = await client.send(command);
46
- * ```
47
- *
48
- * @see {@link StartConversationCommandInput} for command's `input` shape.
49
- * @see {@link StartConversationCommandOutput} for command's `response` shape.
50
- * @see {@link LexRuntimeV2ClientResolvedConfig | config} for command's `input` shape.
51
- *
52
- */
53
- export declare class StartConversationCommand extends $Command<StartConversationCommandInput, StartConversationCommandOutput, LexRuntimeV2ClientResolvedConfig> {
54
- readonly input: StartConversationCommandInput;
55
- constructor(input: StartConversationCommandInput);
56
- /**
57
- * @internal
58
- */
59
- resolveMiddleware(clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>, configuration: LexRuntimeV2ClientResolvedConfig, options?: __HttpHandlerOptions): Handler<StartConversationCommandInput, StartConversationCommandOutput>;
60
- private serialize;
61
- private deserialize;
62
- }