@aws-sdk/client-textract 3.36.0 → 3.39.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 (59) hide show
  1. package/CHANGELOG.md +45 -0
  2. package/dist-cjs/Textract.js +30 -5
  3. package/dist-cjs/TextractClient.js +0 -10
  4. package/dist-cjs/commands/AnalyzeDocumentCommand.js +0 -54
  5. package/dist-cjs/commands/AnalyzeExpenseCommand.js +0 -37
  6. package/dist-cjs/commands/DetectDocumentTextCommand.js +0 -34
  7. package/dist-cjs/commands/GetDocumentAnalysisCommand.js +0 -68
  8. package/dist-cjs/commands/GetDocumentTextDetectionCommand.js +0 -48
  9. package/dist-cjs/commands/GetExpenseAnalysisCommand.js +36 -0
  10. package/dist-cjs/commands/StartDocumentAnalysisCommand.js +0 -41
  11. package/dist-cjs/commands/StartDocumentTextDetectionCommand.js +0 -40
  12. package/dist-cjs/commands/StartExpenseAnalysisCommand.js +36 -0
  13. package/dist-cjs/commands/index.js +12 -0
  14. package/dist-cjs/endpoints.js +42 -3
  15. package/dist-cjs/index.js +3 -9
  16. package/dist-cjs/models/models_0.js +26 -149
  17. package/dist-cjs/protocols/Aws_json1_1.js +306 -6
  18. package/dist-cjs/runtimeConfig.browser.js +1 -5
  19. package/dist-cjs/runtimeConfig.js +1 -5
  20. package/dist-cjs/runtimeConfig.native.js +0 -3
  21. package/dist-cjs/runtimeConfig.shared.js +0 -3
  22. package/dist-es/Textract.js +30 -0
  23. package/dist-es/commands/GetExpenseAnalysisCommand.js +39 -0
  24. package/dist-es/commands/StartExpenseAnalysisCommand.js +39 -0
  25. package/dist-es/commands/index.js +9 -0
  26. package/dist-es/endpoints.js +42 -3
  27. package/dist-es/index.js +3 -9
  28. package/dist-es/models/models_0.js +16 -0
  29. package/dist-es/protocols/Aws_json1_1.js +314 -0
  30. package/dist-types/Textract.d.ts +47 -2
  31. package/dist-types/TextractClient.d.ts +4 -2
  32. package/dist-types/commands/GetExpenseAnalysisCommand.d.ts +51 -0
  33. package/dist-types/commands/StartDocumentAnalysisCommand.d.ts +1 -1
  34. package/dist-types/commands/StartDocumentTextDetectionCommand.d.ts +1 -1
  35. package/dist-types/commands/StartExpenseAnalysisCommand.d.ts +50 -0
  36. package/dist-types/commands/index.d.ts +9 -0
  37. package/dist-types/index.d.ts +3 -9
  38. package/dist-types/models/models_0.d.ts +123 -2
  39. package/dist-types/protocols/Aws_json1_1.d.ts +6 -0
  40. package/dist-types/ts3.4/Textract.d.ts +18 -180
  41. package/dist-types/ts3.4/TextractClient.d.ts +28 -93
  42. package/dist-types/ts3.4/commands/AnalyzeDocumentCommand.d.ts +2 -50
  43. package/dist-types/ts3.4/commands/AnalyzeExpenseCommand.d.ts +2 -33
  44. package/dist-types/ts3.4/commands/DetectDocumentTextCommand.d.ts +2 -30
  45. package/dist-types/ts3.4/commands/GetDocumentAnalysisCommand.d.ts +2 -64
  46. package/dist-types/ts3.4/commands/GetDocumentTextDetectionCommand.d.ts +2 -44
  47. package/dist-types/ts3.4/commands/GetExpenseAnalysisCommand.d.ts +17 -0
  48. package/dist-types/ts3.4/commands/StartDocumentAnalysisCommand.d.ts +2 -37
  49. package/dist-types/ts3.4/commands/StartDocumentTextDetectionCommand.d.ts +2 -36
  50. package/dist-types/ts3.4/commands/StartExpenseAnalysisCommand.d.ts +17 -0
  51. package/dist-types/ts3.4/commands/index.d.ts +9 -0
  52. package/dist-types/ts3.4/index.d.ts +3 -9
  53. package/dist-types/ts3.4/models/models_0.d.ts +253 -893
  54. package/dist-types/ts3.4/protocols/Aws_json1_1.d.ts +6 -0
  55. package/dist-types/ts3.4/runtimeConfig.browser.d.ts +1 -3
  56. package/dist-types/ts3.4/runtimeConfig.d.ts +1 -3
  57. package/dist-types/ts3.4/runtimeConfig.native.d.ts +1 -3
  58. package/dist-types/ts3.4/runtimeConfig.shared.d.ts +1 -3
  59. package/package.json +32 -32
@@ -11,131 +11,66 @@ import { AnalyzeExpenseCommandInput, AnalyzeExpenseCommandOutput } from "./comma
11
11
  import { DetectDocumentTextCommandInput, DetectDocumentTextCommandOutput } from "./commands/DetectDocumentTextCommand";
