Skip to content

Commit d1077a6

Browse files
feat(documentai): update the api
#### documentai:v1 The following keys were added: - schemas.GoogleCloudDocumentaiUiv1beta3TrainProcessorVersionMetadataDatasetValidation.properties.datasetErrorCount (Total Keys: 2) - schemas.GoogleCloudDocumentaiUiv1beta3TrainProcessorVersionMetadataDatasetValidation.properties.documentErrorCount (Total Keys: 2) #### documentai:v1beta2 The following keys were added: - schemas.GoogleCloudDocumentaiUiv1beta3TrainProcessorVersionMetadataDatasetValidation.properties.datasetErrorCount (Total Keys: 2) - schemas.GoogleCloudDocumentaiUiv1beta3TrainProcessorVersionMetadataDatasetValidation.properties.documentErrorCount (Total Keys: 2) #### documentai:v1beta3 The following keys were added: - resources.projects.resources.locations.resources.processors.methods.create (Total Keys: 12) - resources.projects.resources.locations.resources.processors.methods.delete (Total Keys: 11) - resources.projects.resources.locations.resources.processors.methods.disable (Total Keys: 12) - resources.projects.resources.locations.resources.processors.methods.enable (Total Keys: 12) - resources.projects.resources.locations.resources.processors.methods.list (Total Keys: 16) - schemas.GoogleCloudDocumentaiUiv1beta3TrainProcessorVersionMetadataDatasetValidation.properties.datasetErrorCount (Total Keys: 2) - schemas.GoogleCloudDocumentaiUiv1beta3TrainProcessorVersionMetadataDatasetValidation.properties.documentErrorCount (Total Keys: 2) - schemas.GoogleCloudDocumentaiV1beta3DisableProcessorRequest (Total Keys: 2) - schemas.GoogleCloudDocumentaiV1beta3EnableProcessorRequest (Total Keys: 2) - schemas.GoogleCloudDocumentaiV1beta3ListProcessorsResponse (Total Keys: 5) - schemas.GoogleCloudDocumentaiV1beta3Processor (Total Keys: 14)
1 parent ef2f50d commit d1077a6

7 files changed

+499
-9
lines changed

