Update Processor
curl --request POST \
--url https://api-prod.extend.app/v1/processors/:id \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"config": {
"type": "<string>",
"baseProcessor": "<string>",
"baseVersion": "<string>",
"schema": {},
"fields": [
{
"id": "<string>",
"name": "<string>",
"type": "<string>",
"description": "<string>",
"schema": [
{}
],
"enum": [
{
"value": "<string>",
"description": "<string>"
}
]
}
],
"extractionRules": "<string>",
"advancedOptions": {
"fixedPageLimit": 123,
"splitMethod": "<string>",
"splitIdentifierRules": "<string>",
"splitExcelDocumentsBySheetEnabled": true
},
"classifications": [
{
"id": "<string>",
"type": "<string>",
"description": "<string>"
}
],
"classificationRules": "<string>",
"splitClassifications": [
{
"id": "<string>",
"type": "<string>",
"description": "<string>"
}
],
"splitRules": "<string>"
}
}
'import requests
url = "https://api-prod.extend.app/v1/processors/:id"
payload = {
"name": "<string>",
"config": {
"type": "<string>",
"baseProcessor": "<string>",
"baseVersion": "<string>",
"schema": {},
"fields": [
{
"id": "<string>",
"name": "<string>",
"type": "<string>",
"description": "<string>",
"schema": [{}],
"enum": [
{
"value": "<string>",
"description": "<string>"
}
]
}
],
"extractionRules": "<string>",
"advancedOptions": {
"fixedPageLimit": 123,
"splitMethod": "<string>",
"splitIdentifierRules": "<string>",
"splitExcelDocumentsBySheetEnabled": True
},
"classifications": [
{
"id": "<string>",
"type": "<string>",
"description": "<string>"
}
],
"classificationRules": "<string>",
"splitClassifications": [
{
"id": "<string>",
"type": "<string>",
"description": "<string>"
}
],
"splitRules": "<string>"
}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
config: {
type: '<string>',
baseProcessor: '<string>',
baseVersion: '<string>',
schema: {},
fields: [
{
id: '<string>',
name: '<string>',
type: '<string>',
description: '<string>',
schema: [{}],
enum: [{value: '<string>', description: '<string>'}]
}
],
extractionRules: '<string>',
advancedOptions: {
fixedPageLimit: 123,
splitMethod: '<string>',
splitIdentifierRules: '<string>',
splitExcelDocumentsBySheetEnabled: true
},
classifications: [{id: '<string>', type: '<string>', description: '<string>'}],
classificationRules: '<string>',
splitClassifications: [{id: '<string>', type: '<string>', description: '<string>'}],
splitRules: '<string>'
}
})
};
fetch('https://api-prod.extend.app/v1/processors/:id', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api-prod.extend.app/v1/processors/:id",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>',
'config' => [
'type' => '<string>',
'baseProcessor' => '<string>',
'baseVersion' => '<string>',
'schema' => [
],
'fields' => [
[
'id' => '<string>',
'name' => '<string>',
'type' => '<string>',
'description' => '<string>',
'schema' => [
[
]
],
'enum' => [
[
'value' => '<string>',
'description' => '<string>'
]
]
]
],
'extractionRules' => '<string>',
'advancedOptions' => [
'fixedPageLimit' => 123,
'splitMethod' => '<string>',
'splitIdentifierRules' => '<string>',
'splitExcelDocumentsBySheetEnabled' => true
],
'classifications' => [
[
'id' => '<string>',
'type' => '<string>',
'description' => '<string>'
]
],
'classificationRules' => '<string>',
'splitClassifications' => [
[
'id' => '<string>',
'type' => '<string>',
'description' => '<string>'
]
],
'splitRules' => '<string>'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api-prod.extend.app/v1/processors/:id"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"config\": {\n \"type\": \"<string>\",\n \"baseProcessor\": \"<string>\",\n \"baseVersion\": \"<string>\",\n \"schema\": {},\n \"fields\": [\n {\n \"id\": \"<string>\",\n \"name\": \"<string>\",\n \"type\": \"<string>\",\n \"description\": \"<string>\",\n \"schema\": [\n {}\n ],\n \"enum\": [\n {\n \"value\": \"<string>\",\n \"description\": \"<string>\"\n }\n ]\n }\n ],\n \"extractionRules\": \"<string>\",\n \"advancedOptions\": {\n \"fixedPageLimit\": 123,\n \"splitMethod\": \"<string>\",\n \"splitIdentifierRules\": \"<string>\",\n \"splitExcelDocumentsBySheetEnabled\": true\n },\n \"classifications\": [\n {\n \"id\": \"<string>\",\n \"type\": \"<string>\",\n \"description\": \"<string>\"\n }\n ],\n \"classificationRules\": \"<string>\",\n \"splitClassifications\": [\n {\n \"id\": \"<string>\",\n \"type\": \"<string>\",\n \"description\": \"<string>\"\n }\n ],\n \"splitRules\": \"<string>\"\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api-prod.extend.app/v1/processors/:id")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"config\": {\n \"type\": \"<string>\",\n \"baseProcessor\": \"<string>\",\n \"baseVersion\": \"<string>\",\n \"schema\": {},\n \"fields\": [\n {\n \"id\": \"<string>\",\n \"name\": \"<string>\",\n \"type\": \"<string>\",\n \"description\": \"<string>\",\n \"schema\": [\n {}\n ],\n \"enum\": [\n {\n \"value\": \"<string>\",\n \"description\": \"<string>\"\n }\n ]\n }\n ],\n \"extractionRules\": \"<string>\",\n \"advancedOptions\": {\n \"fixedPageLimit\": 123,\n \"splitMethod\": \"<string>\",\n \"splitIdentifierRules\": \"<string>\",\n \"splitExcelDocumentsBySheetEnabled\": true\n },\n \"classifications\": [\n {\n \"id\": \"<string>\",\n \"type\": \"<string>\",\n \"description\": \"<string>\"\n }\n ],\n \"classificationRules\": \"<string>\",\n \"splitClassifications\": [\n {\n \"id\": \"<string>\",\n \"type\": \"<string>\",\n \"description\": \"<string>\"\n }\n ],\n \"splitRules\": \"<string>\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api-prod.extend.app/v1/processors/:id")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\",\n \"config\": {\n \"type\": \"<string>\",\n \"baseProcessor\": \"<string>\",\n \"baseVersion\": \"<string>\",\n \"schema\": {},\n \"fields\": [\n {\n \"id\": \"<string>\",\n \"name\": \"<string>\",\n \"type\": \"<string>\",\n \"description\": \"<string>\",\n \"schema\": [\n {}\n ],\n \"enum\": [\n {\n \"value\": \"<string>\",\n \"description\": \"<string>\"\n }\n ]\n }\n ],\n \"extractionRules\": \"<string>\",\n \"advancedOptions\": {\n \"fixedPageLimit\": 123,\n \"splitMethod\": \"<string>\",\n \"splitIdentifierRules\": \"<string>\",\n \"splitExcelDocumentsBySheetEnabled\": true\n },\n \"classifications\": [\n {\n \"id\": \"<string>\",\n \"type\": \"<string>\",\n \"description\": \"<string>\"\n }\n ],\n \"classificationRules\": \"<string>\",\n \"splitClassifications\": [\n {\n \"id\": \"<string>\",\n \"type\": \"<string>\",\n \"description\": \"<string>\"\n }\n ],\n \"splitRules\": \"<string>\"\n }\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"processor": {
"object": "document_processor",
"id": "processor_1234",
"name": "Updated Invoice Processor",
"type": "EXTRACT",
"createdAt": "2024-03-01T12:00:00Z",
"updatedAt": "2024-03-01T13:00:00Z",
"draftVersion": {
"id": "dpv_4567",
"version": "draft",
"config": {
"fields": [
{
"id": "field_1234",
"name": "invoice_number",
"description": "The invoice number",
"type": "string"
}
]
}
}
}
}
Processor Endpoints
Update Processor
Update an existing processor in Extend.
Update Processor
curl --request POST \
--url https://api-prod.extend.app/v1/processors/:id \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"config": {
"type": "<string>",
"baseProcessor": "<string>",
"baseVersion": "<string>",
"schema": {},
"fields": [
{
"id": "<string>",
"name": "<string>",
"type": "<string>",
"description": "<string>",
"schema": [
{}
],
"enum": [
{
"value": "<string>",
"description": "<string>"
}
]
}
],
"extractionRules": "<string>",
"advancedOptions": {
"fixedPageLimit": 123,
"splitMethod": "<string>",
"splitIdentifierRules": "<string>",
"splitExcelDocumentsBySheetEnabled": true
},
"classifications": [
{
"id": "<string>",
"type": "<string>",
"description": "<string>"
}
],
"classificationRules": "<string>",
"splitClassifications": [
{
"id": "<string>",
"type": "<string>",
"description": "<string>"
}
],
"splitRules": "<string>"
}
}
'import requests
url = "https://api-prod.extend.app/v1/processors/:id"
payload = {
"name": "<string>",
"config": {
"type": "<string>",
"baseProcessor": "<string>",
"baseVersion": "<string>",
"schema": {},
"fields": [
{
"id": "<string>",
"name": "<string>",
"type": "<string>",
"description": "<string>",
"schema": [{}],
"enum": [
{
"value": "<string>",
"description": "<string>"
}
]
}
],
"extractionRules": "<string>",
"advancedOptions": {
"fixedPageLimit": 123,
"splitMethod": "<string>",
"splitIdentifierRules": "<string>",
"splitExcelDocumentsBySheetEnabled": True
},
"classifications": [
{
"id": "<string>",
"type": "<string>",
"description": "<string>"
}
],
"classificationRules": "<string>",
"splitClassifications": [
{
"id": "<string>",
"type": "<string>",
"description": "<string>"
}
],
"splitRules": "<string>"
}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
config: {
type: '<string>',
baseProcessor: '<string>',
baseVersion: '<string>',
schema: {},
fields: [
{
id: '<string>',
name: '<string>',
type: '<string>',
description: '<string>',
schema: [{}],
enum: [{value: '<string>', description: '<string>'}]
}
],
extractionRules: '<string>',
advancedOptions: {
fixedPageLimit: 123,
splitMethod: '<string>',
splitIdentifierRules: '<string>',
splitExcelDocumentsBySheetEnabled: true
},
classifications: [{id: '<string>', type: '<string>', description: '<string>'}],
classificationRules: '<string>',
splitClassifications: [{id: '<string>', type: '<string>', description: '<string>'}],
splitRules: '<string>'
}
})
};
fetch('https://api-prod.extend.app/v1/processors/:id', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api-prod.extend.app/v1/processors/:id",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>',
'config' => [
'type' => '<string>',
'baseProcessor' => '<string>',
'baseVersion' => '<string>',
'schema' => [
],
'fields' => [
[
'id' => '<string>',
'name' => '<string>',
'type' => '<string>',
'description' => '<string>',
'schema' => [
[
]
],
'enum' => [
[
'value' => '<string>',
'description' => '<string>'
]
]
]
],
'extractionRules' => '<string>',
'advancedOptions' => [
'fixedPageLimit' => 123,
'splitMethod' => '<string>',
'splitIdentifierRules' => '<string>',
'splitExcelDocumentsBySheetEnabled' => true
],
'classifications' => [
[
'id' => '<string>',
'type' => '<string>',
'description' => '<string>'
]
],
'classificationRules' => '<string>',
'splitClassifications' => [
[
'id' => '<string>',
'type' => '<string>',
'description' => '<string>'
]
],
'splitRules' => '<string>'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api-prod.extend.app/v1/processors/:id"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"config\": {\n \"type\": \"<string>\",\n \"baseProcessor\": \"<string>\",\n \"baseVersion\": \"<string>\",\n \"schema\": {},\n \"fields\": [\n {\n \"id\": \"<string>\",\n \"name\": \"<string>\",\n \"type\": \"<string>\",\n \"description\": \"<string>\",\n \"schema\": [\n {}\n ],\n \"enum\": [\n {\n \"value\": \"<string>\",\n \"description\": \"<string>\"\n }\n ]\n }\n ],\n \"extractionRules\": \"<string>\",\n \"advancedOptions\": {\n \"fixedPageLimit\": 123,\n \"splitMethod\": \"<string>\",\n \"splitIdentifierRules\": \"<string>\",\n \"splitExcelDocumentsBySheetEnabled\": true\n },\n \"classifications\": [\n {\n \"id\": \"<string>\",\n \"type\": \"<string>\",\n \"description\": \"<string>\"\n }\n ],\n \"classificationRules\": \"<string>\",\n \"splitClassifications\": [\n {\n \"id\": \"<string>\",\n \"type\": \"<string>\",\n \"description\": \"<string>\"\n }\n ],\n \"splitRules\": \"<string>\"\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api-prod.extend.app/v1/processors/:id")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"config\": {\n \"type\": \"<string>\",\n \"baseProcessor\": \"<string>\",\n \"baseVersion\": \"<string>\",\n \"schema\": {},\n \"fields\": [\n {\n \"id\": \"<string>\",\n \"name\": \"<string>\",\n \"type\": \"<string>\",\n \"description\": \"<string>\",\n \"schema\": [\n {}\n ],\n \"enum\": [\n {\n \"value\": \"<string>\",\n \"description\": \"<string>\"\n }\n ]\n }\n ],\n \"extractionRules\": \"<string>\",\n \"advancedOptions\": {\n \"fixedPageLimit\": 123,\n \"splitMethod\": \"<string>\",\n \"splitIdentifierRules\": \"<string>\",\n \"splitExcelDocumentsBySheetEnabled\": true\n },\n \"classifications\": [\n {\n \"id\": \"<string>\",\n \"type\": \"<string>\",\n \"description\": \"<string>\"\n }\n ],\n \"classificationRules\": \"<string>\",\n \"splitClassifications\": [\n {\n \"id\": \"<string>\",\n \"type\": \"<string>\",\n \"description\": \"<string>\"\n }\n ],\n \"splitRules\": \"<string>\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api-prod.extend.app/v1/processors/:id")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\",\n \"config\": {\n \"type\": \"<string>\",\n \"baseProcessor\": \"<string>\",\n \"baseVersion\": \"<string>\",\n \"schema\": {},\n \"fields\": [\n {\n \"id\": \"<string>\",\n \"name\": \"<string>\",\n \"type\": \"<string>\",\n \"description\": \"<string>\",\n \"schema\": [\n {}\n ],\n \"enum\": [\n {\n \"value\": \"<string>\",\n \"description\": \"<string>\"\n }\n ]\n }\n ],\n \"extractionRules\": \"<string>\",\n \"advancedOptions\": {\n \"fixedPageLimit\": 123,\n \"splitMethod\": \"<string>\",\n \"splitIdentifierRules\": \"<string>\",\n \"splitExcelDocumentsBySheetEnabled\": true\n },\n \"classifications\": [\n {\n \"id\": \"<string>\",\n \"type\": \"<string>\",\n \"description\": \"<string>\"\n }\n ],\n \"classificationRules\": \"<string>\",\n \"splitClassifications\": [\n {\n \"id\": \"<string>\",\n \"type\": \"<string>\",\n \"description\": \"<string>\"\n }\n ],\n \"splitRules\": \"<string>\"\n }\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"processor": {
"object": "document_processor",
"id": "processor_1234",
"name": "Updated Invoice Processor",
"type": "EXTRACT",
"createdAt": "2024-03-01T12:00:00Z",
"updatedAt": "2024-03-01T13:00:00Z",
"draftVersion": {
"id": "dpv_4567",
"version": "draft",
"config": {
"fields": [
{
"id": "field_1234",
"name": "invoice_number",
"description": "The invoice number",
"type": "string"
}
]
}
}
}
}
This endpoint allows you to update the properties of an existing processor.
Path Parameters
string
required
The ID of the processor to update.
Body
string
The new name for the processor.
object
The new config to update the processor with.
- Extraction
- Classification
- Splitter
Show properties
Show properties
string
required
Must be
"EXTRACT" for extraction processors.string
The base processor to use. For extractors, this is either
"extraction_performance" or "extraction_light". See the base processor documentation for more details.string
The version of the base processor to use (e.g.
"4.0.0"). If this is provided, baseProcessor must be provided as well. See the processor changelog for available versions.object
The schema that defines the structure of data to extract from documents. One of
schema or fields must be provided. We recommend using schema as fields is deprecated. See the extraction processor schema documentation for more details.array
deprecated
The schema that defines the structure of data to extract from documents. One of
schema or fields must be provided. We recommend using schema as fields is deprecated. See the extraction processor schema documentation for more details on using the fields shape.Show properties
Show properties
string
required
Unique identifier for the field.
string
required
Human-readable name for the field.
string
required
Type of the field. Supported values:
string: Text valuesnumber: Numeric valuescurrency: Monetary valuesboolean: True/false valuesdate: Date valuesarray: Lists of values (requires schema)enum: Values from a predefined list (requires enum)object: Nested structure (requires schema)signature: Signature information
string
required
Detailed description of the field, including expected content and format.
array
Required when type is “array” or “object”. Contains nested field definitions.
string
Custom rules to guide the extraction process in natural language.
object
Advanced configuration options.
Show properties
Show properties
number
Limit processing to a specific number of pages from the beginning of the document.
string
Provide a hint about the document type (e.g. “invoice”, “receipt”, etc.).
string
Define specific key terms or concepts relevant to the document type.
boolean
Enable model reasoning insights in the extraction results.
boolean
Enable advanced multimodal processing for better handling of visual elements.
boolean
Enable citation information for extracted fields.
boolean
Enable advanced parsing of figures and diagrams in the document.
object
Options for controlling document chunking.
Show properties
Show properties
string
Strategy for chunking the document. Supported values:
standard: Default chunking strategysemantic: Content-aware chunking based on document structure
string
Custom rules for semantic chunking in natural language.
number
Number of pages per chunk.
string
Strategy for selecting chunks. Supported values:
intelligent: AI-based selectionconfidence: Select based on confidence scoretake_first: Always use first chunktake_last: Always use last chunk
Show properties
Show properties
string
required
Must be
"CLASSIFY" for classification processors.string
The base processor to use. For classifiers, must be
"classification_performance" or "classification_light". See the base processor documentation for more details.string
The version of the base processor to use (e.g.
"3.2.0"). If this is provided, baseProcessor must be provided as well. See the processor changelog for available versions.array
required
string
Custom rules to guide the classification process in natural language.
object
Advanced configuration options.
Show properties
Show properties
string
required
Must be
"SPLITTER" for splitter processors.string
The base processor to use. For splitters, this can currently only be
"splitter_performance". See the base processor documentation for more details.string
The version of the base processor to use (e.g.
"1.0.0"). If this is provided, baseProcessor must be provided as well. See the processor changelog for available versions.array
required
string
Custom rules to guide the document splitting process in natural language.
object
Advanced configuration options.
Show properties
Show properties
number
Limit processing to a specific number of pages from the beginning of the document.
string
Method to use for splitting. Supported values:
high_precision: More accurate but potentially slowerlow_latency: Faster but potentially less precise
string
boolean
For Excel documents, split by worksheet.
Response
boolean
A true or false value indicating whether the processor was updated
successfully or not.
DocumentProcessor
A DocumentProcessor object representing the updated processor. See the
DocumentProcessor object for more details.
Error Responses
boolean
Will be
false if the request failed.string
A description of the error that occurred.
{
"success": true,
"processor": {
"object": "document_processor",
"id": "processor_1234",
"name": "Updated Invoice Processor",
"type": "EXTRACT",
"createdAt": "2024-03-01T12:00:00Z",
"updatedAt": "2024-03-01T13:00:00Z",
"draftVersion": {
"id": "dpv_4567",
"version": "draft",
"config": {
"fields": [
{
"id": "field_1234",
"name": "invoice_number",
"description": "The invoice number",
"type": "string"
}
]
}
}
}
}

