Creates a document.
HTTP request
POST https://contentwarehouse.googleapis.com/v1/{parent}/documents
Path parameters
Parameters | |
---|---|
parent |
Required. The parent name. Format: projects/{projectNumber}/locations/{location}. It takes the form |
Request body
The request body contains data with the following structure:
JSON representation |
---|
{ "document": { object ( |
Fields | |
---|---|
document |
Required. The document to create. |
requestMetadata |
The meta information collected about the end user, used to enforce access control for the service. |
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. |
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. |
createMask |
Field mask for creating Document fields. If mask path is empty, it means all fields are masked. For the This is a comma-separated list of fully qualified names of fields. Example: |
Response body
Response message for DocumentService.CreateDocument.
If successful, the response body contains data with the following structure:
JSON representation |
---|
{ "document": { object ( |
Fields | |
---|---|
document |
Document created after executing create request. |
ruleEngineOutput |
Output from Rule Engine recording the rule evaluator and action executor's output. Refer format in: google/cloud/contentwarehouse/v1/rule_engine.proto |
metadata |
Additional information for the API invocation, such as the request tracking id. |
longRunningOperations[] |
post-processing LROs |
Authorization scopes
Requires the following OAuth scope:
https://www.googleapis.com/auth/cloud-platform
For more information, see the Authentication Overview.
IAM Permissions
Requires the following IAM permission on the parent
resource:
contentwarehouse.documents.create
For more information, see the IAM documentation.