Skip to main content
By default, the Agent Server omits HTTP headers from server logs for privacy reasons. However, logging request and correlation IDs can help you debug issues and trace requests across distributed systems. You can opt-in to logging headers for all API calls by modifying the logging_headers section in your langgraph.json file.
{
  "$schema": "https://langgra.ph/schema.json",
  "http": {
    "logging_headers": {
      "includes": ["request-id", "x-purchase-id", "*-trace-*"],
      "excludes": ["authorization", "x-api-key", "x-organization-id", "x-user-id"]
    }
  }
}
The includes and excludes lists accept exact header names or glob patterns using * as a wildcard to match any number of characters (case-insensitive). For your security, no other pattern types are supported. Note that exclusions take precedence over inclusions. For example, if you include *-id but exclude x-user-id, the x-user-id header will not be logged.
Connect these docs programmatically to Claude, VSCode, and more via MCP for real-time answers.