@maxim_mazurok/gapi.client.documentai-v1beta3 0.0.20230519 → 0.0.20230605
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/index.d.ts +323 -40
- package/package.json +1 -1
- package/tests.ts +89 -1
package/index.d.ts
CHANGED
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
// This file was generated by https://github.com/Maxim-Mazurok/google-api-typings-generator. Please do not edit it manually.
|
|
10
10
|
// In case of any problems please post issue to https://github.com/Maxim-Mazurok/google-api-typings-generator
|
|
11
11
|
// Generated from: https://documentai.googleapis.com/$discovery/rest?version=v1beta3
|
|
12
|
-
// Revision:
|
|
12
|
+
// Revision: 20230605
|
|
13
13
|
|
|
14
14
|
/// <reference types="gapi.client" />
|
|
15
15
|
|
|
@@ -483,7 +483,7 @@ declare namespace gapi.client {
|
|
|
483
483
|
/** Any error that occurred while processing this document. */
|
|
484
484
|
error?:
|
|
485
485
|
GoogleRpcStatus;
|
|
486
|
-
/** An IANA published
|
|
486
|
+
/** An IANA published [media type (MIME type)](https://www.iana.org/assignments/media-types/media-types.xhtml). */
|
|
487
487
|
mimeType?:
|
|
488
488
|
string;
|
|
489
489
|
/** Visual page layout for the Document. */
|
|
@@ -695,7 +695,7 @@ declare namespace gapi.client {
|
|
|
695
695
|
/** Confidence of detected language. Range `[0, 1]`. */
|
|
696
696
|
confidence?:
|
|
697
697
|
number;
|
|
698
|
-
/** The BCP-47 language code, such as `en-US` or `sr-Latn`.
|
|
698
|
+
/** The [BCP-47 language code](https://www.unicode.org/reports/tr35/#Unicode_locale_identifier), such as `en-US` or `sr-Latn`. */
|
|
699
699
|
languageCode?:
|
|
700
700
|
string;
|
|
701
701
|
}
|
|
@@ -746,7 +746,7 @@ declare namespace gapi.client {
|
|
|
746
746
|
/** Height of the image in pixels. */
|
|
747
747
|
height?:
|
|
748
748
|
number;
|
|
749
|
-
/** Encoding
|
|
749
|
+
/** Encoding [media type (MIME type)](https://www.iana.org/assignments/media-types/media-types.xhtml) for the image. */
|
|
750
750
|
mimeType?:
|
|
751
751
|
string;
|
|
752
752
|
/** Width of the image in pixels. */
|
|
@@ -757,12 +757,12 @@ declare namespace gapi.client {
|
|
|
757
757
|
/** A list of detected defects. */
|
|
758
758
|
detectedDefects?:
|
|
759
759
|
GoogleCloudDocumentaiV1beta1DocumentPageImageQualityScoresDetectedDefect[];
|
|
760
|
-
/** The overall quality score. Range `[0, 1]` where 1 is perfect quality. */
|
|
760
|
+
/** The overall quality score. Range `[0, 1]` where `1` is perfect quality. */
|
|
761
761
|
qualityScore?:
|
|
762
762
|
number;
|
|
763
763
|
}
|
|
764
764
|
interface GoogleCloudDocumentaiV1beta1DocumentPageImageQualityScoresDetectedDefect {
|
|
765
|
-
/** Confidence of detected defect. Range `[0, 1]` where 1 indicates strong confidence of that the defect exists. */
|
|
765
|
+
/** Confidence of detected defect. Range `[0, 1]` where `1` indicates strong confidence of that the defect exists. */
|
|
766
766
|
confidence?:
|
|
767
767
|
number;
|
|
768
768
|
/**
|
|
@@ -1035,16 +1035,16 @@ declare namespace gapi.client {
|
|
|
1035
1035
|
/** Font size. */
|
|
1036
1036
|
fontSize?:
|
|
1037
1037
|
GoogleCloudDocumentaiV1beta1DocumentStyleFontSize;
|
|
1038
|
-
/** Font weight. Possible values are normal
|
|
1038
|
+
/** [Font weight](https://www.w3schools.com/cssref/pr_font_weight.asp). Possible values are `normal`, `bold`, `bolder`, and `lighter`. */
|
|
1039
1039
|
fontWeight?:
|
|
1040
1040
|
string;
|
|
1041
1041
|
/** Text anchor indexing into the Document.text. */
|
|
1042
1042
|
textAnchor?:
|
|
1043
1043
|
GoogleCloudDocumentaiV1beta1DocumentTextAnchor;
|
|
1044
|
-
/** Text decoration
|
|
1044
|
+
/** [Text decoration](https://www.w3schools.com/cssref/pr_text_text-decoration.asp). Follows CSS standard. */
|
|
1045
1045
|
textDecoration?:
|
|
1046
1046
|
string;
|
|
1047
|
-
/** Text style. Possible values are normal
|
|
1047
|
+
/** [Text style](https://www.w3schools.com/cssref/pr_font_font-style.asp). Possible values are `normal`, `italic`, and `oblique`. */
|
|
1048
1048
|
textStyle?:
|
|
1049
1049
|
string;
|
|
1050
1050
|
}
|
|
@@ -1052,7 +1052,7 @@ declare namespace gapi.client {
|
|
|
1052
1052
|
/** Font size for the text. */
|
|
1053
1053
|
size?:
|
|
1054
1054
|
number;
|
|
1055
|
-
/** Unit for the font size. Follows CSS naming (in
|
|
1055
|
+
/** Unit for the font size. Follows CSS naming (`in`, `px`, `pt`, etc.). */
|
|
1056
1056
|
unit?:
|
|
1057
1057
|
string;
|
|
1058
1058
|
}
|
|
@@ -1207,7 +1207,7 @@ declare namespace gapi.client {
|
|
|
1207
1207
|
/** Labels for this document. */
|
|
1208
1208
|
labels?:
|
|
1209
1209
|
GoogleCloudDocumentaiV1beta2DocumentLabel[];
|
|
1210
|
-
/** An IANA published
|
|
1210
|
+
/** An IANA published [media type (MIME type)](https://www.iana.org/assignments/media-types/media-types.xhtml). */
|
|
1211
1211
|
mimeType?:
|
|
1212
1212
|
string;
|
|
1213
1213
|
/** Visual page layout for the Document. */
|
|
@@ -1430,7 +1430,7 @@ declare namespace gapi.client {
|
|
|
1430
1430
|
/** Confidence of detected language. Range `[0, 1]`. */
|
|
1431
1431
|
confidence?:
|
|
1432
1432
|
number;
|
|
1433
|
-
/** The BCP-47 language code, such as `en-US` or `sr-Latn`.
|
|
1433
|
+
/** The [BCP-47 language code](https://www.unicode.org/reports/tr35/#Unicode_locale_identifier), such as `en-US` or `sr-Latn`. */
|
|
1434
1434
|
languageCode?:
|
|
1435
1435
|
string;
|
|
1436
1436
|
}
|
|
@@ -1481,7 +1481,7 @@ declare namespace gapi.client {
|
|
|
1481
1481
|
/** Height of the image in pixels. */
|
|
1482
1482
|
height?:
|
|
1483
1483
|
number;
|
|
1484
|
-
/** Encoding
|
|
1484
|
+
/** Encoding [media type (MIME type)](https://www.iana.org/assignments/media-types/media-types.xhtml) for the image. */
|
|
1485
1485
|
mimeType?:
|
|
1486
1486
|
string;
|
|
1487
1487
|
/** Width of the image in pixels. */
|
|
@@ -1492,12 +1492,12 @@ declare namespace gapi.client {
|
|
|
1492
1492
|
/** A list of detected defects. */
|
|
1493
1493
|
detectedDefects?:
|
|
1494
1494
|
GoogleCloudDocumentaiV1beta2DocumentPageImageQualityScoresDetectedDefect[];
|
|
1495
|
-
/** The overall quality score. Range `[0, 1]` where 1 is perfect quality. */
|
|
1495
|
+
/** The overall quality score. Range `[0, 1]` where `1` is perfect quality. */
|
|
1496
1496
|
qualityScore?:
|
|
1497
1497
|
number;
|
|
1498
1498
|
}
|
|
1499
1499
|
interface GoogleCloudDocumentaiV1beta2DocumentPageImageQualityScoresDetectedDefect {
|
|
1500
|
-
/** Confidence of detected defect. Range `[0, 1]` where 1 indicates strong confidence of that the defect exists. */
|
|
1500
|
+
/** Confidence of detected defect. Range `[0, 1]` where `1` indicates strong confidence of that the defect exists. */
|
|
1501
1501
|
confidence?:
|
|
1502
1502
|
number;
|
|
1503
1503
|
/**
|
|
@@ -1770,16 +1770,16 @@ declare namespace gapi.client {
|
|
|
1770
1770
|
/** Font size. */
|
|
1771
1771
|
fontSize?:
|
|
1772
1772
|
GoogleCloudDocumentaiV1beta2DocumentStyleFontSize;
|
|
1773
|
-
/** Font weight. Possible values are normal
|
|
1773
|
+
/** [Font weight](https://www.w3schools.com/cssref/pr_font_weight.asp). Possible values are `normal`, `bold`, `bolder`, and `lighter`. */
|
|
1774
1774
|
fontWeight?:
|
|
1775
1775
|
string;
|
|
1776
1776
|
/** Text anchor indexing into the Document.text. */
|
|
1777
1777
|
textAnchor?:
|
|
1778
1778
|
GoogleCloudDocumentaiV1beta2DocumentTextAnchor;
|
|
1779
|
-
/** Text decoration
|
|
1779
|
+
/** [Text decoration](https://www.w3schools.com/cssref/pr_text_text-decoration.asp). Follows CSS standard. */
|
|
1780
1780
|
textDecoration?:
|
|
1781
1781
|
string;
|
|
1782
|
-
/** Text style. Possible values are normal
|
|
1782
|
+
/** [Text style](https://www.w3schools.com/cssref/pr_font_font-style.asp). Possible values are `normal`, `italic`, and `oblique`. */
|
|
1783
1783
|
textStyle?:
|
|
1784
1784
|
string;
|
|
1785
1785
|
}
|
|
@@ -1787,7 +1787,7 @@ declare namespace gapi.client {
|
|
|
1787
1787
|
/** Font size for the text. */
|
|
1788
1788
|
size?:
|
|
1789
1789
|
number;
|
|
1790
|
-
/** Unit for the font size. Follows CSS naming (in
|
|
1790
|
+
/** Unit for the font size. Follows CSS naming (`in`, `px`, `pt`, etc.). */
|
|
1791
1791
|
unit?:
|
|
1792
1792
|
string;
|
|
1793
1793
|
}
|
|
@@ -1977,7 +1977,7 @@ declare namespace gapi.client {
|
|
|
1977
1977
|
/** Inference-time options for the process API */
|
|
1978
1978
|
processOptions?:
|
|
1979
1979
|
GoogleCloudDocumentaiV1beta3ProcessOptions;
|
|
1980
|
-
/** Whether Human Review feature should be skipped for this request. Default to false
|
|
1980
|
+
/** Whether Human Review feature should be skipped for this request. Default to `false`. */
|
|
1981
1981
|
skipHumanReview?:
|
|
1982
1982
|
boolean;
|
|
1983
1983
|
}
|
|
@@ -1986,8 +1986,8 @@ declare namespace gapi.client {
|
|
|
1986
1986
|
gcsSource?:
|
|
1987
1987
|
string;
|
|
1988
1988
|
/**
|
|
1989
|
-
*
|
|
1990
|
-
* types. If the input is a Document, the type should be `application/json`.
|
|
1989
|
+
* An IANA published [media type (MIME type)](https://www.iana.org/assignments/media-types/media-types.xhtml) of the input. If the input is a raw document, refer to [supported file
|
|
1990
|
+
* types](https://cloud.google.com/document-ai/docs/file-types) for the list of media types. If the input is a Document, the type should be `application/json`.
|
|
1991
1991
|
*/
|
|
1992
1992
|
mimeType?:
|
|
1993
1993
|
string;
|
|
@@ -2025,6 +2025,53 @@ declare namespace gapi.client {
|
|
|
2025
2025
|
updateTime?:
|
|
2026
2026
|
string;
|
|
2027
2027
|
}
|
|
2028
|
+
interface GoogleCloudDocumentaiV1beta3Dataset {
|
|
2029
|
+
/** Optional. Document Warehouse-based dataset config. */
|
|
2030
|
+
documentWarehouseConfig?:
|
|
2031
|
+
GoogleCloudDocumentaiV1beta3DatasetDocumentWarehouseConfig;
|
|
2032
|
+
/** Optional. User managed GCS dataset config. Use this config if the dataset documents are stored under a user managed GCS location. */
|
|
2033
|
+
gcsManagedConfig?:
|
|
2034
|
+
GoogleCloudDocumentaiV1beta3DatasetGCSManagedConfig;
|
|
2035
|
+
/** Dataset resource name. Format: `projects/{project}/locations/{location}/processors/{processor}/dataset` */
|
|
2036
|
+
name?:
|
|
2037
|
+
string;
|
|
2038
|
+
/** Optional. A lightweight indexing source with low latency and high reliability, but lack advanced features like CMEK and content based search. */
|
|
2039
|
+
spannerIndexingConfig?:
|
|
2040
|
+
any;
|
|
2041
|
+
/** Required. State of the dataset. Will be ignored when updating dataset. */
|
|
2042
|
+
state?:
|
|
2043
|
+
string;
|
|
2044
|
+
/** Optional. Unmanaged dataset config. Use this config if the dataset documents are managed by the document service internally (not user managed). */
|
|
2045
|
+
unmanagedDatasetConfig?:
|
|
2046
|
+
any;
|
|
2047
|
+
}
|
|
2048
|
+
interface GoogleCloudDocumentaiV1beta3DatasetDocumentWarehouseConfig {
|
|
2049
|
+
/** Output only. The collection in Document Warehouse associated with the dataset. */
|
|
2050
|
+
collection?:
|
|
2051
|
+
string;
|
|
2052
|
+
/** Output only. The schema in Document Warehouse associated with the dataset. */
|
|
2053
|
+
schema?:
|
|
2054
|
+
string;
|
|
2055
|
+
}
|
|
2056
|
+
interface GoogleCloudDocumentaiV1beta3DatasetGCSManagedConfig {
|
|
2057
|
+
/** Required. The Cloud Storage uri (a directory) where the documents belonging to the dataset must be stored. */
|
|
2058
|
+
gcsPrefix?:
|
|
2059
|
+
GoogleCloudDocumentaiV1beta3GcsPrefix;
|
|
2060
|
+
}
|
|
2061
|
+
interface GoogleCloudDocumentaiV1beta3DatasetSchema {
|
|
2062
|
+
/** Optional. Schema of the dataset. */
|
|
2063
|
+
documentSchema?:
|
|
2064
|
+
GoogleCloudDocumentaiV1beta3DocumentSchema;
|
|
2065
|
+
/** Dataset schema resource name. Format: `projects/{project}/locations/{location}/processors/{processor}/dataset/datasetSchema` */
|
|
2066
|
+
name?:
|
|
2067
|
+
string;
|
|
2068
|
+
}
|
|
2069
|
+
// tslint:disable-next-line:no-empty-interface
|
|
2070
|
+
interface GoogleCloudDocumentaiV1beta3DatasetSpannerIndexingConfig {
|
|
2071
|
+
}
|
|
2072
|
+
// tslint:disable-next-line:no-empty-interface
|
|
2073
|
+
interface GoogleCloudDocumentaiV1beta3DatasetUnmanagedDatasetConfig {
|
|
2074
|
+
}
|
|
2028
2075
|
interface GoogleCloudDocumentaiV1beta3DeleteProcessorMetadata {
|
|
2029
2076
|
/** The basic metadata of the long-running operation. */
|
|
2030
2077
|
commonMetadata?:
|
|
@@ -2073,7 +2120,7 @@ declare namespace gapi.client {
|
|
|
2073
2120
|
/** Any error that occurred while processing this document. */
|
|
2074
2121
|
error?:
|
|
2075
2122
|
GoogleRpcStatus;
|
|
2076
|
-
/** An IANA published
|
|
2123
|
+
/** An IANA published [media type (MIME type)](https://www.iana.org/assignments/media-types/media-types.xhtml). */
|
|
2077
2124
|
mimeType?:
|
|
2078
2125
|
string;
|
|
2079
2126
|
/** Visual page layout for the Document. */
|
|
@@ -2312,7 +2359,7 @@ declare namespace gapi.client {
|
|
|
2312
2359
|
/** Confidence of detected language. Range `[0, 1]`. */
|
|
2313
2360
|
confidence?:
|
|
2314
2361
|
number;
|
|
2315
|
-
/** The BCP-47 language code, such as `en-US` or `sr-Latn`.
|
|
2362
|
+
/** The [BCP-47 language code](https://www.unicode.org/reports/tr35/#Unicode_locale_identifier), such as `en-US` or `sr-Latn`. */
|
|
2316
2363
|
languageCode?:
|
|
2317
2364
|
string;
|
|
2318
2365
|
}
|
|
@@ -2363,7 +2410,7 @@ declare namespace gapi.client {
|
|
|
2363
2410
|
/** Height of the image in pixels. */
|
|
2364
2411
|
height?:
|
|
2365
2412
|
number;
|
|
2366
|
-
/** Encoding
|
|
2413
|
+
/** Encoding [media type (MIME type)](https://www.iana.org/assignments/media-types/media-types.xhtml) for the image. */
|
|
2367
2414
|
mimeType?:
|
|
2368
2415
|
string;
|
|
2369
2416
|
/** Width of the image in pixels. */
|
|
@@ -2374,12 +2421,12 @@ declare namespace gapi.client {
|
|
|
2374
2421
|
/** A list of detected defects. */
|
|
2375
2422
|
detectedDefects?:
|
|
2376
2423
|
GoogleCloudDocumentaiV1beta3DocumentPageImageQualityScoresDetectedDefect[];
|
|
2377
|
-
/** The overall quality score. Range `[0, 1]` where 1 is perfect quality. */
|
|
2424
|
+
/** The overall quality score. Range `[0, 1]` where `1` is perfect quality. */
|
|
2378
2425
|
qualityScore?:
|
|
2379
2426
|
number;
|
|
2380
2427
|
}
|
|
2381
2428
|
interface GoogleCloudDocumentaiV1beta3DocumentPageImageQualityScoresDetectedDefect {
|
|
2382
|
-
/** Confidence of detected defect. Range `[0, 1]` where 1 indicates strong confidence of that the defect exists. */
|
|
2429
|
+
/** Confidence of detected defect. Range `[0, 1]` where `1` indicates strong confidence of that the defect exists. */
|
|
2383
2430
|
confidence?:
|
|
2384
2431
|
number;
|
|
2385
2432
|
/**
|
|
@@ -2649,6 +2696,9 @@ declare namespace gapi.client {
|
|
|
2649
2696
|
/** User defined name for the type. */
|
|
2650
2697
|
displayName?:
|
|
2651
2698
|
string;
|
|
2699
|
+
/** Metadata for the entity type. */
|
|
2700
|
+
entityTypeMetadata?:
|
|
2701
|
+
GoogleCloudDocumentaiV1beta3EntityTypeMetadata;
|
|
2652
2702
|
/**
|
|
2653
2703
|
* If specified, lists all the possible values for this entity. This should not be more than a handful of values. If the number of values is >10 or could change frequently use the
|
|
2654
2704
|
* `EntityType.value_ontology` field and specify a list of all possible values in a value ontology file.
|
|
@@ -2656,10 +2706,10 @@ declare namespace gapi.client {
|
|
|
2656
2706
|
enumValues?:
|
|
2657
2707
|
GoogleCloudDocumentaiV1beta3DocumentSchemaEntityTypeEnumValues;
|
|
2658
2708
|
/**
|
|
2659
|
-
* Name of the type. It must be unique within the schema file and cannot be a
|
|
2660
|
-
*
|
|
2661
|
-
*
|
|
2662
|
-
*
|
|
2709
|
+
* Name of the type. It must be unique within the schema file and cannot be a "Common Type". The following naming conventions are used: - Use `snake_casing` - Name matching is
|
|
2710
|
+
* case-sensitive - Maximum 64 characters. - Must start with a letter. - Allowed characters: ASCII letters `[a-z0-9_-]`. (For backward compatibility internal infrastructure and tooling
|
|
2711
|
+
* can handle any ascii character) - The `/` is sometimes used to denote a property of a type. For example `line_item/amount`. This convention is deprecated, but will still be honored
|
|
2712
|
+
* for backward compatibility.
|
|
2663
2713
|
*/
|
|
2664
2714
|
name?:
|
|
2665
2715
|
string;
|
|
@@ -2679,6 +2729,9 @@ declare namespace gapi.client {
|
|
|
2679
2729
|
/** Occurrence type limits the number of instances an entity type appears in the document. */
|
|
2680
2730
|
occurrenceType?:
|
|
2681
2731
|
string;
|
|
2732
|
+
/** Any additional metadata about the property can be added here. */
|
|
2733
|
+
propertyMetadata?:
|
|
2734
|
+
GoogleCloudDocumentaiV1beta3PropertyMetadata;
|
|
2682
2735
|
/** A reference to the value type of the property. This type is subject to the same conventions as the `Entity.base_types` field. */
|
|
2683
2736
|
valueType?:
|
|
2684
2737
|
string;
|
|
@@ -2687,7 +2740,7 @@ declare namespace gapi.client {
|
|
|
2687
2740
|
/** If true, on a given page, there can be multiple `document` annotations covering it. */
|
|
2688
2741
|
documentAllowMultipleLabels?:
|
|
2689
2742
|
boolean;
|
|
2690
|
-
/** If true, a `document` entity type can be applied to subdocument (
|
|
2743
|
+
/** If true, a `document` entity type can be applied to subdocument (splitting). Otherwise, it can only be applied to the entire document (classification). */
|
|
2691
2744
|
documentSplitter?:
|
|
2692
2745
|
boolean;
|
|
2693
2746
|
/** If set, all the nested entities must be prefixed with the parents. */
|
|
@@ -2724,16 +2777,16 @@ declare namespace gapi.client {
|
|
|
2724
2777
|
/** Font size. */
|
|
2725
2778
|
fontSize?:
|
|
2726
2779
|
GoogleCloudDocumentaiV1beta3DocumentStyleFontSize;
|
|
2727
|
-
/** Font weight. Possible values are normal
|
|
2780
|
+
/** [Font weight](https://www.w3schools.com/cssref/pr_font_weight.asp). Possible values are `normal`, `bold`, `bolder`, and `lighter`. */
|
|
2728
2781
|
fontWeight?:
|
|
2729
2782
|
string;
|
|
2730
2783
|
/** Text anchor indexing into the Document.text. */
|
|
2731
2784
|
textAnchor?:
|
|
2732
2785
|
GoogleCloudDocumentaiV1beta3DocumentTextAnchor;
|
|
2733
|
-
/** Text decoration
|
|
2786
|
+
/** [Text decoration](https://www.w3schools.com/cssref/pr_text_text-decoration.asp). Follows CSS standard. */
|
|
2734
2787
|
textDecoration?:
|
|
2735
2788
|
string;
|
|
2736
|
-
/** Text style. Possible values are normal
|
|
2789
|
+
/** [Text style](https://www.w3schools.com/cssref/pr_font_font-style.asp). Possible values are `normal`, `italic`, and `oblique`. */
|
|
2737
2790
|
textStyle?:
|
|
2738
2791
|
string;
|
|
2739
2792
|
}
|
|
@@ -2741,7 +2794,7 @@ declare namespace gapi.client {
|
|
|
2741
2794
|
/** Font size for the text. */
|
|
2742
2795
|
size?:
|
|
2743
2796
|
number;
|
|
2744
|
-
/** Unit for the font size. Follows CSS naming (in
|
|
2797
|
+
/** Unit for the font size. Follows CSS naming (`in`, `px`, `pt`, etc.). */
|
|
2745
2798
|
unit?:
|
|
2746
2799
|
string;
|
|
2747
2800
|
}
|
|
@@ -2786,6 +2839,11 @@ declare namespace gapi.client {
|
|
|
2786
2839
|
// tslint:disable-next-line:no-empty-interface
|
|
2787
2840
|
interface GoogleCloudDocumentaiV1beta3EnableProcessorResponse {
|
|
2788
2841
|
}
|
|
2842
|
+
interface GoogleCloudDocumentaiV1beta3EntityTypeMetadata {
|
|
2843
|
+
/** Whether the entity type should be considered as "inactive". */
|
|
2844
|
+
inactive?:
|
|
2845
|
+
boolean;
|
|
2846
|
+
}
|
|
2789
2847
|
interface GoogleCloudDocumentaiV1beta3EvaluateProcessorVersionMetadata {
|
|
2790
2848
|
/** The basic metadata of the long-running operation. */
|
|
2791
2849
|
commonMetadata?:
|
|
@@ -3046,7 +3104,7 @@ declare namespace gapi.client {
|
|
|
3046
3104
|
string[];
|
|
3047
3105
|
}
|
|
3048
3106
|
interface GoogleCloudDocumentaiV1beta3ProcessOptions {
|
|
3049
|
-
/** Only applicable to
|
|
3107
|
+
/** Only applicable to `OCR_PROCESSOR`. Returns error if set on other processor types. */
|
|
3050
3108
|
ocrConfig?:
|
|
3051
3109
|
GoogleCloudDocumentaiV1beta3OcrConfig;
|
|
3052
3110
|
}
|
|
@@ -3060,7 +3118,7 @@ declare namespace gapi.client {
|
|
|
3060
3118
|
/** The display name of the processor. */
|
|
3061
3119
|
displayName?:
|
|
3062
3120
|
string;
|
|
3063
|
-
/** The KMS key used for encryption/decryption in CMEK scenarios.
|
|
3121
|
+
/** The [KMS key](https://cloud.google.com/security-key-management) used for encryption/decryption in CMEK scenarios. */
|
|
3064
3122
|
kmsKeyName?:
|
|
3065
3123
|
string;
|
|
3066
3124
|
/** Output only. Immutable. The resource name of the processor. Format: `projects/{project}/locations/{location}/processors/{processor}` */
|
|
@@ -3100,7 +3158,7 @@ declare namespace gapi.client {
|
|
|
3100
3158
|
string;
|
|
3101
3159
|
}
|
|
3102
3160
|
interface GoogleCloudDocumentaiV1beta3ProcessorTypeLocationInfo {
|
|
3103
|
-
/** The location id,
|
|
3161
|
+
/** The location id, refer to [regional and multi-regional support](/document-ai/docs/regions) for supported locations. */
|
|
3104
3162
|
locationId?:
|
|
3105
3163
|
string;
|
|
3106
3164
|
}
|
|
@@ -3117,7 +3175,7 @@ declare namespace gapi.client {
|
|
|
3117
3175
|
/** The schema of the processor version. Describes the output. */
|
|
3118
3176
|
documentSchema?:
|
|
3119
3177
|
GoogleCloudDocumentaiV1beta3DocumentSchema;
|
|
3120
|
-
/** Denotes that this ProcessorVersion is managed by
|
|
3178
|
+
/** Denotes that this `ProcessorVersion` is managed by Google. */
|
|
3121
3179
|
googleManaged?:
|
|
3122
3180
|
boolean;
|
|
3123
3181
|
/** The KMS key name used for encryption. */
|
|
@@ -3181,6 +3239,11 @@ declare namespace gapi.client {
|
|
|
3181
3239
|
humanReviewStatus?:
|
|
3182
3240
|
GoogleCloudDocumentaiV1beta3HumanReviewStatus;
|
|
3183
3241
|
}
|
|
3242
|
+
interface GoogleCloudDocumentaiV1beta3PropertyMetadata {
|
|
3243
|
+
/** Whether the property should be considered as "inactive". */
|
|
3244
|
+
inactive?:
|
|
3245
|
+
boolean;
|
|
3246
|
+
}
|
|
3184
3247
|
interface GoogleCloudDocumentaiV1beta3RawDocument {
|
|
3185
3248
|
/** Inline document content. */
|
|
3186
3249
|
content?:
|
|
@@ -3820,6 +3883,137 @@ declare namespace gapi.client {
|
|
|
3820
3883
|
string;
|
|
3821
3884
|
}): Request<GoogleLongrunningListOperationsResponse>;
|
|
3822
3885
|
}
|
|
3886
|
+
interface DatasetResource {
|
|
3887
|
+
/** Gets the DatasetSchema of a Dataset. */
|
|
3888
|
+
getDatasetSchema(request?: {
|
|
3889
|
+
/** V1 error format. */
|
|
3890
|
+
"$.xgafv"?:
|
|
3891
|
+
string;
|
|
3892
|
+
/** OAuth access token. */
|
|
3893
|
+
access_token?:
|
|
3894
|
+
string;
|
|
3895
|
+
/** Data format for response. */
|
|
3896
|
+
alt?:
|
|
3897
|
+
string;
|
|
3898
|
+
/** JSONP */
|
|
3899
|
+
callback?:
|
|
3900
|
+
string;
|
|
3901
|
+
/** Selector specifying which fields to include in a partial response. */
|
|
3902
|
+
fields?:
|
|
3903
|
+
string;
|
|
3904
|
+
/** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
|
|
3905
|
+
key?:
|
|
3906
|
+
string;
|
|
3907
|
+
/** Required. The dataset schema resource name. Format: projects/{project}/locations/{location}/processors/{processor}/dataset/datasetSchema */
|
|
3908
|
+
name:
|
|
3909
|
+
string;
|
|
3910
|
+
/** OAuth 2.0 token for the current user. */
|
|
3911
|
+
oauth_token?:
|
|
3912
|
+
string;
|
|
3913
|
+
/** Returns response with indentations and line breaks. */
|
|
3914
|
+
prettyPrint?:
|
|
3915
|
+
boolean;
|
|
3916
|
+
/** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
|
|
3917
|
+
quotaUser?:
|
|
3918
|
+
string;
|
|
3919
|
+
/** Upload protocol for media (e.g. "raw", "multipart"). */
|
|
3920
|
+
upload_protocol?:
|
|
3921
|
+
string;
|
|
3922
|
+
/** Legacy upload protocol for media (e.g. "media", "multipart"). */
|
|
3923
|
+
uploadType?:
|
|
3924
|
+
string;
|
|
3925
|
+
/** If set, only returns the visible fields of the schema. */
|
|
3926
|
+
visibleFieldsOnly?:
|
|
3927
|
+
boolean;
|
|
3928
|
+
}): Request<GoogleCloudDocumentaiV1beta3DatasetSchema>;
|
|
3929
|
+
/** Updates a DatasetSchema. */
|
|
3930
|
+
updateDatasetSchema(request: {
|
|
3931
|
+
/** V1 error format. */
|
|
3932
|
+
"$.xgafv"?:
|
|
3933
|
+
string;
|
|
3934
|
+
/** OAuth access token. */
|
|
3935
|
+
access_token?:
|
|
3936
|
+
string;
|
|
3937
|
+
/** Data format for response. */
|
|
3938
|
+
alt?:
|
|
3939
|
+
string;
|
|
3940
|
+
/** JSONP */
|
|
3941
|
+
callback?:
|
|
3942
|
+
string;
|
|
3943
|
+
/** Selector specifying which fields to include in a partial response. */
|
|
3944
|
+
fields?:
|
|
3945
|
+
string;
|
|
3946
|
+
/** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
|
|
3947
|
+
key?:
|
|
3948
|
+
string;
|
|
3949
|
+
/** Dataset schema resource name. Format: `projects/{project}/locations/{location}/processors/{processor}/dataset/datasetSchema` */
|
|
3950
|
+
name:
|
|
3951
|
+
string;
|
|
3952
|
+
/** OAuth 2.0 token for the current user. */
|
|
3953
|
+
oauth_token?:
|
|
3954
|
+
string;
|
|
3955
|
+
/** Returns response with indentations and line breaks. */
|
|
3956
|
+
prettyPrint?:
|
|
3957
|
+
boolean;
|
|
3958
|
+
/** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
|
|
3959
|
+
quotaUser?:
|
|
3960
|
+
string;
|
|
3961
|
+
/** The update mask applies to the resource. */
|
|
3962
|
+
updateMask?:
|
|
3963
|
+
string;
|
|
3964
|
+
/** Upload protocol for media (e.g. "raw", "multipart"). */
|
|
3965
|
+
upload_protocol?:
|
|
3966
|
+
string;
|
|
3967
|
+
/** Legacy upload protocol for media (e.g. "media", "multipart"). */
|
|
3968
|
+
uploadType?:
|
|
3969
|
+
string;
|
|
3970
|
+
/** Request body */
|
|
3971
|
+
resource:
|
|
3972
|
+
GoogleCloudDocumentaiV1beta3DatasetSchema;
|
|
3973
|
+
}): Request<GoogleCloudDocumentaiV1beta3DatasetSchema>;
|
|
3974
|
+
updateDatasetSchema(request: {
|
|
3975
|
+
/** V1 error format. */
|
|
3976
|
+
"$.xgafv"?:
|
|
3977
|
+
string;
|
|
3978
|
+
/** OAuth access token. */
|
|
3979
|
+
access_token?:
|
|
3980
|
+
string;
|
|
3981
|
+
/** Data format for response. */
|
|
3982
|
+
alt?:
|
|
3983
|
+
string;
|
|
3984
|
+
/** JSONP */
|
|
3985
|
+
callback?:
|
|
3986
|
+
string;
|
|
3987
|
+
/** Selector specifying which fields to include in a partial response. */
|
|
3988
|
+
fields?:
|
|
3989
|
+
string;
|
|
3990
|
+
/** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
|
|
3991
|
+
key?:
|
|
3992
|
+
string;
|
|
3993
|
+
/** Dataset schema resource name. Format: `projects/{project}/locations/{location}/processors/{processor}/dataset/datasetSchema` */
|
|
3994
|
+
name:
|
|
3995
|
+
string;
|
|
3996
|
+
/** OAuth 2.0 token for the current user. */
|
|
3997
|
+
oauth_token?:
|
|
3998
|
+
string;
|
|
3999
|
+
/** Returns response with indentations and line breaks. */
|
|
4000
|
+
prettyPrint?:
|
|
4001
|
+
boolean;
|
|
4002
|
+
/** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
|
|
4003
|
+
quotaUser?:
|
|
4004
|
+
string;
|
|
4005
|
+
/** The update mask applies to the resource. */
|
|
4006
|
+
updateMask?:
|
|
4007
|
+
string;
|
|
4008
|
+
/** Upload protocol for media (e.g. "raw", "multipart"). */
|
|
4009
|
+
upload_protocol?:
|
|
4010
|
+
string;
|
|
4011
|
+
/** Legacy upload protocol for media (e.g. "media", "multipart"). */
|
|
4012
|
+
uploadType?:
|
|
4013
|
+
string;
|
|
4014
|
+
},
|
|
4015
|
+
body: GoogleCloudDocumentaiV1beta3DatasetSchema): Request<GoogleCloudDocumentaiV1beta3DatasetSchema>;
|
|
4016
|
+
}
|
|
3823
4017
|
interface HumanReviewConfigResource {
|
|
3824
4018
|
/** Send a document for Human Review. The input document should be processed by the specified processor. */
|
|
3825
4019
|
reviewDocument(request: {
|
|
@@ -5326,6 +5520,95 @@ declare namespace gapi.client {
|
|
|
5326
5520
|
string;
|
|
5327
5521
|
},
|
|
5328
5522
|
body: GoogleCloudDocumentaiV1beta3SetDefaultProcessorVersionRequest): Request<GoogleLongrunningOperation>;
|
|
5523
|
+
/** Updates metadata associated with a dataset. */
|
|
5524
|
+
updateDataset(request: {
|
|
5525
|
+
/** V1 error format. */
|
|
5526
|
+
"$.xgafv"?:
|
|
5527
|
+
string;
|
|
5528
|
+
/** OAuth access token. */
|
|
5529
|
+
access_token?:
|
|
5530
|
+
string;
|
|
5531
|
+
/** Data format for response. */
|
|
5532
|
+
alt?:
|
|
5533
|
+
string;
|
|
5534
|
+
/** JSONP */
|
|
5535
|
+
callback?:
|
|
5536
|
+
string;
|
|
5537
|
+
/** Selector specifying which fields to include in a partial response. */
|
|
5538
|
+
fields?:
|
|
5539
|
+
string;
|
|
5540
|
+
/** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
|
|
5541
|
+
key?:
|
|
5542
|
+
string;
|
|
5543
|
+
/** Dataset resource name. Format: `projects/{project}/locations/{location}/processors/{processor}/dataset` */
|
|
5544
|
+
name:
|
|
5545
|
+
string;
|
|
5546
|
+
/** OAuth 2.0 token for the current user. */
|
|
5547
|
+
oauth_token?:
|
|
5548
|
+
string;
|
|
5549
|
+
/** Returns response with indentations and line breaks. */
|
|
5550
|
+
prettyPrint?:
|
|
5551
|
+
boolean;
|
|
5552
|
+
/** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
|
|
5553
|
+
quotaUser?:
|
|
5554
|
+
string;
|
|
5555
|
+
/** The update mask applies to the resource. */
|
|
5556
|
+
updateMask?:
|
|
5557
|
+
string;
|
|
5558
|
+
/** Upload protocol for media (e.g. "raw", "multipart"). */
|
|
5559
|
+
upload_protocol?:
|
|
5560
|
+
string;
|
|
5561
|
+
/** Legacy upload protocol for media (e.g. "media", "multipart"). */
|
|
5562
|
+
uploadType?:
|
|
5563
|
+
string;
|
|
5564
|
+
/** Request body */
|
|
5565
|
+
resource:
|
|
5566
|
+
GoogleCloudDocumentaiV1beta3Dataset;
|
|
5567
|
+
}): Request<GoogleLongrunningOperation>;
|
|
5568
|
+
updateDataset(request: {
|
|
5569
|
+
/** V1 error format. */
|
|
5570
|
+
"$.xgafv"?:
|
|
5571
|
+
string;
|
|
5572
|
+
/** OAuth access token. */
|
|
5573
|
+
access_token?:
|
|
5574
|
+
string;
|
|
5575
|
+
/** Data format for response. */
|
|
5576
|
+
alt?:
|
|
5577
|
+
string;
|
|
5578
|
+
/** JSONP */
|
|
5579
|
+
callback?:
|
|
5580
|
+
string;
|
|
5581
|
+
/** Selector specifying which fields to include in a partial response. */
|
|
5582
|
+
fields?:
|
|
5583
|
+
string;
|
|
5584
|
+
/** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
|
|
5585
|
+
key?:
|
|
5586
|
+
string;
|
|
5587
|
+
/** Dataset resource name. Format: `projects/{project}/locations/{location}/processors/{processor}/dataset` */
|
|
5588
|
+
name:
|
|
5589
|
+
string;
|
|
5590
|
+
/** OAuth 2.0 token for the current user. */
|
|
5591
|
+
oauth_token?:
|
|
5592
|
+
string;
|
|
5593
|
+
/** Returns response with indentations and line breaks. */
|
|
5594
|
+
prettyPrint?:
|
|
5595
|
+
boolean;
|
|
5596
|
+
/** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
|
|
5597
|
+
quotaUser?:
|
|
5598
|
+
string;
|
|
5599
|
+
/** The update mask applies to the resource. */
|
|
5600
|
+
updateMask?:
|
|
5601
|
+
string;
|
|
5602
|
+
/** Upload protocol for media (e.g. "raw", "multipart"). */
|
|
5603
|
+
upload_protocol?:
|
|
5604
|
+
string;
|
|
5605
|
+
/** Legacy upload protocol for media (e.g. "media", "multipart"). */
|
|
5606
|
+
uploadType?:
|
|
5607
|
+
string;
|
|
5608
|
+
},
|
|
5609
|
+
body: GoogleCloudDocumentaiV1beta3Dataset): Request<GoogleLongrunningOperation>;
|
|
5610
|
+
dataset:
|
|
5611
|
+
DatasetResource;
|
|
5329
5612
|
humanReviewConfig:
|
|
5330
5613
|
HumanReviewConfigResource;
|
|
5331
5614
|
processorVersions:
|
package/package.json
CHANGED
package/tests.ts
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
// This file was generated by https://github.com/Maxim-Mazurok/google-api-typings-generator. Please do not edit it manually.
|
|
4
4
|
// In case of any problems please post issue to https://github.com/Maxim-Mazurok/google-api-typings-generator
|
|
5
5
|
|
|
6
|
-
// Revision:
|
|
6
|
+
// Revision: 20230605
|
|
7
7
|
|
|
8
8
|
gapi.load('client', async () => {
|
|
9
9
|
/** now we can use gapi.client */
|
|
@@ -1876,6 +1876,76 @@ gapi.load('client', async () => {
|
|
|
1876
1876
|
}, {
|
|
1877
1877
|
defaultProcessorVersion: "Test string",
|
|
1878
1878
|
});
|
|
1879
|
+
/** Updates metadata associated with a dataset. */
|
|
1880
|
+
await gapi.client.documentai.projects.locations.processors.updateDataset({
|
|
1881
|
+
name: "Test string",
|
|
1882
|
+
updateMask: "Test string",
|
|
1883
|
+
}, {
|
|
1884
|
+
documentWarehouseConfig: {
|
|
1885
|
+
collection: "Test string",
|
|
1886
|
+
schema: "Test string",
|
|
1887
|
+
},
|
|
1888
|
+
gcsManagedConfig: {
|
|
1889
|
+
gcsPrefix: {
|
|
1890
|
+
gcsUriPrefix: "Test string",
|
|
1891
|
+
},
|
|
1892
|
+
},
|
|
1893
|
+
name: "Test string",
|
|
1894
|
+
spannerIndexingConfig: {
|
|
1895
|
+
},
|
|
1896
|
+
state: "Test string",
|
|
1897
|
+
unmanagedDatasetConfig: {
|
|
1898
|
+
},
|
|
1899
|
+
});
|
|
1900
|
+
/** Gets the DatasetSchema of a Dataset. */
|
|
1901
|
+
await gapi.client.documentai.projects.locations.processors.dataset.getDatasetSchema({
|
|
1902
|
+
name: "Test string",
|
|
1903
|
+
visibleFieldsOnly: true,
|
|
1904
|
+
});
|
|
1905
|
+
/** Updates a DatasetSchema. */
|
|
1906
|
+
await gapi.client.documentai.projects.locations.processors.dataset.updateDatasetSchema({
|
|
1907
|
+
name: "Test string",
|
|
1908
|
+
updateMask: "Test string",
|
|
1909
|
+
}, {
|
|
1910
|
+
documentSchema: {
|
|
1911
|
+
description: "Test string",
|
|
1912
|
+
displayName: "Test string",
|
|
1913
|
+
entityTypes: [
|
|
1914
|
+
{
|
|
1915
|
+
baseTypes: [
|
|
1916
|
+
"Test string"
|
|
1917
|
+
],
|
|
1918
|
+
displayName: "Test string",
|
|
1919
|
+
entityTypeMetadata: {
|
|
1920
|
+
inactive: true,
|
|
1921
|
+
},
|
|
1922
|
+
enumValues: {
|
|
1923
|
+
values: [
|
|
1924
|
+
"Test string"
|
|
1925
|
+
],
|
|
1926
|
+
},
|
|
1927
|
+
name: "Test string",
|
|
1928
|
+
properties: [
|
|
1929
|
+
{
|
|
1930
|
+
name: "Test string",
|
|
1931
|
+
occurrenceType: "Test string",
|
|
1932
|
+
propertyMetadata: {
|
|
1933
|
+
inactive: true,
|
|
1934
|
+
},
|
|
1935
|
+
valueType: "Test string",
|
|
1936
|
+
}
|
|
1937
|
+
],
|
|
1938
|
+
}
|
|
1939
|
+
],
|
|
1940
|
+
metadata: {
|
|
1941
|
+
documentAllowMultipleLabels: true,
|
|
1942
|
+
documentSplitter: true,
|
|
1943
|
+
prefixedNamingOnProperties: true,
|
|
1944
|
+
skipNamingValidation: true,
|
|
1945
|
+
},
|
|
1946
|
+
},
|
|
1947
|
+
name: "Test string",
|
|
1948
|
+
});
|
|
1879
1949
|
/** Send a document for Human Review. The input document should be processed by the specified processor. */
|
|
1880
1950
|
await gapi.client.documentai.projects.locations.processors.humanReviewConfig.reviewDocument({
|
|
1881
1951
|
humanReviewConfig: "Test string",
|
|
@@ -2733,6 +2803,9 @@ gapi.load('client', async () => {
|
|
|
2733
2803
|
"Test string"
|
|
2734
2804
|
],
|
|
2735
2805
|
displayName: "Test string",
|
|
2806
|
+
entityTypeMetadata: {
|
|
2807
|
+
inactive: true,
|
|
2808
|
+
},
|
|
2736
2809
|
enumValues: {
|
|
2737
2810
|
values: [
|
|
2738
2811
|
"Test string"
|
|
@@ -2743,6 +2816,9 @@ gapi.load('client', async () => {
|
|
|
2743
2816
|
{
|
|
2744
2817
|
name: "Test string",
|
|
2745
2818
|
occurrenceType: "Test string",
|
|
2819
|
+
propertyMetadata: {
|
|
2820
|
+
inactive: true,
|
|
2821
|
+
},
|
|
2746
2822
|
valueType: "Test string",
|
|
2747
2823
|
}
|
|
2748
2824
|
],
|
|
@@ -5428,6 +5504,9 @@ gapi.load('client', async () => {
|
|
|
5428
5504
|
"Test string"
|
|
5429
5505
|
],
|
|
5430
5506
|
displayName: "Test string",
|
|
5507
|
+
entityTypeMetadata: {
|
|
5508
|
+
inactive: true,
|
|
5509
|
+
},
|
|
5431
5510
|
enumValues: {
|
|
5432
5511
|
values: [
|
|
5433
5512
|
"Test string"
|
|
@@ -5438,6 +5517,9 @@ gapi.load('client', async () => {
|
|
|
5438
5517
|
{
|
|
5439
5518
|
name: "Test string",
|
|
5440
5519
|
occurrenceType: "Test string",
|
|
5520
|
+
propertyMetadata: {
|
|
5521
|
+
inactive: true,
|
|
5522
|
+
},
|
|
5441
5523
|
valueType: "Test string",
|
|
5442
5524
|
}
|
|
5443
5525
|
],
|
|
@@ -5494,6 +5576,9 @@ gapi.load('client', async () => {
|
|
|
5494
5576
|
"Test string"
|
|
5495
5577
|
],
|
|
5496
5578
|
displayName: "Test string",
|
|
5579
|
+
entityTypeMetadata: {
|
|
5580
|
+
inactive: true,
|
|
5581
|
+
},
|
|
5497
5582
|
enumValues: {
|
|
5498
5583
|
values: [
|
|
5499
5584
|
"Test string"
|
|
@@ -5504,6 +5589,9 @@ gapi.load('client', async () => {
|
|
|
5504
5589
|
{
|
|
5505
5590
|
name: "Test string",
|
|
5506
5591
|
occurrenceType: "Test string",
|
|
5592
|
+
propertyMetadata: {
|
|
5593
|
+
inactive: true,
|
|
5594
|
+
},
|
|
5507
5595
|
valueType: "Test string",
|
|
5508
5596
|
}
|
|
5509
5597
|
],
|