Docs / Observability
Flight Recorder

Traces & Audit Logs

TrustGate provides a complete "Black Box" recording of every AI interaction. Trace complex agent chains, debug errors, and export logs to your SIEM.

The Flight Recorder

A searchable immutable log of every request. Filter by AgentID, PII Detected, or Latency.

Distributed Tracing

Stitch together multi-step agent workflows (Think → Tool → Act) into a single Gantt view.

Linking Agent Steps (Tracing)

To visualize an Agent's "Chain of Thought" in the dashboard, pass the x-trustgate-trace-id header.

Python SDK
import uuid
trace_id = str(uuid.uuid4())

# Step 1: Planning
client.chat.completions.create(
  model="gpt-4",
  extra_headers={
    "x-trustgate-trace-id": trace_id,
    "x-trustgate-workflow-step": "planning"
  }
)

SIEM Export (Datadog & Splunk)

TrustGate can stream logs to your infrastructure in real-time. Configure these environment variables or set them in Settings → Observability.

Datadog

DD_API_KEYDD_SITE (e.g. datadoghq.com)

Splunk

SPLUNK_HEC_URLSPLUNK_HEC_TOKEN

End-to-End Agentic Tracing

Unlike traditional LLM prompts, autonomous AI Agents often execute multi-step workflows involving tool calls, fallbacks, and internal retries. Standard single-request logging makes debugging these workflows impossible.

TrustGate introduces Agentic Tracing. We automatically group complex, multi-step agent executions into a single unified trace. This provides an end-to-end view of the agent's chain of thought, allowing you to instantly pinpoint where an agent hallucinated or got stuck in an uncontrolled retry loop.

Trace Visualization Capabilities

  • Execution Timelines: View the exact millisecond duration of every tool call and sub-request within the agent's workflow.
  • Retry & Hallucination Flags: TrustGate automatically flags traces where an agent excessively retries a failed tool or deviates from the allowed policy sandbox.
  • Cost per Trace: Aggregate the token cost of the entire multi-step workflow, not just the individual API hits.