---
title: Braintrust
description: Export AI SDK spans to Braintrust for tracing, evals, and monitoring.
url: "https://eve.dev/integrations/braintrust"
docs_index: /llms.txt
type: instrumentation
keywords:
  - otel
  - opentelemetry
  - tracing
  - observability
  - evals
  - monitoring
---

> For an index of all documentation, see [/llms.txt](/llms.txt).

Instrumentation integration for eve. Export AI SDK spans to Braintrust for tracing, evals, and monitoring.

## Install

Add the Braintrust integration from eve's registry:

```bash
eve add instrumentation/braintrust
```

## Quick start

eve installs Braintrust instrumentation:

```ts
// agent/instrumentation/braintrust.ts
import { braintrustEveInstrumentation, initLogger } from "braintrust";

export default braintrustEveInstrumentation({
  metadata: {
    app: "my-eve-agent", // Replace with your app name
  },
  setup: ({ agentName }) => {
    initLogger({
      projectName: agentName,
      apiKey: process.env.BRAINTRUST_API_KEY,
    });
  },
});
```

## Configure

Create an API key in the Braintrust dashboard and expose it as `BRAINTRUST_API_KEY`. Replace the `app` metadata with your app name. Do not wrap the result in `defineInstrumentation`, pass `defineState`, or add `braintrustEveHook`; the instrumentation handles eve lifecycle events directly. See [Instrumentation](/docs/observability/instrumentation) for content policy and event handling.

[Read the full instrumentation documentation](/docs/observability/instrumentation)

---

For a semantic overview of all documentation, see [/sitemap.md](/sitemap.md)

For an index of all available documentation, see [/llms.txt](/llms.txt)

For agent-facing discovery, including API and MCP surfaces, see [/agents.md](/agents.md)