@aws-sdk/client-polly 3.35.0 → 3.38.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/CHANGELOG.md +47 -0
- package/dist-cjs/Polly.js +0 -9
- package/dist-cjs/PollyClient.js +0 -14
- package/dist-cjs/commands/DeleteLexiconCommand.js +0 -28
- package/dist-cjs/commands/DescribeVoicesCommand.js +0 -43
- package/dist-cjs/commands/GetLexiconCommand.js +0 -26
- package/dist-cjs/commands/GetSpeechSynthesisTaskCommand.js +0 -28
- package/dist-cjs/commands/ListLexiconsCommand.js +0 -25
- package/dist-cjs/commands/ListSpeechSynthesisTasksCommand.js +0 -27
- package/dist-cjs/commands/PutLexiconCommand.js +0 -30
- package/dist-cjs/commands/StartSpeechSynthesisTaskCommand.js +0 -34
- package/dist-cjs/commands/SynthesizeSpeechCommand.js +0 -29
- package/dist-cjs/commands/index.js +12 -0
- package/dist-cjs/endpoints.js +1 -2
- package/dist-cjs/index.js +4 -14
- package/dist-cjs/models/index.js +0 -1
- package/dist-cjs/models/models_0.js +0 -133
- package/dist-cjs/pagination/Interfaces.js +0 -1
- package/dist-cjs/pagination/ListSpeechSynthesisTasksPaginator.js +0 -11
- package/dist-cjs/pagination/index.js +5 -0
- package/dist-cjs/protocols/Aws_restJson1.js +0 -6
- package/dist-cjs/runtimeConfig.browser.js +1 -6
- package/dist-cjs/runtimeConfig.js +2 -7
- package/dist-cjs/runtimeConfig.native.js +0 -4
- package/dist-cjs/runtimeConfig.shared.js +0 -4
- package/dist-es/Polly.js +0 -1
- package/dist-es/PollyClient.js +0 -1
- package/dist-es/commands/DeleteLexiconCommand.js +0 -1
- package/dist-es/commands/DescribeVoicesCommand.js +0 -1
- package/dist-es/commands/GetLexiconCommand.js +0 -1
- package/dist-es/commands/GetSpeechSynthesisTaskCommand.js +0 -1
- package/dist-es/commands/ListLexiconsCommand.js +0 -1
- package/dist-es/commands/ListSpeechSynthesisTasksCommand.js +0 -1
- package/dist-es/commands/PutLexiconCommand.js +0 -1
- package/dist-es/commands/StartSpeechSynthesisTaskCommand.js +0 -1
- package/dist-es/commands/SynthesizeSpeechCommand.js +0 -1
- package/dist-es/commands/index.js +9 -0
- package/dist-es/endpoints.js +1 -2
- package/dist-es/index.js +4 -14
- package/dist-es/models/index.js +0 -1
- package/dist-es/models/models_0.js +0 -1
- package/dist-es/pagination/Interfaces.js +0 -1
- package/dist-es/pagination/ListSpeechSynthesisTasksPaginator.js +0 -1
- package/dist-es/pagination/index.js +2 -0
- package/dist-es/protocols/Aws_restJson1.js +0 -1
- package/dist-es/runtimeConfig.browser.js +1 -2
- package/dist-es/runtimeConfig.js +2 -3
- package/dist-es/runtimeConfig.native.js +0 -1
- package/dist-es/runtimeConfig.shared.js +0 -1
- package/dist-types/commands/index.d.ts +9 -0
- package/dist-types/index.d.ts +4 -13
- package/dist-types/pagination/index.d.ts +2 -0
- package/dist-types/ts3.4/Polly.d.ts +10 -80
- package/dist-types/ts3.4/PollyClient.d.ts +24 -94
- package/dist-types/ts3.4/commands/DeleteLexiconCommand.d.ts +2 -23
- package/dist-types/ts3.4/commands/DescribeVoicesCommand.d.ts +2 -38
- package/dist-types/ts3.4/commands/GetLexiconCommand.d.ts +2 -21
- package/dist-types/ts3.4/commands/GetSpeechSynthesisTaskCommand.d.ts +2 -23
- package/dist-types/ts3.4/commands/ListLexiconsCommand.d.ts +2 -20
- package/dist-types/ts3.4/commands/ListSpeechSynthesisTasksCommand.d.ts +2 -22
- package/dist-types/ts3.4/commands/PutLexiconCommand.d.ts +2 -25
- package/dist-types/ts3.4/commands/StartSpeechSynthesisTaskCommand.d.ts +2 -29
- package/dist-types/ts3.4/commands/SynthesizeSpeechCommand.d.ts +2 -24
- package/dist-types/ts3.4/commands/index.d.ts +9 -0
- package/dist-types/ts3.4/index.d.ts +4 -13
- package/dist-types/ts3.4/models/models_0.d.ts +150 -642
- package/dist-types/ts3.4/pagination/index.d.ts +2 -0
- package/dist-types/ts3.4/runtimeConfig.browser.d.ts +1 -3
- package/dist-types/ts3.4/runtimeConfig.d.ts +1 -3
- package/dist-types/ts3.4/runtimeConfig.native.d.ts +1 -3
- package/dist-types/ts3.4/runtimeConfig.shared.d.ts +1 -3
- package/package.json +33 -30
- package/dist-cjs/Polly.js.map +0 -1
- package/dist-cjs/PollyClient.js.map +0 -1
- package/dist-cjs/commands/DeleteLexiconCommand.js.map +0 -1
- package/dist-cjs/commands/DescribeVoicesCommand.js.map +0 -1
- package/dist-cjs/commands/GetLexiconCommand.js.map +0 -1
- package/dist-cjs/commands/GetSpeechSynthesisTaskCommand.js.map +0 -1
- package/dist-cjs/commands/ListLexiconsCommand.js.map +0 -1
- package/dist-cjs/commands/ListSpeechSynthesisTasksCommand.js.map +0 -1
- package/dist-cjs/commands/PutLexiconCommand.js.map +0 -1
- package/dist-cjs/commands/StartSpeechSynthesisTaskCommand.js.map +0 -1
- package/dist-cjs/commands/SynthesizeSpeechCommand.js.map +0 -1
- package/dist-cjs/endpoints.js.map +0 -1
- package/dist-cjs/index.js.map +0 -1
- package/dist-cjs/models/index.js.map +0 -1
- package/dist-cjs/models/models_0.js.map +0 -1
- package/dist-cjs/pagination/Interfaces.js.map +0 -1
- package/dist-cjs/pagination/ListSpeechSynthesisTasksPaginator.js.map +0 -1
- package/dist-cjs/protocols/Aws_restJson1.js.map +0 -1
- package/dist-cjs/runtimeConfig.browser.js.map +0 -1
- package/dist-cjs/runtimeConfig.js.map +0 -1
- package/dist-cjs/runtimeConfig.native.js.map +0 -1
- package/dist-cjs/runtimeConfig.shared.js.map +0 -1
- package/dist-es/Polly.js.map +0 -1
- package/dist-es/PollyClient.js.map +0 -1
- package/dist-es/commands/DeleteLexiconCommand.js.map +0 -1
- package/dist-es/commands/DescribeVoicesCommand.js.map +0 -1
- package/dist-es/commands/GetLexiconCommand.js.map +0 -1
- package/dist-es/commands/GetSpeechSynthesisTaskCommand.js.map +0 -1
- package/dist-es/commands/ListLexiconsCommand.js.map +0 -1
- package/dist-es/commands/ListSpeechSynthesisTasksCommand.js.map +0 -1
- package/dist-es/commands/PutLexiconCommand.js.map +0 -1
- package/dist-es/commands/StartSpeechSynthesisTaskCommand.js.map +0 -1
- package/dist-es/commands/SynthesizeSpeechCommand.js.map +0 -1
- package/dist-es/endpoints.js.map +0 -1
- package/dist-es/index.js.map +0 -1
- package/dist-es/models/index.js.map +0 -1
- package/dist-es/models/models_0.js.map +0 -1
- package/dist-es/pagination/Interfaces.js.map +0 -1
- package/dist-es/pagination/ListSpeechSynthesisTasksPaginator.js.map +0 -1
- package/dist-es/protocols/Aws_restJson1.js.map +0 -1
- package/dist-es/runtimeConfig.browser.js.map +0 -1
- package/dist-es/runtimeConfig.js.map +0 -1
- package/dist-es/runtimeConfig.native.js.map +0 -1
- package/dist-es/runtimeConfig.shared.js.map +0 -1
- package/jest.config.js +0 -4
- package/src/Polly.ts +0 -368
- package/src/PollyClient.ts +0 -277
- package/src/commands/DeleteLexiconCommand.ts +0 -98
- package/src/commands/DescribeVoicesCommand.ts +0 -113
- package/src/commands/GetLexiconCommand.ts +0 -96
- package/src/commands/GetSpeechSynthesisTaskCommand.ts +0 -98
- package/src/commands/ListLexiconsCommand.ts +0 -95
- package/src/commands/ListSpeechSynthesisTasksCommand.ts +0 -97
- package/src/commands/PutLexiconCommand.ts +0 -100
- package/src/commands/StartSpeechSynthesisTaskCommand.ts +0 -104
- package/src/commands/SynthesizeSpeechCommand.ts +0 -99
- package/src/endpoints.ts +0 -82
- package/src/index.ts +0 -14
- package/src/models/index.ts +0 -1
- package/src/models/models_0.ts +0 -1374
- package/src/pagination/Interfaces.ts +0 -8
- package/src/pagination/ListSpeechSynthesisTasksPaginator.ts +0 -59
- package/src/protocols/Aws_restJson1.ts +0 -1712
- package/src/runtimeConfig.browser.ts +0 -41
- package/src/runtimeConfig.native.ts +0 -17
- package/src/runtimeConfig.shared.ts +0 -17
- package/src/runtimeConfig.ts +0 -46
- package/tsconfig.es.json +0 -10
- package/tsconfig.json +0 -33
- package/tsconfig.types.json +0 -9
|
@@ -1,95 +0,0 @@
|
|
|
1
|
-
import { getSerdePlugin } from "@aws-sdk/middleware-serde";
|
|
2
|
-
import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
|
|
3
|
-
import { Command as $Command } from "@aws-sdk/smithy-client";
|
|
4
|
-
import {
|
|
5
|
-
FinalizeHandlerArguments,
|
|
6
|
-
Handler,
|
|
7
|
-
HandlerExecutionContext,
|
|
8
|
-
HttpHandlerOptions as __HttpHandlerOptions,
|
|
9
|
-
MetadataBearer as __MetadataBearer,
|
|
10
|
-
MiddlewareStack,
|
|
11
|
-
SerdeContext as __SerdeContext,
|
|
12
|
-
} from "@aws-sdk/types";
|
|
13
|
-
|
|
14
|
-
import { ListLexiconsInput, ListLexiconsOutput } from "../models/models_0";
|
|
15
|
-
import { PollyClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../PollyClient";
|
|
16
|
-
import {
|
|
17
|
-
deserializeAws_restJson1ListLexiconsCommand,
|
|
18
|
-
serializeAws_restJson1ListLexiconsCommand,
|
|
19
|
-
} from "../protocols/Aws_restJson1";
|
|
20
|
-
|
|
21
|
-
export interface ListLexiconsCommandInput extends ListLexiconsInput {}
|
|
22
|
-
export interface ListLexiconsCommandOutput extends ListLexiconsOutput, __MetadataBearer {}
|
|
23
|
-
|
|
24
|
-
/**
|
|
25
|
-
* <p>Returns a list of pronunciation lexicons stored in an Amazon Web Services Region. For more information, see <a href="https://docs.aws.amazon.com/polly/latest/dg/managing-lexicons.html">Managing Lexicons</a>.</p>
|
|
26
|
-
* @example
|
|
27
|
-
* Use a bare-bones client and the command you need to make an API call.
|
|
28
|
-
* ```javascript
|
|
29
|
-
* import { PollyClient, ListLexiconsCommand } from "@aws-sdk/client-polly"; // ES Modules import
|
|
30
|
-
* // const { PollyClient, ListLexiconsCommand } = require("@aws-sdk/client-polly"); // CommonJS import
|
|
31
|
-
* const client = new PollyClient(config);
|
|
32
|
-
* const command = new ListLexiconsCommand(input);
|
|
33
|
-
* const response = await client.send(command);
|
|
34
|
-
* ```
|
|
35
|
-
*
|
|
36
|
-
* @see {@link ListLexiconsCommandInput} for command's `input` shape.
|
|
37
|
-
* @see {@link ListLexiconsCommandOutput} for command's `response` shape.
|
|
38
|
-
* @see {@link PollyClientResolvedConfig | config} for command's `input` shape.
|
|
39
|
-
*
|
|
40
|
-
*/
|
|
41
|
-
export class ListLexiconsCommand extends $Command<
|
|
42
|
-
ListLexiconsCommandInput,
|
|
43
|
-
ListLexiconsCommandOutput,
|
|
44
|
-
PollyClientResolvedConfig
|
|
45
|
-
> {
|
|
46
|
-
// Start section: command_properties
|
|
47
|
-
// End section: command_properties
|
|
48
|
-
|
|
49
|
-
constructor(readonly input: ListLexiconsCommandInput) {
|
|
50
|
-
// Start section: command_constructor
|
|
51
|
-
super();
|
|
52
|
-
// End section: command_constructor
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
/**
|
|
56
|
-
* @internal
|
|
57
|
-
*/
|
|
58
|
-
resolveMiddleware(
|
|
59
|
-
clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>,
|
|
60
|
-
configuration: PollyClientResolvedConfig,
|
|
61
|
-
options?: __HttpHandlerOptions
|
|
62
|
-
): Handler<ListLexiconsCommandInput, ListLexiconsCommandOutput> {
|
|
63
|
-
this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
|
|
64
|
-
|
|
65
|
-
const stack = clientStack.concat(this.middlewareStack);
|
|
66
|
-
|
|
67
|
-
const { logger } = configuration;
|
|
68
|
-
const clientName = "PollyClient";
|
|
69
|
-
const commandName = "ListLexiconsCommand";
|
|
70
|
-
const handlerExecutionContext: HandlerExecutionContext = {
|
|
71
|
-
logger,
|
|
72
|
-
clientName,
|
|
73
|
-
commandName,
|
|
74
|
-
inputFilterSensitiveLog: ListLexiconsInput.filterSensitiveLog,
|
|
75
|
-
outputFilterSensitiveLog: ListLexiconsOutput.filterSensitiveLog,
|
|
76
|
-
};
|
|
77
|
-
const { requestHandler } = configuration;
|
|
78
|
-
return stack.resolve(
|
|
79
|
-
(request: FinalizeHandlerArguments<any>) =>
|
|
80
|
-
requestHandler.handle(request.request as __HttpRequest, options || {}),
|
|
81
|
-
handlerExecutionContext
|
|
82
|
-
);
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
private serialize(input: ListLexiconsCommandInput, context: __SerdeContext): Promise<__HttpRequest> {
|
|
86
|
-
return serializeAws_restJson1ListLexiconsCommand(input, context);
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
private deserialize(output: __HttpResponse, context: __SerdeContext): Promise<ListLexiconsCommandOutput> {
|
|
90
|
-
return deserializeAws_restJson1ListLexiconsCommand(output, context);
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
// Start section: command_body_extra
|
|
94
|
-
// End section: command_body_extra
|
|
95
|
-
}
|
|
@@ -1,97 +0,0 @@
|
|
|
1
|
-
import { getSerdePlugin } from "@aws-sdk/middleware-serde";
|
|
2
|
-
import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
|
|
3
|
-
import { Command as $Command } from "@aws-sdk/smithy-client";
|
|
4
|
-
import {
|
|
5
|
-
FinalizeHandlerArguments,
|
|
6
|
-
Handler,
|
|
7
|
-
HandlerExecutionContext,
|
|
8
|
-
HttpHandlerOptions as __HttpHandlerOptions,
|
|
9
|
-
MetadataBearer as __MetadataBearer,
|
|
10
|
-
MiddlewareStack,
|
|
11
|
-
SerdeContext as __SerdeContext,
|
|
12
|
-
} from "@aws-sdk/types";
|
|
13
|
-
|
|
14
|
-
import { ListSpeechSynthesisTasksInput, ListSpeechSynthesisTasksOutput } from "../models/models_0";
|
|
15
|
-
import { PollyClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../PollyClient";
|
|
16
|
-
import {
|
|
17
|
-
deserializeAws_restJson1ListSpeechSynthesisTasksCommand,
|
|
18
|
-
serializeAws_restJson1ListSpeechSynthesisTasksCommand,
|
|
19
|
-
} from "../protocols/Aws_restJson1";
|
|
20
|
-
|
|
21
|
-
export interface ListSpeechSynthesisTasksCommandInput extends ListSpeechSynthesisTasksInput {}
|
|
22
|
-
export interface ListSpeechSynthesisTasksCommandOutput extends ListSpeechSynthesisTasksOutput, __MetadataBearer {}
|
|
23
|
-
|
|
24
|
-
/**
|
|
25
|
-
* <p>Returns a list of SpeechSynthesisTask objects ordered by their
|
|
26
|
-
* creation date. This operation can filter the tasks by their status, for
|
|
27
|
-
* example, allowing users to list only tasks that are completed.</p>
|
|
28
|
-
* @example
|
|
29
|
-
* Use a bare-bones client and the command you need to make an API call.
|
|
30
|
-
* ```javascript
|
|
31
|
-
* import { PollyClient, ListSpeechSynthesisTasksCommand } from "@aws-sdk/client-polly"; // ES Modules import
|
|
32
|
-
* // const { PollyClient, ListSpeechSynthesisTasksCommand } = require("@aws-sdk/client-polly"); // CommonJS import
|
|
33
|
-
* const client = new PollyClient(config);
|
|
34
|
-
* const command = new ListSpeechSynthesisTasksCommand(input);
|
|
35
|
-
* const response = await client.send(command);
|
|
36
|
-
* ```
|
|
37
|
-
*
|
|
38
|
-
* @see {@link ListSpeechSynthesisTasksCommandInput} for command's `input` shape.
|
|
39
|
-
* @see {@link ListSpeechSynthesisTasksCommandOutput} for command's `response` shape.
|
|
40
|
-
* @see {@link PollyClientResolvedConfig | config} for command's `input` shape.
|
|
41
|
-
*
|
|
42
|
-
*/
|
|
43
|
-
export class ListSpeechSynthesisTasksCommand extends $Command<
|
|
44
|
-
ListSpeechSynthesisTasksCommandInput,
|
|
45
|
-
ListSpeechSynthesisTasksCommandOutput,
|
|
46
|
-
PollyClientResolvedConfig
|
|
47
|
-
> {
|
|
48
|
-
// Start section: command_properties
|
|
49
|
-
// End section: command_properties
|
|
50
|
-
|
|
51
|
-
constructor(readonly input: ListSpeechSynthesisTasksCommandInput) {
|
|
52
|
-
// Start section: command_constructor
|
|
53
|
-
super();
|
|
54
|
-
// End section: command_constructor
|
|
55
|
-
}
|
|
56
|
-
|
|
57
|
-
/**
|
|
58
|
-
* @internal
|
|
59
|
-
*/
|
|
60
|
-
resolveMiddleware(
|
|
61
|
-
clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>,
|
|
62
|
-
configuration: PollyClientResolvedConfig,
|
|
63
|
-
options?: __HttpHandlerOptions
|
|
64
|
-
): Handler<ListSpeechSynthesisTasksCommandInput, ListSpeechSynthesisTasksCommandOutput> {
|
|
65
|
-
this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
|
|
66
|
-
|
|
67
|
-
const stack = clientStack.concat(this.middlewareStack);
|
|
68
|
-
|
|
69
|
-
const { logger } = configuration;
|
|
70
|
-
const clientName = "PollyClient";
|
|
71
|
-
const commandName = "ListSpeechSynthesisTasksCommand";
|
|
72
|
-
const handlerExecutionContext: HandlerExecutionContext = {
|
|
73
|
-
logger,
|
|
74
|
-
clientName,
|
|
75
|
-
commandName,
|
|
76
|
-
inputFilterSensitiveLog: ListSpeechSynthesisTasksInput.filterSensitiveLog,
|
|
77
|
-
outputFilterSensitiveLog: ListSpeechSynthesisTasksOutput.filterSensitiveLog,
|
|
78
|
-
};
|
|
79
|
-
const { requestHandler } = configuration;
|
|
80
|
-
return stack.resolve(
|
|
81
|
-
(request: FinalizeHandlerArguments<any>) =>
|
|
82
|
-
requestHandler.handle(request.request as __HttpRequest, options || {}),
|
|
83
|
-
handlerExecutionContext
|
|
84
|
-
);
|
|
85
|
-
}
|
|
86
|
-
|
|
87
|
-
private serialize(input: ListSpeechSynthesisTasksCommandInput, context: __SerdeContext): Promise<__HttpRequest> {
|
|
88
|
-
return serializeAws_restJson1ListSpeechSynthesisTasksCommand(input, context);
|
|
89
|
-
}
|
|
90
|
-
|
|
91
|
-
private deserialize(output: __HttpResponse, context: __SerdeContext): Promise<ListSpeechSynthesisTasksCommandOutput> {
|
|
92
|
-
return deserializeAws_restJson1ListSpeechSynthesisTasksCommand(output, context);
|
|
93
|
-
}
|
|
94
|
-
|
|
95
|
-
// Start section: command_body_extra
|
|
96
|
-
// End section: command_body_extra
|
|
97
|
-
}
|
|
@@ -1,100 +0,0 @@
|
|
|
1
|
-
import { getSerdePlugin } from "@aws-sdk/middleware-serde";
|
|
2
|
-
import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
|
|
3
|
-
import { Command as $Command } from "@aws-sdk/smithy-client";
|
|
4
|
-
import {
|
|
5
|
-
FinalizeHandlerArguments,
|
|
6
|
-
Handler,
|
|
7
|
-
HandlerExecutionContext,
|
|
8
|
-
HttpHandlerOptions as __HttpHandlerOptions,
|
|
9
|
-
MetadataBearer as __MetadataBearer,
|
|
10
|
-
MiddlewareStack,
|
|
11
|
-
SerdeContext as __SerdeContext,
|
|
12
|
-
} from "@aws-sdk/types";
|
|
13
|
-
|
|
14
|
-
import { PutLexiconInput, PutLexiconOutput } from "../models/models_0";
|
|
15
|
-
import { PollyClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../PollyClient";
|
|
16
|
-
import {
|
|
17
|
-
deserializeAws_restJson1PutLexiconCommand,
|
|
18
|
-
serializeAws_restJson1PutLexiconCommand,
|
|
19
|
-
} from "../protocols/Aws_restJson1";
|
|
20
|
-
|
|
21
|
-
export interface PutLexiconCommandInput extends PutLexiconInput {}
|
|
22
|
-
export interface PutLexiconCommandOutput extends PutLexiconOutput, __MetadataBearer {}
|
|
23
|
-
|
|
24
|
-
/**
|
|
25
|
-
* <p>Stores a pronunciation lexicon in an Amazon Web Services Region. If
|
|
26
|
-
* a lexicon with the same name already exists in the region, it is
|
|
27
|
-
* overwritten by the new lexicon. Lexicon operations have eventual
|
|
28
|
-
* consistency, therefore, it might take some time before the lexicon is
|
|
29
|
-
* available to the SynthesizeSpeech operation.</p>
|
|
30
|
-
* <p>For more information, see <a href="https://docs.aws.amazon.com/polly/latest/dg/managing-lexicons.html">Managing Lexicons</a>.</p>
|
|
31
|
-
* @example
|
|
32
|
-
* Use a bare-bones client and the command you need to make an API call.
|
|
33
|
-
* ```javascript
|
|
34
|
-
* import { PollyClient, PutLexiconCommand } from "@aws-sdk/client-polly"; // ES Modules import
|
|
35
|
-
* // const { PollyClient, PutLexiconCommand } = require("@aws-sdk/client-polly"); // CommonJS import
|
|
36
|
-
* const client = new PollyClient(config);
|
|
37
|
-
* const command = new PutLexiconCommand(input);
|
|
38
|
-
* const response = await client.send(command);
|
|
39
|
-
* ```
|
|
40
|
-
*
|
|
41
|
-
* @see {@link PutLexiconCommandInput} for command's `input` shape.
|
|
42
|
-
* @see {@link PutLexiconCommandOutput} for command's `response` shape.
|
|
43
|
-
* @see {@link PollyClientResolvedConfig | config} for command's `input` shape.
|
|
44
|
-
*
|
|
45
|
-
*/
|
|
46
|
-
export class PutLexiconCommand extends $Command<
|
|
47
|
-
PutLexiconCommandInput,
|
|
48
|
-
PutLexiconCommandOutput,
|
|
49
|
-
PollyClientResolvedConfig
|
|
50
|
-
> {
|
|
51
|
-
// Start section: command_properties
|
|
52
|
-
// End section: command_properties
|
|
53
|
-
|
|
54
|
-
constructor(readonly input: PutLexiconCommandInput) {
|
|
55
|
-
// Start section: command_constructor
|
|
56
|
-
super();
|
|
57
|
-
// End section: command_constructor
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
/**
|
|
61
|
-
* @internal
|
|
62
|
-
*/
|
|
63
|
-
resolveMiddleware(
|
|
64
|
-
clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>,
|
|
65
|
-
configuration: PollyClientResolvedConfig,
|
|
66
|
-
options?: __HttpHandlerOptions
|
|
67
|
-
): Handler<PutLexiconCommandInput, PutLexiconCommandOutput> {
|
|
68
|
-
this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
|
|
69
|
-
|
|
70
|
-
const stack = clientStack.concat(this.middlewareStack);
|
|
71
|
-
|
|
72
|
-
const { logger } = configuration;
|
|
73
|
-
const clientName = "PollyClient";
|
|
74
|
-
const commandName = "PutLexiconCommand";
|
|
75
|
-
const handlerExecutionContext: HandlerExecutionContext = {
|
|
76
|
-
logger,
|
|
77
|
-
clientName,
|
|
78
|
-
commandName,
|
|
79
|
-
inputFilterSensitiveLog: PutLexiconInput.filterSensitiveLog,
|
|
80
|
-
outputFilterSensitiveLog: PutLexiconOutput.filterSensitiveLog,
|
|
81
|
-
};
|
|
82
|
-
const { requestHandler } = configuration;
|
|
83
|
-
return stack.resolve(
|
|
84
|
-
(request: FinalizeHandlerArguments<any>) =>
|
|
85
|
-
requestHandler.handle(request.request as __HttpRequest, options || {}),
|
|
86
|
-
handlerExecutionContext
|
|
87
|
-
);
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
private serialize(input: PutLexiconCommandInput, context: __SerdeContext): Promise<__HttpRequest> {
|
|
91
|
-
return serializeAws_restJson1PutLexiconCommand(input, context);
|
|
92
|
-
}
|
|
93
|
-
|
|
94
|
-
private deserialize(output: __HttpResponse, context: __SerdeContext): Promise<PutLexiconCommandOutput> {
|
|
95
|
-
return deserializeAws_restJson1PutLexiconCommand(output, context);
|
|
96
|
-
}
|
|
97
|
-
|
|
98
|
-
// Start section: command_body_extra
|
|
99
|
-
// End section: command_body_extra
|
|
100
|
-
}
|
|
@@ -1,104 +0,0 @@
|
|
|
1
|
-
import { getSerdePlugin } from "@aws-sdk/middleware-serde";
|
|
2
|
-
import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
|
|
3
|
-
import { Command as $Command } from "@aws-sdk/smithy-client";
|
|
4
|
-
import {
|
|
5
|
-
FinalizeHandlerArguments,
|
|
6
|
-
Handler,
|
|
7
|
-
HandlerExecutionContext,
|
|
8
|
-
HttpHandlerOptions as __HttpHandlerOptions,
|
|
9
|
-
MetadataBearer as __MetadataBearer,
|
|
10
|
-
MiddlewareStack,
|
|
11
|
-
SerdeContext as __SerdeContext,
|
|
12
|
-
} from "@aws-sdk/types";
|
|
13
|
-
|
|
14
|
-
import { StartSpeechSynthesisTaskInput, StartSpeechSynthesisTaskOutput } from "../models/models_0";
|
|
15
|
-
import { PollyClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../PollyClient";
|
|
16
|
-
import {
|
|
17
|
-
deserializeAws_restJson1StartSpeechSynthesisTaskCommand,
|
|
18
|
-
serializeAws_restJson1StartSpeechSynthesisTaskCommand,
|
|
19
|
-
} from "../protocols/Aws_restJson1";
|
|
20
|
-
|
|
21
|
-
export interface StartSpeechSynthesisTaskCommandInput extends StartSpeechSynthesisTaskInput {}
|
|
22
|
-
export interface StartSpeechSynthesisTaskCommandOutput extends StartSpeechSynthesisTaskOutput, __MetadataBearer {}
|
|
23
|
-
|
|
24
|
-
/**
|
|
25
|
-
* <p>Allows the creation of an asynchronous synthesis task, by starting a
|
|
26
|
-
* new <code>SpeechSynthesisTask</code>. This operation requires all the
|
|
27
|
-
* standard information needed for speech synthesis, plus the name of an
|
|
28
|
-
* Amazon S3 bucket for the service to store the output of the synthesis task
|
|
29
|
-
* and two optional parameters (<code>OutputS3KeyPrefix</code> and
|
|
30
|
-
* <code>SnsTopicArn</code>). Once the synthesis task is created, this
|
|
31
|
-
* operation will return a <code>SpeechSynthesisTask</code> object, which
|
|
32
|
-
* will include an identifier of this task as well as the current status. The
|
|
33
|
-
* <code>SpeechSynthesisTask</code> object is available for 72 hours after
|
|
34
|
-
* starting the asynchronous synthesis task.</p>
|
|
35
|
-
* @example
|
|
36
|
-
* Use a bare-bones client and the command you need to make an API call.
|
|
37
|
-
* ```javascript
|
|
38
|
-
* import { PollyClient, StartSpeechSynthesisTaskCommand } from "@aws-sdk/client-polly"; // ES Modules import
|
|
39
|
-
* // const { PollyClient, StartSpeechSynthesisTaskCommand } = require("@aws-sdk/client-polly"); // CommonJS import
|
|
40
|
-
* const client = new PollyClient(config);
|
|
41
|
-
* const command = new StartSpeechSynthesisTaskCommand(input);
|
|
42
|
-
* const response = await client.send(command);
|
|
43
|
-
* ```
|
|
44
|
-
*
|
|
45
|
-
* @see {@link StartSpeechSynthesisTaskCommandInput} for command's `input` shape.
|
|
46
|
-
* @see {@link StartSpeechSynthesisTaskCommandOutput} for command's `response` shape.
|
|
47
|
-
* @see {@link PollyClientResolvedConfig | config} for command's `input` shape.
|
|
48
|
-
*
|
|
49
|
-
*/
|
|
50
|
-
export class StartSpeechSynthesisTaskCommand extends $Command<
|
|
51
|
-
StartSpeechSynthesisTaskCommandInput,
|
|
52
|
-
StartSpeechSynthesisTaskCommandOutput,
|
|
53
|
-
PollyClientResolvedConfig
|
|
54
|
-
> {
|
|
55
|
-
// Start section: command_properties
|
|
56
|
-
// End section: command_properties
|
|
57
|
-
|
|
58
|
-
constructor(readonly input: StartSpeechSynthesisTaskCommandInput) {
|
|
59
|
-
// Start section: command_constructor
|
|
60
|
-
super();
|
|
61
|
-
// End section: command_constructor
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
/**
|
|
65
|
-
* @internal
|
|
66
|
-
*/
|
|
67
|
-
resolveMiddleware(
|
|
68
|
-
clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>,
|
|
69
|
-
configuration: PollyClientResolvedConfig,
|
|
70
|
-
options?: __HttpHandlerOptions
|
|
71
|
-
): Handler<StartSpeechSynthesisTaskCommandInput, StartSpeechSynthesisTaskCommandOutput> {
|
|
72
|
-
this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
|
|
73
|
-
|
|
74
|
-
const stack = clientStack.concat(this.middlewareStack);
|
|
75
|
-
|
|
76
|
-
const { logger } = configuration;
|
|
77
|
-
const clientName = "PollyClient";
|
|
78
|
-
const commandName = "StartSpeechSynthesisTaskCommand";
|
|
79
|
-
const handlerExecutionContext: HandlerExecutionContext = {
|
|
80
|
-
logger,
|
|
81
|
-
clientName,
|
|
82
|
-
commandName,
|
|
83
|
-
inputFilterSensitiveLog: StartSpeechSynthesisTaskInput.filterSensitiveLog,
|
|
84
|
-
outputFilterSensitiveLog: StartSpeechSynthesisTaskOutput.filterSensitiveLog,
|
|
85
|
-
};
|
|
86
|
-
const { requestHandler } = configuration;
|
|
87
|
-
return stack.resolve(
|
|
88
|
-
(request: FinalizeHandlerArguments<any>) =>
|
|
89
|
-
requestHandler.handle(request.request as __HttpRequest, options || {}),
|
|
90
|
-
handlerExecutionContext
|
|
91
|
-
);
|
|
92
|
-
}
|
|
93
|
-
|
|
94
|
-
private serialize(input: StartSpeechSynthesisTaskCommandInput, context: __SerdeContext): Promise<__HttpRequest> {
|
|
95
|
-
return serializeAws_restJson1StartSpeechSynthesisTaskCommand(input, context);
|
|
96
|
-
}
|
|
97
|
-
|
|
98
|
-
private deserialize(output: __HttpResponse, context: __SerdeContext): Promise<StartSpeechSynthesisTaskCommandOutput> {
|
|
99
|
-
return deserializeAws_restJson1StartSpeechSynthesisTaskCommand(output, context);
|
|
100
|
-
}
|
|
101
|
-
|
|
102
|
-
// Start section: command_body_extra
|
|
103
|
-
// End section: command_body_extra
|
|
104
|
-
}
|
|
@@ -1,99 +0,0 @@
|
|
|
1
|
-
import { getSerdePlugin } from "@aws-sdk/middleware-serde";
|
|
2
|
-
import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
|
|
3
|
-
import { Command as $Command } from "@aws-sdk/smithy-client";
|
|
4
|
-
import {
|
|
5
|
-
FinalizeHandlerArguments,
|
|
6
|
-
Handler,
|
|
7
|
-
HandlerExecutionContext,
|
|
8
|
-
HttpHandlerOptions as __HttpHandlerOptions,
|
|
9
|
-
MetadataBearer as __MetadataBearer,
|
|
10
|
-
MiddlewareStack,
|
|
11
|
-
SerdeContext as __SerdeContext,
|
|
12
|
-
} from "@aws-sdk/types";
|
|
13
|
-
|
|
14
|
-
import { SynthesizeSpeechInput, SynthesizeSpeechOutput } from "../models/models_0";
|
|
15
|
-
import { PollyClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../PollyClient";
|
|
16
|
-
import {
|
|
17
|
-
deserializeAws_restJson1SynthesizeSpeechCommand,
|
|
18
|
-
serializeAws_restJson1SynthesizeSpeechCommand,
|
|
19
|
-
} from "../protocols/Aws_restJson1";
|
|
20
|
-
|
|
21
|
-
export interface SynthesizeSpeechCommandInput extends SynthesizeSpeechInput {}
|
|
22
|
-
export interface SynthesizeSpeechCommandOutput extends SynthesizeSpeechOutput, __MetadataBearer {}
|
|
23
|
-
|
|
24
|
-
/**
|
|
25
|
-
* <p>Synthesizes UTF-8 input, plain text or SSML, to a stream of bytes.
|
|
26
|
-
* SSML input must be valid, well-formed SSML. Some alphabets might not be
|
|
27
|
-
* available with all the voices (for example, Cyrillic might not be read at
|
|
28
|
-
* all by English voices) unless phoneme mapping is used. For more
|
|
29
|
-
* information, see <a href="https://docs.aws.amazon.com/polly/latest/dg/how-text-to-speech-works.html">How it Works</a>.</p>
|
|
30
|
-
* @example
|
|
31
|
-
* Use a bare-bones client and the command you need to make an API call.
|
|
32
|
-
* ```javascript
|
|
33
|
-
* import { PollyClient, SynthesizeSpeechCommand } from "@aws-sdk/client-polly"; // ES Modules import
|
|
34
|
-
* // const { PollyClient, SynthesizeSpeechCommand } = require("@aws-sdk/client-polly"); // CommonJS import
|
|
35
|
-
* const client = new PollyClient(config);
|
|
36
|
-
* const command = new SynthesizeSpeechCommand(input);
|
|
37
|
-
* const response = await client.send(command);
|
|
38
|
-
* ```
|
|
39
|
-
*
|
|
40
|
-
* @see {@link SynthesizeSpeechCommandInput} for command's `input` shape.
|
|
41
|
-
* @see {@link SynthesizeSpeechCommandOutput} for command's `response` shape.
|
|
42
|
-
* @see {@link PollyClientResolvedConfig | config} for command's `input` shape.
|
|
43
|
-
*
|
|
44
|
-
*/
|
|
45
|
-
export class SynthesizeSpeechCommand extends $Command<
|
|
46
|
-
SynthesizeSpeechCommandInput,
|
|
47
|
-
SynthesizeSpeechCommandOutput,
|
|
48
|
-
PollyClientResolvedConfig
|
|
49
|
-
> {
|
|
50
|
-
// Start section: command_properties
|
|
51
|
-
// End section: command_properties
|
|
52
|
-
|
|
53
|
-
constructor(readonly input: SynthesizeSpeechCommandInput) {
|
|
54
|
-
// Start section: command_constructor
|
|
55
|
-
super();
|
|
56
|
-
// End section: command_constructor
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
/**
|
|
60
|
-
* @internal
|
|
61
|
-
*/
|
|
62
|
-
resolveMiddleware(
|
|
63
|
-
clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>,
|
|
64
|
-
configuration: PollyClientResolvedConfig,
|
|
65
|
-
options?: __HttpHandlerOptions
|
|
66
|
-
): Handler<SynthesizeSpeechCommandInput, SynthesizeSpeechCommandOutput> {
|
|
67
|
-
this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
|
|
68
|
-
|
|
69
|
-
const stack = clientStack.concat(this.middlewareStack);
|
|
70
|
-
|
|
71
|
-
const { logger } = configuration;
|
|
72
|
-
const clientName = "PollyClient";
|
|
73
|
-
const commandName = "SynthesizeSpeechCommand";
|
|
74
|
-
const handlerExecutionContext: HandlerExecutionContext = {
|
|
75
|
-
logger,
|
|
76
|
-
clientName,
|
|
77
|
-
commandName,
|
|
78
|
-
inputFilterSensitiveLog: SynthesizeSpeechInput.filterSensitiveLog,
|
|
79
|
-
outputFilterSensitiveLog: SynthesizeSpeechOutput.filterSensitiveLog,
|
|
80
|
-
};
|
|
81
|
-
const { requestHandler } = configuration;
|
|
82
|
-
return stack.resolve(
|
|
83
|
-
(request: FinalizeHandlerArguments<any>) =>
|
|
84
|
-
requestHandler.handle(request.request as __HttpRequest, options || {}),
|
|
85
|
-
handlerExecutionContext
|
|
86
|
-
);
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
private serialize(input: SynthesizeSpeechCommandInput, context: __SerdeContext): Promise<__HttpRequest> {
|
|
90
|
-
return serializeAws_restJson1SynthesizeSpeechCommand(input, context);
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
private deserialize(output: __HttpResponse, context: __SerdeContext): Promise<SynthesizeSpeechCommandOutput> {
|
|
94
|
-
return deserializeAws_restJson1SynthesizeSpeechCommand(output, context);
|
|
95
|
-
}
|
|
96
|
-
|
|
97
|
-
// Start section: command_body_extra
|
|
98
|
-
// End section: command_body_extra
|
|
99
|
-
}
|
package/src/endpoints.ts
DELETED
|
@@ -1,82 +0,0 @@
|
|
|
1
|
-
import { getRegionInfo, PartitionHash, RegionHash } from "@aws-sdk/config-resolver";
|
|
2
|
-
import { RegionInfoProvider } from "@aws-sdk/types";
|
|
3
|
-
|
|
4
|
-
const regionHash: RegionHash = {
|
|
5
|
-
"fips-us-east-1": {
|
|
6
|
-
hostname: "polly-fips.us-east-1.amazonaws.com",
|
|
7
|
-
signingRegion: "us-east-1",
|
|
8
|
-
},
|
|
9
|
-
"fips-us-east-2": {
|
|
10
|
-
hostname: "polly-fips.us-east-2.amazonaws.com",
|
|
11
|
-
signingRegion: "us-east-2",
|
|
12
|
-
},
|
|
13
|
-
"fips-us-gov-west-1": {
|
|
14
|
-
hostname: "polly-fips.us-gov-west-1.amazonaws.com",
|
|
15
|
-
signingRegion: "us-gov-west-1",
|
|
16
|
-
},
|
|
17
|
-
"fips-us-west-1": {
|
|
18
|
-
hostname: "polly-fips.us-west-1.amazonaws.com",
|
|
19
|
-
signingRegion: "us-west-1",
|
|
20
|
-
},
|
|
21
|
-
"fips-us-west-2": {
|
|
22
|
-
hostname: "polly-fips.us-west-2.amazonaws.com",
|
|
23
|
-
signingRegion: "us-west-2",
|
|
24
|
-
},
|
|
25
|
-
};
|
|
26
|
-
|
|
27
|
-
const partitionHash: PartitionHash = {
|
|
28
|
-
aws: {
|
|
29
|
-
regions: [
|
|
30
|
-
"af-south-1",
|
|
31
|
-
"ap-east-1",
|
|
32
|
-
"ap-northeast-1",
|
|
33
|
-
"ap-northeast-2",
|
|
34
|
-
"ap-northeast-3",
|
|
35
|
-
"ap-south-1",
|
|
36
|
-
"ap-southeast-1",
|
|
37
|
-
"ap-southeast-2",
|
|
38
|
-
"ca-central-1",
|
|
39
|
-
"eu-central-1",
|
|
40
|
-
"eu-north-1",
|
|
41
|
-
"eu-south-1",
|
|
42
|
-
"eu-west-1",
|
|
43
|
-
"eu-west-2",
|
|
44
|
-
"eu-west-3",
|
|
45
|
-
"fips-us-east-1",
|
|
46
|
-
"fips-us-east-2",
|
|
47
|
-
"fips-us-west-1",
|
|
48
|
-
"fips-us-west-2",
|
|
49
|
-
"me-south-1",
|
|
50
|
-
"sa-east-1",
|
|
51
|
-
"us-east-1",
|
|
52
|
-
"us-east-2",
|
|
53
|
-
"us-west-1",
|
|
54
|
-
"us-west-2",
|
|
55
|
-
],
|
|
56
|
-
hostname: "polly.{region}.amazonaws.com",
|
|
57
|
-
},
|
|
58
|
-
"aws-cn": {
|
|
59
|
-
regions: ["cn-north-1", "cn-northwest-1"],
|
|
60
|
-
hostname: "polly.{region}.amazonaws.com.cn",
|
|
61
|
-
},
|
|
62
|
-
"aws-iso": {
|
|
63
|
-
regions: ["us-iso-east-1"],
|
|
64
|
-
hostname: "polly.{region}.c2s.ic.gov",
|
|
65
|
-
},
|
|
66
|
-
"aws-iso-b": {
|
|
67
|
-
regions: ["us-isob-east-1"],
|
|
68
|
-
hostname: "polly.{region}.sc2s.sgov.gov",
|
|
69
|
-
},
|
|
70
|
-
"aws-us-gov": {
|
|
71
|
-
regions: ["fips-us-gov-west-1", "us-gov-east-1", "us-gov-west-1"],
|
|
72
|
-
hostname: "polly.{region}.amazonaws.com",
|
|
73
|
-
},
|
|
74
|
-
};
|
|
75
|
-
|
|
76
|
-
export const defaultRegionInfoProvider: RegionInfoProvider = async (region: string, options?: any) =>
|
|
77
|
-
getRegionInfo(region, {
|
|
78
|
-
...options,
|
|
79
|
-
signingService: "polly",
|
|
80
|
-
regionHash,
|
|
81
|
-
partitionHash,
|
|
82
|
-
});
|
package/src/index.ts
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
export * from "./PollyClient";
|
|
2
|
-
export * from "./Polly";
|
|
3
|
-
export * from "./commands/DeleteLexiconCommand";
|
|
4
|
-
export * from "./commands/DescribeVoicesCommand";
|
|
5
|
-
export * from "./commands/GetLexiconCommand";
|
|
6
|
-
export * from "./commands/GetSpeechSynthesisTaskCommand";
|
|
7
|
-
export * from "./commands/ListLexiconsCommand";
|
|
8
|
-
export * from "./commands/ListSpeechSynthesisTasksCommand";
|
|
9
|
-
export * from "./pagination/ListSpeechSynthesisTasksPaginator";
|
|
10
|
-
export * from "./commands/PutLexiconCommand";
|
|
11
|
-
export * from "./commands/StartSpeechSynthesisTaskCommand";
|
|
12
|
-
export * from "./commands/SynthesizeSpeechCommand";
|
|
13
|
-
export * from "./pagination/Interfaces";
|
|
14
|
-
export * from "./models/index";
|
package/src/models/index.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from "./models_0";
|