NAME
Google::Cloud::Contentwarehouse::V1::DocumentServiceRequest - Compiled Protocol Buffers messages for google/cloud/contentwarehouse/v1/document_service_request.proto
SYNOPSIS
use Google::Cloud::Contentwarehouse::V1::DocumentServiceRequest;
my $msg = Google::Cloud::Contentwarehouse::V1::DocumentServiceRequest::CloudAIDocumentOption->new({
enable_entities_conversions => $enable_entities_conversions,
customized_entities_properties_conversions => $customized_entities_properties_conversions,
});
# Read or update a field
my $val = $msg->enable_entities_conversions();
# Binary wire-format roundtrip
my $bytes = $msg->serialize();
my $decoded = Google::Cloud::Contentwarehouse::V1::DocumentServiceRequest::CloudAIDocumentOption->parse($bytes);
# Canonical ProtoJSON
my $json = $msg->to_json();
DESCRIPTION
Auto-generated Protobuf message classes compiled from google/cloud/contentwarehouse/v1/document_service_request.proto. All message classes inherit from Protobuf::Message and support new(), serialize(), parse(), to_json(), from_json(), to_text(), and to_perl().
MESSAGES
Google::Cloud::Contentwarehouse::V1::DocumentServiceRequest::CloudAIDocumentOption
Request Option for processing Cloud AI Document in CW Document.
Inherits from Protobuf::Message.
Accessors
$msg->enable_entities_conversions()/$msg->enable_entities_conversions($value)Type:
BoolWhether to convert all the entities to properties.
$msg->customized_entities_properties_conversions()/$msg->customized_entities_properties_conversions($value)Type:
Message(Google::Cloud::Contentwarehouse::V1::DocumentServiceRequest::CloudAIDocumentOption::CustomizedEntitiesPropertiesConversionsEntry)If set, only selected entities will be converted to properties.
Google::Cloud::Contentwarehouse::V1::DocumentServiceRequest::CreateDocumentRequest
Request message for DocumentService.CreateDocument.
Inherits from Protobuf::Message.
Accessors
$msg->parent()/$msg->parent($value)Type:
StringRequired. The parent name. Format: projects/{project_number}/locations/{location}.
$msg->document()/$msg->document($value)Type:
Message(Google::Cloud::Contentwarehouse::V1::Document::Document)Required. The document to create.
$msg->request_metadata()/$msg->request_metadata($value)Type:
Message(Google::Cloud::Contentwarehouse::V1::Common::RequestMetadata)The meta information collected about the end user, used to enforce access control for the service.
$msg->policy()/$msg->policy($value)Type:
Message(Google::Iam::V1::Policy::Policy)Default document policy during creation. This refers to an Identity and Access (IAM) policy, which specifies access controls for the Document. Conditions defined in the policy will be ignored.
$msg->cloud_ai_document_option()/$msg->cloud_ai_document_option($value)Type:
Message(Google::Cloud::Contentwarehouse::V1::DocumentServiceRequest::CloudAIDocumentOption)Request Option for processing Cloud AI Document in Document Warehouse. This field offers limited support for mapping entities from Cloud AI Document to Warehouse Document. Please consult with product team before using this field and other available options.
$msg->create_mask()/$msg->create_mask($value)Type:
Message(Google::Protobuf::FieldMask::FieldMask)Field mask for creating Document fields. If mask path is empty, it means all fields are masked. For the `FieldMask` definition, see https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask.
Google::Cloud::Contentwarehouse::V1::DocumentServiceRequest::GetDocumentRequest
Request message for DocumentService.GetDocument.
Inherits from Protobuf::Message.
Accessors
$msg->name()/$msg->name($value)Type:
StringRequired. The name of the document to retrieve. Format: projects/{project_number}/locations/{location}/documents/{document_id} or projects/{project_number}/locations/{location}/documents/referenceId/{reference_id}.
$msg->request_metadata()/$msg->request_metadata($value)Type:
Message(Google::Cloud::Contentwarehouse::V1::Common::RequestMetadata)The meta information collected about the end user, used to enforce access control for the service.
Google::Cloud::Contentwarehouse::V1::DocumentServiceRequest::UpdateDocumentRequest
Request message for DocumentService.UpdateDocument.
Inherits from Protobuf::Message.
Accessors
$msg->name()/$msg->name($value)Type:
StringRequired. The name of the document to update. Format: projects/{project_number}/locations/{location}/documents/{document_id} or projects/{project_number}/locations/{location}/documents/referenceId/{reference_id}.
$msg->document()/$msg->document($value)Type:
Message(Google::Cloud::Contentwarehouse::V1::Document::Document)Required. The document to update.
$msg->request_metadata()/$msg->request_metadata($value)Type:
Message(Google::Cloud::Contentwarehouse::V1::Common::RequestMetadata)The meta information collected about the end user, used to enforce access control for the service.
$msg->cloud_ai_document_option()/$msg->cloud_ai_document_option($value)Type:
Message(Google::Cloud::Contentwarehouse::V1::DocumentServiceRequest::CloudAIDocumentOption)Request Option for processing Cloud AI Document in Document Warehouse. This field offers limited support for mapping entities from Cloud AI Document to Warehouse Document. Please consult with product team before using this field and other available options.
$msg->update_options()/$msg->update_options($value)Type:
Message(Google::Cloud::Contentwarehouse::V1::Common::UpdateOptions)Options for the update operation.
Google::Cloud::Contentwarehouse::V1::DocumentServiceRequest::DeleteDocumentRequest
Request message for DocumentService.DeleteDocument.
Inherits from Protobuf::Message.
Accessors
$msg->name()/$msg->name($value)Type:
StringRequired. The name of the document to delete. Format: projects/{project_number}/locations/{location}/documents/{document_id} or projects/{project_number}/locations/{location}/documents/referenceId/{reference_id}.
$msg->request_metadata()/$msg->request_metadata($value)Type:
Message(Google::Cloud::Contentwarehouse::V1::Common::RequestMetadata)The meta information collected about the end user, used to enforce access control for the service.
Google::Cloud::Contentwarehouse::V1::DocumentServiceRequest::SearchDocumentsRequest
Request message for DocumentService.SearchDocuments.
Inherits from Protobuf::Message.
Accessors
$msg->parent()/$msg->parent($value)Type:
StringRequired. The parent, which owns this collection of documents. Format: projects/{project_number}/locations/{location}.
$msg->request_metadata()/$msg->request_metadata($value)Type:
Message(Google::Cloud::Contentwarehouse::V1::Common::RequestMetadata)The meta information collected about the end user, used to enforce access control and improve the search quality of the service.
$msg->document_query()/$msg->document_query($value)Type:
Message(Google::Cloud::Contentwarehouse::V1::Filters::DocumentQuery)Query used to search against documents (keyword, filters, etc.).
$msg->offset()/$msg->offset($value)Type:
Int32An integer that specifies the current offset (that is, starting result location, amongst the documents deemed by the API as relevant) in search results. This field is only considered if [page_token][google.cloud.contentwarehouse.v1.SearchDocumentsRequest.page_token] is unset.
The maximum allowed value is 5000. Otherwise an error is thrown.
For example, 0 means to return results starting from the first matching document, and 10 means to return from the 11th document. This can be used for pagination, (for example, pageSize = 10 and offset = 10 means to return from the second page).
$msg->page_size()/$msg->page_size($value)Type:
Int32A limit on the number of documents returned in the search results. Increasing this value above the default value of 10 can increase search response time. The value can be between 1 and 100.
$msg->page_token()/$msg->page_token($value)Type:
StringThe token specifying the current offset within search results. See [SearchDocumentsResponse.next_page_token][google.cloud.contentwarehouse.v1.SearchDocumentsResponse.next_page_token] for an explanation of how to obtain the next set of query results.
$msg->order_by()/$msg->order_by($value)Type:
StringThe criteria determining how search results are sorted. For non-empty query, default is `"relevance desc"`. For empty query, default is `"upload_date desc"`.
Supported options are:
* `"relevance desc"`: By relevance descending, as determined by the API algorithms. * `"upload_date desc"`: By upload date descending. * `"upload_date"`: By upload date ascending. * `"update_date desc"`: By last updated date descending. * `"update_date"`: By last updated date ascending. * `"retrieval_importance desc"`: By retrieval importance of properties descending. This feature is still under development, please do not use unless otherwise instructed to do so.
$msg->histogram_queries()/$msg->histogram_queries($value)Type:
Message(Google::Cloud::Contentwarehouse::V1::Histogram::HistogramQuery)An expression specifying a histogram request against matching documents. Expression syntax is an aggregation function call with histogram facets and other options.
The following aggregation functions are supported:
* `count(string_histogram_facet)`: Count the number of matching entities for each distinct attribute value.
Data types:
* Histogram facet (aka filterable properties): Facet names with format <schema id>.<facet>. Facets will have the format of: `[a-zA-Z][a-zA-Z0-9_:/-.]`. If the facet is a child facet, then the parent hierarchy needs to be specified separated by dots in the prefix after the schema id. Thus, the format for a multi- level facet is: <schema id>.<parent facet name>. <child facet name>. Example: schema123.root_parent_facet.middle_facet.child_facet * DocumentSchemaId: (with no schema id prefix) to get histograms for each document type (returns the schema id path, e.g. projects/12345/locations/us-west/documentSchemas/abc123).
Example expression:
* Document type counts: count('DocumentSchemaId')
* For schema id, abc123, get the counts for MORTGAGE_TYPE: count('abc123.MORTGAGE_TYPE')
$msg->require_total_size()/$msg->require_total_size($value)Type:
BoolControls if the search document request requires the return of a total size of matched documents. See [SearchDocumentsResponse.total_size][google.cloud.contentwarehouse.v1.SearchDocumentsResponse.total_size].
Enabling this flag may adversely impact performance. Hint: If this is used with pagination, set this flag on the initial query but set this to false on subsequent page calls (keep the total count locally).
Defaults to false.
$msg->total_result_size()/$msg->total_result_size($value)Type:
Enum(Google::Cloud::Contentwarehouse::V1::SearchDocumentsRequest::TotalResultSize)Controls if the search document request requires the return of a total size of matched documents. See [SearchDocumentsResponse.total_size][google.cloud.contentwarehouse.v1.SearchDocumentsResponse.total_size].
$msg->qa_size_limit()/$msg->qa_size_limit($value)Type:
Int32Experimental, do not use. The limit on the number of documents returned for the question-answering feature. To enable the question-answering feature, set [DocumentQuery].[is_nl_query][] to true.
Enum: SearchDocumentsRequest::TotalResultSize
TOTAL_RESULT_SIZE_UNSPECIFIED=>0ESTIMATED_SIZE=>1ACTUAL_SIZE=>2
Google::Cloud::Contentwarehouse::V1::DocumentServiceRequest::LockDocumentRequest
Request message for DocumentService.LockDocument.
Inherits from Protobuf::Message.
Accessors
$msg->name()/$msg->name($value)Type:
StringRequired. The name of the document to lock. Format: projects/{project_number}/locations/{location}/documents/{document}.
$msg->collection_id()/$msg->collection_id($value)Type:
StringThe collection the document connects to.
$msg->locking_user()/$msg->locking_user($value)Type:
Message(Google::Cloud::Contentwarehouse::V1::Common::UserInfo)The user information who locks the document.
Google::Cloud::Contentwarehouse::V1::DocumentServiceRequest::FetchAclRequest
Request message for DocumentService.FetchAcl
Inherits from Protobuf::Message.
Accessors
$msg->resource()/$msg->resource($value)Type:
StringRequired. REQUIRED: The resource for which the policy is being requested. Format for document: projects/{project_number}/locations/{location}/documents/{document_id}. Format for collection: projects/{project_number}/locations/{location}/collections/{collection_id}. Format for project: projects/{project_number}.
$msg->request_metadata()/$msg->request_metadata($value)Type:
Message(Google::Cloud::Contentwarehouse::V1::Common::RequestMetadata)The meta information collected about the end user, used to enforce access control for the service.
$msg->project_owner()/$msg->project_owner($value)Type:
BoolFor Get Project ACL only. Authorization check for end user will be ignored when project_owner=true.
Google::Cloud::Contentwarehouse::V1::DocumentServiceRequest::SetAclRequest
Request message for DocumentService.SetAcl.
Inherits from Protobuf::Message.
Accessors
$msg->resource()/$msg->resource($value)Type:
StringRequired. REQUIRED: The resource for which the policy is being requested. Format for document: projects/{project_number}/locations/{location}/documents/{document_id}. Format for collection: projects/{project_number}/locations/{location}/collections/{collection_id}. Format for project: projects/{project_number}.
$msg->policy()/$msg->policy($value)Type:
Message(Google::Iam::V1::Policy::Policy)Required. REQUIRED: The complete policy to be applied to the `resource`. The size of the policy is limited to a few 10s of KB. This refers to an Identity and Access (IAM) policy, which specifies access controls for the Document.
You can set ACL with condition for projects only.
Supported operators are: `=`, `!=`, `<`, `<=`, `>`, and `>=` where the left of the operator is `DocumentSchemaId` or property name and the right of the operator is a number or a quoted string. You must escape backslash (\\) and quote (\") characters.
Boolean expressions (AND/OR) are supported up to 3 levels of nesting (for example, "((A AND B AND C) OR D) AND E"), a maximum of 10 comparisons are allowed in the expression. The expression must be < 6000 bytes in length.
Sample condition: `"DocumentSchemaId = \"some schema id\" OR SchemaId.floatPropertyName >= 10"`
$msg->request_metadata()/$msg->request_metadata($value)Type:
Message(Google::Cloud::Contentwarehouse::V1::Common::RequestMetadata)The meta information collected about the end user, used to enforce access control for the service.
$msg->project_owner()/$msg->project_owner($value)Type:
BoolFor Set Project ACL only. Authorization check for end user will be ignored when project_owner=true.
SEE ALSO
Protobuf, Protobuf::Message, Google::Cloud::Contentwarehouse::V1::DocumentServiceRequest::Types, https://protobuf.dev/
LICENSE AND COPYRIGHT
Copyright (C) 2026 Google LLC
This program is released under the Apache 2.0 license.