Create Document Job Endpoint
POST
/v1/documents
const url = 'http://localhost:8080/v1/documents';const form = new FormData();form.append('file', 'example');form.append('template_id', 'example');form.append('template_name', 'example');form.append('processing_mode', 'example');form.append('page_range', 'example');
const options = {method: 'POST'};
options.body = form;
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url http://localhost:8080/v1/documents \ --header 'Content-Type: multipart/form-data' \ --form file=example \ --form template_id=example \ --form template_name=example \ --form processing_mode=example \ --form page_range=exampleRequest Body required
Section titled “Request Body required ”Responses
Section titled “ Responses ”Successful Response
Media type application/json
JobSubmissionResponse
object
job_id
required
Job Id
string
deduplicated
required
Deduplicated
boolean
status
required
Status
string
Example
{ "status": "queued"}Validation Error
Media type application/json
HTTPValidationError
object
detail
Detail
Array<object>
ValidationErrorobject
loc
required
Location
Array
msg
required
Message
string
type
required
Error Type
string
input
Input
ctx
Context
object
Example generated
{ "detail": [ { "loc": [ "example" ], "msg": "example", "type": "example", "input": "example", "ctx": {} } ]}