Get Call Trace

Hand off to an LLM

Retrieve the full execution trace of a workflow call.

Returns all function calls and events emitted during the call as flat arrays. The DAG can be reconstructed using FunctionCallResponseBase.sourceEventID (the event that spawned each function call) and each event's functionCallID (the function call that emitted it).

Graph structure

  • A function call with no sourceEventID is the root.
  • An event's functionCallID points to the function call that emitted it.
  • A function call's sourceEventID points to the event that triggered it.
  • workflowNodeName identifies the DAG node; incomingDestinationName identifies the labelled outlet used to reach this call (absent for unlabelled edges and root calls).

The trace is available as soon as the call exists and grows as execution proceeds.

GET
/v3/calls/{callID}/trace
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/trace"
{
  "trace": {
    "functionCalls": [
      {
        "functionCallID": "string",
        "functionID": "string",
        "functionName": "string",
        "type": "transform",
        "referenceID": "string",
        "status": "pending",
        "functionVersionNum": 0,
        "activity": [
          {
            "displayName": "string",
            "status": "pending"
          }
        ],
        "startedAt": "2019-08-24T14:15:22Z",
        "finishedAt": "2019-08-24T14:15:22Z",
        "sourceFunctionCallID": "string",
        "sourceEventID": "string",
        "workflowCallID": "string",
        "workflowNodeName": "string",
        "incomingDestinationName": "string",
        "inputType": "string",
        "s3URL": "string",
        "inputs": [
          {
            "inputType": "string",
            "itemReferenceID": "string",
            "s3URL": "string"
          }
        ]
      }
    ],
    "events": [
      null
    ]
  },
  "error": "string"
}

See also