Skip to content
Framework Docs

Classify

Create Classify Job
client.Classify.New(ctx, params) (*ClassifyNewResponse, error)
POST/api/v2/classify
List Classify Jobs
client.Classify.List(ctx, query) (*PaginatedCursor[ClassifyListResponse], error)
GET/api/v2/classify
Get Classify Job
client.Classify.Get(ctx, jobID, query) (*ClassifyGetResponse, error)
GET/api/v2/classify/{job_id}
ModelsExpand Collapse
type ClassifyConfiguration struct{…}

Configuration for a classify job.

Rules []ClassifyConfigurationRule

Classify rules to evaluate against the document (at least one required)

Description string

Natural language criteria for matching this rule

maxLength500
minLength10
Type string

Document type to assign when rule matches

maxLength50
minLength1
Mode ClassifyConfigurationModeoptional

Classify execution mode

ParsingConfiguration ClassifyConfigurationParsingConfigurationoptional

Parsing configuration for classify jobs.

Lang stringoptional

ISO 639-1 language code for the document

MaxPages int64optional

Maximum number of pages to process. Omit for no limit.

minimum1
TargetPages stringoptional

Comma-separated page numbers or ranges to process (1-based). Omit to process all pages.

type ClassifyCreateRequest struct{…}

Request to create a classify job.

Configuration ClassifyConfigurationoptional

Configuration for a classify job.

Rules []ClassifyConfigurationRule

Classify rules to evaluate against the document (at least one required)

Description string

Natural language criteria for matching this rule

maxLength500
minLength10
Type string

Document type to assign when rule matches

maxLength50
minLength1
Mode ClassifyConfigurationModeoptional

Classify execution mode

ParsingConfiguration ClassifyConfigurationParsingConfigurationoptional

Parsing configuration for classify jobs.

Lang stringoptional

ISO 639-1 language code for the document

MaxPages int64optional

Maximum number of pages to process. Omit for no limit.

minimum1
TargetPages stringoptional

Comma-separated page numbers or ranges to process (1-based). Omit to process all pages.

ConfigurationID stringoptional

Saved configuration ID

DeprecatedFileID stringoptional

Deprecated: use file_input instead

FileInput stringoptional

File ID or parse job ID to classify

maxLength200
DeprecatedParseJobID stringoptional

Deprecated: use file_input instead

TransactionID stringoptional

Idempotency key scoped to the project

type ClassifyResult struct{…}

Result of classifying a document.

Confidence float64

Confidence score between 0.0 and 1.0

maximum1
minimum0
Reasoning string

Why the document matched (or didn't match) the returned rule

Type string

Matched rule type, or null if no rule matched