Class ProcessorRunClient
- java.lang.Object
-
- ai.extend.resources.processorrun.ProcessorRunClient
-
public class ProcessorRunClient extends java.lang.Object
-
-
Field Summary
Fields Modifier and Type Field Description protected ClientOptionsclientOptions
-
Constructor Summary
Constructors Constructor Description ProcessorRunClient(ClientOptions clientOptions)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ProcessorRunCancelResponsecancel(java.lang.String id)Cancel a running processor run by its ID.ProcessorRunCancelResponsecancel(java.lang.String id, RequestOptions requestOptions)Cancel a running processor run by its ID.ProcessorRunCreateResponsecreate(ProcessorRunCreateRequest request)Run processors (extraction, classification, splitting, etc.) on a given document.ProcessorRunCreateResponsecreate(ProcessorRunCreateRequest request, RequestOptions requestOptions)Run processors (extraction, classification, splitting, etc.) on a given document.ProcessorRunDeleteResponsedelete(java.lang.String id)Delete a processor run and all associated data from Extend.ProcessorRunDeleteResponsedelete(java.lang.String id, RequestOptions requestOptions)Delete a processor run and all associated data from Extend.ProcessorRunGetResponseget(java.lang.String id)Retrieve details about a specific processor run, including its status, outputs, and any edits made during review.ProcessorRunGetResponseget(java.lang.String id, RequestOptions requestOptions)Retrieve details about a specific processor run, including its status, outputs, and any edits made during review.RawProcessorRunClientwithRawResponse()Get responses with HTTP metadata like headers
-
-
-
Field Detail
-
clientOptions
protected final ClientOptions clientOptions
-
-
Constructor Detail
-
ProcessorRunClient
public ProcessorRunClient(ClientOptions clientOptions)
-
-
Method Detail
-
withRawResponse
public RawProcessorRunClient withRawResponse()
Get responses with HTTP metadata like headers
-
create
public ProcessorRunCreateResponse create(ProcessorRunCreateRequest request)
Run processors (extraction, classification, splitting, etc.) on a given document.Synchronous vs Asynchronous Processing:
- Asynchronous (default): Returns immediately with
PROCESSINGstatus. Use webhooks or polling to get results. - Synchronous: Set
sync: trueto wait for completion and get final results in the response (5-minute timeout).
For asynchronous processing:
- You can configure webhooks to receive notifications when a processor run is complete or failed.
- Or you can poll the get endpoint for updates on the status of the processor run.
- Asynchronous (default): Returns immediately with
-
create
public ProcessorRunCreateResponse create(ProcessorRunCreateRequest request, RequestOptions requestOptions)
Run processors (extraction, classification, splitting, etc.) on a given document.Synchronous vs Asynchronous Processing:
- Asynchronous (default): Returns immediately with
PROCESSINGstatus. Use webhooks or polling to get results. - Synchronous: Set
sync: trueto wait for completion and get final results in the response (5-minute timeout).
For asynchronous processing:
- You can configure webhooks to receive notifications when a processor run is complete or failed.
- Or you can poll the get endpoint for updates on the status of the processor run.
- Asynchronous (default): Returns immediately with
-
get
public ProcessorRunGetResponse get(java.lang.String id)
Retrieve details about a specific processor run, including its status, outputs, and any edits made during review.A common use case for this endpoint is to poll for the status and final output of an async processor run when using the Run Processor endpoint. For instance, if you do not want to not configure webhooks to receive the output via completion/failure events.
-
get
public ProcessorRunGetResponse get(java.lang.String id, RequestOptions requestOptions)
Retrieve details about a specific processor run, including its status, outputs, and any edits made during review.A common use case for this endpoint is to poll for the status and final output of an async processor run when using the Run Processor endpoint. For instance, if you do not want to not configure webhooks to receive the output via completion/failure events.
-
delete
public ProcessorRunDeleteResponse delete(java.lang.String id)
Delete a processor run and all associated data from Extend. This operation is permanent and cannot be undone.This endpoint can be used if you'd like to manage data retention on your own rather than automated data retention policies. Or make one-off deletions for your downstream customers.
-
delete
public ProcessorRunDeleteResponse delete(java.lang.String id, RequestOptions requestOptions)
Delete a processor run and all associated data from Extend. This operation is permanent and cannot be undone.This endpoint can be used if you'd like to manage data retention on your own rather than automated data retention policies. Or make one-off deletions for your downstream customers.
-
cancel
public ProcessorRunCancelResponse cancel(java.lang.String id)
Cancel a running processor run by its ID. This endpoint allows you to stop a processor run that is currently in progress.Note: Only processor runs with a status of
"PROCESSING"can be cancelled. Processor runs that have already completed, failed, or been cancelled cannot be cancelled again.
-
cancel
public ProcessorRunCancelResponse cancel(java.lang.String id, RequestOptions requestOptions)
Cancel a running processor run by its ID. This endpoint allows you to stop a processor run that is currently in progress.Note: Only processor runs with a status of
"PROCESSING"can be cancelled. Processor runs that have already completed, failed, or been cancelled cannot be cancelled again.
-
-