12
12
  import { GetDocumentAnalysisCommandInput, GetDocumentAnalysisCommandOutput } from "./commands/GetDocumentAnalysisCommand";
13
13
  import { GetDocumentTextDetectionCommandInput, GetDocumentTextDetectionCommandOutput } from "./commands/GetDocumentTextDetectionCommand";
14
+ import { GetExpenseAnalysisCommandInput, GetExpenseAnalysisCommandOutput } from "./commands/GetExpenseAnalysisCommand";
14
15
  import { StartDocumentAnalysisCommandInput, StartDocumentAnalysisCommandOutput } from "./commands/StartDocumentAnalysisCommand";
15
16
  import { StartDocumentTextDetectionCommandInput, StartDocumentTextDetectionCommandOutput } from "./commands/StartDocumentTextDetectionCommand";
16
- export declare type ServiceInputTypes = AnalyzeDocumentCommandInput | AnalyzeExpenseCommandInput | DetectDocumentTextCommandInput | GetDocumentAnalysisCommandInput | GetDocumentTextDetectionCommandInput | StartDocumentAnalysisCommandInput | StartDocumentTextDetectionCommandInput;
17
- export declare type ServiceOutputTypes = AnalyzeDocumentCommandOutput | AnalyzeExpenseCommandOutput | DetectDocumentTextCommandOutput | GetDocumentAnalysisCommandOutput | GetDocumentTextDetectionCommandOutput | StartDocumentAnalysisCommandOutput | StartDocumentTextDetectionCommandOutput;
17
+ import { StartExpenseAnalysisCommandInput, StartExpenseAnalysisCommandOutput } from "./commands/StartExpenseAnalysisCommand";
18
+ export declare type ServiceInputTypes = AnalyzeDocumentCommandInput | AnalyzeExpenseCommandInput | DetectDocumentTextCommandInput | GetDocumentAnalysisCommandInput | GetDocumentTextDetectionCommandInput | GetExpenseAnalysisCommandInput | StartDocumentAnalysisCommandInput | StartDocumentTextDetectionCommandInput | StartExpenseAnalysisCommandInput;
19
+ export declare type ServiceOutputTypes = AnalyzeDocumentCommandOutput | AnalyzeExpenseCommandOutput | DetectDocumentTextCommandOutput | GetDocumentAnalysisCommandOutput | GetDocumentTextDetectionCommandOutput | GetExpenseAnalysisCommandOutput | StartDocumentAnalysisCommandOutput | StartDocumentTextDetectionCommandOutput | StartExpenseAnalysisCommandOutput;
18
20
  export interface ClientDefaults extends Partial<__SmithyResolvedConfiguration<__HttpHandlerOptions>> {
19
- /**
20
- * The HTTP handler to use. Fetch in browser and Https in Nodejs.
21
- */
21
+
22
22
  requestHandler?: __HttpHandler;
23
- /**
24
- * A constructor for a class implementing the {@link __Hash} interface
25
- * that computes the SHA-256 HMAC or checksum of a string or binary buffer.
26
- * @internal
27
- */
23
+
28
24
  sha256?: __HashConstructor;
29
- /**
30
- * The function that will be used to convert strings into HTTP endpoints.
31
- * @internal
32
- */
25
+
33
26
  urlParser?: __UrlParser;
34
- /**
35
- * A function that can calculate the length of a request body.
36
- * @internal
37
- */
27
+
38
28
  bodyLengthChecker?: (body: any) => number | undefined;
39
- /**
40
- * A function that converts a stream into an array of bytes.
41
- * @internal
42
- */
29
+
43
30
  streamCollector?: __StreamCollector;
44
- /**
45
- * The function that will be used to convert a base64-encoded string to a byte array.
46
- * @internal
47
- */
31
+
48
32
  base64Decoder?: __Decoder;
49
- /**
50
- * The function that will be used to convert binary data to a base64-encoded string.
51
- * @internal
52
- */
33
+
53
34
  base64Encoder?: __Encoder;
54
- /**
55
- * The function that will be used to convert a UTF8-encoded string to a byte array.
56
- * @internal
57
- */
35
+
58
36
  utf8Decoder?: __Decoder;
59
- /**
60
- * The function that will be used to convert binary data to a UTF-8 encoded string.
61
- * @internal
62
- */
37
+
63
38
  utf8Encoder?: __Encoder;
64
- /**
65
- * The runtime environment.
66
- * @internal
67
- */
39
+
68
40
  runtime?: string;
69
- /**
70
- * Disable dyanamically changing the endpoint of the client based on the hostPrefix
71
- * trait of an operation.
72
- */
41
+
73
42
  disableHostPrefix?: boolean;
74
- /**
75
- * Value for how many times a request will be made at most in case of retry.
76
- */
43
+
77
44
  maxAttempts?: number | __Provider<number>;
78
- /**
79
- * Specifies which retry algorithm to use.
80
- */
45
+
81
46
  retryMode?: string | __Provider<string>;
82
- /**
83
- * Optional logger for logging debug/info/warn/error.
84
- */
47
+
85
48
  logger?: __Logger;
86
- /**
87
- * Unique service identifier.
88
- * @internal
89
- */
49
+
90
50
  serviceId?: string;
91
- /**
92
- * The AWS region to which this client will send requests
93
- */
51
+
94
52
  region?: string | __Provider<string>;
95
- /**
96
- * Default credentials provider; Not available in browser runtime.
97
- * @internal
98
- */
53
+
99
54
  credentialDefaultProvider?: (input: any) => __Provider<__Credentials>;
100
- /**
101
- * Fetch related hostname, signing name or signing region with given region.
102
- * @internal
103
- */
55
+
104
56
  regionInfoProvider?: RegionInfoProvider;
105
- /**
106
- * The provider populating default tracking information to be sent with `user-agent`, `x-amz-user-agent` header
107
- * @internal
108
- */
57
+
109
58
  defaultUserAgentProvider?: Provider<__UserAgent>;
110
59
  }
