Skip to main content
GET
/
v1
/
spans
/
{spanId}
Get span
curl --request GET \
  --url https://api.agentmark.co/v1/spans/{spanId} \
  --header 'Authorization: Bearer <token>' \
  --header 'X-Agentmark-App-Id: <api-key>'
{
  "data": {
    "cost": 123,
    "duration_ms": 123,
    "id": "<string>",
    "input": "<string>",
    "input_tokens": 1,
    "metadata": {},
    "model": "<string>",
    "name": "<string>",
    "output": "<string>",
    "output_object": "<string>",
    "output_tokens": 1,
    "parent_id": "<string>",
    "prompt_name": "<string>",
    "service_name": "<string>",
    "span_kind": "<string>",
    "status_message": "<string>",
    "timestamp": "2023-11-07T05:31:56Z",
    "tokens": 1,
    "tool_calls": "<string>",
    "trace_id": "<string>",
    "type": "<string>"
  }
}

Documentation Index

Fetch the complete documentation index at: https://docs.agentmark.co/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

X-Agentmark-App-Id
string
header
required

Application ID for tenant scoping

Authorization
string
header
required

API key (sk_agentmark_*)

Path Parameters

spanId
string
required

Response

The full span (metadata + I/O payload).

data
object
required