Endpoint dei processi
Endpoint e parametri dei processi
Recupero dei dettagli di un processo specifico
Retrieve Messages of a Specific Job
Per ulteriori informazioni sulle relazioni tra oggetti e su come utilizzarle nell'API, consulta la sezione Relazioni tra oggetti .
Per ulteriori informazioni sui processi, consulta la pagina di assistenza Processi: interfaccia di amministrazione .
Recupero dei dettagli di un processo specifico
Per recuperare i dettagli di un processo esistente e il suo stato corrente, utilizza l'endpoint
GET {baseURL}/v3/jobs/{jobId}
. Utilizza vari parametri per filtrare i processi che desideri visualizzare.
Nota
È possibile utilizza solo i flussi di lavoro delle app.
Users are able to see jobs run by them and jobs run on schedules shared via Collections.
Parametri
jobId (stringa): obbligatorio. Immetti l'ID del processo di cui desideri visualizzare i dettagli.
includeMessages (booleano): opzionale. È possibile non specificare alcun valore o selezionare "true" o "false". Se il parametro è impostato su "false", viene restituito un oggetto ridotto. In assenza di una specifica, viene utilizzato il valore "true".
curl -X 'GET' \ 'http://localhost/webapi/v3/jobs/66ebd18d3d6200007e000d8c?includeMessages=true' \ -H 'accept: application/json' \ -H 'authorization: Bearer BearerTokenGoesHere'
200: OK
{ "id": "string", "appId": "string", "createDateTime": "2024-09-19T10:02:54.589Z", "status": "string", "disposition": "string", "outputs": [ { "id": "string", "availableFormats": [ "string" ], "fileName": "string" } ], "messages": [ { "status": 0, "text": "string", "toolId": 0 } ], "priority": "Default", "workerTag": "string", "runWithE2": true }
401: Unauthorized
404: NotFound
Retrieve Messages of a Specific Job
To retrieve all messages of a specific job, use the GET {baseURL}/v3/jobs/{jobId}/messages
endpoint.
Nota
Only Curators can use this endpoint.
Parameters
jobId (string): Required. Enter the Job ID for which you want to display messages.
curl -X 'GET' \ 'http://localhost/webapi/v3/jobs/66ebd18d3d6200007e000d8c/messages' \ -H 'accept: application/json' \ -H 'authorization: Bearer BearerTokenGoesHere'
200: OK
{ "status": 0, "text": "string", "toolId": 0 }
401: Unauthorized
404: NotFound
Cancel a Specific Job
To cancel a specific job, use the DELETE {baseURL}/v3/jobs/{jobId}
endpoint. The job must be in "Queued" or "Running" state.
If you cancel a running job, it gets canceled. If you cancel a queued job, it gets deleted.
Nota
Curators can cancel any jobs.
Other roles can cancel jobs they have created, triggered, or scheduled. It includes jobs shared with them through Collections, even if they are not the job owner.
Parameters
jobId (string): Required. Enter the Job ID you want to cancel.
curl -X 'DELETE' \ 'http://localhost/webapi/v3/jobs/678f97baa15300008c0039fc' \ -H 'accept: application/json' \ -H 'authorization: Bearer BearerTokenGoesHere'
200: OK
Response when you cancel a running job:
{ "message": "Cancelled Successfully." }
Response when you cancel a queued job:
{ "message": "Deleted Successfully." }
400: BadRequest
Response when the job is not in ‘Queued’ or ‘Running’ state:
{ "message": "This job is not in 'Queued' or 'Running' state." }
Response when the user making the API call does not have permission to cancel the job:
{ "message": "You do not have permission to cancel this job." }
401: Unauthorized
404: NotFound
Relazioni tra oggetti
Per avere informazioni su un processo specifico, hai bisogno di un parametro
jobId
. Per ottenere il parametro jobId, utilizza l'endpoint
GET {baseURL}/v3/workflows/{workflowId}/jobs
. Per ulteriori informazioni su questo endpoint, consulta la pagina di assistenza
Endpoint dei flussi di lavoro
.
Richieste Postman
Per ulteriori informazioni sulle richieste Postman, consulta la pagina di assistenza Come utilizzare Postman .