111
60
  declare type TextractClientConfigType = Partial<__SmithyConfiguration<__HttpHandlerOptions>> & ClientDefaults & RegionInputConfig & EndpointsInputConfig & RetryInputConfig & HostHeaderInputConfig & AwsAuthInputConfig & UserAgentInputConfig;
112
- /**
113
- * The configuration interface of TextractClient class constructor that set the region, credentials and other options.
114
- */
61
+
115
62
  export interface TextractClientConfig extends TextractClientConfigType {
116
63
  }
117
64
  declare type TextractClientResolvedConfigType = __SmithyResolvedConfiguration<__HttpHandlerOptions> & Required<ClientDefaults> & RegionResolvedConfig & EndpointsResolvedConfig & RetryResolvedConfig & HostHeaderResolvedConfig & AwsAuthResolvedConfig & UserAgentResolvedConfig;
118
- /**
119
- * The resolved configuration interface of TextractClient class. This is resolved and normalized from the {@link TextractClientConfig | constructor configuration interface}.
120
- */
65
+
121
66
  export interface TextractClientResolvedConfig extends TextractClientResolvedConfigType {
122
67
  }
123
- /**
124
- * <p>Amazon Textract detects and analyzes text in documents and converts it
125
- * into machine-readable text. This is the API reference documentation for
126
- * Amazon Textract.</p>
127
- */
68
+
128
69
  export declare class TextractClient extends __Client<__HttpHandlerOptions, ServiceInputTypes, ServiceOutputTypes, TextractClientResolvedConfig> {
129
- /**
130
- * The resolved configuration of TextractClient class. This is resolved and normalized from the {@link TextractClientConfig | constructor configuration interface}.
131
- */
70
+
132
71
  readonly config: TextractClientResolvedConfig;
133
72
  constructor(configuration: TextractClientConfig);
134
- /**
135
- * Destroy underlying resources, like sockets. It's usually not necessary to do this.
136
- * However in Node.js, it's best to explicitly shut down the client's agent when it is no longer needed.
137
- * Otherwise, sockets might stay open for quite a long time before the server terminates them.
138
- */
73
+
139
74
  destroy(): void;
140
75
  }
141
76
  export {};
@@ -6,59 +6,11 @@ export interface AnalyzeDocumentCommandInput extends AnalyzeDocumentRequest {
6
6
  }
7
7
  export interface AnalyzeDocumentCommandOutput extends AnalyzeDocumentResponse, __MetadataBearer {
8
8
  }
