@maxim_mazurok/gapi.client.documentai-v1 0.0.20221108 → 0.0.20221114

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 (3) hide show
  1. package/index.d.ts +94 -237
  2. package/package.json +1 -1
  3. package/tests.ts +1 -37
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=v1
12
- // Revision: 20221108
12
+ // Revision: 20221114
13
13
 
14
14
  /// <reference types="gapi.client" />
15
15
 
@@ -291,24 +291,24 @@ declare namespace gapi.client {
291
291
  }
292
292
  interface GoogleCloudDocumentaiV1Barcode {
293
293
  /**
294
- * Format of a barcode. The supported formats are: CODE_128: Code 128 type. CODE_39: Code 39 type. CODE_93: Code 93 type. CODABAR: Codabar type. DATA_MATRIX: 2D Data Matrix type. ITF:
295
- * ITF type. EAN_13: EAN-13 type. EAN_8: EAN-8 type. QR_CODE: 2D QR code type. UPC_A: UPC-A type. UPC_E: UPC-E type. PDF417: PDF417 type. AZTEC: 2D Aztec code type. DATABAR: GS1
296
- * DataBar code type.
294
+ * Format of a barcode. The supported formats are: - `CODE_128`: Code 128 type. - `CODE_39`: Code 39 type. - `CODE_93`: Code 93 type. - `CODABAR`: Codabar type. - `DATA_MATRIX`: 2D
295
+ * Data Matrix type. - `ITF`: ITF type. - `EAN_13`: EAN-13 type. - `EAN_8`: EAN-8 type. - `QR_CODE`: 2D QR code type. - `UPC_A`: UPC-A type. - `UPC_E`: UPC-E type. - `PDF417`: PDF417
296
+ * type. - `AZTEC`: 2D Aztec code type. - `DATABAR`: GS1 DataBar code type.
297
297
  */
298
298
  format?: string;
299
- /** Raw value encoded in the barcode. For example, 'MEBKM:TITLE:Google;URL:https://www.google.com;;'. */
299
+ /** Raw value encoded in the barcode. For example: `'MEBKM:TITLE:Google;URL:https://www.google.com;;'`. */
300
300
  rawValue?: string;
301
301
  /**
302
- * Value format describes the format of the value that a barcode encodes. The supported formats are: CONTACT_INFO: Contact information. EMAIL: Email address. ISBN: ISBN identifier.
303
- * PHONE: Phone number. PRODUCT: Product. SMS: SMS message. TEXT: Text string. URL: URL address. WIFI: Wifi information. GEO: Geo-localization. CALENDAR_EVENT: Calendar event.
304
- * DRIVER_LICENSE: Driver's license.
302
+ * Value format describes the format of the value that a barcode encodes. The supported formats are: - `CONTACT_INFO`: Contact information. - `EMAIL`: Email address. - `ISBN`: ISBN
303
+ * identifier. - `PHONE`: Phone number. - `PRODUCT`: Product. - `SMS`: SMS message. - `TEXT`: Text string. - `URL`: URL address. - `WIFI`: Wifi information. - `GEO`: Geo-localization.
304
+ * - `CALENDAR_EVENT`: Calendar event. - `DRIVER_LICENSE`: Driver's license.
305
305
  */
306
306
  valueFormat?: string;
307
307
  }
308
308
  interface GoogleCloudDocumentaiV1BatchDocumentsInputConfig {
309
309
  /** The set of documents individually specified on Cloud Storage. */
310
310
  gcsDocuments?: GoogleCloudDocumentaiV1GcsDocuments;
311
- /** The set of documents that match the specified Cloud Storage [gcs_prefix]. */
311
+ /** The set of documents that match the specified Cloud Storage `gcs_prefix`. */
312
312
  gcsPrefix?: GoogleCloudDocumentaiV1GcsPrefix;
313
313
  }
