# Integrations | Sentry for Cloud Functions for Firebase

The Sentry SDK uses integrations to hook into the functionality of popular libraries to automatically instrument your application and give you the best data out of the box.

Integrations automatically add error instrumentation, performance instrumentation, and/or extra context information to your application. Some are enabled by default, but you can disable them or modify their settings.

### [Integrations](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations.md#integrations)

|                                                                                                                                                   | **Auto Enabled** | **Errors** | **Tracing** | **Additional Context** |
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------- | ---------- | ----------- | ---------------------- |
| [`amqplibIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/amqplib.md)                         | ✓                |            | ✓           |                        |
| [`anrIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/anr.md)                                 |                  | ✓          |             |                        |
| [`captureConsoleIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/captureconsole.md)           |                  |            |             | ✓                      |
| [`eventLoopBlockIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/event-loop-block.md)         |                  | ✓          |             |                        |
| [`childProcessIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/childProcess.md)               | ✓                |            |             | ✓                      |
| [`consoleIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/console.md)                         | ✓                |            |             | ✓                      |
| [`contextLinesIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/contextlines.md)               | ✓                | ✓          |             |                        |
| [`dataloaderIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/dataloader.md)                   |                  |            | ✓           |                        |
| [`dedupeIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/dedupe.md)                           | ✓                | ✓          |             |                        |
| [`extraErrorDataIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/extraerrordata.md)           |                  |            |             | ✓                      |
| [`fsIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/fs.md)                                   |                  |            | ✓           |                        |
| [`functionToStringIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/functiontostring.md)       | ✓                |            |             |                        |
| [`genericPoolIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/genericpool.md)                 | ✓                |            | ✓           |                        |
| [`graphqlIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/graphql.md)                         | ✓                |            | ✓           |                        |
| [`httpIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/http.md)                               | ✓                | ✓          | ✓           | ✓                      |
| [`inboundFiltersIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/inboundfilters.md)           | ✓                | ✓          |             |                        |
| [`kafkaIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/kafka.md)                             | ✓                |            | ✓           |                        |
| [`knexIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/knex.md)                               |                  |            | ✓           |                        |
| [`linkedErrorsIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/linkederrors.md)               | ✓                | ✓          |             |                        |
| [`localVariablesIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/localvariables.md)           |                  | ✓          |             |                        |
| [`lruMemoizerIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/lrumemoizer.md)                 | ✓                |            | ✓           |                        |
| [`modulesIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/modules.md)                         | ✓                |            |             | ✓                      |
| [`mongoIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/mongo.md)                             | ✓                |            | ✓           |                        |
| [`mongooseIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/mongoose.md)                       | ✓                |            | ✓           |                        |
| [`mysqlIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/mysql.md)                             | ✓                |            | ✓           |                        |
| [`mysql2Integration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/mysql2.md)                           | ✓                |            | ✓           |                        |
| [`nativeNodeFetchIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/nodefetch.md)               | ✓                |            | ✓           | ✓                      |
| [`nodeContextIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/nodecontext.md)                 | ✓                |            |             | ✓                      |
| [`nodeProfilingIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/nodeprofiling.md)             |                  |            | ✓           |                        |
| [`onUncaughtExceptionIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/onuncaughtexception.md) | ✓                | ✓          |             |                        |
| [`onUnhandledRejectionIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/unhandledrejection.md) | ✓                | ✓          |             |                        |
| [`postgresIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/postgres.md)                       | ✓                |            | ✓           |                        |
| [`prismaIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/prisma.md)                           | ✓                |            | ✓           |                        |
| [`redisIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/redis.md)                             | ✓                |            | ✓           |                        |
| [`requestDataIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/requestdata.md)                 | ✓                |            | ✓           |                        |
| [`vercelAiIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/vercelai.md)                       | ✓                |            | ✓           |                        |
| [`rewriteFramesIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/rewriteframes.md)             |                  | ✓          |             |                        |
| [`supabaseIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/supabase.md)                       |                  | ✓          | ✓           |                        |
| [`tediousIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/tedious.md)                         | ✓                |            | ✓           |                        |
| [`trpcMiddleware`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/trpc.md)                                |                  | ✓          | ✓           | ✓                      |
| [`openAIIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/openai.md)                           | ✓                |            | ✓           |                        |
| [`anthropicAIIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/anthropic.md)                   | ✓                | ✓          | ✓           |                        |
| [`googleGenAIIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/google-genai.md)                | ✓                | ✓          | ✓           |                        |
| [`langChainIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/langchain.md)                     | ✓                | ✓          | ✓           |                        |
| [`firebaseIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/firebase.md)                       | ✓                |            | ✓           |                        |
| [`zodErrorsIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/zodErrors.md)                     |                  |            |             | ✓                      |
| [`pinoIntegration`](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/pino.md)                               |                  | ✓          |             |                        |

## [Modifying Default Integrations](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations.md#modifying-default-integrations)

To disable system integrations, set `defaultIntegrations: false` when calling `init()`.

To override their settings, provide a new instance with your config to the `integrations` option. For example, to turn off browser capturing console calls:

```javascript
Sentry.init({
  dsn: "___PUBLIC_DSN___",

  integrations: [
    Sentry.breadcrumbsIntegration({
      console: false,
    }),
  ],

});
```

## [Adding an Integration](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations.md#adding-an-integration)

You can add additional integrations in your `init` call:

```javascript
import * as Sentry from "@sentry/node";

Sentry.init({
  dsn: "https://examplePublicKey@o0.ingest.sentry.io/0",
  integrations: [],
});

Sentry.addIntegration(Sentry.captureConsoleIntegration());
```

Alternatively, you can add integrations via `Sentry.addIntegration()`. This is useful if you only want to enable an integration in a specific environment or if you want to load an integration later. For all other cases, we recommend you use the `integrations` option.

```javascript
import * as Sentry from "@sentry/node";

Sentry.init({
  dsn: "https://examplePublicKey@o0.ingest.sentry.io/0",
  integrations: [Sentry.captureConsoleIntegration()],
});
```

## [Removing a Default Integration](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations.md#removing-a-default-integration)

If you only want to remove a single or some of the default integrations, instead of disabling all of them with `defaultIntegrations: false`, you can use the following syntax to filter out the ones you don't want.

This example removes the integration for adding breadcrumbs to the event, which is enabled by default:

```javascript
Sentry.init({
  // ...
  integrations: function (integrations) {
    // integrations will be all default integrations
    return integrations.filter(function (integration) {
      return integration.name !== "Breadcrumbs";
    });
  },
});
```

## [Custom Integrations](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations.md#custom-integrations)

You can also create [custom integrations](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/custom.md).

## [Available Integrations](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations.md#available-integrations)

* #### [Anthropic](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/anthropic.md)

  Adds instrumentation for the Anthropic SDK.

* #### [Breadcrumbs](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/breadcrumbs.md)

  Wraps native browser APIs to capture breadcrumbs. (default)

* #### [BrowserApiErrors](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/browserapierrors.md)

  Wraps native time and events APIs (\`setTimeout\`, \`setInterval\`, \`requestAnimationFrame\`, \`addEventListener/removeEventListener\`) in \`try/catch\` blocks to handle async exceptions. (default)

* #### [BrowserProfiling](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/browserprofiling.md)

  Capture profiling data for the Browser.

* #### [BrowserSession](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/browsersession.md)

  Track healthy Sessions in the Browser.

* #### [BrowserTracing](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/browsertracing.md)

  Capture performance data for the Browser.

* #### [CaptureConsole](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/captureconsole.md)

  Captures all Console API calls via \`captureException\` or \`captureMessage\`.

* #### [ContextLines](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/contextlines.md)

  Adds source code from inline JavaScript of the current page's HTML.

* #### [Dedupe](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/dedupe.md)

  Deduplicate certain events to avoid receiving duplicate errors. (default)

* #### [ExtraErrorData](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/extraerrordata.md)

  Extracts all non-native attributes from the error object and attaches them to the event as extra data.

* #### [Firebase](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/firebase.md)

  Adds instrumentation for Firebase. (default)

* #### [FunctionToString](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/functiontostring.md)

  Allows the SDK to provide original functions and method names, even when those functions or methods are wrapped by our error or breadcrumb handlers. (default)

* #### [Generic Feature Flags Integration](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/featureflags.md)

  Learn how to attach custom feature flag data to Sentry error events.

* #### [GlobalHandlers](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/globalhandlers.md)

  Attaches global handlers to capture uncaught exceptions and unhandled rejections. (default)

* #### [Google Gen AI](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/google-genai.md)

  Adds instrumentation for Google Gen AI SDK.

* #### [GraphQLClient](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/graphqlclient.md)

  Enhance spans and breadcrumbs with data from GraphQL requests.

* #### [HttpClient](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/httpclient.md)

  Captures errors on failed requests from Fetch and XHR and attaches request and response information.

* #### [HttpContext](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/httpcontext.md)

  Attaches HTTP request information, such as URL, user-agent, referrer, and other headers to the event. (default)

* #### [InboundFilters](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/inboundfilters.md)

  Allows you to ignore specific errors based on the type, message, or URLs in a given exception. (default)

* #### [LangChain](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/langchain.md)

  Adds instrumentation for LangChain.

* #### [LangGraph](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/langgraph.md)

  Adds instrumentation for the LangGraph SDK.

* #### [LaunchDarkly](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/launchdarkly.md)

  Learn how to use Sentry with LaunchDarkly.

* #### [LinkedErrors](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/linkederrors.md)

  Allows you to configure linked errors. (default)

* #### [ModuleMetadata](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/modulemetadata.md)

  Adds module metadata to stack frames.

* #### [OpenAI](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/openai.md)

  Adds instrumentation for the OpenAI SDK.

* #### [OpenFeature](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/openfeature.md)

  Learn how to use Sentry with OpenFeature.

* #### [Replay](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/replay.md)

  Capture a video-like reproduction of what was happening in the user's browser.

* #### [ReplayCanvas](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/replaycanvas.md)

  Capture session replays from HTML canvas elements.

* #### [ReportingObserver](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/reportingobserver.md)

  Captures the reports collected via the \`ReportingObserver\` interface and sends them to Sentry.

* #### [RewriteFrames](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/rewriteframes.md)

  Allows you to apply a transformation to each frame of the stack trace.

* #### [Statsig](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/statsig.md)

  Learn how to use Sentry with Statsig.

* #### [Unleash](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/unleash.md)

  Learn how to use Sentry with Unleash.

* #### [WebWorker](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/webworker.md)

  Connect Web Workers with the SDK running on the main thread

* #### [ZodErrors](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/zodErrors.md)

  Adds additional data to Zod validation errors.

## Pages in this section

- [Anthropic](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/anthropic.md)
- [Breadcrumbs](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/breadcrumbs.md)
- [BrowserApiErrors](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/browserapierrors.md)
- [BrowserProfiling](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/browserprofiling.md)
- [BrowserSession](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/browsersession.md)
- [BrowserTracing](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/browsertracing.md)
- [CaptureConsole](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/captureconsole.md)
- [ContextLines](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/contextlines.md)
- [Dedupe](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/dedupe.md)
- [ExtraErrorData](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/extraerrordata.md)
- [Firebase](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/firebase.md)
- [FunctionToString](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/functiontostring.md)
- [Generic Feature Flags Integration](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/featureflags.md)
- [GlobalHandlers](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/globalhandlers.md)
- [Google Gen AI](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/google-genai.md)
- [GraphQLClient](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/graphqlclient.md)
- [HttpClient](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/httpclient.md)
- [HttpContext](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/httpcontext.md)
- [InboundFilters](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/inboundfilters.md)
- [LangChain](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/langchain.md)
- [LangGraph](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/langgraph.md)
- [LaunchDarkly](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/launchdarkly.md)
- [LinkedErrors](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/linkederrors.md)
- [ModuleMetadata](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/modulemetadata.md)
- [OpenAI](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/openai.md)
- [OpenFeature](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/openfeature.md)
- [Replay](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/replay.md)
- [ReplayCanvas](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/replaycanvas.md)
- [ReportingObserver](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/reportingobserver.md)
- [RewriteFrames](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/rewriteframes.md)
- [Statsig](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/statsig.md)
- [Unleash](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/unleash.md)
- [WebWorker](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/webworker.md)
- [ZodErrors](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/zodErrors.md)
- [Custom Integrations](https://docs.sentry.io/platforms/javascript/guides/firebase/configuration/integrations/custom.md)