9
- /**
10
- * <p>Analyzes an input document for relationships between detected items. </p>
11
- * <p>The types of information returned are as follows: </p>
12
- * <ul>
13
- * <li>
14
- * <p>Form data (key-value pairs). The related information is returned in two <a>Block</a> objects, each of type <code>KEY_VALUE_SET</code>: a KEY
15
- * <code>Block</code> object and a VALUE <code>Block</code> object. For example,
16
- * <i>Name: Ana Silva Carolina</i> contains a key and value.
17
- * <i>Name:</i> is the key. <i>Ana Silva Carolina</i> is
18
- * the value.</p>
19
- * </li>
20
- * <li>
21
- * <p>Table and table cell data. A TABLE <code>Block</code> object contains information about a detected table. A CELL
22
- * <code>Block</code> object is returned for each cell in a table.</p>
23
- * </li>
24
- * <li>
25
- * <p>Lines and words of text. A LINE <code>Block</code> object contains one or more WORD <code>Block</code> objects.
26
- * All lines and words that are detected in the document are returned (including text that doesn't have a
27
- * relationship with the value of <code>FeatureTypes</code>). </p>
28
- * </li>
29
- * </ul>
30
- *
31
- * <p>Selection elements such as check boxes and option buttons (radio buttons) can be detected in form data and in tables.
32
- * A SELECTION_ELEMENT <code>Block</code> object contains information about a selection element,
33
- * including the selection status.</p>
34
- * <p>You can choose which type of analysis to perform by specifying the <code>FeatureTypes</code> list.
35
- * </p>
36
- * <p>The output is returned in a list of <code>Block</code> objects.</p>
37
- * <p>
38
- * <code>AnalyzeDocument</code> is a synchronous operation. To analyze documents
39
- * asynchronously, use <a>StartDocumentAnalysis</a>.</p>
40
- * <p>For more information, see <a href="https://docs.aws.amazon.com/textract/latest/dg/how-it-works-analyzing.html">Document Text Analysis</a>.</p>
41
- * @example
42
- * Use a bare-bones client and the command you need to make an API call.
43
- * ```javascript
44
- * import { TextractClient, AnalyzeDocumentCommand } from "@aws-sdk/client-textract"; // ES Modules import
45
- * // const { TextractClient, AnalyzeDocumentCommand } = require("@aws-sdk/client-textract"); // CommonJS import
46
- * const client = new TextractClient(config);
47
- * const command = new AnalyzeDocumentCommand(input);
48
- * const response = await client.send(command);
49
- * ```
50
- *
51
- * @see {@link AnalyzeDocumentCommandInput} for command's `input` shape.
52
- * @see {@link AnalyzeDocumentCommandOutput} for command's `response` shape.
53
- * @see {@link TextractClientResolvedConfig | config} for command's `input` shape.
54
- *
55
- */
9
+
56
10
  export declare class AnalyzeDocumentCommand extends $Command<AnalyzeDocumentCommandInput, AnalyzeDocumentCommandOutput, TextractClientResolvedConfig> {
57
11
  readonly input: AnalyzeDocumentCommandInput;
58
12
  constructor(input: AnalyzeDocumentCommandInput);
59
- /**
60
- * @internal
61
- */
13
+
62
14
  resolveMiddleware(clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>, configuration: TextractClientResolvedConfig, options?: __HttpHandlerOptions): Handler<AnalyzeDocumentCommandInput, AnalyzeDocumentCommandOutput>;
63
15
  private serialize;
64
16
  private deserialize;
@@ -6,42 +6,11 @@ export interface AnalyzeExpenseCommandInput extends AnalyzeExpenseRequest {
6
6
  }
7
7
  export interface AnalyzeExpenseCommandOutput extends AnalyzeExpenseResponse, __MetadataBearer {
8
8
  }
9
- /**
10
- * <p>Analyzes an input document for financially related relationships between text.</p>
11
- * <p>Information is returned as <code>ExpenseDocuments</code> and seperated as follows.</p>
12
- * <ul>
13
- * <li>
14
- * <p>
15
- * <code>LineItemGroups</code>- A data set containing <code>LineItems</code> which
16
- * store information about the lines of text, such as an item purchased and its price on a receipt.</p>
17
- * </li>
18
- * <li>
19
- * <p>
20
- * <code>SummaryFields</code>- Contains all other information a receipt, such as header information
21
- * or the vendors name.</p>
22
- * </li>
23
- * </ul>
24
- * @example
25
- * Use a bare-bones client and the command you need to make an API call.
26
- * ```javascript
27
- * import { TextractClient, AnalyzeExpenseCommand } from "@aws-sdk/client-textract"; // ES Modules import
28
- * // const { TextractClient, AnalyzeExpenseCommand } = require("@aws-sdk/client-textract"); // CommonJS import
29
- * const client = new TextractClient(config);
30
- * const command = new AnalyzeExpenseCommand(input);
31
- * const response = await client.send(command);
32
- * ```
33
- *
34
- * @see {@link AnalyzeExpenseCommandInput} for command's `input` shape.
35
- * @see {@link AnalyzeExpenseCommandOutput} for command's `response` shape.
36
- * @see {@link TextractClientResolvedConfig | config} for command's `input` shape.
37
- *
38
- */
9
+
39
10
  export declare class AnalyzeExpenseCommand extends $Command<AnalyzeExpenseCommandInput, AnalyzeExpenseCommandOutput, TextractClientResolvedConfig> {
40
11
  readonly input: AnalyzeExpenseCommandInput;
41
12
  constructor(input: AnalyzeExpenseCommandInput);
42
- /**
43
- * @internal
44
- */
13
+
45
14
  resolveMiddleware(clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>, configuration: TextractClientResolvedConfig, options?: __HttpHandlerOptions): Handler<AnalyzeExpenseCommandInput, AnalyzeExpenseCommandOutput>;
46
15
  private serialize;
47
16
  private deserialize;
@@ -6,39 +6,11 @@ export interface DetectDocumentTextCommandInput extends DetectDocumentTextReques
6
6
  }
7
7
  export interface DetectDocumentTextCommandOutput extends DetectDocumentTextResponse, __MetadataBearer {
8
8
  }
9
- /**
10
- * <p>Detects text in the input document. Amazon Textract can detect lines of text and the
11
- * words that make up a line of text. The input document must be an image in JPEG or PNG
12
- * format. <code>DetectDocumentText</code> returns the detected text in an array of <a>Block</a> objects. </p>
13
- * <p>Each document page has as an associated <code>Block</code> of type PAGE. Each PAGE <code>Block</code> object
14
- * is the parent of LINE <code>Block</code> objects that represent the lines of detected text on a page. A LINE <code>Block</code> object is
15
- * a parent for each word that makes up the line. Words are represented by <code>Block</code> objects of type WORD.</p>
16
- *
17
- * <p>
18
- * <code>DetectDocumentText</code> is a synchronous operation. To analyze documents
19
- * asynchronously, use <a>StartDocumentTextDetection</a>.</p>
20
- * <p>For more information, see <a href="https://docs.aws.amazon.com/textract/latest/dg/how-it-works-detecting.html">Document Text Detection</a>.</p>
21
- * @example
22
- * Use a bare-bones client and the command you need to make an API call.
23
- * ```javascript
24
- * import { TextractClient, DetectDocumentTextCommand } from "@aws-sdk/client-textract"; // ES Modules import
25
- * // const { TextractClient, DetectDocumentTextCommand } = require("@aws-sdk/client-textract"); // CommonJS import
26
- * const client = new TextractClient(config);
27
- * const command = new DetectDocumentTextCommand(input);
28
- * const response = await client.send(command);
29
- * ```
30
- *
31
- * @see {@link DetectDocumentTextCommandInput} for command's `input` shape.
32
- * @see {@link DetectDocumentTextCommandOutput} for command's `response` shape.
33
- * @see {@link TextractClientResolvedConfig | config} for command's `input` shape.
34
- *
35
- */
9
+
36
10
  export declare class DetectDocumentTextCommand extends $Command<DetectDocumentTextCommandInput, DetectDocumentTextCommandOutput, TextractClientResolvedConfig> {
37
11
  readonly input: DetectDocumentTextCommandInput;
38
12
  constructor(input: DetectDocumentTextCommandInput);
39
- /**
40
- * @internal
41
- */
13
+
42
14
  resolveMiddleware(clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>, configuration: TextractClientResolvedConfig, options?: __HttpHandlerOptions): Handler<DetectDocumentTextCommandInput, DetectDocumentTextCommandOutput>;
43
15
  private serialize;
44
16
  private deserialize;
@@ -6,73 +6,11 @@ export interface GetDocumentAnalysisCommandInput extends GetDocumentAnalysisRequ
6
6
  }
7
7
  export interface GetDocumentAnalysisCommandOutput extends GetDocumentAnalysisResponse, __MetadataBearer {
8
8
  }
9
- /**
10
- * <p>Gets the results for an Amazon Textract asynchronous operation that analyzes text in a document.</p>
11
- * <p>You start asynchronous text analysis by calling <a>StartDocumentAnalysis</a>, which returns a job identifier
12
- * (<code>JobId</code>). When the text analysis operation finishes, Amazon Textract publishes a
13
- * completion status to the Amazon Simple Notification Service (Amazon SNS) topic that's registered in the initial call to
14
- * <code>StartDocumentAnalysis</code>. To get the results of the text-detection operation,
15
- * first check that the status value published to the Amazon SNS topic is <code>SUCCEEDED</code>.
16
- * If so, call <code>GetDocumentAnalysis</code>, and pass the job identifier
17
- * (<code>JobId</code>) from the initial call to <code>StartDocumentAnalysis</code>.</p>
18
- * <p>
19
- * <code>GetDocumentAnalysis</code> returns an array of <a>Block</a> objects. The following
20
- * types of information are returned: </p>
21
- * <ul>
22
- * <li>
23
- * <p>Form data (key-value pairs). The related information is returned in two <a>Block</a> objects, each of type <code>KEY_VALUE_SET</code>: a KEY
24
- * <code>Block</code> object and a VALUE <code>Block</code> object. For example,
25
- * <i>Name: Ana Silva Carolina</i> contains a key and value.
26
- * <i>Name:</i> is the key. <i>Ana Silva Carolina</i> is
27
- * the value.</p>
28
- * </li>
29
- * <li>
30
- * <p>Table and table cell data. A TABLE <code>Block</code> object contains information about a detected table. A CELL
31
- * <code>Block</code> object is returned for each cell in a table.</p>
32
- * </li>
33
- * <li>
34
- * <p>Lines and words of text. A LINE <code>Block</code> object contains one or more WORD <code>Block</code> objects.
35
- * All lines and words that are detected in the document are returned (including text that doesn't have a
36
- * relationship with the value of the <code>StartDocumentAnalysis</code>
37
- * <code>FeatureTypes</code> input parameter). </p>
38
- * </li>
39
- * </ul>
40
- *
41
- * <p>Selection elements such as check boxes and option buttons (radio buttons) can be detected in form data and in tables.
42
- * A SELECTION_ELEMENT <code>Block</code> object contains information about a selection element,
43
- * including the selection status.</p>
44
- *
45
- *
46
- *
47
- * <p>Use the <code>MaxResults</code> parameter to limit the number of blocks that are
48
- * returned. If there are more results than specified in <code>MaxResults</code>, the value of
49
- * <code>NextToken</code> in the operation response contains a pagination token for getting
50
- * the next set of results. To get the next page of results, call
51
- * <code>GetDocumentAnalysis</code>, and populate the <code>NextToken</code> request
52
- * parameter with the token value that's returned from the previous call to
53
- * <code>GetDocumentAnalysis</code>.</p>
54
- * <p>For more information, see <a href="https://docs.aws.amazon.com/textract/latest/dg/how-it-works-analyzing.html">Document Text Analysis</a>.</p>
55
- * @example
56
- * Use a bare-bones client and the command you need to make an API call.
57
- * ```javascript
58
- * import { TextractClient, GetDocumentAnalysisCommand } from "@aws-sdk/client-textract"; // ES Modules import
59
- * // const { TextractClient, GetDocumentAnalysisCommand } = require("@aws-sdk/client-textract"); // CommonJS import
60
- * const client = new TextractClient(config);
61
- * const command = new GetDocumentAnalysisCommand(input);
62
- * const response = await client.send(command);
63
- * ```
64
- *
65
- * @see {@link GetDocumentAnalysisCommandInput} for command's `input` shape.
66
- * @see {@link GetDocumentAnalysisCommandOutput} for command's `response` shape.
67
- * @see {@link TextractClientResolvedConfig | config} for command's `input` shape.
68
- *
69
- */
9
+
70
10
  export declare class GetDocumentAnalysisCommand extends $Command<GetDocumentAnalysisCommandInput, GetDocumentAnalysisCommandOutput, TextractClientResolvedConfig> {
71
11
  readonly input: GetDocumentAnalysisCommandInput;
72
12
  constructor(input: GetDocumentAnalysisCommandInput);
73
- /**
74
- * @internal
75
- */
13
+
76
14
  resolveMiddleware(clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>, configuration: TextractClientResolvedConfig, options?: __HttpHandlerOptions): Handler<GetDocumentAnalysisCommandInput, GetDocumentAnalysisCommandOutput>;
77
15
  private serialize;
78
16
  private deserialize;
@@ -6,53 +6,11 @@ export interface GetDocumentTextDetectionCommandInput extends GetDocumentTextDet
6
6
  }
7
7
  export interface GetDocumentTextDetectionCommandOutput extends GetDocumentTextDetectionResponse, __MetadataBearer {
8
8
  }
9
- /**
10
- * <p>Gets the results for an Amazon Textract asynchronous operation that detects text in a document.
11
- * Amazon Textract can detect lines of text and the words that make up a line of text.</p>
12
- * <p>You start asynchronous text detection by calling <a>StartDocumentTextDetection</a>, which returns a job identifier
13
- * (<code>JobId</code>). When the text detection operation finishes, Amazon Textract publishes a
14
- * completion status to the Amazon Simple Notification Service (Amazon SNS) topic that's registered in the initial call to
15
- * <code>StartDocumentTextDetection</code>. To get the results of the text-detection
16
- * operation, first check that the status value published to the Amazon SNS topic is
17
- * <code>SUCCEEDED</code>. If so, call <code>GetDocumentTextDetection</code>, and pass the
18
- * job identifier (<code>JobId</code>) from the initial call to
19
- * <code>StartDocumentTextDetection</code>.</p>
20
- * <p>
21
- * <code>GetDocumentTextDetection</code> returns an array of <a>Block</a>
22
- * objects. </p>
23
- * <p>Each document page has as an associated <code>Block</code> of type PAGE. Each PAGE <code>Block</code> object
24
- * is the parent of LINE <code>Block</code> objects that represent the lines of detected text on a page. A LINE <code>Block</code> object is
25
- * a parent for each word that makes up the line. Words are represented by <code>Block</code> objects of type WORD.</p>
26
- *
27
- * <p>Use the MaxResults parameter to limit the number of blocks that are returned. If there
28
- * are more results than specified in <code>MaxResults</code>, the value of
29
- * <code>NextToken</code> in the operation response contains a pagination token for getting
30
- * the next set of results. To get the next page of results, call
31
- * <code>GetDocumentTextDetection</code>, and populate the <code>NextToken</code> request
32
- * parameter with the token value that's returned from the previous call to
33
- * <code>GetDocumentTextDetection</code>.</p>
34
- * <p>For more information, see <a href="https://docs.aws.amazon.com/textract/latest/dg/how-it-works-detecting.html">Document Text Detection</a>.</p>
35
- * @example
36
- * Use a bare-bones client and the command you need to make an API call.
37
- * ```javascript
38
- * import { TextractClient, GetDocumentTextDetectionCommand } from "@aws-sdk/client-textract"; // ES Modules import
39
- * // const { TextractClient, GetDocumentTextDetectionCommand } = require("@aws-sdk/client-textract"); // CommonJS import
40
- * const client = new TextractClient(config);
41
- * const command = new GetDocumentTextDetectionCommand(input);
42
- * const response = await client.send(command);
43
- * ```
44
- *
45
- * @see {@link GetDocumentTextDetectionCommandInput} for command's `input` shape.
46
- * @see {@link GetDocumentTextDetectionCommandOutput} for command's `response` shape.
47
- * @see {@link TextractClientResolvedConfig | config} for command's `input` shape.
48
- *
49
- */
9
+
50
10
  export declare class GetDocumentTextDetectionCommand extends $Command<GetDocumentTextDetectionCommandInput, GetDocumentTextDetectionCommandOutput, TextractClientResolvedConfig> {
51
11
  readonly input: GetDocumentTextDetectionCommandInput;
52
12
  constructor(input: GetDocumentTextDetectionCommandInput);
53
- /**
54
- * @internal
55
- */
13
+
56
14
  resolveMiddleware(clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>, configuration: TextractClientResolvedConfig, options?: __HttpHandlerOptions): Handler<GetDocumentTextDetectionCommandInput, GetDocumentTextDetectionCommandOutput>;
57
15
  private serialize;
58
16
  private deserialize;
@@ -0,0 +1,17 @@
1
+ import { Command as $Command } from "@aws-sdk/smithy-client";
2
+ import { Handler, HttpHandlerOptions as __HttpHandlerOptions, MetadataBearer as __MetadataBearer, MiddlewareStack } from "@aws-sdk/types";
3
+ import { GetExpenseAnalysisRequest, GetExpenseAnalysisResponse } from "../models/models_0";
4
+ import { ServiceInputTypes, ServiceOutputTypes, TextractClientResolvedConfig } from "../TextractClient";
5
+ export interface GetExpenseAnalysisCommandInput extends GetExpenseAnalysisRequest {
6
+ }
7
+ export interface GetExpenseAnalysisCommandOutput extends GetExpenseAnalysisResponse, __MetadataBearer {
8
+ }
9
+
10
+ export declare class GetExpenseAnalysisCommand extends $Command<GetExpenseAnalysisCommandInput, GetExpenseAnalysisCommandOutput, TextractClientResolvedConfig> {
11
+ readonly input: GetExpenseAnalysisCommandInput;
12
+ constructor(input: GetExpenseAnalysisCommandInput);
13
+
14
+ resolveMiddleware(clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>, configuration: TextractClientResolvedConfig, options?: __HttpHandlerOptions): Handler<GetExpenseAnalysisCommandInput, GetExpenseAnalysisCommandOutput>;
15
+ private serialize;
16
+ private deserialize;
17
+ }
@@ -6,46 +6,11 @@ export interface StartDocumentAnalysisCommandInput extends StartDocumentAnalysis
6
6
  }
7
7
  export interface StartDocumentAnalysisCommandOutput extends StartDocumentAnalysisResponse, __MetadataBearer {
8
8
  }
9
- /**
10
- * <p>Starts the asynchronous analysis of an input document for relationships between detected
11
- * items such as key-value pairs, tables, and selection elements.</p>
12
- *
13
- * <p>
14
- * <code>StartDocumentAnalysis</code> can analyze text in documents that are in JPEG, PNG, and PDF format. The
15
- * documents are stored in an Amazon S3 bucket. Use <a>DocumentLocation</a> to specify the bucket name and file name
16
- * of the document.
17
- * </p>
18
- * <p>
19
- * <code>StartDocumentAnalysis</code> returns a job identifier
20
- * (<code>JobId</code>) that you use to get the results of the operation. When text
21
- * analysis is finished, Amazon Textract publishes a completion status to the Amazon Simple Notification Service (Amazon SNS)
22
- * topic that you specify in <code>NotificationChannel</code>. To get the results of the text
23
- * analysis operation, first check that the status value published to the Amazon SNS topic is
24
- * <code>SUCCEEDED</code>. If so, call <a>GetDocumentAnalysis</a>, and pass
25
- * the job identifier (<code>JobId</code>) from the initial call to
26
- * <code>StartDocumentAnalysis</code>.</p>
27
- * <p>For more information, see <a href="https://docs.aws.amazon.com/textract/latest/dg/how-it-works-analyzing.html">Document Text Analysis</a>.</p>
28
- * @example
29
- * Use a bare-bones client and the command you need to make an API call.
30
- * ```javascript
31
- * import { TextractClient, StartDocumentAnalysisCommand } from "@aws-sdk/client-textract"; // ES Modules import
32
- * // const { TextractClient, StartDocumentAnalysisCommand } = require("@aws-sdk/client-textract"); // CommonJS import
33
- * const client = new TextractClient(config);
34
- * const command = new StartDocumentAnalysisCommand(input);
35
- * const response = await client.send(command);
36
- * ```
37
- *
38
- * @see {@link StartDocumentAnalysisCommandInput} for command's `input` shape.
39
- * @see {@link StartDocumentAnalysisCommandOutput} for command's `response` shape.
40
- * @see {@link TextractClientResolvedConfig | config} for command's `input` shape.
41
- *
42
- */
9
+
43
10
  export declare class StartDocumentAnalysisCommand extends $Command<StartDocumentAnalysisCommandInput, StartDocumentAnalysisCommandOutput, TextractClientResolvedConfig> {
44
11
  readonly input: StartDocumentAnalysisCommandInput;
45
12
  constructor(input: StartDocumentAnalysisCommandInput);
46
- /**
47
- * @internal
48
- */
13
+
49
14
  resolveMiddleware(clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>, configuration: TextractClientResolvedConfig, options?: __HttpHandlerOptions): Handler<StartDocumentAnalysisCommandInput, StartDocumentAnalysisCommandOutput>;
50
15
  private serialize;
51
16
  private deserialize;
@@ -6,45 +6,11 @@ export interface StartDocumentTextDetectionCommandInput extends StartDocumentTex
6
6
  }
7
7
  export interface StartDocumentTextDetectionCommandOutput extends StartDocumentTextDetectionResponse, __MetadataBearer {
8
8
  }
9
- /**
10
- * <p>Starts the asynchronous detection of text in a document. Amazon Textract can detect lines of
11
- * text and the words that make up a line of text.</p>
12
- * <p>
13
- * <code>StartDocumentTextDetection</code> can analyze text in documents that are in JPEG, PNG, and PDF format. The
14
- * documents are stored in an Amazon S3 bucket. Use <a>DocumentLocation</a> to specify the bucket name and file name
15
- * of the document.
16
- * </p>
17
- * <p>
18
- * <code>StartTextDetection</code> returns a job identifier
19
- * (<code>JobId</code>) that you use to get the results of the operation. When text
20
- * detection is finished, Amazon Textract publishes a completion status to the Amazon Simple Notification Service (Amazon SNS)
21
- * topic that you specify in <code>NotificationChannel</code>. To get the results of the text
22
- * detection operation, first check that the status value published to the Amazon SNS topic is
23
- * <code>SUCCEEDED</code>. If so, call <a>GetDocumentTextDetection</a>, and
24
- * pass the job identifier (<code>JobId</code>) from the initial call to
25
- * <code>StartDocumentTextDetection</code>.</p>
26
- * <p>For more information, see <a href="https://docs.aws.amazon.com/textract/latest/dg/how-it-works-detecting.html">Document Text Detection</a>.</p>
27
- * @example
28
- * Use a bare-bones client and the command you need to make an API call.
29
- * ```javascript
30
- * import { TextractClient, StartDocumentTextDetectionCommand } from "@aws-sdk/client-textract"; // ES Modules import
31
- * // const { TextractClient, StartDocumentTextDetectionCommand } = require("@aws-sdk/client-textract"); // CommonJS import
32
- * const client = new TextractClient(config);
33
- * const command = new StartDocumentTextDetectionCommand(input);
34
- * const response = await client.send(command);
35
- * ```
36
- *
37
- * @see {@link StartDocumentTextDetectionCommandInput} for command's `input` shape.
38
- * @see {@link StartDocumentTextDetectionCommandOutput} for command's `response` shape.
39
- * @see {@link TextractClientResolvedConfig | config} for command's `input` shape.
40
- *
41
- */
9
+
42
10
  export declare class StartDocumentTextDetectionCommand extends $Command<StartDocumentTextDetectionCommandInput, StartDocumentTextDetectionCommandOutput, TextractClientResolvedConfig> {
43
11
  readonly input: StartDocumentTextDetectionCommandInput;
44
12
  constructor(input: StartDocumentTextDetectionCommandInput);
45
- /**
46
- * @internal
47
- */
13
+
48
14
  resolveMiddleware(clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>, configuration: TextractClientResolvedConfig, options?: __HttpHandlerOptions): Handler<StartDocumentTextDetectionCommandInput, StartDocumentTextDetectionCommandOutput>;
49
15
  private serialize;
50
16
  private deserialize;
@@ -0,0 +1,17 @@
1
+ import { Command as $Command } from "@aws-sdk/smithy-client";
2
+ import { Handler, HttpHandlerOptions as __HttpHandlerOptions, MetadataBearer as __MetadataBearer, MiddlewareStack } from "@aws-sdk/types";
3
+ import { StartExpenseAnalysisRequest, StartExpenseAnalysisResponse } from "../models/models_0";
4
+ import { ServiceInputTypes, ServiceOutputTypes, TextractClientResolvedConfig } from "../TextractClient";
5
+ export interface StartExpenseAnalysisCommandInput extends StartExpenseAnalysisRequest {
6
+ }
7
+ export interface StartExpenseAnalysisCommandOutput extends StartExpenseAnalysisResponse, __MetadataBearer {
8
+ }
9
+
10
+ export declare class StartExpenseAnalysisCommand extends $Command<StartExpenseAnalysisCommandInput, StartExpenseAnalysisCommandOutput, TextractClientResolvedConfig> {
11
+ readonly input: StartExpenseAnalysisCommandInput;
12
+ constructor(input: StartExpenseAnalysisCommandInput);
13
+
14
+ resolveMiddleware(clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>, configuration: TextractClientResolvedConfig, options?: __HttpHandlerOptions): Handler<StartExpenseAnalysisCommandInput, StartExpenseAnalysisCommandOutput>;
15
+ private serialize;
16
+ private deserialize;
17
+ }
@@ -0,0 +1,9 @@
1
+ export * from "./AnalyzeDocumentCommand";
2
+ export * from "./AnalyzeExpenseCommand";
3
+ export * from "./DetectDocumentTextCommand";
4
+ export * from "./GetDocumentAnalysisCommand";
5
+ export * from "./GetDocumentTextDetectionCommand";
6
+ export * from "./GetExpenseAnalysisCommand";
7
+ export * from "./StartDocumentAnalysisCommand";
8
+ export * from "./StartDocumentTextDetectionCommand";
9
+ export * from "./StartExpenseAnalysisCommand";
@@ -1,10 +1,4 @@
1
- export * from "./TextractClient";
2
1
  export * from "./Textract";
3
- export * from "./commands/AnalyzeDocumentCommand";
4
- export * from "./commands/AnalyzeExpenseCommand";
5
- export * from "./commands/DetectDocumentTextCommand";
6
- export * from "./commands/GetDocumentAnalysisCommand";
7
- export * from "./commands/GetDocumentTextDetectionCommand";
8
- export * from "./commands/StartDocumentAnalysisCommand";
9
- export * from "./commands/StartDocumentTextDetectionCommand";
10
- export * from "./models/index";
2
+ export * from "./TextractClient";
3
+ export * from "./commands";
4
+ export * from "./models";