314
314
  interface GoogleCloudDocumentaiV1BatchProcessMetadata {
@@ -349,17 +349,17 @@ declare namespace gapi.client {
349
349
  }
350
350
  interface GoogleCloudDocumentaiV1beta1Barcode {
351
351
  /**
352
- * Format of a barcode. The supported formats are: CODE_128: Code 128 type. CODE_39: Code 39 type. CODE_93: Code 93 type. CODABAR: Codabar type. DATA_MATRIX: 2D Data Matrix type. ITF:
353
- * ITF type. EAN_13: EAN-13 type. EAN_8: EAN-8 type. QR_CODE: 2D QR code type. UPC_A: UPC-A type. UPC_E: UPC-E type. PDF417: PDF417 type. AZTEC: 2D Aztec code type. DATABAR: GS1
354
- * DataBar code type.
352
+ * Format of a barcode. The supported formats are: - `CODE_128`: Code 128 type. - `CODE_39`: Code 39 type. - `CODE_93`: Code 93 type. - `CODABAR`: Codabar type. - `DATA_MATRIX`: 2D
353
+ * Data Matrix type. - `ITF`: ITF type. - `EAN_13`: EAN-13 type. - `EAN_8`: EAN-8 type. - `QR_CODE`: 2D QR code type. - `UPC_A`: UPC-A type. - `UPC_E`: UPC-E type. - `PDF417`: PDF417
354
+ * type. - `AZTEC`: 2D Aztec code type. - `DATABAR`: GS1 DataBar code type.
355
355
  */
356
356
  format?: string;
357
- /** Raw value encoded in the barcode. For example, 'MEBKM:TITLE:Google;URL:https://www.google.com;;'. */
357
+ /** Raw value encoded in the barcode. For example: `'MEBKM:TITLE:Google;URL:https://www.google.com;;'`. */
358
358
  rawValue?: string;
359
359
  /**
360
- * Value format describes the format of the value that a barcode encodes. The supported formats are: CONTACT_INFO: Contact information. EMAIL: Email address. ISBN: ISBN identifier.
361
- * PHONE: Phone number. PRODUCT: Product. SMS: SMS message. TEXT: Text string. URL: URL address. WIFI: Wifi information. GEO: Geo-localization. CALENDAR_EVENT: Calendar event.
362
- * DRIVER_LICENSE: Driver's license.
360
+ * Value format describes the format of the value that a barcode encodes. The supported formats are: - `CONTACT_INFO`: Contact information. - `EMAIL`: Email address. - `ISBN`: ISBN
361
+ * identifier. - `PHONE`: Phone number. - `PRODUCT`: Product. - `SMS`: SMS message. - `TEXT`: Text string. - `URL`: URL address. - `WIFI`: Wifi information. - `GEO`: Geo-localization.
362
+ * - `CALENDAR_EVENT`: Calendar event. - `DRIVER_LICENSE`: Driver's license.
363
363
  */
364
364
  valueFormat?: string;
365
365
  }
@@ -396,7 +396,7 @@ declare namespace gapi.client {
396
396
  /** Optional. UTF-8 encoded text in reading order from the document. */
397
397
  text?: string;
398
398
  /**
399
- * Placeholder. A list of text corrections made to [Document.text]. This is usually used for annotating corrections to OCR mistakes. Text changes for a given revision may not overlap
399
+ * Placeholder. A list of text corrections made to Document.text. This is usually used for annotating corrections to OCR mistakes. Text changes for a given revision may not overlap
400
400
  * with each other.
401
401
  */
402
402
  textChanges?: GoogleCloudDocumentaiV1beta1DocumentTextChange[];
@@ -409,7 +409,7 @@ declare namespace gapi.client {
409
409
  uri?: string;
410
410
  }
411
411
  interface GoogleCloudDocumentaiV1beta1DocumentEntity {
412
- /** Optional. Confidence of detected Schema entity. Range [0, 1]. */
412
+ /** Optional. Confidence of detected Schema entity. Range `[0, 1]`. */
413
413
  confidence?: number;
414
414
  /** Optional. Canonical id. This will be a unique value in the entity list for this document. */
415
415
  id?: string;
@@ -509,7 +509,7 @@ declare namespace gapi.client {
509
509
  interface GoogleCloudDocumentaiV1beta1DocumentPageAnchorPageRef {
510
510
  /** Optional. Identifies the bounding polygon of a layout element on the page. */
511
511
  boundingPoly?: GoogleCloudDocumentaiV1beta1BoundingPoly;
512
- /** Optional. Confidence of detected page element, if applicable. Range [0, 1]. */
512
+ /** Optional. Confidence of detected page element, if applicable. Range `[0, 1]`. */
513
513
  confidence?: number;
514
514
  /** Optional. Deprecated. Use PageRef.bounding_poly instead. */
515
515
  layoutId?: string;
@@ -536,9 +536,9 @@ declare namespace gapi.client {
536
536
  layout?: GoogleCloudDocumentaiV1beta1DocumentPageLayout;
537
537
  }
538
538
  interface GoogleCloudDocumentaiV1beta1DocumentPageDetectedLanguage {
539
- /** Confidence of detected language. Range [0, 1]. */
539
+ /** Confidence of detected language. Range `[0, 1]`. */
540
540
  confidence?: number;
541
- /** The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see https://www.unicode.org/reports/tr35/#Unicode_locale_identifier. */
541
+ /** The BCP-47 language code, such as `en-US` or `sr-Latn`. For more information, see https://www.unicode.org/reports/tr35/#Unicode_locale_identifier. */
542
542
  languageCode?: string;
543
543
  }
544
544
  interface GoogleCloudDocumentaiV1beta1DocumentPageDimension {
@@ -583,15 +583,15 @@ declare namespace gapi.client {
583
583
  interface GoogleCloudDocumentaiV1beta1DocumentPageImageQualityScores {
584
584
  /** A list of detected defects. */
585
585
  detectedDefects?: GoogleCloudDocumentaiV1beta1DocumentPageImageQualityScoresDetectedDefect[];
586
- /** The overall quality score. Range [0, 1] where 1 is perfect quality. */
586
+ /** The overall quality score. Range `[0, 1]` where 1 is perfect quality. */
587
587
  qualityScore?: number;
588
588
  }
589
589
  interface GoogleCloudDocumentaiV1beta1DocumentPageImageQualityScoresDetectedDefect {
590
- /** Confidence of detected defect. Range [0, 1] where 1 indicates strong confidence of that the defect exists. */
590
+ /** Confidence of detected defect. Range `[0, 1]` where 1 indicates strong confidence of that the defect exists. */
591
591
  confidence?: number;
592
592
  /**
593
- * Name of the defect type. Supported values are "quality/defect_blurry", "quality/defect_noisy", "quality/defect_dark", "quality/defect_faint", "quality/defect_text_too_small",
594
- * "quality/defect_document_cutoff", "quality/defect_text_cutoff", "quality/defect_glare"
593
+ * Name of the defect type. Supported values are: - `quality/defect_blurry` - `quality/defect_noisy` - `quality/defect_dark` - `quality/defect_faint` - `quality/defect_text_too_small`
594
+ * - `quality/defect_document_cutoff` - `quality/defect_text_cutoff` - `quality/defect_glare`
595
595
  */
596
596
  type?: string;
597
597
  }
@@ -600,7 +600,7 @@ declare namespace gapi.client {
600
600
  boundingPoly?: GoogleCloudDocumentaiV1beta1BoundingPoly;
601
601
  /**
602
602
  * Confidence of the current Layout within context of the object this layout is for. e.g. confidence can be for a single token, a table, a visual element, etc. depending on context.
603
- * Range [0, 1].
603
+ * Range `[0, 1]`.
604
604
  */
605
605
  confidence?: number;
606
606
  /** Detected orientation for the Layout. */
@@ -747,7 +747,7 @@ declare namespace gapi.client {
747
747
  backgroundColor?: GoogleTypeColor;
748
748
  /** Text color. */
749
749
  color?: GoogleTypeColor;
750
- /** Font family such as "Arial", "Times New Roman". https://www.w3schools.com/cssref/pr_font_font-family.asp */
750
+ /** Font family such as `Arial`, `Times New Roman`. https://www.w3schools.com/cssref/pr_font_font-family.asp */
751
751
  fontFamily?: string;
752
752
  /** Font size. */
753
753
  fontSize?: GoogleCloudDocumentaiV1beta1DocumentStyleFontSize;
@@ -845,17 +845,17 @@ declare namespace gapi.client {
845
845
  }
846
846
  interface GoogleCloudDocumentaiV1beta2Barcode {
847
847
  /**
848
- * Format of a barcode. The supported formats are: CODE_128: Code 128 type. CODE_39: Code 39 type. CODE_93: Code 93 type. CODABAR: Codabar type. DATA_MATRIX: 2D Data Matrix type. ITF:
849
- * ITF type. EAN_13: EAN-13 type. EAN_8: EAN-8 type. QR_CODE: 2D QR code type. UPC_A: UPC-A type. UPC_E: UPC-E type. PDF417: PDF417 type. AZTEC: 2D Aztec code type. DATABAR: GS1
850
- * DataBar code type.
848
+ * Format of a barcode. The supported formats are: - `CODE_128`: Code 128 type. - `CODE_39`: Code 39 type. - `CODE_93`: Code 93 type. - `CODABAR`: Codabar type. - `DATA_MATRIX`: 2D
849
+ * Data Matrix type. - `ITF`: ITF type. - `EAN_13`: EAN-13 type. - `EAN_8`: EAN-8 type. - `QR_CODE`: 2D QR code type. - `UPC_A`: UPC-A type. - `UPC_E`: UPC-E type. - `PDF417`: PDF417
850
+ * type. - `AZTEC`: 2D Aztec code type. - `DATABAR`: GS1 DataBar code type.
851
851
  */
852
852
  format?: string;
853
- /** Raw value encoded in the barcode. For example, 'MEBKM:TITLE:Google;URL:https://www.google.com;;'. */
853
+ /** Raw value encoded in the barcode. For example: `'MEBKM:TITLE:Google;URL:https://www.google.com;;'`. */
854
854
  rawValue?: string;
855
855
  /**
856
- * Value format describes the format of the value that a barcode encodes. The supported formats are: CONTACT_INFO: Contact information. EMAIL: Email address. ISBN: ISBN identifier.
857
- * PHONE: Phone number. PRODUCT: Product. SMS: SMS message. TEXT: Text string. URL: URL address. WIFI: Wifi information. GEO: Geo-localization. CALENDAR_EVENT: Calendar event.
858
- * DRIVER_LICENSE: Driver's license.
856
+ * Value format describes the format of the value that a barcode encodes. The supported formats are: - `CONTACT_INFO`: Contact information. - `EMAIL`: Email address. - `ISBN`: ISBN
857
+ * identifier. - `PHONE`: Phone number. - `PRODUCT`: Product. - `SMS`: SMS message. - `TEXT`: Text string. - `URL`: URL address. - `WIFI`: Wifi information. - `GEO`: Geo-localization.
858
+ * - `CALENDAR_EVENT`: Calendar event. - `DRIVER_LICENSE`: Driver's license.
859
859
  */
860
860
  valueFormat?: string;
861
861
  }
@@ -894,7 +894,7 @@ declare namespace gapi.client {
894
894
  /** Optional. UTF-8 encoded text in reading order from the document. */
895
895
  text?: string;
896
896
  /**
897
- * Placeholder. A list of text corrections made to [Document.text]. This is usually used for annotating corrections to OCR mistakes. Text changes for a given revision may not overlap
897
+ * Placeholder. A list of text corrections made to Document.text. This is usually used for annotating corrections to OCR mistakes. Text changes for a given revision may not overlap
898
898
  * with each other.
899
899
  */
900
900
  textChanges?: GoogleCloudDocumentaiV1beta2DocumentTextChange[];
@@ -907,7 +907,7 @@ declare namespace gapi.client {
907
907
  uri?: string;
908
908
  }
909
909
  interface GoogleCloudDocumentaiV1beta2DocumentEntity {
910
- /** Optional. Confidence of detected Schema entity. Range [0, 1]. */
910
+ /** Optional. Confidence of detected Schema entity. Range `[0, 1]`. */
911
911
  confidence?: number;
912
912
  /** Optional. Canonical id. This will be a unique value in the entity list for this document. */
913
913
  id?: string;
@@ -1015,7 +1015,7 @@ declare namespace gapi.client {
1015
1015
  interface GoogleCloudDocumentaiV1beta2DocumentPageAnchorPageRef {
1016
1016
  /** Optional. Identifies the bounding polygon of a layout element on the page. */
1017
1017
  boundingPoly?: GoogleCloudDocumentaiV1beta2BoundingPoly;
1018
- /** Optional. Confidence of detected page element, if applicable. Range [0, 1]. */
1018
+ /** Optional. Confidence of detected page element, if applicable. Range `[0, 1]`. */
1019
1019
  confidence?: number;
1020
1020
  /** Optional. Deprecated. Use PageRef.bounding_poly instead. */
1021
1021
  layoutId?: string;
@@ -1042,9 +1042,9 @@ declare namespace gapi.client {
1042
1042
  layout?: GoogleCloudDocumentaiV1beta2DocumentPageLayout;
1043
1043
  }
1044
1044
  interface GoogleCloudDocumentaiV1beta2DocumentPageDetectedLanguage {
1045
- /** Confidence of detected language. Range [0, 1]. */
1045
+ /** Confidence of detected language. Range `[0, 1]`. */
1046
1046
  confidence?: number;
1047
- /** The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see https://www.unicode.org/reports/tr35/#Unicode_locale_identifier. */
1047
+ /** The BCP-47 language code, such as `en-US` or `sr-Latn`. For more information, see https://www.unicode.org/reports/tr35/#Unicode_locale_identifier. */
1048
1048
  languageCode?: string;
1049
1049
  }
1050
1050
  interface GoogleCloudDocumentaiV1beta2DocumentPageDimension {
@@ -1089,15 +1089,15 @@ declare namespace gapi.client {
1089
1089
  interface GoogleCloudDocumentaiV1beta2DocumentPageImageQualityScores {
1090
1090
  /** A list of detected defects. */
1091
1091
  detectedDefects?: GoogleCloudDocumentaiV1beta2DocumentPageImageQualityScoresDetectedDefect[];
1092
- /** The overall quality score. Range [0, 1] where 1 is perfect quality. */
1092
+ /** The overall quality score. Range `[0, 1]` where 1 is perfect quality. */
1093
1093
  qualityScore?: number;
1094
1094
  }
1095
1095
  interface GoogleCloudDocumentaiV1beta2DocumentPageImageQualityScoresDetectedDefect {
1096
- /** Confidence of detected defect. Range [0, 1] where 1 indicates strong confidence of that the defect exists. */
1096
+ /** Confidence of detected defect. Range `[0, 1]` where 1 indicates strong confidence of that the defect exists. */
1097
1097
  confidence?: number;
1098
1098
  /**
1099
- * Name of the defect type. Supported values are "quality/defect_blurry", "quality/defect_noisy", "quality/defect_dark", "quality/defect_faint", "quality/defect_text_too_small",
1100
- * "quality/defect_document_cutoff", "quality/defect_text_cutoff", "quality/defect_glare"
1099
+ * Name of the defect type. Supported values are: - `quality/defect_blurry` - `quality/defect_noisy` - `quality/defect_dark` - `quality/defect_faint` - `quality/defect_text_too_small`
1100
+ * - `quality/defect_document_cutoff` - `quality/defect_text_cutoff` - `quality/defect_glare`
1101
1101
  */
1102
1102
  type?: string;
1103
1103
  }
@@ -1106,7 +1106,7 @@ declare namespace gapi.client {
1106
1106
  boundingPoly?: GoogleCloudDocumentaiV1beta2BoundingPoly;
1107
1107
  /**
1108
1108
  * Confidence of the current Layout within context of the object this layout is for. e.g. confidence can be for a single token, a table, a visual element, etc. depending on context.
1109
- * Range [0, 1].
1109
+ * Range `[0, 1]`.
1110
1110
  */
1111
1111
  confidence?: number;
1112
1112
  /** Detected orientation for the Layout. */
@@ -1253,7 +1253,7 @@ declare namespace gapi.client {
1253
1253
  backgroundColor?: GoogleTypeColor;
1254
1254
  /** Text color. */
1255
1255
  color?: GoogleTypeColor;
1256
- /** Font family such as "Arial", "Times New Roman". https://www.w3schools.com/cssref/pr_font_font-family.asp */
1256
+ /** Font family such as `Arial`, `Times New Roman`. https://www.w3schools.com/cssref/pr_font_font-family.asp */
1257
1257
  fontFamily?: string;
1258
1258
  /** Font size. */
1259
1259
  fontSize?: GoogleCloudDocumentaiV1beta2DocumentStyleFontSize;
@@ -1428,6 +1428,14 @@ declare namespace gapi.client {
1428
1428
  // tslint:disable-next-line:no-empty-interface
1429
1429
  interface GoogleCloudDocumentaiV1beta3EnableProcessorResponse {
1430
1430
  }
1431
+ interface GoogleCloudDocumentaiV1beta3EvaluateProcessorVersionMetadata {
1432
+ /** The basic metadata of the long running operation. */
1433
+ commonMetadata?: GoogleCloudDocumentaiV1beta3CommonOperationMetadata;
1434
+ }
1435
+ interface GoogleCloudDocumentaiV1beta3EvaluateProcessorVersionResponse {
1436
+ /** The resource name of the created evaluation. */
1437
+ evaluation?: string;
1438
+ }
1431
1439
  interface GoogleCloudDocumentaiV1beta3HumanReviewStatus {
1432
1440
  /**
1433
1441
  * The name of the operation triggered by the processed document. This field is populated only when the [state] is [HUMAN_REVIEW_IN_PROGRESS]. It has the same response type and
@@ -1468,6 +1476,28 @@ declare namespace gapi.client {
1468
1476
  // tslint:disable-next-line:no-empty-interface
1469
1477
  interface GoogleCloudDocumentaiV1beta3SetDefaultProcessorVersionResponse {
1470
1478
  }
1479
+ interface GoogleCloudDocumentaiV1beta3TrainProcessorVersionMetadata {
1480
+ /** The basic metadata of the long running operation. */
1481
+ commonMetadata?: GoogleCloudDocumentaiV1beta3CommonOperationMetadata;
1482
+ /** The test dataset validation information. */
1483
+ testDatasetValidation?: GoogleCloudDocumentaiV1beta3TrainProcessorVersionMetadataDatasetValidation;
1484
+ /** The training dataset validation information. */
1485
+ trainingDatasetValidation?: GoogleCloudDocumentaiV1beta3TrainProcessorVersionMetadataDatasetValidation;
1486
+ }
1487
+ interface GoogleCloudDocumentaiV1beta3TrainProcessorVersionMetadataDatasetValidation {
1488
+ /** The total number of dataset errors. */
1489
+ datasetErrorCount?: number;
1490
+ /** Error information for the dataset as a whole. A maximum of 10 dataset errors will be returned. A single dataset error is terminal for training. */
1491
+ datasetErrors?: GoogleRpcStatus[];
1492
+ /** The total number of document errors. */
1493
+ documentErrorCount?: number;
1494
+ /** Error information pertaining to specific documents. A maximum of 10 document errors will be returned. Any document with errors will not be used throughout training. */
1495
+ documentErrors?: GoogleRpcStatus[];
1496
+ }
1497
+ interface GoogleCloudDocumentaiV1beta3TrainProcessorVersionResponse {
1498
+ /** The resource name of the processor version produced by training. */
1499
+ processorVersion?: string;
1500
+ }
1471
1501
  interface GoogleCloudDocumentaiV1beta3UndeployProcessorVersionMetadata {
1472
1502
  /** The basic metadata of the long running operation. */
1473
1503
  commonMetadata?: GoogleCloudDocumentaiV1beta3CommonOperationMetadata;
@@ -1544,7 +1574,7 @@ declare namespace gapi.client {
1544
1574
  /** Optional. UTF-8 encoded text in reading order from the document. */
1545
1575
  text?: string;
1546
1576
  /**
1547
- * Placeholder. A list of text corrections made to [Document.text]. This is usually used for annotating corrections to OCR mistakes. Text changes for a given revision may not overlap
1577
+ * Placeholder. A list of text corrections made to Document.text. This is usually used for annotating corrections to OCR mistakes. Text changes for a given revision may not overlap
1548
1578
  * with each other.
1549
1579
  */
1550
1580
  textChanges?: GoogleCloudDocumentaiV1DocumentTextChange[];
@@ -1557,7 +1587,7 @@ declare namespace gapi.client {
1557
1587
  uri?: string;
1558
1588
  }
1559
1589
  interface GoogleCloudDocumentaiV1DocumentEntity {
1560
- /** Optional. Confidence of detected Schema entity. Range [0, 1]. */
1590
+ /** Optional. Confidence of detected Schema entity. Range `[0, 1]`. */
1561
1591
  confidence?: number;
1562
1592
  /** Optional. Canonical id. This will be a unique value in the entity list for this document. */
1563
1593
  id?: string;
@@ -1670,7 +1700,7 @@ declare namespace gapi.client {
1670
1700
  interface GoogleCloudDocumentaiV1DocumentPageAnchorPageRef {
1671
1701
  /** Optional. Identifies the bounding polygon of a layout element on the page. */
1672
1702
  boundingPoly?: GoogleCloudDocumentaiV1BoundingPoly;
1673
- /** Optional. Confidence of detected page element, if applicable. Range [0, 1]. */
1703
+ /** Optional. Confidence of detected page element, if applicable. Range `[0, 1]`. */
1674
1704
  confidence?: number;
1675
1705
  /** Optional. Deprecated. Use PageRef.bounding_poly instead. */
1676
1706
  layoutId?: string;
@@ -1697,9 +1727,9 @@ declare namespace gapi.client {
1697
1727
  layout?: GoogleCloudDocumentaiV1DocumentPageLayout;
1698
1728
  }
1699
1729
  interface GoogleCloudDocumentaiV1DocumentPageDetectedLanguage {
1700
- /** Confidence of detected language. Range [0, 1]. */
1730
+ /** Confidence of detected language. Range `[0, 1]`. */
1701
1731
  confidence?: number;
1702
- /** The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see https://www.unicode.org/reports/tr35/#Unicode_locale_identifier. */
1732
+ /** The BCP-47 language code, such as `en-US` or `sr-Latn`. For more information, see https://www.unicode.org/reports/tr35/#Unicode_locale_identifier. */
1703
1733
  languageCode?: string;
1704
1734
  }
1705
1735
  interface GoogleCloudDocumentaiV1DocumentPageDimension {
@@ -1744,15 +1774,15 @@ declare namespace gapi.client {
1744
1774
  interface GoogleCloudDocumentaiV1DocumentPageImageQualityScores {
1745
1775
  /** A list of detected defects. */
1746
1776
  detectedDefects?: GoogleCloudDocumentaiV1DocumentPageImageQualityScoresDetectedDefect[];
1747
- /** The overall quality score. Range [0, 1] where 1 is perfect quality. */
1777
+ /** The overall quality score. Range `[0, 1]` where 1 is perfect quality. */
1748
1778
  qualityScore?: number;
1749
1779
  }
1750
1780
  interface GoogleCloudDocumentaiV1DocumentPageImageQualityScoresDetectedDefect {
1751
- /** Confidence of detected defect. Range [0, 1] where 1 indicates strong confidence of that the defect exists. */
1781
+ /** Confidence of detected defect. Range `[0, 1]` where 1 indicates strong confidence of that the defect exists. */
1752
1782
  confidence?: number;
1753
1783
  /**
1754
- * Name of the defect type. Supported values are "quality/defect_blurry", "quality/defect_noisy", "quality/defect_dark", "quality/defect_faint", "quality/defect_text_too_small",
1755
- * "quality/defect_document_cutoff", "quality/defect_text_cutoff", "quality/defect_glare"
1784
+ * Name of the defect type. Supported values are: - `quality/defect_blurry` - `quality/defect_noisy` - `quality/defect_dark` - `quality/defect_faint` - `quality/defect_text_too_small`
1785
+ * - `quality/defect_document_cutoff` - `quality/defect_text_cutoff` - `quality/defect_glare`
1756
1786
  */
1757
1787
  type?: string;
1758
1788
  }
@@ -1761,7 +1791,7 @@ declare namespace gapi.client {
1761
1791
  boundingPoly?: GoogleCloudDocumentaiV1BoundingPoly;
1762
1792
  /**
1763
1793
  * Confidence of the current Layout within context of the object this layout is for. e.g. confidence can be for a single token, a table, a visual element, etc. depending on context.
1764
- * Range [0, 1].
1794
+ * Range `[0, 1]`.
1765
1795
  */
1766
1796
  confidence?: number;
1767
1797
  /** Detected orientation for the Layout. */
@@ -1916,10 +1946,10 @@ declare namespace gapi.client {
1916
1946
  */
1917
1947
  enumValues?: GoogleCloudDocumentaiV1DocumentSchemaEntityTypeEnumValues;
1918
1948
  /**
1919
- * Name of the type. It must be unique within the schema file and cannot be a 'Common Type'. Besides that we use the following naming conventions: - *use snake_casing* - name matching
1920
- * is case-insensitive - Maximum 64 characters. - Must start with a letter. - Allowed characters: ASCII letters `[a-z0-9_-]`. (For backward compatibility internal infrastructure and
1921
- * tooling 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
1922
- * honored for backward compatibility.
1949
+ * Name of the type. It must be unique within the schema file and cannot be a 'Common Type'. Besides that we use the following naming conventions: - *use `snake_casing`* - name
1950
+ * matching is case-insensitive - Maximum 64 characters. - Must start with a letter. - Allowed characters: ASCII letters `[a-z0-9_-]`. (For backward compatibility internal
1951
+ * infrastructure and tooling 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,
1952
+ * but will still be honored for backward compatibility.
1923
1953
  */
1924
1954
  name?: string;
1925
1955
  /** Describing the nested structure, or composition of an entity. */
@@ -1963,7 +1993,7 @@ declare namespace gapi.client {
1963
1993
  backgroundColor?: GoogleTypeColor;
1964
1994
  /** Text color. */
1965
1995
  color?: GoogleTypeColor;
1966
- /** Font family such as "Arial", "Times New Roman". https://www.w3schools.com/cssref/pr_font_font-family.asp */
1996
+ /** Font family such as `Arial`, `Times New Roman`. https://www.w3schools.com/cssref/pr_font_font-family.asp */
1967
1997
  fontFamily?: string;
1968
1998
  /** Font size. */
1969
1999
  fontSize?: GoogleCloudDocumentaiV1DocumentStyleFontSize;
@@ -2083,7 +2113,7 @@ declare namespace gapi.client {
2083
2113
  processEndpoint?: string;
2084
2114
  /** Output only. The state of the processor. */
2085
2115
  state?: string;
2086
- /** The processor type, e.g., OCR_PROCESSOR, INVOICE_PROCESSOR, etc. To get a list of processors types, see FetchProcessorTypes. */
2116
+ /** The processor type, e.g., `OCR_PROCESSOR`, `INVOICE_PROCESSOR`, etc. To get a list of processors types, see FetchProcessorTypes. */
2087
2117
  type?: string;
2088
2118
  }
2089
2119
  interface GoogleCloudDocumentaiV1ProcessorType {
@@ -2095,9 +2125,9 @@ declare namespace gapi.client {
2095
2125
  category?: string;
2096
2126
  /** Launch stage of the processor type */
2097
2127
  launchStage?: string;
2098
- /** The resource name of the processor type. Format: projects/{project}/processorTypes/{processor_type} */
2128
+ /** The resource name of the processor type. Format: `projects/{project}/processorTypes/{processor_type}` */
2099
2129
  name?: string;
2100
- /** The type of the processor, e.g., "invoice_parsing". */
2130
+ /** The processor type, e.g., `OCR_PROCESSOR`, `INVOICE_PROCESSOR`, etc. */
2101
2131
  type?: string;
2102
2132
  }
2103
2133
  interface GoogleCloudDocumentaiV1ProcessorTypeLocationInfo {
@@ -2152,7 +2182,7 @@ declare namespace gapi.client {
2152
2182
  interface GoogleCloudDocumentaiV1RawDocument {
2153
2183
  /** Inline document content. */
2154
2184
  content?: string;
2155
- /** An IANA MIME type (RFC6838) indicating the nature and format of the [content]. */
2185
+ /** An IANA MIME type (RFC6838) indicating the nature and format of the content. */
2156
2186
  mimeType?: string;
2157
2187
  }
2158
2188
  interface GoogleCloudDocumentaiV1ReviewDocumentOperationMetadata {
@@ -3493,182 +3523,9 @@ declare namespace gapi.client {
3493
3523
  locations: LocationsResource;
3494
3524
  operations: OperationsResource;
3495
3525
  }
3496
- interface OperationsResource {
3497
- /**
3498
- * Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support
3499
- * this method, it returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the
3500
- * operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a
3501
- * google.rpc.Status.code of 1, corresponding to `Code.CANCELLED`.
3502
- */
3503
- cancel(request?: {
3504
- /** V1 error format. */
3505
- "$.xgafv"?: string;
3506
- /** OAuth access token. */
3507
- access_token?: string;
3508
- /** Data format for response. */
3509
- alt?: string;
3510
- /** JSONP */
3511
- callback?: string;
3512
- /** Selector specifying which fields to include in a partial response. */
3513
- fields?: string;
3514
- /** 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. */
3515
- key?: string;
3516
- /** The name of the operation resource to be cancelled. */
3517
- name: string;
3518
- /** OAuth 2.0 token for the current user. */
3519
- oauth_token?: string;
3520
- /** Returns response with indentations and line breaks. */
3521
- prettyPrint?: boolean;
3522
- /** 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. */
3523
- quotaUser?: string;
3524
- /** Upload protocol for media (e.g. "raw", "multipart"). */
3525
- upload_protocol?: string;
3526
- /** Legacy upload protocol for media (e.g. "media", "multipart"). */
3527
- uploadType?: string;
3528
- }): Request<{}>;
3529
- /** Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service. */
3530
- get(request?: {
3531
- /** V1 error format. */
3532
- "$.xgafv"?: string;
3533
- /** OAuth access token. */
3534
- access_token?: string;
3535
- /** Data format for response. */
3536
- alt?: string;
3537
- /** JSONP */
3538
- callback?: string;
3539
- /** Selector specifying which fields to include in a partial response. */
3540
- fields?: string;
3541
- /** 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. */
3542
- key?: string;
3543
- /** The name of the operation resource. */
3544
- name: string;
3545
- /** OAuth 2.0 token for the current user. */
3546
- oauth_token?: string;
3547
- /** Returns response with indentations and line breaks. */
3548
- prettyPrint?: boolean;
3549
- /** 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. */
3550
- quotaUser?: string;
3551
- /** Upload protocol for media (e.g. "raw", "multipart"). */
3552
- upload_protocol?: string;
3553
- /** Legacy upload protocol for media (e.g. "media", "multipart"). */
3554
- uploadType?: string;
3555
- }): Request<GoogleLongrunningOperation>;
3556
- /**
3557
- * Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services
3558
- * to override the binding to use different resource name schemes, such as `users/*‍/operations`. To override the binding, API services can add a binding such as
3559
- * `"/v1/{name=users/*}/operations"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must
3560
- * ensure the name binding is the parent resource, without the operations collection id.
3561
- */
3562
- list(request?: {
3563
- /** V1 error format. */
3564
- "$.xgafv"?: string;
3565
- /** OAuth access token. */
3566
- access_token?: string;
3567
- /** Data format for response. */
3568
- alt?: string;
3569
- /** JSONP */
3570
- callback?: string;
3571
- /** Selector specifying which fields to include in a partial response. */
3572
- fields?: string;
3573
- /** The standard list filter. */
3574
- filter?: string;
3575
- /** 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. */
3576
- key?: string;
3577
- /** The name of the operation's parent resource. */
3578
- name: string;
3579
- /** OAuth 2.0 token for the current user. */
3580
- oauth_token?: string;
3581
- /** The standard list page size. */
3582
- pageSize?: number;
3583
- /** The standard list page token. */
3584
- pageToken?: string;
3585
- /** Returns response with indentations and line breaks. */
3586
- prettyPrint?: boolean;
3587
- /** 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. */
3588
- quotaUser?: string;
3589
- /** Upload protocol for media (e.g. "raw", "multipart"). */
3590
- upload_protocol?: string;
3591
- /** Legacy upload protocol for media (e.g. "media", "multipart"). */
3592
- uploadType?: string;
3593
- }): Request<GoogleLongrunningListOperationsResponse>;
3594
- }
3595
- interface LocationsResource {
3596
- /** Gets information about a location. */
3597
- get(request?: {
3598
- /** V1 error format. */
3599
- "$.xgafv"?: string;
3600
- /** OAuth access token. */
3601
- access_token?: string;
3602
- /** Data format for response. */
3603
- alt?: string;
3604
- /** JSONP */
3605
- callback?: string;
3606
- /** Selector specifying which fields to include in a partial response. */
3607
- fields?: string;
3608
- /** 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. */
3609
- key?: string;
3610
- /** Resource name for the location. */
3611
- name: string;
3612
- /** OAuth 2.0 token for the current user. */
3613
- oauth_token?: string;
3614
- /** Returns response with indentations and line breaks. */
3615
- prettyPrint?: boolean;
3616
- /** 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. */
3617
- quotaUser?: string;
3618
- /** Upload protocol for media (e.g. "raw", "multipart"). */
3619
- upload_protocol?: string;
3620
- /** Legacy upload protocol for media (e.g. "media", "multipart"). */
3621
- uploadType?: string;
3622
- }): Request<GoogleCloudLocationLocation>;
3623
- /** Lists information about the supported locations for this service. */
3624
- list(request?: {
3625
- /** V1 error format. */
3626
- "$.xgafv"?: string;
3627
- /** OAuth access token. */
3628
- access_token?: string;
3629
- /** Data format for response. */
3630
- alt?: string;
3631
- /** JSONP */
3632
- callback?: string;
3633
- /** Selector specifying which fields to include in a partial response. */
3634
- fields?: string;
3635
- /**
3636
- * A filter to narrow down results to a preferred subset. The filtering language accepts strings like `"displayName=tokyo"`, and is documented in more detail in
3637
- * [AIP-160](https://google.aip.dev/160).
3638
- */
3639
- filter?: string;
3640
- /** 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. */
3641
- key?: string;
3642
- /** The resource that owns the locations collection, if applicable. */
3643
- name: string;
3644
- /** OAuth 2.0 token for the current user. */
3645
- oauth_token?: string;
3646
- /** The maximum number of results to return. If not set, the service selects a default. */
3647
- pageSize?: number;
3648
- /** A page token received from the `next_page_token` field in the response. Send that page token to receive the subsequent page. */
3649
- pageToken?: string;
3650
- /** Returns response with indentations and line breaks. */
3651
- prettyPrint?: boolean;
3652
- /** 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. */
3653
- quotaUser?: string;
3654
- /** Upload protocol for media (e.g. "raw", "multipart"). */
3655
- upload_protocol?: string;
3656
- /** Legacy upload protocol for media (e.g. "media", "multipart"). */
3657
- uploadType?: string;
3658
- }): Request<GoogleCloudLocationListLocationsResponse>;
3659
- operations: OperationsResource;
3660
- }
3661
- interface ProjectsResource {
3662
- locations: LocationsResource;
3663
- }
3664
- interface Uiv1beta3Resource {
3665
- projects: ProjectsResource;
3666
- }
3667
3526
 
3668
3527
  const operations: OperationsResource;
3669
3528
 
3670
3529
  const projects: ProjectsResource;
3671
-
3672
- const uiv1beta3: Uiv1beta3Resource;
3673
3530
  }
3674
3531
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@maxim_mazurok/gapi.client.documentai-v1",
3
- "version": "0.0.20221108",
3
+ "version": "0.0.20221114",
4
4
  "description": "TypeScript typings for Cloud Document AI API v1",
5
5
  "license": "MIT",
6
6
  "author": {
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: 20221108
6
+ // Revision: 20221114
7
7
 
8
8
  gapi.load('client', async () => {
9
9
  /** now we can use gapi.client */
@@ -2714,41 +2714,5 @@ gapi.load('client', async () => {
2714
2714
  await gapi.client.documentai.projects.operations.get({
2715
2715
  name: "Test string",
2716
2716
  });
2717
- /** Gets information about a location. */
2718
- await gapi.client.documentai.uiv1beta3.projects.locations.get({
2719
- name: "Test string",
2720
- });
2721
- /** Lists information about the supported locations for this service. */
2722
- await gapi.client.documentai.uiv1beta3.projects.locations.list({
2723
- filter: "Test string",
2724
- name: "Test string",
2725
- pageSize: 42,
2726
- pageToken: "Test string",
2727
- });
2728
- /**
2729
- * Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this
2730
- * method, it returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation
2731
- * completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of
2732
- * 1, corresponding to `Code.CANCELLED`.
2733
- */
2734
- await gapi.client.documentai.uiv1beta3.projects.locations.operations.cancel({
2735
- name: "Test string",
2736
- });
2737
- /** Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service. */
2738
- await gapi.client.documentai.uiv1beta3.projects.locations.operations.get({
2739
- name: "Test string",
2740
- });
2741
- /**
2742
- * Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to
2743
- * override the binding to use different resource name schemes, such as `users/*‍/operations`. To override the binding, API services can add a binding such as
2744
- * `"/v1/{name=users/*}/operations"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must
2745
- * ensure the name binding is the parent resource, without the operations collection id.
2746
- */
2747
- await gapi.client.documentai.uiv1beta3.projects.locations.operations.list({
2748
- filter: "Test string",
2749
- name: "Test string",
2750
- pageSize: 42,
2751
- pageToken: "Test string",
2752
- });
2753
2717
  }
2754
2718
  });