Skip to main content
Quick setup? Instead of following these steps manually, copy a prompt into your coding agent and it will set this up for you automatically.
LangWatch integrates with LangGraph to provide detailed observability into your graph-based agents, LLM calls, and tool usage.

Installation

Usage

The LangWatch API key is configured by default via the LANGWATCH_API_KEY environment variable.
Use LangWatch’s callback handler to instrument your LangGraph agents. Pass the callback to model invocations within your graph nodes to capture LLM calls and tool usage as spans.
The @langwatch.trace() decorator creates a parent trace for your graph execution. Within each node that makes LLM calls, use get_langchain_callback() and pass it to the model’s RunnableConfig to capture those calls as spans within the trace.