public class Client
extends java.lang.Object
| Constructor and Description |
|---|
Client(Credentials credentials)
A client to invoke api methods from Lucidtech AI Services.
|
| Modifier and Type | Method and Description |
|---|---|
org.json.JSONObject |
createAsset(byte[] content)
Creates an asset, calls the POST /assets endpoint.
|
org.json.JSONObject |
createAsset(byte[] content,
CreateAssetOptions options)
Creates an asset, calls the POST /assets endpoint.
|
org.json.JSONObject |
createAsset(java.io.InputStream content)
Creates an asset, calls the POST /assets endpoint.
|
org.json.JSONObject |
createAsset(java.io.InputStream content,
CreateAssetOptions options)
Creates an asset, calls the POST /assets endpoint.
|
org.json.JSONObject |
createBatch()
Creates a batch, calls the POST /batches endpoint.
|
org.json.JSONObject |
createBatch(CreateBatchOptions options)
Creates a batch, calls the POST /batches endpoint.
|
org.json.JSONObject |
createDocument(byte[] content,
ContentType contentType)
Creates a document, calls the POST /documents endpoint.
|
org.json.JSONObject |
createDocument(byte[] content,
ContentType contentType,
CreateDocumentOptions options)
Creates a document, calls the POST /documents endpoint.
|
org.json.JSONObject |
createDocument(java.io.InputStream content,
ContentType contentType)
Creates a document, calls the POST /documents endpoint.
|
org.json.JSONObject |
createDocument(java.io.InputStream content,
ContentType contentType,
CreateDocumentOptions options)
Creates a document, calls the POST /documents endpoint.
|
org.json.JSONObject |
createPrediction(java.lang.String documentId,
java.lang.String modelId)
Create a prediction on a document using specified model, calls the POST /predictions endpoint.
|
org.json.JSONObject |
createPrediction(java.lang.String documentId,
java.lang.String modelId,
CreatePredictionOptions options)
Create a prediction on a document using specified model, calls the POST /predictions endpoint.
|
org.json.JSONObject |
createSecret(org.json.JSONObject data)
Creates a secret, calls the POST /secrets endpoint.
|
org.json.JSONObject |
createSecret(org.json.JSONObject data,
CreateSecretOptions options)
Creates a secret, calls the POST /secrets endpoint.
|
org.json.JSONObject |
createSecret(java.util.Map<java.lang.String,java.lang.String> data)
Creates a secret, calls the POST /secrets endpoint.
|
org.json.JSONObject |
createSecret(java.util.Map<java.lang.String,java.lang.String> data,
CreateSecretOptions options)
Creates a secret, calls the POST /secrets endpoint.
|
org.json.JSONObject |
createTransition(TransitionType transitionType)
Creates a transition, calls the POST /transitions endpoint.
|
org.json.JSONObject |
createTransition(TransitionType transitionType,
CreateTransitionOptions options)
Creates a transition, calls the POST /transitions endpoint.
|
org.json.JSONObject |
createUser(java.lang.String email)
Creates a new user, calls the POST /users endpoint.
|
org.json.JSONObject |
createUser(java.lang.String email,
CreateUserOptions options)
Creates a new user, calls the POST /users endpoint.
|
org.json.JSONObject |
createWorkflow(org.json.JSONObject specification)
Creates a new workflow, calls the POST /workflows endpoint.
|
org.json.JSONObject |
createWorkflow(org.json.JSONObject specification,
CreateWorkflowOptions options)
Creates a new workflow, calls the POST /workflows endpoint.
|
org.json.JSONObject |
deleteDocuments()
Delete documents, calls the DELETE /documents endpoint.
|
org.json.JSONObject |
deleteDocuments(java.lang.String consentId)
Delete documents with the provided consentId, calls the DELETE /documents endpoint.
|
org.json.JSONObject |
deleteTransition(java.lang.String transitionId)
Delete a transition, calls the PATCH /transitions/{transitionId} endpoint.
|
org.json.JSONObject |
deleteUser(java.lang.String userId)
Delete a user, calls the PATCH /users/{userId} endpoint.
|
org.json.JSONObject |
deleteWorkflow(java.lang.String workflowId)
Delete a workflow, calls the DELETE /workflows/{workflowId} endpoint.
|
org.json.JSONObject |
deleteWorkflowExecution(java.lang.String workflowId,
java.lang.String executionId)
Deletes the execution with the provided executionId from workflowId,
calls the DELETE /workflows/{workflowId}/executions/{executionId} endpoint.
|
org.json.JSONObject |
executeTransition(java.lang.String transitionId)
Start executing a manual transition, calls the POST /transitions/{transitionId}/executions endpoint.
|
org.json.JSONObject |
executeWorkflow(java.lang.String workflowId,
org.json.JSONObject content)
Start a workflow execution, calls the POST /workflows/{workflowId}/executions endpoint.
|
org.json.JSONObject |
getAsset(java.lang.String assetId)
Get asset, calls the GET /assets/{assetId} endpoint.
|
org.json.JSONObject |
getDocument(java.lang.String documentId)
Get document, calls the GET /documents/{documentId} endpoint.
|
org.json.JSONObject |
getLog(java.lang.String logId)
Get log, calls the GET /logs/{logId} endpoint.
|
org.json.JSONObject |
getTransition(java.lang.String transitionId)
Get transition, calls the GET /transitions/{transitionId} endpoint.
|
org.json.JSONObject |
getTransitionExecution(java.lang.String transitionId,
java.lang.String executionId)
Get an execution of a transition, calls the GET /transitions/{transitionId}/executions/{executionId} endpoint
|
org.json.JSONObject |
getUser(java.lang.String userId)
Get information about a specific user, calls the GET /users/{user_id} endpoint.
|
org.json.JSONObject |
getWorkflow(java.lang.String workflowId)
Get workflow, calls the GET /workflows/{workflowId} endpoint.
|
org.json.JSONObject |
listAssets()
List assets available, calls the GET /assets endpoint.
|
org.json.JSONObject |
listAssets(ListAssetsOptions options)
List assets available, calls the GET /assets endpoint.
|
org.json.JSONObject |
listDocuments()
List documents, calls the GET /documents endpoint.
|
org.json.JSONObject |
listDocuments(ListDocumentsOptions options)
List documents, calls the GET /documents endpoint.
|
org.json.JSONObject |
listModels()
List models available, calls the GET /models endpoint.
|
org.json.JSONObject |
listModels(ListModelsOptions options)
List models available, calls the GET /models endpoint.
|
org.json.JSONObject |
listPredictions()
List predictions available, calls the GET /predictions endpoint.
|
org.json.JSONObject |
listPredictions(ListPredictionsOptions options)
List predictions available, calls the GET /predictions endpoint.
|
org.json.JSONObject |
listSecrets()
List secrets available, calls the GET /secrets endpoint.
|
org.json.JSONObject |
listSecrets(ListSecretsOptions options)
List secrets available, calls the GET /secrets endpoint.
|
org.json.JSONObject |
listTransitionExecutions(java.lang.String transitionId)
List executions in a transition, calls the GET /transitions/{transitionId}/executions endpoint.
|
org.json.JSONObject |
listTransitionExecutions(java.lang.String transitionId,
ListTransitionExecutionsOptions options)
List executions in a transition, calls the GET /transitions/{transitionId}/executions endpoint.
|
org.json.JSONObject |
listTransitions()
List transitions, calls the GET /transitions endpoint.
|
org.json.JSONObject |
listTransitions(ListTransitionsOptions options)
List transitions, calls the GET /transitions endpoint.
|
org.json.JSONObject |
listUsers()
List users, calls the GET /users endpoint.
|
org.json.JSONObject |
listUsers(ListUsersOptions options)
List users, calls the GET /users endpoint.
|
org.json.JSONObject |
listWorkflowExecutions(java.lang.String workflowId)
List executions in a workflow, calls the GET /workflows/{workflowId}/executions endpoint.
|
org.json.JSONObject |
listWorkflowExecutions(java.lang.String workflowId,
ListWorkflowExecutionsOptions options)
List executions in a workflow, calls the GET /workflows/{workflowId}/executions endpoint.
|
org.json.JSONObject |
listWorkflows()
List workflows, calls the GET /workflows endpoint.
|
org.json.JSONObject |
listWorkflows(ListWorkflowsOptions options)
List workflows, calls the GET /workflows endpoint.
|
org.json.JSONObject |
sendHeartbeat(java.lang.String transitionId,
java.lang.String executionId)
Send heartbeat for a manual execution to signal that we are still working on it.
|
org.json.JSONObject |
updateAsset(java.lang.String assetId,
UpdateAssetOptions options)
Updates an asset, calls the PATCH /assets/{assetId} endpoint.
|
org.json.JSONObject |
updateDocument(java.lang.String documentId,
org.json.JSONArray groundTruth)
Update ground truth for a document, calls the PATCH /documents/{documentId} endpoint.
|
org.json.JSONObject |
updateSecret(java.lang.String secretId,
UpdateSecretOptions options)
Updates a secret, calls the PATCH /secrets/{secretId} endpoint.
|
org.json.JSONObject |
updateTransition(java.lang.String transitionId,
UpdateTransitionOptions options)
Updates a transition, calls the PATCH /transitions/{transitionId} endpoint.
|
org.json.JSONObject |
updateTransitionExecution(java.lang.String transitionId,
java.lang.String executionId,
TransitionExecutionStatus status,
UpdateTransitionExecutionOptions options)
Ends the processing of the transition execution,
calls the PATCH /transitions/{transition_id}/executions/{execution_id} endpoint.
|
org.json.JSONObject |
updateUser(java.lang.String userId,
UpdateUserOptions options)
Updates a user, calls the PATCH /users/{userId} endpoint.
|
org.json.JSONObject |
updateWorkflow(java.lang.String workflowId,
UpdateWorkflowOptions options)
Updates a workflow, calls the PATCH /workflows/{workflowId} endpoint.
|
public Client(Credentials credentials)
credentials - Credentials to useCredentialspublic org.json.JSONObject createAsset(byte[] content,
CreateAssetOptions options)
throws java.io.IOException,
APIException,
MissingAccessTokenException
content - Binary dataoptions - Additional options to include in request bodyjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedCreateAssetOptionspublic org.json.JSONObject createAsset(java.io.InputStream content,
CreateAssetOptions options)
throws java.io.IOException,
APIException,
MissingAccessTokenException
content - Data from input streamoptions - Additional options to include in request bodyjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedCreateAssetOptionspublic org.json.JSONObject createAsset(byte[] content)
throws java.io.IOException,
APIException,
MissingAccessTokenException
content - Binary datajava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject createAsset(java.io.InputStream content)
throws java.io.IOException,
APIException,
MissingAccessTokenException
content - Data from input streamjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject listAssets(ListAssetsOptions options) throws java.io.IOException, APIException, MissingAccessTokenException
options - Additional options to pass along as query parametersjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedListAssetsOptionspublic org.json.JSONObject listAssets()
throws java.io.IOException,
APIException,
MissingAccessTokenException
java.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject getAsset(java.lang.String assetId)
throws java.io.IOException,
APIException,
MissingAccessTokenException
assetId - Id of the assetjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject updateAsset(java.lang.String assetId,
UpdateAssetOptions options)
throws java.io.IOException,
APIException,
MissingAccessTokenException
assetId - Id of the assetoptions - Additional options to include in request bodyjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedUpdateAssetOptionspublic org.json.JSONObject createBatch(CreateBatchOptions options) throws java.io.IOException, APIException, MissingAccessTokenException
options - Additional options to include in request bodyjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedCreateBatchOptionspublic org.json.JSONObject createBatch()
throws java.io.IOException,
APIException,
MissingAccessTokenException
java.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject createDocument(byte[] content,
ContentType contentType,
CreateDocumentOptions options)
throws java.io.IOException,
APIException,
MissingAccessTokenException
content - Binary datacontentType - A mime type for the documentoptions - Additional options to include in request bodyjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedCreateDocumentOptionspublic org.json.JSONObject createDocument(java.io.InputStream content,
ContentType contentType,
CreateDocumentOptions options)
throws java.io.IOException,
APIException,
MissingAccessTokenException
content - Data from input streamcontentType - A mime type for the documentoptions - Additional options to include in request bodyjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedCreateDocumentOptionspublic org.json.JSONObject createDocument(java.io.InputStream content,
ContentType contentType)
throws java.io.IOException,
APIException,
MissingAccessTokenException
content - Data from input streamcontentType - A mime type for the documentjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedCreateDocumentOptionspublic org.json.JSONObject createDocument(byte[] content,
ContentType contentType)
throws java.io.IOException,
APIException,
MissingAccessTokenException
content - Binary datacontentType - A mime type for the documentjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedCreateDocumentOptionspublic org.json.JSONObject listDocuments(ListDocumentsOptions options) throws java.io.IOException, APIException, MissingAccessTokenException
options - Additional options to pass along as query parametersjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedListDocumentsOptionspublic org.json.JSONObject listDocuments()
throws java.io.IOException,
APIException,
MissingAccessTokenException
java.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject deleteDocuments()
throws java.io.IOException,
APIException,
MissingAccessTokenException
java.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedcreateDocument(byte[], ai.lucidtech.las.sdk.ContentType, ai.lucidtech.las.sdk.CreateDocumentOptions)public org.json.JSONObject deleteDocuments(java.lang.String consentId)
throws java.io.IOException,
APIException,
MissingAccessTokenException
consentId - Delete documents with this consentIdjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedcreateDocument(byte[], ai.lucidtech.las.sdk.ContentType, ai.lucidtech.las.sdk.CreateDocumentOptions)public org.json.JSONObject getDocument(java.lang.String documentId)
throws java.io.IOException,
APIException,
MissingAccessTokenException
documentId - Id of the documentjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject updateDocument(java.lang.String documentId,
org.json.JSONArray groundTruth)
throws java.io.IOException,
APIException,
MissingAccessTokenException
documentId - The document id to post groundTruth to.groundTruth - List of json objects containing label and value for the ground truthjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedcreateDocument(byte[], ai.lucidtech.las.sdk.ContentType, ai.lucidtech.las.sdk.CreateDocumentOptions)public org.json.JSONObject getLog(java.lang.String logId)
throws java.io.IOException,
APIException,
MissingAccessTokenException
logId - Id of the logjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject listModels(ListModelsOptions options) throws java.io.IOException, APIException, MissingAccessTokenException
options - Additional options to pass along as query parametersjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedListModelsOptionspublic org.json.JSONObject listModels()
throws java.io.IOException,
APIException,
MissingAccessTokenException
java.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject createPrediction(java.lang.String documentId,
java.lang.String modelId,
CreatePredictionOptions options)
throws java.io.IOException,
APIException,
MissingAccessTokenException
documentId - The document id to run inference and create a prediction on.modelId - The id of the model to use for inferenceoptions - Additional options to include in request bodyjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedcreateDocument(byte[], ai.lucidtech.las.sdk.ContentType, ai.lucidtech.las.sdk.CreateDocumentOptions),
CreatePredictionOptionspublic org.json.JSONObject createPrediction(java.lang.String documentId,
java.lang.String modelId)
throws java.io.IOException,
APIException,
MissingAccessTokenException
documentId - The document id to run inference and create a prediction on.modelId - The id of the model to use for inferencejava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedcreateDocument(byte[], ai.lucidtech.las.sdk.ContentType, ai.lucidtech.las.sdk.CreateDocumentOptions)public org.json.JSONObject listPredictions(ListPredictionsOptions options) throws java.io.IOException, APIException, MissingAccessTokenException
options - Additional options to pass along as query parametersjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedListPredictionsOptionspublic org.json.JSONObject listPredictions()
throws java.io.IOException,
APIException,
MissingAccessTokenException
java.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject createSecret(org.json.JSONObject data,
CreateSecretOptions options)
throws java.io.IOException,
APIException,
MissingAccessTokenException
data - Key-Value pairs to store secretlyoptions - Additional options to include in request bodyjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedCreateSecretOptionspublic org.json.JSONObject createSecret(java.util.Map<java.lang.String,java.lang.String> data,
CreateSecretOptions options)
throws java.io.IOException,
APIException,
MissingAccessTokenException
data - Key-Value pairs to store secretlyoptions - Additional options to include in request bodyjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedCreateSecretOptionspublic org.json.JSONObject createSecret(java.util.Map<java.lang.String,java.lang.String> data)
throws java.io.IOException,
APIException,
MissingAccessTokenException
data - Key-Value pairs to store secretlyjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject createSecret(org.json.JSONObject data)
throws java.io.IOException,
APIException,
MissingAccessTokenException
data - Key-Value pairs to store secretlyjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject listSecrets(ListSecretsOptions options) throws java.io.IOException, APIException, MissingAccessTokenException
options - Additional options to pass along as query parametersjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedListSecretsOptionspublic org.json.JSONObject listSecrets()
throws java.io.IOException,
APIException,
MissingAccessTokenException
java.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject updateSecret(java.lang.String secretId,
UpdateSecretOptions options)
throws java.io.IOException,
APIException,
MissingAccessTokenException
secretId - Id of the secretoptions - Additional options to include in request bodyjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedUpdateSecretOptionspublic org.json.JSONObject createTransition(TransitionType transitionType, CreateTransitionOptions options) throws java.io.IOException, APIException, MissingAccessTokenException
transitionType - Type of transitionoptions - Additional options to include in request bodyjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedCreateTransitionOptions,
TransitionTypepublic org.json.JSONObject createTransition(TransitionType transitionType) throws java.io.IOException, APIException, MissingAccessTokenException
transitionType - Type of transitionjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedTransitionTypepublic org.json.JSONObject listTransitions(ListTransitionsOptions options) throws java.io.IOException, APIException, MissingAccessTokenException
options - Additional options to pass along as query parametersjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedListTransitionsOptionspublic org.json.JSONObject listTransitions()
throws java.io.IOException,
APIException,
MissingAccessTokenException
java.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject getTransition(java.lang.String transitionId)
throws java.io.IOException,
APIException,
MissingAccessTokenException
transitionId - Id of the transitionjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject updateTransition(java.lang.String transitionId,
UpdateTransitionOptions options)
throws java.io.IOException,
APIException,
MissingAccessTokenException
transitionId - Id of the transitionoptions - Additional options to include in request bodyjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedUpdateTransitionOptionspublic org.json.JSONObject executeTransition(java.lang.String transitionId)
throws java.io.IOException,
APIException,
MissingAccessTokenException
transitionId - Id of the transitionjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject deleteTransition(java.lang.String transitionId)
throws java.io.IOException,
APIException,
MissingAccessTokenException
transitionId - Id of the transitionjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject listTransitionExecutions(java.lang.String transitionId,
ListTransitionExecutionsOptions options)
throws java.io.IOException,
APIException,
MissingAccessTokenException
transitionId - Id of the transitionoptions - Additional options to pass along as query parametersjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedListTransitionExecutionsOptionspublic org.json.JSONObject listTransitionExecutions(java.lang.String transitionId)
throws java.io.IOException,
APIException,
MissingAccessTokenException
transitionId - Id of the transitionjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject getTransitionExecution(java.lang.String transitionId,
java.lang.String executionId)
throws java.io.IOException,
APIException,
MissingAccessTokenException
transitionId - Id of the transitionexecutionId - Id of the executionjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject updateTransitionExecution(java.lang.String transitionId,
java.lang.String executionId,
TransitionExecutionStatus status,
UpdateTransitionExecutionOptions options)
throws java.io.IOException,
APIException,
MissingAccessTokenException
transitionId - Id of the transitionexecutionId - Id of the executionstatus - Status of the executionoptions - Additional options to include in request bodyjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedUpdateTransitionExecutionOptions,
TransitionExecutionStatuspublic org.json.JSONObject sendHeartbeat(java.lang.String transitionId,
java.lang.String executionId)
throws java.io.IOException,
APIException,
MissingAccessTokenException
transitionId - Id of the transitionexecutionId - Id of the executionjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject createUser(java.lang.String email,
CreateUserOptions options)
throws java.io.IOException,
APIException,
MissingAccessTokenException
email - Email of the new useroptions - Additional options to include in request bodyjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedCreateUserOptionspublic org.json.JSONObject createUser(java.lang.String email)
throws java.io.IOException,
APIException,
MissingAccessTokenException
email - Email to the new userjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject listUsers(ListUsersOptions options) throws java.io.IOException, APIException, MissingAccessTokenException
options - Additional options to pass along as query parametersjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedListUsersOptionspublic org.json.JSONObject listUsers()
throws java.io.IOException,
APIException,
MissingAccessTokenException
java.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject getUser(java.lang.String userId)
throws java.io.IOException,
APIException,
MissingAccessTokenException
userId - The Id of the userjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject updateUser(java.lang.String userId,
UpdateUserOptions options)
throws java.io.IOException,
APIException,
MissingAccessTokenException
userId - Id of the useroptions - Additional options to include in request bodyjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedUpdateUserOptionspublic org.json.JSONObject deleteUser(java.lang.String userId)
throws java.io.IOException,
APIException,
MissingAccessTokenException
userId - Id of the userjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject createWorkflow(org.json.JSONObject specification,
CreateWorkflowOptions options)
throws java.io.IOException,
APIException,
MissingAccessTokenException
specification - Specification of the workflow,
currently supporting ASL: https://states-language.net/spec.html. Check out the tutorials for more information:
see https://docs.lucidtech.ai/getting-started/tutorials/tutorial_custom_predict_and_approve#creating-the-workflowoptions - Additional options to include in request bodyjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedCreateWorkflowOptionspublic org.json.JSONObject createWorkflow(org.json.JSONObject specification)
throws java.io.IOException,
APIException,
MissingAccessTokenException
specification - Specification of the workflow,
currently supporting ASL: https://states-language.net/spec.html. Check out the tutorials for more information:
see https://docs.lucidtech.ai/getting-started/tutorials/tutorial_custom_predict_and_approve#creating-the-workflowjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject listWorkflows(ListWorkflowsOptions options) throws java.io.IOException, APIException, MissingAccessTokenException
options - Additional options to pass along as query parametersjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedListWorkflowsOptionspublic org.json.JSONObject listWorkflows()
throws java.io.IOException,
APIException,
MissingAccessTokenException
java.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject getWorkflow(java.lang.String workflowId)
throws java.io.IOException,
APIException,
MissingAccessTokenException
workflowId - Id of the workflowjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject updateWorkflow(java.lang.String workflowId,
UpdateWorkflowOptions options)
throws java.io.IOException,
APIException,
MissingAccessTokenException
workflowId - Id of the workflowoptions - Additional options to include in request bodyjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedUpdateWorkflowOptionspublic org.json.JSONObject deleteWorkflow(java.lang.String workflowId)
throws java.io.IOException,
APIException,
MissingAccessTokenException
workflowId - Id of the workflowjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedcreateWorkflow(org.json.JSONObject, ai.lucidtech.las.sdk.CreateWorkflowOptions)public org.json.JSONObject executeWorkflow(java.lang.String workflowId,
org.json.JSONObject content)
throws java.io.IOException,
APIException,
MissingAccessTokenException
workflowId - Id of the workflowcontent - Input to the first step of the workflowjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject listWorkflowExecutions(java.lang.String workflowId,
ListWorkflowExecutionsOptions options)
throws java.io.IOException,
APIException,
MissingAccessTokenException
workflowId - Id of the workflowoptions - Additional options to pass along as query parametersjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedListWorkflowExecutionsOptionspublic org.json.JSONObject listWorkflowExecutions(java.lang.String workflowId)
throws java.io.IOException,
APIException,
MissingAccessTokenException
workflowId - Id of the workflowjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedpublic org.json.JSONObject deleteWorkflowExecution(java.lang.String workflowId,
java.lang.String executionId)
throws java.io.IOException,
APIException,
MissingAccessTokenException
workflowId - Id of the workflowexecutionId - Id of the executionjava.io.IOException - General IOExceptionAPIException - Raised when API returns an erroneous status codeMissingAccessTokenException - Raised if access token cannot be obtainedexecuteWorkflow(java.lang.String, org.json.JSONObject)