Get a Call

Hand off to an LLM

Retrieve a workflow call by ID.

Returns the full call object including status, workflow details, terminal outputs, and terminal errors. outputs and errors are both populated once the call finishes — they are not mutually exclusive (a partially-completed workflow may have both).

Status

StatusDescription
pendingQueued, not yet started
runningCurrently executing
completedAll enclosed function calls finished without errors
failedOne or more enclosed function calls produced an error event

Poll this endpoint or configure a webhook subscription to detect completion.

GET
/v3/calls/{callID}
x-api-key<token>

Authenticate using API Key in request header

In: header

Path Parameters

callID*string

The unique identifier of the call.

Response Body

application/json

curl -X GET "https://api.bem.ai/v3/calls/string"
{
  "call": {
    "callID": "string",
    "status": "pending",
    "createdAt": "2019-08-24T14:15:22Z",
    "finishedAt": "2019-08-24T14:15:22Z",
    "workflowID": "string",
    "workflowName": "string",
    "workflowVersionNum": 0,
    "callReferenceID": "string",
    "outputs": [
      {
        "functionCallTryNumber": 0,
        "eventID": "string",
        "createdAt": "2019-08-24T14:15:22Z",
        "referenceID": "string",
        "inboundEmail": {
          "to": "string",
          "deliveredTo": "string",
          "from": "string",
          "subject": "string"
        },
        "metadata": {
          "durationFunctionToEventSeconds": 0
        },
        "eventType": "transform",
        "functionCallID": "string",
        "functionID": "string",
        "functionName": "string",
        "functionVersionNum": 0,
        "callID": "string",
        "workflowID": "string",
        "workflowName": "string",
        "workflowVersionNum": 0,
        "pipelineID": "string",
        "publishedAt": "2019-08-24T14:15:22Z",
        "lastPublishErrorAt": "string",
        "inputType": "csv",
        "transformationID": "string",
        "s3URL": "string",
        "inputs": [
          {
            "inputType": "string",
            "inputContent": "string",
            "jsonInputContent": {},
            "s3URL": "string"
          }
        ],
        "transformedContent": {},
        "correctedContent": {
          "output": [
            {}
          ]
        },
        "invalidProperties": [
          "string"
        ],
        "metrics": {
          "metrics": {
            "accuracy": 0,
            "precision": 0,
            "recall": 0,
            "f1Score": 0
          },
          "differences": [
            {
              "category": "string",
              "correctedVal": null,
              "extractedVal": null,
              "jsonPointer": "string"
            }
          ]
        },
        "orderMatching": true,
        "isRegression": true,
        "itemOffset": 0,
        "itemCount": 0,
        "fieldConfidences": {},
        "avgConfidence": 0.1
      }
    ],
    "errors": [
      {
        "functionCallTryNumber": 0,
        "eventID": "string",
        "createdAt": "2019-08-24T14:15:22Z",
        "referenceID": "string",
        "inboundEmail": {
          "to": "string",
          "deliveredTo": "string",
          "from": "string",
          "subject": "string"
        },
        "metadata": {
          "durationFunctionToEventSeconds": 0
        },
        "eventType": "error",
        "functionCallID": "string",
        "functionID": "string",
        "functionName": "string",
        "functionVersionNum": 0,
        "callID": "string",
        "workflowID": "string",
        "workflowName": "string",
        "workflowVersionNum": 0,
        "message": "string"
      }
    ],
    "input": {
      "singleFile": {
        "inputType": "string",
        "s3URL": "string"
      },
      "batchFiles": {
        "inputs": [
          {
            "inputType": "string",
            "itemReferenceID": "string",
            "s3URL": "string"
          }
        ]
      }
    },
    "url": "string",
    "traceUrl": "string"
  },
  "error": "string"
}

See also