Poll Run Pipeline

GET /pipelines/run/${pipelineId}?jobId=${jobId}

Poll to retrieve the pipeline

Request

Headers

An API Key is required to access this endpoint.

NameValue

x-api-key

your_api_key

Polling response

The API returns the response in JSON format.

The request will return a 200 with the errors, jobId, metadata, result, status, and timeElapsed. The metadata includes the request parameters used to generate the transforms. Errors is an array of objects, each containing a key and a corresponding message.

Example

{
  "jobId": "093ae7d8-1668-4c76-9f31-772c50bcb172",
  "metadata": {
    "restaurant_id": "d9504261cc66", 
    "review": "This place was really good. Highly recommend it. We had the steak, chicken and prawns. All super good. You definitely come out full."
  },
  "result": {
    "sentiment": "POSITIVE",
    "translated_sentiment": "POSITIVO"
  },
  "status": "COMPLETE",
  "timeElapsed": 7885
}

Webhook response

The webhook sends back a JSON response when the transforms for each API request are done.

The request will return a 200 with the errors, jobId, metadata, result, status, and timeElapsed. The metadata includes the request parameters used to generate the transforms. Errors is an array of objects, each containing a key and a corresponding message.

Example

{
  "jobId": "093ae7d8-1668-4c76-9f31-772c50bcb172",
  "metadata": {
    "restaurant_id": "d9504261cc66", 
    "review": "This place was really good. Highly recommend it. We had the steak, chicken and prawns. All super good. You definitely come out full."
  },
  "result": {
    "sentiment": "POSITIVE",
    "translated_sentiment": "POSITIVO"
  },
  "status": "COMPLETE",
  "timeElapsed": 7885
}

Last updated