@maxim_mazurok/gapi.client.documentai-v1beta3 0.0.20230705 → 0.0.20230714
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 +394 -1
- package/package.json +1 -1
- package/tests.ts +74 -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: 20230714
|
|
13
13
|
|
|
14
14
|
/// <reference types="gapi.client" />
|
|
15
15
|
|
|
@@ -258,6 +258,9 @@ declare namespace gapi.client {
|
|
|
258
258
|
/** The source Cloud Storage URI of the document. */
|
|
259
259
|
inputGcsSource?:
|
|
260
260
|
string;
|
|
261
|
+
/** The document id of imported document if it was successful, otherwise empty. */
|
|
262
|
+
outputDocumentId?:
|
|
263
|
+
GoogleCloudDocumentaiUiv1beta3DocumentId;
|
|
261
264
|
/** The output_gcs_destination of the processed document if it was successful, otherwise empty. */
|
|
262
265
|
outputGcsDestination?:
|
|
263
266
|
string;
|
|
@@ -331,6 +334,12 @@ declare namespace gapi.client {
|
|
|
331
334
|
GoogleCloudDocumentaiUiv1beta3CommonOperationMetadata;
|
|
332
335
|
}
|
|
333
336
|
interface GoogleCloudDocumentaiUiv1beta3SampleDocumentsResponse {
|
|
337
|
+
/** The status of sampling documents in test split. */
|
|
338
|
+
sampleTestStatus?:
|
|
339
|
+
GoogleRpcStatus;
|
|
340
|
+
/** The status of sampling documents in training split. */
|
|
341
|
+
sampleTrainingStatus?:
|
|
342
|
+
GoogleRpcStatus;
|
|
334
343
|
/** The result of the sampling process. */
|
|
335
344
|
selectedDocuments?:
|
|
336
345
|
GoogleCloudDocumentaiUiv1beta3SampleDocumentsResponseSelectedDocument[];
|
|
@@ -1916,6 +1925,52 @@ declare namespace gapi.client {
|
|
|
1916
1925
|
valueFormat?:
|
|
1917
1926
|
string;
|
|
1918
1927
|
}
|
|
1928
|
+
interface GoogleCloudDocumentaiV1beta3BatchDatasetDocuments {
|
|
1929
|
+
/** A filter matching the documents. Follows the same format and restriction as [google.cloud.documentai.master.ListDocumentsRequest.filter]. */
|
|
1930
|
+
filter?:
|
|
1931
|
+
string;
|
|
1932
|
+
/** Document identifiers. */
|
|
1933
|
+
individualDocumentIds?:
|
|
1934
|
+
GoogleCloudDocumentaiV1beta3BatchDatasetDocumentsIndividualDocumentIds;
|
|
1935
|
+
}
|
|
1936
|
+
interface GoogleCloudDocumentaiV1beta3BatchDatasetDocumentsIndividualDocumentIds {
|
|
1937
|
+
/** Required. List of Document IDs indicating where the actual documents are stored. */
|
|
1938
|
+
documentIds?:
|
|
1939
|
+
GoogleCloudDocumentaiV1beta3DocumentId[];
|
|
1940
|
+
}
|
|
1941
|
+
interface GoogleCloudDocumentaiV1beta3BatchDeleteDocumentsMetadata {
|
|
1942
|
+
/** The basic metadata of the long running operation. */
|
|
1943
|
+
commonMetadata?:
|
|
1944
|
+
GoogleCloudDocumentaiV1beta3CommonOperationMetadata;
|
|
1945
|
+
/** Total number of documents that failed to be deleted in storage. */
|
|
1946
|
+
errorDocumentCount?:
|
|
1947
|
+
number;
|
|
1948
|
+
/** The list of response details of each document. */
|
|
1949
|
+
individualBatchDeleteStatuses?:
|
|
1950
|
+
GoogleCloudDocumentaiV1beta3BatchDeleteDocumentsMetadataIndividualBatchDeleteStatus[];
|
|
1951
|
+
/** Total number of documents deleting from dataset. */
|
|
1952
|
+
totalDocumentCount?:
|
|
1953
|
+
number;
|
|
1954
|
+
}
|
|
1955
|
+
interface GoogleCloudDocumentaiV1beta3BatchDeleteDocumentsMetadataIndividualBatchDeleteStatus {
|
|
1956
|
+
/** The document id of the document. */
|
|
1957
|
+
documentId?:
|
|
1958
|
+
GoogleCloudDocumentaiV1beta3DocumentId;
|
|
1959
|
+
/** The status of deleting the document in storage. */
|
|
1960
|
+
status?:
|
|
1961
|
+
GoogleRpcStatus;
|
|
1962
|
+
}
|
|
1963
|
+
interface GoogleCloudDocumentaiV1beta3BatchDeleteDocumentsRequest {
|
|
1964
|
+
/**
|
|
1965
|
+
* Required. Dataset documents input. If given `filter`, all documents satisfying the filter will be deleted. If given documentIds, a maximum of 50 documents can be deleted in a batch.
|
|
1966
|
+
* The request will be rejected if more than 50 document_ids are provided.
|
|
1967
|
+
*/
|
|
1968
|
+
datasetDocuments?:
|
|
1969
|
+
GoogleCloudDocumentaiV1beta3BatchDatasetDocuments;
|
|
1970
|
+
}
|
|
1971
|
+
// tslint:disable-next-line:no-empty-interface
|
|
1972
|
+
interface GoogleCloudDocumentaiV1beta3BatchDeleteDocumentsResponse {
|
|
1973
|
+
}
|
|
1919
1974
|
interface GoogleCloudDocumentaiV1beta3BatchDocumentsInputConfig {
|
|
1920
1975
|
/** The set of documents individually specified on Cloud Storage. */
|
|
1921
1976
|
gcsDocuments?:
|
|
@@ -2231,6 +2286,30 @@ declare namespace gapi.client {
|
|
|
2231
2286
|
subjectId?:
|
|
2232
2287
|
string;
|
|
2233
2288
|
}
|
|
2289
|
+
interface GoogleCloudDocumentaiV1beta3DocumentId {
|
|
2290
|
+
/** A document id within user-managed Cloud Storage. */
|
|
2291
|
+
gcsManagedDocId?:
|
|
2292
|
+
GoogleCloudDocumentaiV1beta3DocumentIdGCSManagedDocumentId;
|
|
2293
|
+
/** Points to a specific revision of the document if set. */
|
|
2294
|
+
revisionRef?:
|
|
2295
|
+
GoogleCloudDocumentaiV1beta3RevisionRef;
|
|
2296
|
+
/** A document id within unmanaged dataset. */
|
|
2297
|
+
unmanagedDocId?:
|
|
2298
|
+
GoogleCloudDocumentaiV1beta3DocumentIdUnmanagedDocumentId;
|
|
2299
|
+
}
|
|
2300
|
+
interface GoogleCloudDocumentaiV1beta3DocumentIdGCSManagedDocumentId {
|
|
2301
|
+
/** Id of the document (indexed) managed by Content Warehouse. */
|
|
2302
|
+
cwDocId?:
|
|
2303
|
+
string;
|
|
2304
|
+
/** Required. The Cloud Storage URI where the actual document is stored. */
|
|
2305
|
+
gcsUri?:
|
|
2306
|
+
string;
|
|
2307
|
+
}
|
|
2308
|
+
interface GoogleCloudDocumentaiV1beta3DocumentIdUnmanagedDocumentId {
|
|
2309
|
+
/** Required. The id of the document. */
|
|
2310
|
+
docId?:
|
|
2311
|
+
string;
|
|
2312
|
+
}
|
|
2234
2313
|
interface GoogleCloudDocumentaiV1beta3DocumentOutputConfig {
|
|
2235
2314
|
/** Output config to write the results to Cloud Storage. */
|
|
2236
2315
|
gcsOutputConfig?:
|
|
@@ -2999,6 +3078,10 @@ declare namespace gapi.client {
|
|
|
2999
3078
|
gcsUriPrefix?:
|
|
3000
3079
|
string;
|
|
3001
3080
|
}
|
|
3081
|
+
interface GoogleCloudDocumentaiV1beta3GetDocumentResponse {
|
|
3082
|
+
document?:
|
|
3083
|
+
GoogleCloudDocumentaiV1beta3Document;
|
|
3084
|
+
}
|
|
3002
3085
|
interface GoogleCloudDocumentaiV1beta3HumanReviewStatus {
|
|
3003
3086
|
/**
|
|
3004
3087
|
* 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 metadata
|
|
@@ -3013,6 +3096,63 @@ declare namespace gapi.client {
|
|
|
3013
3096
|
stateMessage?:
|
|
3014
3097
|
string;
|
|
3015
3098
|
}
|
|
3099
|
+
interface GoogleCloudDocumentaiV1beta3ImportDocumentsMetadata {
|
|
3100
|
+
/** The basic metadata of the long running operation. */
|
|
3101
|
+
commonMetadata?:
|
|
3102
|
+
GoogleCloudDocumentaiV1beta3CommonOperationMetadata;
|
|
3103
|
+
/** Validation statuses of the batch documents import config. */
|
|
3104
|
+
importConfigValidationResults?:
|
|
3105
|
+
GoogleCloudDocumentaiV1beta3ImportDocumentsMetadataImportConfigValidationResult[];
|
|
3106
|
+
/** The list of response details of each document. */
|
|
3107
|
+
individualImportStatuses?:
|
|
3108
|
+
GoogleCloudDocumentaiV1beta3ImportDocumentsMetadataIndividualImportStatus[];
|
|
3109
|
+
/** Total number of the documents that are qualified for importing. */
|
|
3110
|
+
totalDocumentCount?:
|
|
3111
|
+
number;
|
|
3112
|
+
}
|
|
3113
|
+
interface GoogleCloudDocumentaiV1beta3ImportDocumentsMetadataImportConfigValidationResult {
|
|
3114
|
+
/** The source Cloud Storage URI specified in the import config. */
|
|
3115
|
+
inputGcsSource?:
|
|
3116
|
+
string;
|
|
3117
|
+
/** The validation status of import config. */
|
|
3118
|
+
status?:
|
|
3119
|
+
GoogleRpcStatus;
|
|
3120
|
+
}
|
|
3121
|
+
interface GoogleCloudDocumentaiV1beta3ImportDocumentsMetadataIndividualImportStatus {
|
|
3122
|
+
/** The source Cloud Storage URI of the document. */
|
|
3123
|
+
inputGcsSource?:
|
|
3124
|
+
string;
|
|
3125
|
+
/** The document id of imported document if it was successful, otherwise empty. */
|
|
3126
|
+
outputDocumentId?:
|
|
3127
|
+
GoogleCloudDocumentaiV1beta3DocumentId;
|
|
3128
|
+
/** The status of the importing of the document. */
|
|
3129
|
+
status?:
|
|
3130
|
+
GoogleRpcStatus;
|
|
3131
|
+
}
|
|
3132
|
+
interface GoogleCloudDocumentaiV1beta3ImportDocumentsRequest {
|
|
3133
|
+
/** Required. The Cloud Storage uri containing raw documents that must be imported. */
|
|
3134
|
+
batchDocumentsImportConfigs?:
|
|
3135
|
+
GoogleCloudDocumentaiV1beta3ImportDocumentsRequestBatchDocumentsImportConfig[];
|
|
3136
|
+
}
|
|
3137
|
+
interface GoogleCloudDocumentaiV1beta3ImportDocumentsRequestBatchDocumentsImportConfig {
|
|
3138
|
+
/** If set, documents will be automatically split into training and test split category with the specified ratio. */
|
|
3139
|
+
autoSplitConfig?:
|
|
3140
|
+
GoogleCloudDocumentaiV1beta3ImportDocumentsRequestBatchDocumentsImportConfigAutoSplitConfig;
|
|
3141
|
+
/** The common config to specify a set of documents used as input. */
|
|
3142
|
+
batchInputConfig?:
|
|
3143
|
+
GoogleCloudDocumentaiV1beta3BatchDocumentsInputConfig;
|
|
3144
|
+
/** Target dataset split where the documents must be stored. */
|
|
3145
|
+
datasetSplit?:
|
|
3146
|
+
string;
|
|
3147
|
+
}
|
|
3148
|
+
interface GoogleCloudDocumentaiV1beta3ImportDocumentsRequestBatchDocumentsImportConfigAutoSplitConfig {
|
|
3149
|
+
/** Ratio of training dataset split. */
|
|
3150
|
+
trainingSplitRatio?:
|
|
3151
|
+
number;
|
|
3152
|
+
}
|
|
3153
|
+
// tslint:disable-next-line:no-empty-interface
|
|
3154
|
+
interface GoogleCloudDocumentaiV1beta3ImportDocumentsResponse {
|
|
3155
|
+
}
|
|
3016
3156
|
interface GoogleCloudDocumentaiV1beta3ImportProcessorVersionMetadata {
|
|
3017
3157
|
/** The basic metadata for the long-running operation. */
|
|
3018
3158
|
commonMetadata?:
|
|
@@ -3212,6 +3352,9 @@ declare namespace gapi.client {
|
|
|
3212
3352
|
*/
|
|
3213
3353
|
fieldMask?:
|
|
3214
3354
|
string;
|
|
3355
|
+
/** A raw document on Google Cloud Storage. */
|
|
3356
|
+
gcsDocument?:
|
|
3357
|
+
GoogleCloudDocumentaiV1beta3GcsDocument;
|
|
3215
3358
|
/** An inline document proto. */
|
|
3216
3359
|
inlineDocument?:
|
|
3217
3360
|
GoogleCloudDocumentaiV1beta3Document;
|
|
@@ -3300,6 +3443,20 @@ declare namespace gapi.client {
|
|
|
3300
3443
|
state?:
|
|
3301
3444
|
string;
|
|
3302
3445
|
}
|
|
3446
|
+
interface GoogleCloudDocumentaiV1beta3RevisionRef {
|
|
3447
|
+
/**
|
|
3448
|
+
* Reads the revision generated by the processor version. The format takes the full resource name of processor version.
|
|
3449
|
+
* `projects/{project}/locations/{location}/processors/{processor}/processorVersions/{processorVersion}`
|
|
3450
|
+
*/
|
|
3451
|
+
latestProcessorVersion?:
|
|
3452
|
+
string;
|
|
3453
|
+
/** Reads the revision by the predefined case. */
|
|
3454
|
+
revisionCase?:
|
|
3455
|
+
string;
|
|
3456
|
+
/** Reads the revision given by the id. */
|
|
3457
|
+
revisionId?:
|
|
3458
|
+
string;
|
|
3459
|
+
}
|
|
3303
3460
|
interface GoogleCloudDocumentaiV1beta3SetDefaultProcessorVersionMetadata {
|
|
3304
3461
|
/** The basic metadata of the long-running operation. */
|
|
3305
3462
|
commonMetadata?:
|
|
@@ -3387,6 +3544,11 @@ declare namespace gapi.client {
|
|
|
3387
3544
|
// tslint:disable-next-line:no-empty-interface
|
|
3388
3545
|
interface GoogleCloudDocumentaiV1beta3UndeployProcessorVersionResponse {
|
|
3389
3546
|
}
|
|
3547
|
+
interface GoogleCloudDocumentaiV1beta3UpdateDatasetOperationMetadata {
|
|
3548
|
+
/** The basic metadata of the long running operation. */
|
|
3549
|
+
commonMetadata?:
|
|
3550
|
+
GoogleCloudDocumentaiV1beta3CommonOperationMetadata;
|
|
3551
|
+
}
|
|
3390
3552
|
interface GoogleCloudDocumentaiV1beta3Vertex {
|
|
3391
3553
|
/** X coordinate. */
|
|
3392
3554
|
x?:
|
|
@@ -3892,6 +4054,87 @@ declare namespace gapi.client {
|
|
|
3892
4054
|
}): Request<GoogleLongrunningListOperationsResponse>;
|
|
3893
4055
|
}
|
|
3894
4056
|
interface DatasetResource {
|
|
4057
|
+
/** Deletes a set of documents. */
|
|
4058
|
+
batchDeleteDocuments(request: {
|
|
4059
|
+
/** V1 error format. */
|
|
4060
|
+
"$.xgafv"?:
|
|
4061
|
+
string;
|
|
4062
|
+
/** OAuth access token. */
|
|
4063
|
+
access_token?:
|
|
4064
|
+
string;
|
|
4065
|
+
/** Data format for response. */
|
|
4066
|
+
alt?:
|
|
4067
|
+
string;
|
|
4068
|
+
/** JSONP */
|
|
4069
|
+
callback?:
|
|
4070
|
+
string;
|
|
4071
|
+
/** Required. The dataset resource name. Format: projects/{project}/locations/{location}/processors/{processor}/dataset */
|
|
4072
|
+
dataset:
|
|
4073
|
+
string;
|
|
4074
|
+
/** Selector specifying which fields to include in a partial response. */
|
|
4075
|
+
fields?:
|
|
4076
|
+
string;
|
|
4077
|
+
/** 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. */
|
|
4078
|
+
key?:
|
|
4079
|
+
string;
|
|
4080
|
+
/** OAuth 2.0 token for the current user. */
|
|
4081
|
+
oauth_token?:
|
|
4082
|
+
string;
|
|
4083
|
+
/** Returns response with indentations and line breaks. */
|
|
4084
|
+
prettyPrint?:
|
|
4085
|
+
boolean;
|
|
4086
|
+
/** 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. */
|
|
4087
|
+
quotaUser?:
|
|
4088
|
+
string;
|
|
4089
|
+
/** Upload protocol for media (e.g. "raw", "multipart"). */
|
|
4090
|
+
upload_protocol?:
|
|
4091
|
+
string;
|
|
4092
|
+
/** Legacy upload protocol for media (e.g. "media", "multipart"). */
|
|
4093
|
+
uploadType?:
|
|
4094
|
+
string;
|
|
4095
|
+
/** Request body */
|
|
4096
|
+
resource:
|
|
4097
|
+
GoogleCloudDocumentaiV1beta3BatchDeleteDocumentsRequest;
|
|
4098
|
+
}): Request<GoogleLongrunningOperation>;
|
|
4099
|
+
batchDeleteDocuments(request: {
|
|
4100
|
+
/** V1 error format. */
|
|
4101
|
+
"$.xgafv"?:
|
|
4102
|
+
string;
|
|
4103
|
+
/** OAuth access token. */
|
|
4104
|
+
access_token?:
|
|
4105
|
+
string;
|
|
4106
|
+
/** Data format for response. */
|
|
4107
|
+
alt?:
|
|
4108
|
+
string;
|
|
4109
|
+
/** JSONP */
|
|
4110
|
+
callback?:
|
|
4111
|
+
string;
|
|
4112
|
+
/** Required. The dataset resource name. Format: projects/{project}/locations/{location}/processors/{processor}/dataset */
|
|
4113
|
+
dataset:
|
|
4114
|
+
string;
|
|
4115
|
+
/** Selector specifying which fields to include in a partial response. */
|
|
4116
|
+
fields?:
|
|
4117
|
+
string;
|
|
4118
|
+
/** 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. */
|
|
4119
|
+
key?:
|
|
4120
|
+
string;
|
|
4121
|
+
/** OAuth 2.0 token for the current user. */
|
|
4122
|
+
oauth_token?:
|
|
4123
|
+
string;
|
|
4124
|
+
/** Returns response with indentations and line breaks. */
|
|
4125
|
+
prettyPrint?:
|
|
4126
|
+
boolean;
|
|
4127
|
+
/** 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. */
|
|
4128
|
+
quotaUser?:
|
|
4129
|
+
string;
|
|
4130
|
+
/** Upload protocol for media (e.g. "raw", "multipart"). */
|
|
4131
|
+
upload_protocol?:
|
|
4132
|
+
string;
|
|
4133
|
+
/** Legacy upload protocol for media (e.g. "media", "multipart"). */
|
|
4134
|
+
uploadType?:
|
|
4135
|
+
string;
|
|
4136
|
+
},
|
|
4137
|
+
body: GoogleCloudDocumentaiV1beta3BatchDeleteDocumentsRequest): Request<GoogleLongrunningOperation>;
|
|
3895
4138
|
/** Gets the `DatasetSchema` of a `Dataset`. */
|
|
3896
4139
|
getDatasetSchema(request?: {
|
|
3897
4140
|
/** V1 error format. */
|
|
@@ -3934,6 +4177,156 @@ declare namespace gapi.client {
|
|
|
3934
4177
|
visibleFieldsOnly?:
|
|
3935
4178
|
boolean;
|
|
3936
4179
|
}): Request<GoogleCloudDocumentaiV1beta3DatasetSchema>;
|
|
4180
|
+
/** Returns relevant fields present in the requested document. */
|
|
4181
|
+
getDocument(request?: {
|
|
4182
|
+
/** V1 error format. */
|
|
4183
|
+
"$.xgafv"?:
|
|
4184
|
+
string;
|
|
4185
|
+
/** OAuth access token. */
|
|
4186
|
+
access_token?:
|
|
4187
|
+
string;
|
|
4188
|
+
/** Data format for response. */
|
|
4189
|
+
alt?:
|
|
4190
|
+
string;
|
|
4191
|
+
/** JSONP */
|
|
4192
|
+
callback?:
|
|
4193
|
+
string;
|
|
4194
|
+
/** Required. The resource name of the dataset that the document belongs to . Format: projects/{project}/locations/{location}/processors/{processor}/dataset */
|
|
4195
|
+
dataset:
|
|
4196
|
+
string;
|
|
4197
|
+
/** Id of the document (indexed) managed by Content Warehouse. */
|
|
4198
|
+
"documentId.gcsManagedDocId.cwDocId"?:
|
|
4199
|
+
string;
|
|
4200
|
+
/** Required. The Cloud Storage URI where the actual document is stored. */
|
|
4201
|
+
"documentId.gcsManagedDocId.gcsUri"?:
|
|
4202
|
+
string;
|
|
4203
|
+
/**
|
|
4204
|
+
* Reads the revision generated by the processor version. The format takes the full resource name of processor version.
|
|
4205
|
+
* `projects/{project}/locations/{location}/processors/{processor}/processorVersions/{processorVersion}`
|
|
4206
|
+
*/
|
|
4207
|
+
"documentId.revisionRef.latestProcessorVersion"?:
|
|
4208
|
+
string;
|
|
4209
|
+
/** Reads the revision by the predefined case. */
|
|
4210
|
+
"documentId.revisionRef.revisionCase"?:
|
|
4211
|
+
string;
|
|
4212
|
+
/** Reads the revision given by the id. */
|
|
4213
|
+
"documentId.revisionRef.revisionId"?:
|
|
4214
|
+
string;
|
|
4215
|
+
/** Required. The id of the document. */
|
|
4216
|
+
"documentId.unmanagedDocId.docId"?:
|
|
4217
|
+
string;
|
|
4218
|
+
/** Selector specifying which fields to include in a partial response. */
|
|
4219
|
+
fields?:
|
|
4220
|
+
string;
|
|
4221
|
+
/** 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. */
|
|
4222
|
+
key?:
|
|
4223
|
+
string;
|
|
4224
|
+
/** OAuth 2.0 token for the current user. */
|
|
4225
|
+
oauth_token?:
|
|
4226
|
+
string;
|
|
4227
|
+
/** Last page number (one-based index) to be returned. */
|
|
4228
|
+
"pageRange.end"?:
|
|
4229
|
+
number;
|
|
4230
|
+
/** First page number (one-based index) to be returned. */
|
|
4231
|
+
"pageRange.start"?:
|
|
4232
|
+
number;
|
|
4233
|
+
/** Returns response with indentations and line breaks. */
|
|
4234
|
+
prettyPrint?:
|
|
4235
|
+
boolean;
|
|
4236
|
+
/** 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. */
|
|
4237
|
+
quotaUser?:
|
|
4238
|
+
string;
|
|
4239
|
+
/** If set, only fields listed here will be returned. Otherwise, all fields will be returned by default. */
|
|
4240
|
+
readMask?:
|
|
4241
|
+
string;
|
|
4242
|
+
/** Upload protocol for media (e.g. "raw", "multipart"). */
|
|
4243
|
+
upload_protocol?:
|
|
4244
|
+
string;
|
|
4245
|
+
/** Legacy upload protocol for media (e.g. "media", "multipart"). */
|
|
4246
|
+
uploadType?:
|
|
4247
|
+
string;
|
|
4248
|
+
}): Request<GoogleCloudDocumentaiV1beta3GetDocumentResponse>;
|
|
4249
|
+
/** Import documents into a dataset. */
|
|
4250
|
+
importDocuments(request: {
|
|
4251
|
+
/** V1 error format. */
|
|
4252
|
+
"$.xgafv"?:
|
|
4253
|
+
string;
|
|
4254
|
+
/** OAuth access token. */
|
|
4255
|
+
access_token?:
|
|
4256
|
+
string;
|
|
4257
|
+
/** Data format for response. */
|
|
4258
|
+
alt?:
|
|
4259
|
+
string;
|
|
4260
|
+
/** JSONP */
|
|
4261
|
+
callback?:
|
|
4262
|
+
string;
|
|
4263
|
+
/** Required. The dataset resource name. Format: projects/{project}/locations/{location}/processors/{processor}/dataset */
|
|
4264
|
+
dataset:
|
|
4265
|
+
string;
|
|
4266
|
+
/** Selector specifying which fields to include in a partial response. */
|
|
4267
|
+
fields?:
|
|
4268
|
+
string;
|
|
4269
|
+
/** 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. */
|
|
4270
|
+
key?:
|
|
4271
|
+
string;
|
|
4272
|
+
/** OAuth 2.0 token for the current user. */
|
|
4273
|
+
oauth_token?:
|
|
4274
|
+
string;
|
|
4275
|
+
/** Returns response with indentations and line breaks. */
|
|
4276
|
+
prettyPrint?:
|
|
4277
|
+
boolean;
|
|
4278
|
+
/** 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. */
|
|
4279
|
+
quotaUser?:
|
|
4280
|
+
string;
|
|
4281
|
+
/** Upload protocol for media (e.g. "raw", "multipart"). */
|
|
4282
|
+
upload_protocol?:
|
|
4283
|
+
string;
|
|
4284
|
+
/** Legacy upload protocol for media (e.g. "media", "multipart"). */
|
|
4285
|
+
uploadType?:
|
|
4286
|
+
string;
|
|
4287
|
+
/** Request body */
|
|
4288
|
+
resource:
|
|
4289
|
+
GoogleCloudDocumentaiV1beta3ImportDocumentsRequest;
|
|
4290
|
+
}): Request<GoogleLongrunningOperation>;
|
|
4291
|
+
importDocuments(request: {
|
|
4292
|
+
/** V1 error format. */
|
|
4293
|
+
"$.xgafv"?:
|
|
4294
|
+
string;
|
|
4295
|
+
/** OAuth access token. */
|
|
4296
|
+
access_token?:
|
|
4297
|
+
string;
|
|
4298
|
+
/** Data format for response. */
|
|
4299
|
+
alt?:
|
|
4300
|
+
string;
|
|
4301
|
+
/** JSONP */
|
|
4302
|
+
callback?:
|
|
4303
|
+
string;
|
|
4304
|
+
/** Required. The dataset resource name. Format: projects/{project}/locations/{location}/processors/{processor}/dataset */
|
|
4305
|
+
dataset:
|
|
4306
|
+
string;
|
|
4307
|
+
/** Selector specifying which fields to include in a partial response. */
|
|
4308
|
+
fields?:
|
|
4309
|
+
string;
|
|
4310
|
+
/** 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. */
|
|
4311
|
+
key?:
|
|
4312
|
+
string;
|
|
4313
|
+
/** OAuth 2.0 token for the current user. */
|
|
4314
|
+
oauth_token?:
|
|
4315
|
+
string;
|
|
4316
|
+
/** Returns response with indentations and line breaks. */
|
|
4317
|
+
prettyPrint?:
|
|
4318
|
+
boolean;
|
|
4319
|
+
/** 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. */
|
|
4320
|
+
quotaUser?:
|
|
4321
|
+
string;
|
|
4322
|
+
/** Upload protocol for media (e.g. "raw", "multipart"). */
|
|
4323
|
+
upload_protocol?:
|
|
4324
|
+
string;
|
|
4325
|
+
/** Legacy upload protocol for media (e.g. "media", "multipart"). */
|
|
4326
|
+
uploadType?:
|
|
4327
|
+
string;
|
|
4328
|
+
},
|
|
4329
|
+
body: GoogleCloudDocumentaiV1beta3ImportDocumentsRequest): Request<GoogleLongrunningOperation>;
|
|
3937
4330
|
/** Updates a `DatasetSchema`. */
|
|
3938
4331
|
updateDatasetSchema(request: {
|
|
3939
4332
|
/** V1 error format. */
|
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: 20230714
|
|
7
7
|
|
|
8
8
|
gapi.load('client', async () => {
|
|
9
9
|
/** now we can use gapi.client */
|
|
@@ -1004,6 +1004,10 @@ gapi.load('client', async () => {
|
|
|
1004
1004
|
uri: "Test string",
|
|
1005
1005
|
},
|
|
1006
1006
|
fieldMask: "Test string",
|
|
1007
|
+
gcsDocument: {
|
|
1008
|
+
gcsUri: "Test string",
|
|
1009
|
+
mimeType: "Test string",
|
|
1010
|
+
},
|
|
1007
1011
|
inlineDocument: {
|
|
1008
1012
|
content: "Test string",
|
|
1009
1013
|
entities: [
|
|
@@ -1897,11 +1901,76 @@ gapi.load('client', async () => {
|
|
|
1897
1901
|
unmanagedDatasetConfig: {
|
|
1898
1902
|
},
|
|
1899
1903
|
});
|
|
1904
|
+
/** Deletes a set of documents. */
|
|
1905
|
+
await gapi.client.documentai.projects.locations.processors.dataset.batchDeleteDocuments({
|
|
1906
|
+
dataset: "Test string",
|
|
1907
|
+
}, {
|
|
1908
|
+
datasetDocuments: {
|
|
1909
|
+
filter: "Test string",
|
|
1910
|
+
individualDocumentIds: {
|
|
1911
|
+
documentIds: [
|
|
1912
|
+
{
|
|
1913
|
+
gcsManagedDocId: {
|
|
1914
|
+
cwDocId: "Test string",
|
|
1915
|
+
gcsUri: "Test string",
|
|
1916
|
+
},
|
|
1917
|
+
revisionRef: {
|
|
1918
|
+
latestProcessorVersion: "Test string",
|
|
1919
|
+
revisionCase: "Test string",
|
|
1920
|
+
revisionId: "Test string",
|
|
1921
|
+
},
|
|
1922
|
+
unmanagedDocId: {
|
|
1923
|
+
docId: "Test string",
|
|
1924
|
+
},
|
|
1925
|
+
}
|
|
1926
|
+
],
|
|
1927
|
+
},
|
|
1928
|
+
},
|
|
1929
|
+
});
|
|
1900
1930
|
/** Gets the `DatasetSchema` of a `Dataset`. */
|
|
1901
1931
|
await gapi.client.documentai.projects.locations.processors.dataset.getDatasetSchema({
|
|
1902
1932
|
name: "Test string",
|
|
1903
1933
|
visibleFieldsOnly: true,
|
|
1904
1934
|
});
|
|
1935
|
+
/** Returns relevant fields present in the requested document. */
|
|
1936
|
+
await gapi.client.documentai.projects.locations.processors.dataset.getDocument({
|
|
1937
|
+
dataset: "Test string",
|
|
1938
|
+
"documentId.gcsManagedDocId.cwDocId": "Test string",
|
|
1939
|
+
"documentId.gcsManagedDocId.gcsUri": "Test string",
|
|
1940
|
+
"documentId.revisionRef.latestProcessorVersion": "Test string",
|
|
1941
|
+
"documentId.revisionRef.revisionCase": "Test string",
|
|
1942
|
+
"documentId.revisionRef.revisionId": "Test string",
|
|
1943
|
+
"documentId.unmanagedDocId.docId": "Test string",
|
|
1944
|
+
"pageRange.end": 42,
|
|
1945
|
+
"pageRange.start": 42,
|
|
1946
|
+
readMask: "Test string",
|
|
1947
|
+
});
|
|
1948
|
+
/** Import documents into a dataset. */
|
|
1949
|
+
await gapi.client.documentai.projects.locations.processors.dataset.importDocuments({
|
|
1950
|
+
dataset: "Test string",
|
|
1951
|
+
}, {
|
|
1952
|
+
batchDocumentsImportConfigs: [
|
|
1953
|
+
{
|
|
1954
|
+
autoSplitConfig: {
|
|
1955
|
+
trainingSplitRatio: 42,
|
|
1956
|
+
},
|
|
1957
|
+
batchInputConfig: {
|
|
1958
|
+
gcsDocuments: {
|
|
1959
|
+
documents: [
|
|
1960
|
+
{
|
|
1961
|
+
gcsUri: "Test string",
|
|
1962
|
+
mimeType: "Test string",
|
|
1963
|
+
}
|
|
1964
|
+
],
|
|
1965
|
+
},
|
|
1966
|
+
gcsPrefix: {
|
|
1967
|
+
gcsUriPrefix: "Test string",
|
|
1968
|
+
},
|
|
1969
|
+
},
|
|
1970
|
+
datasetSplit: "Test string",
|
|
1971
|
+
}
|
|
1972
|
+
],
|
|
1973
|
+
});
|
|
1905
1974
|
/** Updates a `DatasetSchema`. */
|
|
1906
1975
|
await gapi.client.documentai.projects.locations.processors.dataset.updateDatasetSchema({
|
|
1907
1976
|
name: "Test string",
|
|
@@ -4624,6 +4693,10 @@ gapi.load('client', async () => {
|
|
|
4624
4693
|
uri: "Test string",
|
|
4625
4694
|
},
|
|
4626
4695
|
fieldMask: "Test string",
|
|
4696
|
+
gcsDocument: {
|
|
4697
|
+
gcsUri: "Test string",
|
|
4698
|
+
mimeType: "Test string",
|
|
4699
|
+
},
|
|
4627
4700
|
inlineDocument: {
|
|
4628
4701
|
content: "Test string",
|
|
4629
4702
|
entities: [
|