REST Resource: projects.locations.processors

Resource: Processor

The first-class citizen for Document AI. Each processor defines how to extract structural information from a document.

JSON representation
{
  "name": string,
  "type": string,
  "displayName": string,
  "state": enum (State),
  "defaultProcessorVersion": string,
  "processorVersionAliases": [
    {
      object (ProcessorVersionAlias)
    }
  ],
  "processEndpoint": string,
  "createTime": string,
  "kmsKeyName": string
}
Fields
name

string

Output only. Immutable. The resource name of the processor. Format: projects/{project}/locations/{location}/processors/{processor}

type

string

The processor type, such as: OCR_PROCESSOR, INVOICE_PROCESSOR. To get a list of processor types, see FetchProcessorTypes.

displayName

string

The display name of the processor.

state

enum (State)

Output only. The state of the processor.

defaultProcessorVersion

string

The default processor version.

processorVersionAliases[]

object (ProcessorVersionAlias)

Output only. The processor version aliases.

processEndpoint

string

Output only. Immutable. The http endpoint that can be called to invoke processing.

createTime

string (Timestamp format)

The time the processor was created.

A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".

kmsKeyName

string

The KMS key used for encryption and decryption in CMEK scenarios.

State

The possible states of the processor.

Enums
STATE_UNSPECIFIED The processor is in an unspecified state.
ENABLED The processor is enabled, i.e., has an enabled version which can currently serve processing requests and all the feature dependencies have been successfully initialized.
DISABLED The processor is disabled.
ENABLING The processor is being enabled, will become ENABLED if successful.
DISABLING The processor is being disabled, will become DISABLED if successful.
CREATING The processor is being created, will become either ENABLED (for successful creation) or FAILED (for failed ones). Once a processor is in this state, it can then be used for document processing, but the feature dependencies of the processor might not be fully created yet.
FAILED The processor failed during creation or initialization of feature dependencies. The user should delete the processor and recreate one as all the functionalities of the processor are disabled.
DELETING The processor is being deleted, will be removed if successful.

ProcessorVersionAlias

Contains the alias and the aliased resource name of processor version.

JSON representation
{
  "alias": string,
  "processorVersion": string
}
Fields
alias

string

The alias in the form of processorVersion resource name.

processorVersion

string

The resource name of aliased processor version.

Methods

batchProcess

LRO endpoint to batch process many documents.

create

Creates a processor from the ProcessorType provided.

delete

Deletes the processor, unloads all deployed model artifacts if it was enabled and then deletes all artifacts associated with this processor.

disable

Disables a processor

enable

Enables a processor

get

Gets a processor detail.

list

Lists all processors which belong to this project.

process

Processes a single document.

setDefaultProcessorVersion

Set the default (active) version of a Processor that will be used in ProcessDocument and BatchProcessDocuments.