Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions apps/website/content/docs/telemetry/guides/browser.mdx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Browser Telemetry

Browser telemetry is opt-in. If your Angular app never calls `provideThreadplaneTelemetry()`, the service has no enabled config and `capture()` returns without sending.
Browser telemetry is opt-in. If your Angular app never calls `provideThreadplaneTelemetry()`, the service has no enabled config and `capture()` returns without sending anything.

## Configure

Expand Down Expand Up @@ -32,7 +32,7 @@ The endpoint receives:
}
```

The browser distinct ID is generated per service instance. The source does not write it to storage.
The browser distinct ID is generated per service instance. The source never writes it to storage.

## Prefer a sink for app-owned analytics

Expand All @@ -47,7 +47,7 @@ provideThreadplaneTelemetry({
});
```

When `sink` is present, the service does not use `endpoint` or PostHog.
When `sink` is present, the service skips `endpoint` and PostHog entirely.

## Sampling

Expand Down Expand Up @@ -89,4 +89,4 @@ telemetry.captureStreamErrored({ transport: 'langgraph', provider: 'openai', mod

Browser capture is wrapped in a `try/catch`. A sink error, fetch failure, or dynamic import failure is swallowed.

That keeps telemetry from becoming part of your application control flow.
That keeps telemetry out of your application's control flow.
8 changes: 4 additions & 4 deletions apps/website/content/docs/telemetry/guides/node.mdx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Node Telemetry

Node telemetry lives under `@threadplane/telemetry/node`. It is intended for package lifecycle hooks and server-side adapters.
Node telemetry lives under `@threadplane/telemetry/node`. It's built for package lifecycle hooks and server-side adapters.

```ts
import {
Expand All @@ -23,7 +23,7 @@ import { disableTelemetry } from '@threadplane/telemetry/node';
disableTelemetry();
```

This sets an in-process flag. It does not mutate environment variables.
This sets an in-process flag. It doesn't mutate environment variables.

## Capture runtime lifecycle

Expand Down Expand Up @@ -70,7 +70,7 @@ await captureStreamErrored({
});
```

`captureStreamErrored()` records an error class. It does not send the full error object.
`captureStreamErrored()` records an error class. It doesn't send the full error object.

## Ingest and sampling

Expand Down Expand Up @@ -104,4 +104,4 @@ type CaptureResult =
| { sent: false; reason: 'disabled' | 'sampled' | 'failed' };
```

Use the result in tests or diagnostics. Do not make application correctness depend on telemetry delivery.
Use the result in tests or diagnostics. Don't make application correctness depend on telemetry delivery.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Privacy and Opt-Out

The telemetry source has two different privacy postures.
The telemetry source has two distinct privacy postures.

Browser telemetry is off unless the app opts in. Node telemetry can send from package lifecycle hooks or server adapters unless the environment or process disables it.

Expand Down Expand Up @@ -46,15 +46,15 @@ provideThreadplaneTelemetry({ enabled: true, sink });

With `enabled: false` or no provider, browser capture no-ops.

The browser service sends only when application code or framework browser code calls its capture methods. It does not install a global listener.
The browser service sends only when application code or framework browser code calls its capture methods. It never installs a global listener.

## Anonymous IDs

Node uses `anon_<uuid>` from `node:crypto` and caches it for the current process.

Browser endpoint delivery uses `browser:<uuid>` when `crypto.randomUUID()` is available, with a `Math.random()` fallback. The value is kept in the service instance.

The source does not persist either ID across process restarts or browser sessions.
The source never persists either ID across process restarts or browser sessions.

## Data minimization from source

Expand All @@ -64,7 +64,7 @@ Runtime lifecycle helpers send transport/provider/model style metadata. Stream e

The source strips `apiKey` in the Node runtime adapter before sending.

There is no source path that sends prompts, completions, message content, tool call arguments, tool call outputs, or environment variable dumps.
No source path sends prompts, completions, message content, tool call arguments, tool call outputs, or environment variable dumps.

## Custom ingest

Expand Down
Loading