docs/dyn/documentai_v1.projects.locations.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ <h3>Method Details</h3>
136136
Args:
137137
name: string, The resource that owns the locations collection, if applicable. (required)
138138
filter: string, A filter to narrow down results to a preferred subset. The filtering language accepts strings like &quot;displayName=tokyo&quot;, and is documented in more detail in [AIP-160](https://google.aip.dev/160).
139-
pageSize: integer, The maximum number of results to return. If not set, the service will select a default.
139+
pageSize: integer, The maximum number of results to return. If not set, the service selects a default.
140140
pageToken: string, A page token received from the `next_page_token` field in the response. Send that page token to receive the subsequent page.
141141
x__xgafv: string, V1 error format.
142142
Allowed values

docs/dyn/documentai_v1.uiv1beta3.projects.locations.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ <h3>Method Details</h3>
131131
Args:
132132
name: string, The resource that owns the locations collection, if applicable. (required)
133133
filter: string, A filter to narrow down results to a preferred subset. The filtering language accepts strings like &quot;displayName=tokyo&quot;, and is documented in more detail in [AIP-160](https://google.aip.dev/160).
134-
pageSize: integer, The maximum number of results to return. If not set, the service will select a default.
134+
pageSize: integer, The maximum number of results to return. If not set, the service selects a default.
135135
pageToken: string, A page token received from the `next_page_token` field in the response. Send that page token to receive the subsequent page.
136136
x__xgafv: string, V1 error format.
137137
Allowed values

docs/dyn/documentai_v1beta3.projects.locations.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ <h3>Method Details</h3>
136136
Args:
137137
name: string, The resource that owns the locations collection, if applicable. (required)
138138
filter: string, A filter to narrow down results to a preferred subset. The filtering language accepts strings like &quot;displayName=tokyo&quot;, and is documented in more detail in [AIP-160](https://google.aip.dev/160).
139-
pageSize: integer, The maximum number of results to return. If not set, the service will select a default.
139+
pageSize: integer, The maximum number of results to return. If not set, the service selects a default.
140140
pageToken: string, A page token received from the `next_page_token` field in the response. Send that page token to receive the subsequent page.
141141
x__xgafv: string, V1 error format.
142142
Allowed values

docs/dyn/documentai_v1beta3.projects.locations.processors.html

Lines changed: 222 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,24 @@ <h2>Instance Methods</h2>
9090
<p class="toc_element">
9191
<code><a href="#close">close()</a></code></p>
9292
<p class="firstline">Close httplib2 connections.</p>
93+
<p class="toc_element">
94+
<code><a href="#create">create(parent, body=None, x__xgafv=None)</a></code></p>
95+
<p class="firstline">Creates a processor from the type processor that the user chose. The processor will be at "ENABLED" state by default after its creation.</p>
96+
<p class="toc_element">
97+
<code><a href="#delete">delete(name, x__xgafv=None)</a></code></p>
98+
<p class="firstline">Deletes the processor, unloads all deployed model artifacts if it was enabled and then deletes all artifacts associated with this processor.</p>
99+
<p class="toc_element">
100+
<code><a href="#disable">disable(name, body=None, x__xgafv=None)</a></code></p>
101+
<p class="firstline">Disables a processor</p>
102+
<p class="toc_element">
103+
<code><a href="#enable">enable(name, body=None, x__xgafv=None)</a></code></p>
104+
<p class="firstline">Enables a processor</p>
105+
<p class="toc_element">
106+
<code><a href="#list">list(parent, pageSize=None, pageToken=None, x__xgafv=None)</a></code></p>
107+
<p class="firstline">Lists all processors which belong to this project.</p>
108+
<p class="toc_element">
109+
<code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p>
110+
<p class="firstline">Retrieves the next page of results.</p>
93111
<p class="toc_element">
94112
<code><a href="#process">process(name, body=None, x__xgafv=None)</a></code></p>
95113
<p class="firstline">Processes a single document.</p>
@@ -168,6 +186,210 @@ <h3>Method Details</h3>
168186
<pre>Close httplib2 connections.</pre>
169187
</div>
170188

189+
<div class="method">
190+
<code class="details" id="create">create(parent, body=None, x__xgafv=None)</code>
191+
<pre>Creates a processor from the type processor that the user chose. The processor will be at &quot;ENABLED&quot; state by default after its creation.
192+
193+
Args:
194+
parent: string, Required. The parent (project and location) under which to create the processor. Format: projects/{project}/locations/{location} (required)
195+
body: object, The request body.
196+
The object takes the form of:
197+
198+
{ # The first-class citizen for DAI. Each processor defines how to extract structural information from a document.
199+
&quot;createTime&quot;: &quot;A String&quot;, # The time the processor was created.
200+
&quot;defaultProcessorVersion&quot;: &quot;A String&quot;, # The default processor version.
201+
&quot;displayName&quot;: &quot;A String&quot;, # The display name of the processor.
202+
&quot;kmsKeyName&quot;: &quot;A String&quot;, # The KMS key used for encryption/decryption in CMEK scenarios. See https://cloud.google.com/security-key-management.
203+
&quot;name&quot;: &quot;A String&quot;, # Output only. Immutable. The resource name of the processor. Format: projects/{project}/locations/{location}/processors/{processor}
204+
&quot;processEndpoint&quot;: &quot;A String&quot;, # Output only. Immutable. The http endpoint that can be called to invoke processing.
205+
&quot;state&quot;: &quot;A String&quot;, # Output only. The state of the processor.
206+
&quot;type&quot;: &quot;A String&quot;, # The processor type, e.g., INVOICE_PARSING, W2_PARSING, etc.
207+
}
208+
209+
x__xgafv: string, V1 error format.
210+
Allowed values
211+
1 - v1 error format
212+
2 - v2 error format
213+
214+
Returns:
215+
An object of the form:
216+
217+
{ # The first-class citizen for DAI. Each processor defines how to extract structural information from a document.
218+
&quot;createTime&quot;: &quot;A String&quot;, # The time the processor was created.
219+
&quot;defaultProcessorVersion&quot;: &quot;A String&quot;, # The default processor version.
220+
&quot;displayName&quot;: &quot;A String&quot;, # The display name of the processor.
221+
&quot;kmsKeyName&quot;: &quot;A String&quot;, # The KMS key used for encryption/decryption in CMEK scenarios. See https://cloud.google.com/security-key-management.
222+
&quot;name&quot;: &quot;A String&quot;, # Output only. Immutable. The resource name of the processor. Format: projects/{project}/locations/{location}/processors/{processor}
223+
&quot;processEndpoint&quot;: &quot;A String&quot;, # Output only. Immutable. The http endpoint that can be called to invoke processing.
224+
&quot;state&quot;: &quot;A String&quot;, # Output only. The state of the processor.
225+
&quot;type&quot;: &quot;A String&quot;, # The processor type, e.g., INVOICE_PARSING, W2_PARSING, etc.
226+
}</pre>
227+
</div>
228+
229+
<div class="method">
230+
<code class="details" id="delete">delete(name, x__xgafv=None)</code>
231+
<pre>Deletes the processor, unloads all deployed model artifacts if it was enabled and then deletes all artifacts associated with this processor.
232+
233+
Args:
234+
name: string, Required. The processor resource name to be deleted. (required)
235+
x__xgafv: string, V1 error format.
236+
Allowed values
237+
1 - v1 error format
238+
2 - v2 error format
239+
240+
Returns:
241+
An object of the form:
242+
243+
{ # This resource represents a long-running operation that is the result of a network API call.
244+
&quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress. If `true`, the operation is completed, and either `error` or `response` is available.
245+
&quot;error&quot;: { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # The error result of the operation in case of failure or cancellation.
246+
&quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
247+
&quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of message types for APIs to use.
248+
{
249+
&quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
250+
},
251+
],
252+
&quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
253+
},
254+
&quot;metadata&quot;: { # Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any.
255+
&quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
256+
},
257+
&quot;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`.
258+
&quot;response&quot;: { # The normal response of the operation in case of success. If the original method returns no data on success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the response should have the type `XxxResponse`, where `Xxx` is the original method name. For example, if the original method name is `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`.
259+
&quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
260+
},
261+
}</pre>
262+
</div>
263+
264+
<div class="method">
265+
<code class="details" id="disable">disable(name, body=None, x__xgafv=None)</code>
266+
<pre>Disables a processor
267+
268+
Args:
269+
name: string, Required. The processor resource name to be disabled. (required)
270+
body: object, The request body.
271+
The object takes the form of:
272+
273+
{ # Request message for the disable processor method.
274+
}
275+
276+
x__xgafv: string, V1 error format.
277+
Allowed values
278+
1 - v1 error format
279+
2 - v2 error format
280+
281+
Returns:
282+
An object of the form:
283+
284+
{ # This resource represents a long-running operation that is the result of a network API call.
285+
&quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress. If `true`, the operation is completed, and either `error` or `response` is available.
286+
&quot;error&quot;: { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # The error result of the operation in case of failure or cancellation.
287+
&quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
288+
&quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of message types for APIs to use.
289+
{
290+
&quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
291+
},
292+
],
293+
&quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
294+
},
295+
&quot;metadata&quot;: { # Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any.
296+
&quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
297+
},
298+
&quot;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`.
299+
&quot;response&quot;: { # The normal response of the operation in case of success. If the original method returns no data on success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the response should have the type `XxxResponse`, where `Xxx` is the original method name. For example, if the original method name is `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`.
300+
&quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
301+
},
302+
}</pre>
303+
</div>
304+
305+
<div class="method">
306+
<code class="details" id="enable">enable(name, body=None, x__xgafv=None)</code>
307+
<pre>Enables a processor
308+
309+
Args:
310+
name: string, Required. The processor resource name to be enabled. (required)
311+
body: object, The request body.
312+
The object takes the form of:
313+
314+
{ # Request message for the enable processor method.
315+
}
316+
317+
x__xgafv: string, V1 error format.
318+
Allowed values
319+
1 - v1 error format
320+
2 - v2 error format
321+
322+
Returns:
323+
An object of the form:
324+
325+
{ # This resource represents a long-running operation that is the result of a network API call.
326+
&quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress. If `true`, the operation is completed, and either `error` or `response` is available.
327+
&quot;error&quot;: { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # The error result of the operation in case of failure or cancellation.
328+
&quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
329+
&quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of message types for APIs to use.
330+
{
331+
&quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
332+
},
333+
],
334+
&quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
335+
},
336+
&quot;metadata&quot;: { # Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any.
337+
&quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
338+
},
339+
&quot;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`.
340+
&quot;response&quot;: { # The normal response of the operation in case of success. If the original method returns no data on success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the response should have the type `XxxResponse`, where `Xxx` is the original method name. For example, if the original method name is `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`.
341+
&quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
342+
},
343+
}</pre>
344+
</div>
345+
346+
<div class="method">
347+
<code class="details" id="list">list(parent, pageSize=None, pageToken=None, x__xgafv=None)</code>
348+
<pre>Lists all processors which belong to this project.
349+
350+
Args:
351+
parent: string, Required. The parent (project and location) which owns this collection of Processors. Format: projects/{project}/locations/{location} (required)
352+
pageSize: integer, The maximum number of processors to return. If unspecified, at most 50 processors will be returned. The maximum value is 100; values above 100 will be coerced to 100.
353+
pageToken: string, We will return the processors sorted by creation time. The page token will point to the next processor.
354+
x__xgafv: string, V1 error format.
355+
Allowed values
356+
1 - v1 error format
357+
2 - v2 error format
358+
359+
Returns:
360+
An object of the form:
361+
362+
{ # Response message for list processors.
363+
&quot;nextPageToken&quot;: &quot;A String&quot;, # Points to the next processor, otherwise empty.
364+
&quot;processors&quot;: [ # The list of processors.
365+
{ # The first-class citizen for DAI. Each processor defines how to extract structural information from a document.
366+
&quot;createTime&quot;: &quot;A String&quot;, # The time the processor was created.
367+
&quot;defaultProcessorVersion&quot;: &quot;A String&quot;, # The default processor version.
368+
&quot;displayName&quot;: &quot;A String&quot;, # The display name of the processor.
369+
&quot;kmsKeyName&quot;: &quot;A String&quot;, # The KMS key used for encryption/decryption in CMEK scenarios. See https://cloud.google.com/security-key-management.
370+
&quot;name&quot;: &quot;A String&quot;, # Output only. Immutable. The resource name of the processor. Format: projects/{project}/locations/{location}/processors/{processor}
371+
&quot;processEndpoint&quot;: &quot;A String&quot;, # Output only. Immutable. The http endpoint that can be called to invoke processing.
372+
&quot;state&quot;: &quot;A String&quot;, # Output only. The state of the processor.
373+
&quot;type&quot;: &quot;A String&quot;, # The processor type, e.g., INVOICE_PARSING, W2_PARSING, etc.
374+
},
375+
],
376+
}</pre>
377+
</div>
378+
379+
<div class="method">
380+
<code class="details" id="list_next">list_next(previous_request, previous_response)</code>
381+
<pre>Retrieves the next page of results.
382+
383+
Args:
384+
previous_request: The request for the previous page. (required)
385+
previous_response: The response from the request for the previous page. (required)
386+
387+
Returns:
388+
A request object that you can call &#x27;execute()&#x27; on to request the next
389+
page. Returns None if there are no more items in the collection.
390+
</pre>
391+
</div>
392+
171393
<div class="method">
172394
<code class="details" id="process">process(name, body=None, x__xgafv=None)</code>
173395
<pre>Processes a single document.

0 commit comments

Comments
 (0)