UNPKG

1.03 kBTypeScriptView Raw
1export declare const instrumentPrisma: ((options?: unknown) => void) & {
2 id: string;
3};
4/**
5 * Adds Sentry tracing instrumentation for the [prisma](https://www.npmjs.com/package/prisma) library.
6 *
7 * For more information, see the [`prismaIntegration` documentation](https://docs.sentry.io/platforms/javascript/guides/node/configuration/integrations/prisma/).
8 *
9 * @example
10 *
11 * Make sure `previewFeatures = ["tracing"]` is set in the prisma client generator block. See the
12 * [prisma docs](https://www.prisma.io/docs/concepts/components/prisma-client/opentelemetry-tracing) for more details.
13 *
14 * ```prisma
15 * generator client {
16 * provider = "prisma-client-js"
17 * previewFeatures = ["tracing"]
18 * }
19 * ```
20 *
21 * Then you can use the integration like this:
22 *
23 * ```javascript
24 * const Sentry = require('@sentry/node');
25 *
26 * Sentry.init({
27 * integrations: [Sentry.prismaIntegration()],
28 * });
29 * ```
30 */
31export declare const prismaIntegration: () => import("@sentry/core").Integration;
32//# sourceMappingURL=prisma.d.ts.map
\No newline at end of file