---
title: "Sentry"
description: "Forward Blyp logs and structured events into Sentry from server, browser, and Expo runtimes."
canonical_url: "https://www.blyp.dev/docs/connectors/sentry"
markdown_url: "https://www.blyp.dev/docs/connectors/sentry.md"
last_updated: "2018-10-20"
x_farming_labs_generated_preamble: true
agent:
  task: "Forward Blyp logs and structured events to Sentry across supported runtimes."
  outcome: "A uniquely named record appears in the intended Sentry project with normalized Blyp context."
  appliesTo:
    package:
      - "@blyp/core"
      - "@sentry/node"
  prerequisites:
    - "A Sentry DSN and project are available."
  files:
    - "blyp.config.ts"
    - ".env"
  commands:
    - "pnpm add @blyp/core @sentry/node"
  sideEffects:
    - "Logs and configured error context leave the application for Sentry."
  verification:
    - "Emit a unique record"
    - "flush Blyp"
    - "and locate it in Sentry Logs."
  rollback:
    - "Set connectors.sentry to false and remove the optional peer if unused."
  failureModes:
    - symptom: "Server records arrive but browser or Expo records do not."
      resolution: "Route client records through the Blyp ingestion handler configured with the Sentry connector."
---

# Sentry
URL: /docs/connectors/sentry
LLM index: /llms.txt
Description: Forward Blyp logs and structured events into Sentry from server, browser, and Expo runtimes.
Related: /docs/connectors, /docs/configuration, /docs/integrations/client

<!-- farming-labs:agent-contract:start -->
## Agent Contract

Task: Forward Blyp logs and structured events to Sentry across supported runtimes.
Outcome: A uniquely named record appears in the intended Sentry project with normalized Blyp context.

### Applies To

- Package: `@blyp/core`, `@sentry/node`

### Prerequisites

- A Sentry DSN and project are available.

### Files

- `blyp.config.ts`
- `.env`

### Commands

- `pnpm add @blyp/core @sentry/node`

### Side Effects

- Logs and configured error context leave the application for Sentry.

### Verification

- Emit a unique record
- flush Blyp
- and locate it in Sentry Logs.

### Rollback

- Set connectors.sentry to false and remove the optional peer if unused.

### Failure Modes

- Server records arrive but browser or Expo records do not. — Recovery: Route client records through the Blyp ingestion handler configured with the Sentry connector.
<!-- farming-labs:agent-contract:end -->

# Sentry

Install the Sentry peer, configure the DSN, and verify a unique server record after awaiting flush.
Client and Expo records are forwarded by the server ingestion path, not directly by `@sentry/node`.
If only server logs arrive, repair ingestion before changing Sentry configuration.

Use `connectors.sentry` when you want Blyp logs forwarded into Sentry Logs.

## Install required peer packages

Install the optional peer dependency when this connector is enabled:

```bash
bun add @sentry/node
```

## Config

```ts
export default {
  connectors: {
    sentry: {
      enabled: true,
      mode: "auto",
      dsn: process.env.SENTRY_DSN,
      environment: process.env.NODE_ENV,
      release: "2026.03.11",
    },
  },
};
```

## Config fields

- `enabled`: enables Sentry delivery
- `mode`: `auto` or `manual`
- `dsn`: Sentry DSN
- `environment`: optional Sentry environment
- `release`: optional Sentry release string

## Automatic server forwarding

When `mode: "auto"` is enabled, Blyp server logs and structured logs are forwarded into Sentry automatically.

If Sentry was already initialized by the app, Blyp reuses the existing client instead of replacing it.

> In `auto` mode, Blyp log lines appear in Sentry Logs. `error` and `critical` logs carry the same structured context, which makes the linked exception or log entry easier to inspect.

## Manual APIs

```ts
import {
  createSentryLogger,
  createStructuredSentryLogger,
} from "@blyp/core/sentry";

createSentryLogger().info("manual sentry log");

const structured = createStructuredSentryLogger("checkout", {
  orderId: "ord_123",
});

structured.info("cart loaded");
structured.emit({ status: 200 });
```

## Browser and Expo forwarding

```ts
const browserLogger = createClientLogger({
  endpoint: "/inngest",
  connector: "sentry",
});
```

```ts
const expoLogger = createExpoLogger({
  endpoint: "https://api.example.com/inngest",
  connector: "sentry",
});
```

Browser and Expo still send logs to Blyp first. Blyp forwards to Sentry only when the server connector is configured.

## Notes

- `connectors.delivery` can make retryable Sentry forwarding failures durable without Redis or another external queue
- if Sentry was already initialized by the app, Blyp reuses the existing client instead of replacing it
- Convex maps `connectors.sentry` to Sentry OTLP logs from the DSN. The `@sentry/node` SDK is not loaded. See [Convex](/docs/integrations/convex).

## Sitemap

See the full [sitemap](/sitemap.md) for all pages.
Docs-scoped sitemap: [/docs/sitemap.md](/docs/sitemap.md).
Well-known sitemap: [/.well-known/sitemap.md](/.well-known/sitemap.md).
