Class ClassifyRunsClient
- java.lang.Object
-
- ai.extend.resources.classifyruns.ClassifyRunsClient
-
- Direct Known Subclasses:
ClassifyRunsClient
public class ClassifyRunsClient extends java.lang.Object
-
-
Field Summary
Fields Modifier and Type Field Description protected ClientOptionsclientOptions
-
Constructor Summary
Constructors Constructor Description ClassifyRunsClient(ClientOptions clientOptions)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ClassifyRuncancel(java.lang.String id)Cancel an in-progress classify run.ClassifyRuncancel(java.lang.String id, RequestOptions requestOptions)Cancel an in-progress classify run.ClassifyRuncancel(java.lang.String id, ClassifyRunsCancelRequest request)Cancel an in-progress classify run.ClassifyRuncancel(java.lang.String id, ClassifyRunsCancelRequest request, RequestOptions requestOptions)Cancel an in-progress classify run.ClassifyRuncreate(ClassifyRunsCreateRequest request)Classify a document using an existing classifier or an inline configuration.ClassifyRuncreate(ClassifyRunsCreateRequest request, RequestOptions requestOptions)Classify a document using an existing classifier or an inline configuration.BatchRuncreateBatch(ClassifyRunsCreateBatchRequest request)Submit up to 1,000 files for classification in a single request.BatchRuncreateBatch(ClassifyRunsCreateBatchRequest request, RequestOptions requestOptions)Submit up to 1,000 files for classification in a single request.ClassifyRunsDeleteResponsedelete(java.lang.String id)Delete a classify run and all associated data from Extend.ClassifyRunsDeleteResponsedelete(java.lang.String id, RequestOptions requestOptions)Delete a classify run and all associated data from Extend.ClassifyRunsDeleteResponsedelete(java.lang.String id, ClassifyRunsDeleteRequest request)Delete a classify run and all associated data from Extend.ClassifyRunsDeleteResponsedelete(java.lang.String id, ClassifyRunsDeleteRequest request, RequestOptions requestOptions)Delete a classify run and all associated data from Extend.ClassifyRunsListResponselist()List all classify runs.ClassifyRunsListResponselist(RequestOptions requestOptions)List all classify runs.ClassifyRunsListResponselist(ClassifyRunsListRequest request)List all classify runs.ClassifyRunsListResponselist(ClassifyRunsListRequest request, RequestOptions requestOptions)List all classify runs.ClassifyRunretrieve(java.lang.String id)Retrieve details about a specific classify run, including its status and outputs.ClassifyRunretrieve(java.lang.String id, RequestOptions requestOptions)Retrieve details about a specific classify run, including its status and outputs.ClassifyRunretrieve(java.lang.String id, ClassifyRunsRetrieveRequest request)Retrieve details about a specific classify run, including its status and outputs.ClassifyRunretrieve(java.lang.String id, ClassifyRunsRetrieveRequest request, RequestOptions requestOptions)Retrieve details about a specific classify run, including its status and outputs.RawClassifyRunsClientwithRawResponse()Get responses with HTTP metadata like headers
-
-
-
Field Detail
-
clientOptions
protected final ClientOptions clientOptions
-
-
Constructor Detail
-
ClassifyRunsClient
public ClassifyRunsClient(ClientOptions clientOptions)
-
-
Method Detail
-
withRawResponse
public RawClassifyRunsClient withRawResponse()
Get responses with HTTP metadata like headers
-
list
public ClassifyRunsListResponse list()
List all classify runs.Returns a summary of each run. Use
GET /classify_runs/{id}to retrieve the full object includingoutputandconfig.
-
list
public ClassifyRunsListResponse list(RequestOptions requestOptions)
List all classify runs.Returns a summary of each run. Use
GET /classify_runs/{id}to retrieve the full object includingoutputandconfig.
-
list
public ClassifyRunsListResponse list(ClassifyRunsListRequest request)
List all classify runs.Returns a summary of each run. Use
GET /classify_runs/{id}to retrieve the full object includingoutputandconfig.
-
list
public ClassifyRunsListResponse list(ClassifyRunsListRequest request, RequestOptions requestOptions)
List all classify runs.Returns a summary of each run. Use
GET /classify_runs/{id}to retrieve the full object includingoutputandconfig.
-
create
public ClassifyRun create(ClassifyRunsCreateRequest request)
Classify a document using an existing classifier or an inline configuration.The request returns immediately with a
PROCESSINGstatus. Use webhooks or poll the Get Classify Run endpoint for results.
-
create
public ClassifyRun create(ClassifyRunsCreateRequest request, RequestOptions requestOptions)
Classify a document using an existing classifier or an inline configuration.The request returns immediately with a
PROCESSINGstatus. Use webhooks or poll the Get Classify Run endpoint for results.
-
retrieve
public ClassifyRun retrieve(java.lang.String id)
Retrieve details about a specific classify run, including its status and outputs.A common use case for this endpoint is to poll for the status and final output of a classify run when using the Create Classify Run endpoint. For instance, if you do not want to not configure webhooks to receive the output via completion/failure events.
-
retrieve
public ClassifyRun retrieve(java.lang.String id, RequestOptions requestOptions)
Retrieve details about a specific classify run, including its status and outputs.A common use case for this endpoint is to poll for the status and final output of a classify run when using the Create Classify Run endpoint. For instance, if you do not want to not configure webhooks to receive the output via completion/failure events.
-
retrieve
public ClassifyRun retrieve(java.lang.String id, ClassifyRunsRetrieveRequest request)
Retrieve details about a specific classify run, including its status and outputs.A common use case for this endpoint is to poll for the status and final output of a classify run when using the Create Classify Run endpoint. For instance, if you do not want to not configure webhooks to receive the output via completion/failure events.
-
retrieve
public ClassifyRun retrieve(java.lang.String id, ClassifyRunsRetrieveRequest request, RequestOptions requestOptions)
Retrieve details about a specific classify run, including its status and outputs.A common use case for this endpoint is to poll for the status and final output of a classify run when using the Create Classify Run endpoint. For instance, if you do not want to not configure webhooks to receive the output via completion/failure events.
-
delete
public ClassifyRunsDeleteResponse delete(java.lang.String id)
Delete a classify 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 ClassifyRunsDeleteResponse delete(java.lang.String id, RequestOptions requestOptions)
Delete a classify 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 ClassifyRunsDeleteResponse delete(java.lang.String id, ClassifyRunsDeleteRequest request)
Delete a classify 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 ClassifyRunsDeleteResponse delete(java.lang.String id, ClassifyRunsDeleteRequest request, RequestOptions requestOptions)
Delete a classify 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 ClassifyRun cancel(java.lang.String id)
Cancel an in-progress classify run.Note: Only classify runs with a status of
"PROCESSING"can be cancelled. Classifier runs that have already completed, failed, or been cancelled cannot be cancelled again.
-
cancel
public ClassifyRun cancel(java.lang.String id, RequestOptions requestOptions)
Cancel an in-progress classify run.Note: Only classify runs with a status of
"PROCESSING"can be cancelled. Classifier runs that have already completed, failed, or been cancelled cannot be cancelled again.
-
cancel
public ClassifyRun cancel(java.lang.String id, ClassifyRunsCancelRequest request)
Cancel an in-progress classify run.Note: Only classify runs with a status of
"PROCESSING"can be cancelled. Classifier runs that have already completed, failed, or been cancelled cannot be cancelled again.
-
cancel
public ClassifyRun cancel(java.lang.String id, ClassifyRunsCancelRequest request, RequestOptions requestOptions)
Cancel an in-progress classify run.Note: Only classify runs with a status of
"PROCESSING"can be cancelled. Classifier runs that have already completed, failed, or been cancelled cannot be cancelled again.
-
createBatch
public BatchRun createBatch(ClassifyRunsCreateBatchRequest request)
Submit up to 1,000 files for classification in a single request. Each file is processed as an independent classify run using the same classifier and configuration.Unlike the single Classify File (Async) endpoint, this batch endpoint accepts an
inputsarray and immediately returns aBatchRunobject containing a batchidand aPENDINGstatus. The individual runs are then queued and processed asynchronously.Monitoring results:
- Webhooks (recommended): Subscribe to
batch_processor_run.processedandbatch_processor_run.failedevents. The webhook payload indicates the batch has finished — fetch individual run results usingGET /classify_runs?batchId={id}. - Polling: Call
GET /batch_runs/{id}to check the overall batch status, and useGET /classify_runsfiltered bybatchIdto retrieve individual run results.
Notes:
- A processor reference (
classifier.id) is required — inlineconfigis not supported for batch requests. inputsmust contain between 1 and 1,000 items.- All inputs in a batch use the same classifier version and override config.
- Webhooks (recommended): Subscribe to
-
createBatch
public BatchRun createBatch(ClassifyRunsCreateBatchRequest request, RequestOptions requestOptions)
Submit up to 1,000 files for classification in a single request. Each file is processed as an independent classify run using the same classifier and configuration.Unlike the single Classify File (Async) endpoint, this batch endpoint accepts an
inputsarray and immediately returns aBatchRunobject containing a batchidand aPENDINGstatus. The individual runs are then queued and processed asynchronously.Monitoring results:
- Webhooks (recommended): Subscribe to
batch_processor_run.processedandbatch_processor_run.failedevents. The webhook payload indicates the batch has finished — fetch individual run results usingGET /classify_runs?batchId={id}. - Polling: Call
GET /batch_runs/{id}to check the overall batch status, and useGET /classify_runsfiltered bybatchIdto retrieve individual run results.
Notes:
- A processor reference (
classifier.id) is required — inlineconfigis not supported for batch requests. inputsmust contain between 1 and 1,000 items.- All inputs in a batch use the same classifier version and override config.
- Webhooks (recommended): Subscribe to
-
-