diff --git a/types/raven/index.d.ts b/types/raven/index.d.ts index 23cd3b05e2..09ba6f6b4c 100644 --- a/types/raven/index.d.ts +++ b/types/raven/index.d.ts @@ -45,6 +45,7 @@ export class Client extends EventEmitter { captureBreadcrumb(breadcrumb: any): void; setUserContext(data: UserData): void; setDataCallback(fn: DataCallback): void; + setShouldSendCallback(fn: ShouldSendCallback): this; context(ctx: any, func: () => void, onErr?: () => void): Client; context(func: () => void, onErr?: () => void): Client; process(kwargs: any, cb?: () => void): void; @@ -59,6 +60,7 @@ export interface ConstructorOptions { tags?: { [key: string]: string }; extra?: { [key: string]: any }; dataCallback?: DataCallback; + shouldSendCallback?: ShouldSendCallback; transport?(): void; captureUnhandledRejections?: boolean; autoBreadcrumbs?: boolean | any; @@ -86,6 +88,8 @@ export type CaptureCallback = (err: { [key: string]: any }, eventId: any) => voi export type DataCallback = (data: { [key: string]: any }) => void; +export type ShouldSendCallback = (data: { [key: string]: any }) => boolean; + export type TransportCallback = (options: { [key: string]: any }) => void; export interface CaptureOptions {