@sentry/types 5.22.3 → 5.24.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/hub.d.ts CHANGED
@@ -6,7 +6,7 @@ import { Integration, IntegrationClass } from './integration';
6
6
  import { Scope } from './scope';
7
7
  import { Severity } from './severity';
8
8
  import { Span, SpanContext } from './span';
9
- import { Transaction, TransactionContext } from './transaction';
9
+ import { CustomSamplingContext, Transaction, TransactionContext } from './transaction';
10
10
  import { User } from './user';
11
11
  /**
12
12
  * Internal class used to make sure we always have the latest internal functions
@@ -166,22 +166,22 @@ export interface Hub {
166
166
  */
167
167
  startSpan(context: SpanContext): Span;
168
168
  /**
169
- * Starts a new `Transaction` and returns it. This is the entry point to manual
170
- * tracing instrumentation.
169
+ * Starts a new `Transaction` and returns it. This is the entry point to manual tracing instrumentation.
171
170
  *
172
- * A tree structure can be built by adding child spans to the transaction, and
173
- * child spans to other spans. To start a new child span within the transaction
174
- * or any span, call the respective `.startChild()` method.
171
+ * A tree structure can be built by adding child spans to the transaction, and child spans to other spans. To start a
172
+ * new child span within the transaction or any span, call the respective `.startChild()` method.
175
173
  *
176
- * Every child span must be finished before the transaction is finished,
177
- * otherwise the unfinished spans are discarded.
174
+ * Every child span must be finished before the transaction is finished, otherwise the unfinished spans are discarded.
178
175
  *
179
- * The transaction must be finished with a call to its `.finish()` method, at
180
- * which point the transaction with all its finished child spans will be sent to
181
- * Sentry.
176
+ * The transaction must be finished with a call to its `.finish()` method, at which point the transaction with all its
177
+ * finished child spans will be sent to Sentry.
182
178
  *
183
179
  * @param context Properties of the new `Transaction`.
180
+ * @param customSamplingContext Information given to the transaction sampling function (along with context-dependent
181
+ * default values). See {@link Options.tracesSampler}.
182
+ *
183
+ * @returns The transaction which was just started
184
184
  */
185
- startTransaction(context: TransactionContext): Transaction;
185
+ startTransaction(context: TransactionContext, customSamplingContext?: CustomSamplingContext): Transaction;
186
186
  }
187
187
  //# sourceMappingURL=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IAAI,EAAE,MAAM,EAAE,OAAO,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;KAAE,GAAG,IAAI,GAAG,IAAI,CAAC;IAEvE;;;;OAIG;IACH,cAAc,CAAC,QAAQ,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,IAAI,GAAG,IAAI,CAAC;IAEvD;;;;OAIG;IACH,GAAG,CAAC,QAAQ,EAAE,CAAC,GAAG,EAAE,GAAG,KAAK,IAAI,GAAG,IAAI,CAAC;IAExC,kEAAkE;IAClE,cAAc,CAAC,CAAC,SAAS,WAAW,EAAE,WAAW,EAAE,gBAAgB,CAAC,CAAC,CAAC,GAAG,CAAC,GAAG,IAAI,CAAC;IAElF,qEAAqE;IACrE,YAAY,IAAI;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;IAE1C;;;;;OAKG;IACH,SAAS,CAAC,OAAO,EAAE,WAAW,GAAG,IAAI,CAAC;IAEtC;;;;;;;;;;;;;;;;OAgBG;IACH,gBAAgB,CAAC,OAAO,EAAE,kBAAkB,EAAE,qBAAqB,CAAC,EAAE,qBAAqB,GAAG,WAAW,CAAC;CAC3G"}
package/dist/hub.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"hub.js","sourceRoot":"","sources":["../src/hub.ts"],"names":[],"mappings":"","sourcesContent":["import { Breadcrumb, BreadcrumbHint } from './breadcrumb';\nimport { Client } from './client';\nimport { Event, EventHint } from './event';\nimport { Extra, Extras } from './extra';\nimport { Integration, IntegrationClass } from './integration';\nimport { Scope } from './scope';\nimport { Severity } from './severity';\nimport { Span, SpanContext } from './span';\nimport { Transaction, TransactionContext } from './transaction';\nimport { User } from './user';\n\n/**\n * Internal class used to make sure we always have the latest internal functions\n * working in case we have a version conflict.\n */\nexport interface Hub {\n /**\n * Checks if this hub's version is older than the given version.\n *\n * @param version A version number to compare to.\n * @return True if the given version is newer; otherwise false.\n *\n * @hidden\n */\n isOlderThan(version: number): boolean;\n\n /**\n * This binds the given client to the current scope.\n * @param client An SDK client (client) instance.\n */\n bindClient(client?: Client): void;\n\n /**\n * Create a new scope to store context information.\n *\n * The scope will be layered on top of the current one. It is isolated, i.e. all\n * breadcrumbs and context information added to this scope will be removed once\n * the scope ends. Be sure to always remove this scope with {@link this.popScope}\n * when the operation finishes or throws.\n *\n * @returns Scope, the new cloned scope\n */\n pushScope(): Scope;\n\n /**\n * Removes a previously pushed scope from the stack.\n *\n * This restores the state before the scope was pushed. All breadcrumbs and\n * context information added since the last call to {@link this.pushScope} are\n * discarded.\n */\n popScope(): boolean;\n\n /**\n * Creates a new scope with and executes the given operation within.\n * The scope is automatically removed once the operation\n * finishes or throws.\n *\n * This is essentially a convenience function for:\n *\n * pushScope();\n * callback();\n * popScope();\n *\n * @param callback that will be enclosed into push/popScope.\n */\n withScope(callback: (scope: Scope) => void): void;\n\n /** Returns the client of the top stack. */\n getClient(): Client | undefined;\n\n /**\n * Captures an exception event and sends it to Sentry.\n *\n * @param exception An exception-like object.\n * @param hint May contain additional information about the original exception.\n * @returns The generated eventId.\n */\n captureException(exception: any, hint?: EventHint): string;\n\n /**\n * Captures a message event and sends it to Sentry.\n *\n * @param message The message to send to Sentry.\n * @param level Define the level of the message.\n * @param hint May contain additional information about the original exception.\n * @returns The generated eventId.\n */\n captureMessage(message: string, level?: Severity, hint?: EventHint): string;\n\n /**\n * Captures a manually created event and sends it to Sentry.\n *\n * @param event The event to send to Sentry.\n * @param hint May contain additional information about the original exception.\n */\n captureEvent(event: Event, hint?: EventHint): string;\n\n /**\n * This is the getter for lastEventId.\n *\n * @returns The last event id of a captured event.\n */\n lastEventId(): string | undefined;\n\n /**\n * Records a new breadcrumb which will be attached to future events.\n *\n * Breadcrumbs will be added to subsequent events to provide more context on\n * user's actions prior to an error or crash.\n *\n * @param breadcrumb The breadcrumb to record.\n * @param hint May contain additional information about the original breadcrumb.\n */\n addBreadcrumb(breadcrumb: Breadcrumb, hint?: BreadcrumbHint): void;\n\n /**\n * Updates user context information for future events.\n *\n * @param user User context object to be set in the current context. Pass `null` to unset the user.\n */\n setUser(user: User | null): void;\n\n /**\n * Set an object that will be merged sent as tags data with the event.\n * @param tags Tags context object to merge into current context.\n */\n setTags(tags: { [key: string]: string }): void;\n\n /**\n * Set key:value that will be sent as tags data with the event.\n * @param key String key of tag\n * @param value String value of tag\n */\n setTag(key: string, value: string): void;\n\n /**\n * Set key:value that will be sent as extra data with the event.\n * @param key String of extra\n * @param extra Any kind of data. This data will be normalized.\n */\n setExtra(key: string, extra: Extra): void;\n\n /**\n * Set an object that will be merged sent as extra data with the event.\n * @param extras Extras object to merge into current context.\n */\n setExtras(extras: Extras): void;\n\n /**\n * Sets context data with the given name.\n * @param name of the context\n * @param context Any kind of data. This data will be normalized.\n */\n setContext(name: string, context: { [key: string]: any } | null): void;\n\n /**\n * Callback to set context information onto the scope.\n *\n * @param callback Callback function that receives Scope.\n */\n configureScope(callback: (scope: Scope) => void): void;\n\n /**\n * For the duraction of the callback, this hub will be set as the global current Hub.\n * This function is useful if you want to run your own client and hook into an already initialized one\n * e.g.: Reporting issues to your own sentry when running in your component while still using the users configuration.\n */\n run(callback: (hub: Hub) => void): void;\n\n /** Returns the integration if installed on the current client. */\n getIntegration<T extends Integration>(integration: IntegrationClass<T>): T | null;\n\n /** Returns all trace headers that are currently on the top scope. */\n traceHeaders(): { [key: string]: string };\n\n /**\n * Starts a new `Span` and returns it. If there is a `Span` on the `Scope`,\n * the new `Span` will be a child of the existing `Span`.\n *\n * @param context Properties of the new `Span`.\n */\n startSpan(context: SpanContext): Span;\n\n /**\n * Starts a new `Transaction` and returns it. This is the entry point to manual\n * tracing instrumentation.\n *\n * A tree structure can be built by adding child spans to the transaction, and\n * child spans to other spans. To start a new child span within the transaction\n * or any span, call the respective `.startChild()` method.\n *\n * Every child span must be finished before the transaction is finished,\n * otherwise the unfinished spans are discarded.\n *\n * The transaction must be finished with a call to its `.finish()` method, at\n * which point the transaction with all its finished child spans will be sent to\n * Sentry.\n *\n * @param context Properties of the new `Transaction`.\n */\n startTransaction(context: TransactionContext): Transaction;\n}\n"]}
1
+ {"version":3,"file":"hub.js","sourceRoot":"","sources":["../src/hub.ts"],"names":[],"mappings":"","sourcesContent":["import { Breadcrumb, BreadcrumbHint } from './breadcrumb';\nimport { Client } from './client';\nimport { Event, EventHint } from './event';\nimport { Extra, Extras } from './extra';\nimport { Integration, IntegrationClass } from './integration';\nimport { Scope } from './scope';\nimport { Severity } from './severity';\nimport { Span, SpanContext } from './span';\nimport { CustomSamplingContext, Transaction, TransactionContext } from './transaction';\nimport { User } from './user';\n\n/**\n * Internal class used to make sure we always have the latest internal functions\n * working in case we have a version conflict.\n */\nexport interface Hub {\n /**\n * Checks if this hub's version is older than the given version.\n *\n * @param version A version number to compare to.\n * @return True if the given version is newer; otherwise false.\n *\n * @hidden\n */\n isOlderThan(version: number): boolean;\n\n /**\n * This binds the given client to the current scope.\n * @param client An SDK client (client) instance.\n */\n bindClient(client?: Client): void;\n\n /**\n * Create a new scope to store context information.\n *\n * The scope will be layered on top of the current one. It is isolated, i.e. all\n * breadcrumbs and context information added to this scope will be removed once\n * the scope ends. Be sure to always remove this scope with {@link this.popScope}\n * when the operation finishes or throws.\n *\n * @returns Scope, the new cloned scope\n */\n pushScope(): Scope;\n\n /**\n * Removes a previously pushed scope from the stack.\n *\n * This restores the state before the scope was pushed. All breadcrumbs and\n * context information added since the last call to {@link this.pushScope} are\n * discarded.\n */\n popScope(): boolean;\n\n /**\n * Creates a new scope with and executes the given operation within.\n * The scope is automatically removed once the operation\n * finishes or throws.\n *\n * This is essentially a convenience function for:\n *\n * pushScope();\n * callback();\n * popScope();\n *\n * @param callback that will be enclosed into push/popScope.\n */\n withScope(callback: (scope: Scope) => void): void;\n\n /** Returns the client of the top stack. */\n getClient(): Client | undefined;\n\n /**\n * Captures an exception event and sends it to Sentry.\n *\n * @param exception An exception-like object.\n * @param hint May contain additional information about the original exception.\n * @returns The generated eventId.\n */\n captureException(exception: any, hint?: EventHint): string;\n\n /**\n * Captures a message event and sends it to Sentry.\n *\n * @param message The message to send to Sentry.\n * @param level Define the level of the message.\n * @param hint May contain additional information about the original exception.\n * @returns The generated eventId.\n */\n captureMessage(message: string, level?: Severity, hint?: EventHint): string;\n\n /**\n * Captures a manually created event and sends it to Sentry.\n *\n * @param event The event to send to Sentry.\n * @param hint May contain additional information about the original exception.\n */\n captureEvent(event: Event, hint?: EventHint): string;\n\n /**\n * This is the getter for lastEventId.\n *\n * @returns The last event id of a captured event.\n */\n lastEventId(): string | undefined;\n\n /**\n * Records a new breadcrumb which will be attached to future events.\n *\n * Breadcrumbs will be added to subsequent events to provide more context on\n * user's actions prior to an error or crash.\n *\n * @param breadcrumb The breadcrumb to record.\n * @param hint May contain additional information about the original breadcrumb.\n */\n addBreadcrumb(breadcrumb: Breadcrumb, hint?: BreadcrumbHint): void;\n\n /**\n * Updates user context information for future events.\n *\n * @param user User context object to be set in the current context. Pass `null` to unset the user.\n */\n setUser(user: User | null): void;\n\n /**\n * Set an object that will be merged sent as tags data with the event.\n * @param tags Tags context object to merge into current context.\n */\n setTags(tags: { [key: string]: string }): void;\n\n /**\n * Set key:value that will be sent as tags data with the event.\n * @param key String key of tag\n * @param value String value of tag\n */\n setTag(key: string, value: string): void;\n\n /**\n * Set key:value that will be sent as extra data with the event.\n * @param key String of extra\n * @param extra Any kind of data. This data will be normalized.\n */\n setExtra(key: string, extra: Extra): void;\n\n /**\n * Set an object that will be merged sent as extra data with the event.\n * @param extras Extras object to merge into current context.\n */\n setExtras(extras: Extras): void;\n\n /**\n * Sets context data with the given name.\n * @param name of the context\n * @param context Any kind of data. This data will be normalized.\n */\n setContext(name: string, context: { [key: string]: any } | null): void;\n\n /**\n * Callback to set context information onto the scope.\n *\n * @param callback Callback function that receives Scope.\n */\n configureScope(callback: (scope: Scope) => void): void;\n\n /**\n * For the duraction of the callback, this hub will be set as the global current Hub.\n * This function is useful if you want to run your own client and hook into an already initialized one\n * e.g.: Reporting issues to your own sentry when running in your component while still using the users configuration.\n */\n run(callback: (hub: Hub) => void): void;\n\n /** Returns the integration if installed on the current client. */\n getIntegration<T extends Integration>(integration: IntegrationClass<T>): T | null;\n\n /** Returns all trace headers that are currently on the top scope. */\n traceHeaders(): { [key: string]: string };\n\n /**\n * Starts a new `Span` and returns it. If there is a `Span` on the `Scope`,\n * the new `Span` will be a child of the existing `Span`.\n *\n * @param context Properties of the new `Span`.\n */\n startSpan(context: SpanContext): Span;\n\n /**\n * Starts a new `Transaction` and returns it. This is the entry point to manual tracing instrumentation.\n *\n * A tree structure can be built by adding child spans to the transaction, and child spans to other spans. To start a\n * new child span within the transaction or any span, call the respective `.startChild()` method.\n *\n * Every child span must be finished before the transaction is finished, otherwise the unfinished spans are discarded.\n *\n * The transaction must be finished with a call to its `.finish()` method, at which point the transaction with all its\n * finished child spans will be sent to Sentry.\n *\n * @param context Properties of the new `Transaction`.\n * @param customSamplingContext Information given to the transaction sampling function (along with context-dependent\n * default values). See {@link Options.tracesSampler}.\n *\n * @returns The transaction which was just started\n */\n startTransaction(context: TransactionContext, customSamplingContext?: CustomSamplingContext): Transaction;\n}\n"]}
package/dist/index.d.ts CHANGED
@@ -10,6 +10,7 @@ export { Hub } from './hub';
10
10
  export { Integration, IntegrationClass } from './integration';
11
11
  export { LogLevel } from './loglevel';
12
12
  export { Mechanism } from './mechanism';
13
+ export { ExtractedNodeRequestData, WorkerLocation } from './misc';
13
14
  export { Options } from './options';
14
15
  export { Package } from './package';
15
16
  export { Request } from './request';
@@ -22,7 +23,7 @@ export { Span, SpanContext } from './span';
22
23
  export { StackFrame } from './stackframe';
23
24
  export { Stacktrace } from './stacktrace';
24
25
  export { Status } from './status';
25
- export { Transaction, TransactionContext } from './transaction';
26
+ export { CustomSamplingContext, SamplingContext, TraceparentData, Transaction, TransactionContext, } from './transaction';
26
27
  export { Thread } from './thread';
27
28
  export { Transport, TransportOptions, TransportClass } from './transport';
28
29
  export { User } from './user';
@@ -1 +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AO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,cAAc,EAAE,KAAK,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAC9D,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,IAAI,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAC;AAC3C,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAClC,OAAO,EACL,qBAAqB,EACrB,eAAe,EACf,eAAe,EACf,WAAW,EACX,kBAAkB,GACnB,MAAM,eAAe,CAAC;AACvB,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAClC,OAAO,EAAE,SAAS,EAAE,gBAAgB,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAC1E,OAAO,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AAC9B,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC"}
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAUA,uCAAsC;AAA7B,8BAAA,QAAQ,CAAA;AASjB,uCAAsC;AAA7B,8BAAA,QAAQ,CAAA;AAIjB,mCAAkC;AAAzB,0BAAA,MAAM,CAAA","sourcesContent":["export { Breadcrumb, BreadcrumbHint } from './breadcrumb';\nexport { Client } from './client';\nexport { Dsn, DsnComponents, DsnLike, DsnProtocol } from './dsn';\nexport { ExtendedError } from './error';\nexport { Event, EventHint } from './event';\nexport { EventProcessor } from './eventprocessor';\nexport { Exception } from './exception';\nexport { Extra, Extras } from './extra';\nexport { Hub } from './hub';\nexport { Integration, IntegrationClass } from './integration';\nexport { LogLevel } from './loglevel';\nexport { Mechanism } from './mechanism';\nexport { Options } from './options';\nexport { Package } from './package';\nexport { Request } from './request';\nexport { Response } from './response';\nexport { Runtime } from './runtime';\nexport { CaptureContext, Scope, ScopeContext } from './scope';\nexport { SdkInfo } from './sdkinfo';\nexport { Severity } from './severity';\nexport { Span, SpanContext } from './span';\nexport { StackFrame } from './stackframe';\nexport { Stacktrace } from './stacktrace';\nexport { Status } from './status';\nexport { Transaction, TransactionContext } from './transaction';\nexport { Thread } from './thread';\nexport { Transport, TransportOptions, TransportClass } from './transport';\nexport { User } from './user';\nexport { WrappedFunction } from './wrappedfunction';\n"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAUA,uCAAsC;AAA7B,8BAAA,QAAQ,CAAA;AAUjB,uCAAsC;AAA7B,8BAAA,QAAQ,CAAA;AAIjB,mCAAkC;AAAzB,0BAAA,MAAM,CAAA","sourcesContent":["export { Breadcrumb, BreadcrumbHint } from './breadcrumb';\nexport { Client } from './client';\nexport { Dsn, DsnComponents, DsnLike, DsnProtocol } from './dsn';\nexport { ExtendedError } from './error';\nexport { Event, EventHint } from './event';\nexport { EventProcessor } from './eventprocessor';\nexport { Exception } from './exception';\nexport { Extra, Extras } from './extra';\nexport { Hub } from './hub';\nexport { Integration, IntegrationClass } from './integration';\nexport { LogLevel } from './loglevel';\nexport { Mechanism } from './mechanism';\nexport { ExtractedNodeRequestData, WorkerLocation } from './misc';\nexport { Options } from './options';\nexport { Package } from './package';\nexport { Request } from './request';\nexport { Response } from './response';\nexport { Runtime } from './runtime';\nexport { CaptureContext, Scope, ScopeContext } from './scope';\nexport { SdkInfo } from './sdkinfo';\nexport { Severity } from './severity';\nexport { Span, SpanContext } from './span';\nexport { StackFrame } from './stackframe';\nexport { Stacktrace } from './stacktrace';\nexport { Status } from './status';\nexport {\n CustomSamplingContext,\n SamplingContext,\n TraceparentData,\n Transaction,\n TransactionContext,\n} from './transaction';\nexport { Thread } from './thread';\nexport { Transport, TransportOptions, TransportClass } from './transport';\nexport { User } from './user';\nexport { WrappedFunction } from './wrappedfunction';\n"]}
package/dist/misc.d.ts ADDED
@@ -0,0 +1,50 @@
1
+ /**
2
+ * Data extracted from an incoming request to a node server
3
+ */
4
+ export interface ExtractedNodeRequestData {
5
+ [key: string]: any;
6
+ /** Specific headers from the request */
7
+ headers?: {
8
+ [key: string]: string;
9
+ };
10
+ /** The request's method */
11
+ method?: string;
12
+ /** The request's URL, including query string */
13
+ url?: string;
14
+ /** String representing the cookies sent along with the request */
15
+ cookies?: {
16
+ [key: string]: string;
17
+ };
18
+ /** The request's query string, without the leading '?' */
19
+ query_string?: string;
20
+ /** Any data sent in the request's body, as a JSON string */
21
+ data?: string;
22
+ }
23
+ /**
24
+ * Location object on a service worker's `self` object.
25
+ *
26
+ * See https://developer.mozilla.org/en-US/docs/Web/API/WorkerLocation.
27
+ */
28
+ export interface WorkerLocation {
29
+ /** The protocol scheme of the URL of the script executed in the Worker, including the final ':'. */
30
+ readonly protocol: string;
31
+ /** The host, that is the hostname, a ':', and the port of the URL of the script executed in the Worker. */
32
+ readonly host: string;
33
+ /** The domain of the URL of the script executed in the Worker. */
34
+ readonly hostname: string;
35
+ /** The canonical form of the origin of the specific location. */
36
+ readonly origin: string;
37
+ /** The port number of the URL of the script executed in the Worker. */
38
+ readonly port: string;
39
+ /** The path of the URL of the script executed in the Worker, beginning with a '/'. */
40
+ readonly pathname: string;
41
+ /** The parameters (query string) of the URL of the script executed in the Worker, beginning with a '?'. */
42
+ readonly search: string;
43
+ /** The fragment identifier of the URL of the script executed in the Worker, beginning with a '#'. */
44
+ readonly hash: string;
45
+ /** Stringifier that returns the whole URL of the script executed in the Worker. */
46
+ readonly href: string;
47
+ /** Synonym for `href` attribute */
48
+ toString(): string;
49
+ }
50
+ //# sourceMappingURL=misc.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"misc.d.ts","sourceRoot":"","sources":["../src/misc.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,WAAW,wBAAwB;IACvC,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAC;IAEnB,wCAAwC;IACxC,OAAO,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;IAEpC,4BAA4B;IAC5B,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB,gDAAgD;IAChD,GAAG,CAAC,EAAE,MAAM,CAAC;IAEb,kEAAkE;IAClE,OAAO,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;IAEpC,0DAA0D;IAC1D,YAAY,CAAC,EAAE,MAAM,CAAC;IAEtB,4DAA4D;IAC5D,IAAI,CAAC,EAAE,MAAM,CAAC;CACf;AAED;;;;GAIG;AACH,MAAM,WAAW,cAAc;IAC7B,oGAAoG;IACpG,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAE1B,2GAA2G;IAC3G,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IAEtB,kEAAkE;IAClE,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAE1B,iEAAiE;IACjE,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IAExB,uEAAuE;IACvE,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IAEtB,sFAAsF;IACtF,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAE1B,2GAA2G;IAC3G,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IAExB,qGAAqG;IACrG,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IAEtB,mFAAmF;IACnF,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IAEtB,mCAAmC;IACnC,QAAQ,IAAI,MAAM,CAAC;CACpB"}
package/dist/misc.js ADDED
@@ -0,0 +1,2 @@
1
+ Object.defineProperty(exports, "__esModule", { value: true });
2
+ //# sourceMappingURL=misc.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"misc.js","sourceRoot":"","sources":["../src/misc.ts"],"names":[],"mappings":"","sourcesContent":["/**\n * Data extracted from an incoming request to a node server\n */\nexport interface ExtractedNodeRequestData {\n [key: string]: any;\n\n /** Specific headers from the request */\n headers?: { [key: string]: string };\n\n /** The request's method */\n method?: string;\n\n /** The request's URL, including query string */\n url?: string;\n\n /** String representing the cookies sent along with the request */\n cookies?: { [key: string]: string };\n\n /** The request's query string, without the leading '?' */\n query_string?: string;\n\n /** Any data sent in the request's body, as a JSON string */\n data?: string;\n}\n\n/**\n * Location object on a service worker's `self` object.\n *\n * See https://developer.mozilla.org/en-US/docs/Web/API/WorkerLocation.\n */\nexport interface WorkerLocation {\n /** The protocol scheme of the URL of the script executed in the Worker, including the final ':'. */\n readonly protocol: string;\n\n /** The host, that is the hostname, a ':', and the port of the URL of the script executed in the Worker. */\n readonly host: string;\n\n /** The domain of the URL of the script executed in the Worker. */\n readonly hostname: string;\n\n /** The canonical form of the origin of the specific location. */\n readonly origin: string;\n\n /** The port number of the URL of the script executed in the Worker. */\n readonly port: string;\n\n /** The path of the URL of the script executed in the Worker, beginning with a '/'. */\n readonly pathname: string;\n\n /** The parameters (query string) of the URL of the script executed in the Worker, beginning with a '?'. */\n readonly search: string;\n\n /** The fragment identifier of the URL of the script executed in the Worker, beginning with a '#'. */\n readonly hash: string;\n\n /** Stringifier that returns the whole URL of the script executed in the Worker. */\n readonly href: string;\n\n /** Synonym for `href` attribute */\n toString(): string;\n}\n"]}
package/dist/options.d.ts CHANGED
@@ -2,6 +2,7 @@ import { Breadcrumb, BreadcrumbHint } from './breadcrumb';
2
2
  import { Event, EventHint } from './event';
3
3
  import { Integration } from './integration';
4
4
  import { LogLevel } from './loglevel';
5
+ import { SamplingContext } from './transaction';
5
6
  import { Transport, TransportClass, TransportOptions } from './transport';
6
7
  /** Base configuration options for every SDK. */
7
8
  export interface Options {
@@ -63,15 +64,6 @@ export interface Options {
63
64
  logLevel?: LogLevel;
64
65
  /** A global sample rate to apply to all events (0 - 1). */
65
66
  sampleRate?: number;
66
- /**
67
- * Sample rate to determine trace sampling.
68
- *
69
- * 0.0 = 0% chance of a given trace being sent (send no traces)
70
- * 1.0 = 100% chance of a given trace being sent (send all traces)
71
- *
72
- * Default: 0.0
73
- */
74
- tracesSampleRate?: number;
75
67
  /** Attaches stacktraces to pure capture message / log integrations */
76
68
  attachStacktrace?: boolean;
77
69
  /** Maxium number of chars a single value can have before it will be truncated. */
@@ -94,9 +86,35 @@ export interface Options {
94
86
  * problems.
95
87
  */
96
88
  shutdownTimeout?: number;
89
+ /**
90
+ * Options which are in beta, or otherwise not guaranteed to be stable.
91
+ */
97
92
  _experiments?: {
98
93
  [key: string]: any;
99
94
  };
95
+ /**
96
+ * Sample rate to determine trace sampling.
97
+ *
98
+ * 0.0 = 0% chance of a given trace being sent (send no traces) 1.0 = 100% chance of a given trace being sent (send
99
+ * all traces)
100
+ *
101
+ * Tracing is enabled if either this or `tracesSampler` is defined. If both are defined, `tracesSampleRate` is
102
+ * ignored.
103
+ */
104
+ tracesSampleRate?: number;
105
+ /**
106
+ * Function to compute tracing sample rate dynamically and filter unwanted traces.
107
+ *
108
+ * Tracing is enabled if either this or `tracesSampleRate` is defined. If both are defined, `tracesSampleRate` is
109
+ * ignored.
110
+ *
111
+ * Will automatically be passed a context object of default and optional custom data. See
112
+ * {@link Transaction.samplingContext} and {@link Hub.startTransaction}.
113
+ *
114
+ * @returns A sample rate between 0 and 1 (0 drops the trace, 1 guarantees it will be sent). Returning `true` is
115
+ * equivalent to returning 1 and returning `false` is equivalent to returning 0.
116
+ */
117
+ tracesSampler?(samplingContext: SamplingContext): number | boolean;
100
118
  /**
101
119
  * A callback invoked during event submission, allowing to optionally modify
102
120
  * the event before it is sent to Sentry.
@@ -1 +1 @@
1
- {"version":3,"file":"options.d.ts","sourceRoot":"","sources":["../src/options.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AAC1D,OAAO,EAAE,KAAK,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAC3C,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,SAAS,EAAE,cAAc,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAE1E,gDAAgD;AAChD,MAAM,WAAW,OAAO;IACtB;;OAEG;IACH,KAAK,CAAC,EAAE,OAAO,CAAC;IAEhB;;;;OAIG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAElB;;;OAGG;IACH,GAAG,CAAC,EAAE,MAAM,CAAC;IAEb;;;OAGG;IACH,mBAAmB,CAAC,EAAE,KAAK,GAAG,WAAW,EAAE,CAAC;IAE5C;;;;OAIG;IACH,YAAY,CAAC,EAAE,WAAW,EAAE,GAAG,CAAC,CAAC,YAAY,EAAE,WAAW,EAAE,KAAK,WAAW,EAAE,CAAC,CAAC;IAEhF;;;OAGG;IACH,YAAY,CAAC,EAAE,KAAK,CAAC,MAAM,GAAG,MAAM,CAAC,CAAC;IAEtC;;OAEG;IACH,SAAS,CAAC,EAAE,cAAc,CAAC,SAAS,CAAC,CAAC;IAEtC;;OAEG;IACH,gBAAgB,CAAC,EAAE,gBAAgB,CAAC;IAEpC;;;;OAIG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB,uEAAuE;IACvE,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB,2CAA2C;IAC3C,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd;;;OAGG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC;I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H,aAAa,CAAC,CAAC,eAAe,EAAE,eAAe,GAAG,MAAM,GAAG,OAAO,CAAC;IAEnE;;;;;;;;;;;OAWG;IACH,UAAU,CAAC,CAAC,KAAK,EAAE,KAAK,EAAE,IAAI,CAAC,EAAE,SAAS,GAAG,WAAW,CAAC,KAAK,GAAG,IAAI,CAAC,GAAG,KAAK,GAAG,IAAI,CAAC;IAEtF;;;;;;;;;;OAUG;IACH,gBAAgB,CAAC,CAAC,UAAU,EAAE,UAAU,EAAE,IAAI,CAAC,EAAE,cAAc,GAAG,UAAU,GAAG,IAAI,CAAC;CACrF"}
@@ -1 +1 @@
1
- {"version":3,"file":"options.js","sourceRoot":"","sources":["../src/options.ts"],"names":[],"mappings":"","sourcesContent":["import { Breadcrumb, BreadcrumbHint } from './breadcrumb';\nimport { Event, EventHint } from './event';\nimport { Integration } from './integration';\nimport { LogLevel } from './loglevel';\nimport { Transport, TransportClass, TransportOptions } from './transport';\n\n/** Base configuration options for every SDK. */\nexport interface Options {\n /**\n * Enable debug functionality in the SDK itself\n */\n debug?: boolean;\n\n /**\n * Specifies whether this SDK should activate and send events to Sentry.\n * Disabling the SDK reduces all overhead from instrumentation, collecting\n * breadcrumbs and capturing events. Defaults to true.\n */\n enabled?: boolean;\n\n /**\n * The Dsn used to connect to Sentry and identify the project. If omitted, the\n * SDK will not send any data to Sentry.\n */\n dsn?: string;\n\n /**\n * If this is set to false, default integrations will not be added, otherwise this will internally be set to the\n * recommended default integrations.\n */\n defaultIntegrations?: false | Integration[];\n\n /**\n * List of integrations that should be installed after SDK was initialized.\n * Accepts either a list of integrations or a function that receives\n * default integrations and returns a new, updated list.\n */\n integrations?: Integration[] | ((integrations: Integration[]) => Integration[]);\n\n /**\n * A pattern for error messages which should not be sent to Sentry.\n * By default, all errors will be sent.\n */\n ignoreErrors?: Array<string | RegExp>;\n\n /**\n * Transport object that should be used to send events to Sentry\n */\n transport?: TransportClass<Transport>;\n\n /**\n * Options for the default transport that the SDK uses.\n */\n transportOptions?: TransportOptions;\n\n /**\n * The release identifier used when uploading respective source maps. Specify\n * this value to allow Sentry to resolve the correct source maps when\n * processing events.\n */\n release?: string;\n\n /** The current environment of your application (e.g. \"production\"). */\n environment?: string;\n\n /** Sets the distribution for all events */\n dist?: string;\n\n /**\n * The maximum number of breadcrumbs sent with events. Defaults to 30.\n * Values over 100 will be ignored and 100 used instead.\n */\n maxBreadcrumbs?: number;\n\n /** Console logging verbosity for the SDK Client. */\n logLevel?: LogLevel;\n\n /** A global sample rate to apply to all events (0 - 1). */\n sampleRate?: number;\n\n /**\n * Sample rate to determine trace sampling.\n *\n * 0.0 = 0% chance of a given trace being sent (send no traces)\n * 1.0 = 100% chance of a given trace being sent (send all traces)\n *\n * Default: 0.0\n */\n tracesSampleRate?: number;\n\n /** Attaches stacktraces to pure capture message / log integrations */\n attachStacktrace?: boolean;\n\n /** Maxium number of chars a single value can have before it will be truncated. */\n maxValueLength?: number;\n\n /**\n * Maximum number of levels that normalization algorithm will traverse in objects and arrays.\n * Used when normalizing an event before sending, on all of the listed attributes:\n * - `breadcrumbs.data`\n * - `user`\n * - `contexts`\n * - `extra`\n * Defaults to `3`. Set to `0` to disable.\n */\n normalizeDepth?: number;\n\n /**\n * Controls how many milliseconds to wait before shutting down. The default is\n * SDK-specific but typically around 2 seconds. Setting this too low can cause\n * problems for sending events from command line applications. Setting it too\n * high can cause the application to block for users with network connectivity\n * problems.\n */\n shutdownTimeout?: number;\n\n _experiments?: {\n [key: string]: any;\n };\n\n /**\n * A callback invoked during event submission, allowing to optionally modify\n * the event before it is sent to Sentry.\n *\n * Note that you must return a valid event from this callback. If you do not\n * wish to modify the event, simply return it at the end.\n * Returning null will cause the event to be dropped.\n *\n * @param event The error or message event generated by the SDK.\n * @param hint May contain additional information about the original exception.\n * @returns A new event that will be sent | null.\n */\n beforeSend?(event: Event, hint?: EventHint): PromiseLike<Event | null> | Event | null;\n\n /**\n * A callback invoked when adding a breadcrumb, allowing to optionally modify\n * it before adding it to future events.\n *\n * Note that you must return a valid breadcrumb from this callback. If you do\n * not wish to modify the breadcrumb, simply return it at the end.\n * Returning null will cause the breadcrumb to be dropped.\n *\n * @param breadcrumb The breadcrumb as created by the SDK.\n * @returns The breadcrumb that will be added | null.\n */\n beforeBreadcrumb?(breadcrumb: Breadcrumb, hint?: BreadcrumbHint): Breadcrumb | null;\n}\n"]}
1
+ {"version":3,"file":"options.js","sourceRoot":"","sources":["../src/options.ts"],"names":[],"mappings":"","sourcesContent":["import { Breadcrumb, BreadcrumbHint } from './breadcrumb';\nimport { Event, EventHint } from './event';\nimport { Integration } from './integration';\nimport { LogLevel } from './loglevel';\nimport { SamplingContext } from './transaction';\nimport { Transport, TransportClass, TransportOptions } from './transport';\n\n/** Base configuration options for every SDK. */\nexport interface Options {\n /**\n * Enable debug functionality in the SDK itself\n */\n debug?: boolean;\n\n /**\n * Specifies whether this SDK should activate and send events to Sentry.\n * Disabling the SDK reduces all overhead from instrumentation, collecting\n * breadcrumbs and capturing events. Defaults to true.\n */\n enabled?: boolean;\n\n /**\n * The Dsn used to connect to Sentry and identify the project. If omitted, the\n * SDK will not send any data to Sentry.\n */\n dsn?: string;\n\n /**\n * If this is set to false, default integrations will not be added, otherwise this will internally be set to the\n * recommended default integrations.\n */\n defaultIntegrations?: false | Integration[];\n\n /**\n * List of integrations that should be installed after SDK was initialized.\n * Accepts either a list of integrations or a function that receives\n * default integrations and returns a new, updated list.\n */\n integrations?: Integration[] | ((integrations: Integration[]) => Integration[]);\n\n /**\n * A pattern for error messages which should not be sent to Sentry.\n * By default, all errors will be sent.\n */\n ignoreErrors?: Array<string | RegExp>;\n\n /**\n * Transport object that should be used to send events to Sentry\n */\n transport?: TransportClass<Transport>;\n\n /**\n * Options for the default transport that the SDK uses.\n */\n transportOptions?: TransportOptions;\n\n /**\n * The release identifier used when uploading respective source maps. Specify\n * this value to allow Sentry to resolve the correct source maps when\n * processing events.\n */\n release?: string;\n\n /** The current environment of your application (e.g. \"production\"). */\n environment?: string;\n\n /** Sets the distribution for all events */\n dist?: string;\n\n /**\n * The maximum number of breadcrumbs sent with events. Defaults to 30.\n * Values over 100 will be ignored and 100 used instead.\n */\n maxBreadcrumbs?: number;\n\n /** Console logging verbosity for the SDK Client. */\n logLevel?: LogLevel;\n\n /** A global sample rate to apply to all events (0 - 1). */\n sampleRate?: number;\n\n /** Attaches stacktraces to pure capture message / log integrations */\n attachStacktrace?: boolean;\n\n /** Maxium number of chars a single value can have before it will be truncated. */\n maxValueLength?: number;\n\n /**\n * Maximum number of levels that normalization algorithm will traverse in objects and arrays.\n * Used when normalizing an event before sending, on all of the listed attributes:\n * - `breadcrumbs.data`\n * - `user`\n * - `contexts`\n * - `extra`\n * Defaults to `3`. Set to `0` to disable.\n */\n normalizeDepth?: number;\n\n /**\n * Controls how many milliseconds to wait before shutting down. The default is\n * SDK-specific but typically around 2 seconds. Setting this too low can cause\n * problems for sending events from command line applications. Setting it too\n * high can cause the application to block for users with network connectivity\n * problems.\n */\n shutdownTimeout?: number;\n\n /**\n * Options which are in beta, or otherwise not guaranteed to be stable.\n */\n _experiments?: {\n [key: string]: any;\n };\n\n /**\n * Sample rate to determine trace sampling.\n *\n * 0.0 = 0% chance of a given trace being sent (send no traces) 1.0 = 100% chance of a given trace being sent (send\n * all traces)\n *\n * Tracing is enabled if either this or `tracesSampler` is defined. If both are defined, `tracesSampleRate` is\n * ignored.\n */\n tracesSampleRate?: number;\n\n /**\n * Function to compute tracing sample rate dynamically and filter unwanted traces.\n *\n * Tracing is enabled if either this or `tracesSampleRate` is defined. If both are defined, `tracesSampleRate` is\n * ignored.\n *\n * Will automatically be passed a context object of default and optional custom data. See\n * {@link Transaction.samplingContext} and {@link Hub.startTransaction}.\n *\n * @returns A sample rate between 0 and 1 (0 drops the trace, 1 guarantees it will be sent). Returning `true` is\n * equivalent to returning 1 and returning `false` is equivalent to returning 0.\n */\n tracesSampler?(samplingContext: SamplingContext): number | boolean;\n\n /**\n * A callback invoked during event submission, allowing to optionally modify\n * the event before it is sent to Sentry.\n *\n * Note that you must return a valid event from this callback. If you do not\n * wish to modify the event, simply return it at the end.\n * Returning null will cause the event to be dropped.\n *\n * @param event The error or message event generated by the SDK.\n * @param hint May contain additional information about the original exception.\n * @returns A new event that will be sent | null.\n */\n beforeSend?(event: Event, hint?: EventHint): PromiseLike<Event | null> | Event | null;\n\n /**\n * A callback invoked when adding a breadcrumb, allowing to optionally modify\n * it before adding it to future events.\n *\n * Note that you must return a valid breadcrumb from this callback. If you do\n * not wish to modify the breadcrumb, simply return it at the end.\n * Returning null will cause the breadcrumb to be dropped.\n *\n * @param breadcrumb The breadcrumb as created by the SDK.\n * @returns The breadcrumb that will be added | null.\n */\n beforeBreadcrumb?(breadcrumb: Breadcrumb, hint?: BreadcrumbHint): Breadcrumb | null;\n}\n"]}
package/dist/request.d.ts CHANGED
@@ -1,4 +1,6 @@
1
- /** JSDoc */
1
+ /**
2
+ * Request data included in an event as sent to Sentry
3
+ */
2
4
  export interface Request {
3
5
  url?: string;
4
6
  method?: string;
@@ -1 +1 @@
1
- {"version":3,"file":"request.d.ts","sourceRoot":"","sources":["../src/request.ts"],"names":[],"mappings":"AAAA,YAAY;AACZ,MAAM,WAAW,OAAO;IACtB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,IAAI,CAAC,EAAE,GAAG,CAAC;IACX,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,OAAO,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;IACpC,GAAG,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;IAChC,OAAO,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;CACrC"}
1
+ {"version":3,"file":"request.d.ts","sourceRoot":"","sources":["../src/request.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,WAAW,OAAO;IACtB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,IAAI,CAAC,EAAE,GAAG,CAAC;IACX,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,OAAO,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;IACpC,GAAG,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;IAChC,OAAO,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;CACrC"}
@@ -1 +1 @@
1
- {"version":3,"file":"request.js","sourceRoot":"","sources":["../src/request.ts"],"names":[],"mappings":"","sourcesContent":["/** JSDoc */\nexport interface Request {\n url?: string;\n method?: string;\n data?: any;\n query_string?: string;\n cookies?: { [key: string]: string };\n env?: { [key: string]: string };\n headers?: { [key: string]: string };\n}\n"]}
1
+ {"version":3,"file":"request.js","sourceRoot":"","sources":["../src/request.ts"],"names":[],"mappings":"","sourcesContent":["/**\n * Request data included in an event as sent to Sentry\n */\nexport interface Request {\n url?: string;\n method?: string;\n data?: any;\n query_string?: string;\n cookies?: { [key: string]: string };\n env?: { [key: string]: string };\n headers?: { [key: string]: string };\n}\n"]}
package/dist/scope.d.ts CHANGED
@@ -91,7 +91,7 @@ export interface Scope {
91
91
  */
92
92
  getSpan(): Span | undefined;
93
93
  /**
94
- * Returns the `Transaction` if there is one
94
+ * Returns the `Transaction` attached to the scope (if there is one)
95
95
  */
96
96
  getTransaction(): Transaction | undefined;
97
97
  /**
package/dist/scope.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"scope.js","sourceRoot":"","sources":["../src/scope.ts"],"names":[],"mappings":"","sourcesContent":["import { Breadcrumb } from './breadcrumb';\nimport { EventProcessor } from './eventprocessor';\nimport { Extra, Extras } from './extra';\nimport { Severity } from './severity';\nimport { Span } from './span';\nimport { Transaction } from './transaction';\nimport { User } from './user';\n\n/** JSDocs */\nexport type CaptureContext = Scope | Partial<ScopeContext> | ((scope: Scope) => Scope);\n\n/** JSDocs */\nexport interface ScopeContext {\n user: User;\n level: Severity;\n extra: { [key: string]: any };\n contexts: { [key: string]: any };\n tags: { [key: string]: string };\n fingerprint: string[];\n}\n\n/**\n * Holds additional event information. {@link Scope.applyToEvent} will be\n * called by the client before an event will be sent.\n */\nexport interface Scope {\n /** Add new event processor that will be called after {@link applyToEvent}. */\n addEventProcessor(callback: EventProcessor): this;\n\n /**\n * Updates user context information for future events.\n *\n * @param user User context object to be set in the current context. Pass `null` to unset the user.\n */\n setUser(user: User | null): this;\n\n /**\n * Set an object that will be merged sent as tags data with the event.\n * @param tags Tags context object to merge into current context.\n */\n setTags(tags: { [key: string]: string }): this;\n\n /**\n * Set key:value that will be sent as tags data with the event.\n * @param key String key of tag\n * @param value String value of tag\n */\n setTag(key: string, value: string): this;\n\n /**\n * Set an object that will be merged sent as extra data with the event.\n * @param extras Extras object to merge into current context.\n */\n setExtras(extras: Extras): this;\n\n /**\n * Set key:value that will be sent as extra data with the event.\n * @param key String of extra\n * @param extra Any kind of data. This data will be normailzed.\n */\n setExtra(key: string, extra: Extra): this;\n\n /**\n * Sets the fingerprint on the scope to send with the events.\n * @param fingerprint string[] to group events in Sentry.\n */\n setFingerprint(fingerprint: string[]): this;\n\n /**\n * Sets the level on the scope for future events.\n * @param level string {@link Severity}\n */\n setLevel(level: Severity): this;\n\n /**\n * Sets the transaction name on the scope for future events.\n */\n setTransactionName(name?: string): this;\n\n /**\n * Sets context data with the given name.\n * @param name of the context\n * @param context Any kind of data. This data will be normailzed.\n */\n setContext(name: string, context: { [key: string]: any } | null): this;\n\n /**\n * Sets the Span on the scope.\n * @param span Span\n */\n setSpan(span?: Span): this;\n\n /**\n * Returns the `Span` if there is one\n */\n getSpan(): Span | undefined;\n\n /**\n * Returns the `Transaction` if there is one\n */\n getTransaction(): Transaction | undefined;\n\n /**\n * Updates the scope with provided data. Can work in three variations:\n * - plain object containing updatable attributes\n * - Scope instance that'll extract the attributes from\n * - callback function that'll receive the current scope as an argument and allow for modifications\n * @param captureContext scope modifier to be used\n */\n update(captureContext?: CaptureContext): this;\n\n /** Clears the current scope and resets its properties. */\n clear(): this;\n\n /**\n * Sets the breadcrumbs in the scope\n * @param breadcrumbs Breadcrumb\n * @param maxBreadcrumbs number of max breadcrumbs to merged into event.\n */\n addBreadcrumb(breadcrumb: Breadcrumb, maxBreadcrumbs?: number): this;\n\n /**\n * Clears all currently set Breadcrumbs.\n */\n clearBreadcrumbs(): this;\n}\n"]}
1
+ {"version":3,"file":"scope.js","sourceRoot":"","sources":["../src/scope.ts"],"names":[],"mappings":"","sourcesContent":["import { Breadcrumb } from './breadcrumb';\nimport { EventProcessor } from './eventprocessor';\nimport { Extra, Extras } from './extra';\nimport { Severity } from './severity';\nimport { Span } from './span';\nimport { Transaction } from './transaction';\nimport { User } from './user';\n\n/** JSDocs */\nexport type CaptureContext = Scope | Partial<ScopeContext> | ((scope: Scope) => Scope);\n\n/** JSDocs */\nexport interface ScopeContext {\n user: User;\n level: Severity;\n extra: { [key: string]: any };\n contexts: { [key: string]: any };\n tags: { [key: string]: string };\n fingerprint: string[];\n}\n\n/**\n * Holds additional event information. {@link Scope.applyToEvent} will be\n * called by the client before an event will be sent.\n */\nexport interface Scope {\n /** Add new event processor that will be called after {@link applyToEvent}. */\n addEventProcessor(callback: EventProcessor): this;\n\n /**\n * Updates user context information for future events.\n *\n * @param user User context object to be set in the current context. Pass `null` to unset the user.\n */\n setUser(user: User | null): this;\n\n /**\n * Set an object that will be merged sent as tags data with the event.\n * @param tags Tags context object to merge into current context.\n */\n setTags(tags: { [key: string]: string }): this;\n\n /**\n * Set key:value that will be sent as tags data with the event.\n * @param key String key of tag\n * @param value String value of tag\n */\n setTag(key: string, value: string): this;\n\n /**\n * Set an object that will be merged sent as extra data with the event.\n * @param extras Extras object to merge into current context.\n */\n setExtras(extras: Extras): this;\n\n /**\n * Set key:value that will be sent as extra data with the event.\n * @param key String of extra\n * @param extra Any kind of data. This data will be normailzed.\n */\n setExtra(key: string, extra: Extra): this;\n\n /**\n * Sets the fingerprint on the scope to send with the events.\n * @param fingerprint string[] to group events in Sentry.\n */\n setFingerprint(fingerprint: string[]): this;\n\n /**\n * Sets the level on the scope for future events.\n * @param level string {@link Severity}\n */\n setLevel(level: Severity): this;\n\n /**\n * Sets the transaction name on the scope for future events.\n */\n setTransactionName(name?: string): this;\n\n /**\n * Sets context data with the given name.\n * @param name of the context\n * @param context Any kind of data. This data will be normailzed.\n */\n setContext(name: string, context: { [key: string]: any } | null): this;\n\n /**\n * Sets the Span on the scope.\n * @param span Span\n */\n setSpan(span?: Span): this;\n\n /**\n * Returns the `Span` if there is one\n */\n getSpan(): Span | undefined;\n\n /**\n * Returns the `Transaction` attached to the scope (if there is one)\n */\n getTransaction(): Transaction | undefined;\n\n /**\n * Updates the scope with provided data. Can work in three variations:\n * - plain object containing updatable attributes\n * - Scope instance that'll extract the attributes from\n * - callback function that'll receive the current scope as an argument and allow for modifications\n * @param captureContext scope modifier to be used\n */\n update(captureContext?: CaptureContext): this;\n\n /** Clears the current scope and resets its properties. */\n clear(): this;\n\n /**\n * Sets the breadcrumbs in the scope\n * @param breadcrumbs Breadcrumb\n * @param maxBreadcrumbs number of max breadcrumbs to merged into event.\n */\n addBreadcrumb(breadcrumb: Breadcrumb, maxBreadcrumbs?: number): this;\n\n /**\n * Clears all currently set Breadcrumbs.\n */\n clearBreadcrumbs(): this;\n}\n"]}
@@ -1,8 +1,12 @@
1
+ import { ExtractedNodeRequestData, WorkerLocation } from './misc';
1
2
  import { Span, SpanContext } from './span';
2
3
  /**
3
4
  * Interface holding Transaction-specific properties
4
5
  */
5
6
  export interface TransactionContext extends SpanContext {
7
+ /**
8
+ * Human-readable identifier for the transaction
9
+ */
6
10
  name: string;
7
11
  /**
8
12
  * If true, sets the end timestamp of the transaction to the highest timestamp of child spans, trimming
@@ -11,7 +15,15 @@ export interface TransactionContext extends SpanContext {
11
15
  * transaction after a given "idle time" and we don't want this "idle time" to be part of the transaction.
12
16
  */
13
17
  trimEnd?: boolean;
18
+ /**
19
+ * If this transaction has a parent, the parent's sampling decision
20
+ */
21
+ parentSampled?: boolean;
14
22
  }
23
+ /**
24
+ * Data pulled from a `sentry-trace` header
25
+ */
26
+ export declare type TraceparentData = Pick<TransactionContext, 'traceId' | 'parentSpanId' | 'parentSampled'>;
15
27
  /**
16
28
  * Transaction "Class", inherits Span only has `setName`
17
29
  */
@@ -45,4 +57,34 @@ export interface Transaction extends TransactionContext, Span {
45
57
  */
46
58
  setName(name: string): void;
47
59
  }
60
+ /**
61
+ * Context data passed by the user when starting a transaction, to be used by the tracesSampler method.
62
+ */
63
+ export interface CustomSamplingContext {
64
+ [key: string]: any;
65
+ }
66
+ /**
67
+ * Data passed to the `tracesSampler` function, which forms the basis for whatever decisions it might make.
68
+ *
69
+ * Adds default data to data provided by the user. See {@link Hub.startTransaction}
70
+ */
71
+ export interface SamplingContext extends CustomSamplingContext {
72
+ /**
73
+ * Context data with which transaction being sampled was created
74
+ */
75
+ transactionContext: TransactionContext;
76
+ /**
77
+ * Sampling decision from the parent transaction, if any.
78
+ */
79
+ parentSampled?: boolean;
80
+ /**
81
+ * Object representing the URL of the current page or worker script. Passed by default in a browser or service worker
82
+ * context.
83
+ */
84
+ location?: WorkerLocation;
85
+ /**
86
+ * Object representing the incoming request to a node server. Passed by default when using the TracingHandler.
87
+ */
88
+ request?: ExtractedNodeRequestData;
89
+ }
48
90
  //# sourceMappingURL=transaction.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"transaction.d.ts","sourceRoot":"","sources":["../src/transaction.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAC;AAE3C;;GAEG;AACH,MAAM,WAAW,kBAAmB,SAAQ,WAAW;IACrD,IAAI,EAAE,M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AAI,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;IAEhC;;OAEG;IACH,IAAI,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;KAAE,CAAC;IAE7B;;OAEG;IACH,OAAO,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,CAAC;CAC7B;AAED;;GAEG;AACH,MAAM,WAAW,qBAAqB;IACpC,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAC;CACpB;AAED;;;;GAIG;AACH,MAAM,WAAW,eAAgB,SAAQ,qBAAqB;IAC5D;;OAEG;IACH,kBAAkB,EAAE,kBAAkB,CAAC;IAEvC;;OAEG;IACH,aAAa,CAAC,EAAE,OAAO,CAAC;IAExB;;;OAGG;IACH,QAAQ,CAAC,EAAE,cAAc,CAAC;IAE1B;;OAEG;IACH,OAAO,CAAC,EAAE,wBAAwB,CAAC;CACpC"}
@@ -1 +1 @@
1
- {"version":3,"file":"transaction.js","sourceRoot":"","sources":["../src/transaction.ts"],"names":[],"mappings":"","sourcesContent":["import { Span, SpanContext } from './span';\n\n/**\n * Interface holding Transaction-specific properties\n */\nexport interface TransactionContext extends SpanContext {\n name: string;\n /**\n * If true, sets the end timestamp of the transaction to the highest timestamp of child spans, trimming\n * the duration of the transaction. This is useful to discard extra time in the transaction that is not\n * accounted for in child spans, like what happens in the idle transaction Tracing integration, where we finish the\n * transaction after a given \"idle time\" and we don't want this \"idle time\" to be part of the transaction.\n */\n trimEnd?: boolean;\n}\n\n/**\n * Transaction \"Class\", inherits Span only has `setName`\n */\nexport interface Transaction extends TransactionContext, Span {\n /**\n * @inheritDoc\n */\n spanId: string;\n\n /**\n * @inheritDoc\n */\n traceId: string;\n\n /**\n * @inheritDoc\n */\n startTimestamp: number;\n\n /**\n * @inheritDoc\n */\n tags: { [key: string]: string };\n\n /**\n * @inheritDoc\n */\n data: { [key: string]: any };\n\n /**\n * Set the name of the transaction\n */\n setName(name: string): void;\n}\n"]}
1
+ {"version":3,"file":"transaction.js","sourceRoot":"","sources":["../src/transaction.ts"],"names":[],"mappings":"","sourcesContent":["import { ExtractedNodeRequestData, WorkerLocation } from './misc';\nimport { Span, SpanContext } from './span';\n\n/**\n * Interface holding Transaction-specific properties\n */\nexport interface TransactionContext extends SpanContext {\n /**\n * Human-readable identifier for the transaction\n */\n name: string;\n\n /**\n * If true, sets the end timestamp of the transaction to the highest timestamp of child spans, trimming\n * the duration of the transaction. This is useful to discard extra time in the transaction that is not\n * accounted for in child spans, like what happens in the idle transaction Tracing integration, where we finish the\n * transaction after a given \"idle time\" and we don't want this \"idle time\" to be part of the transaction.\n */\n trimEnd?: boolean;\n\n /**\n * If this transaction has a parent, the parent's sampling decision\n */\n parentSampled?: boolean;\n}\n\n/**\n * Data pulled from a `sentry-trace` header\n */\nexport type TraceparentData = Pick<TransactionContext, 'traceId' | 'parentSpanId' | 'parentSampled'>;\n\n/**\n * Transaction \"Class\", inherits Span only has `setName`\n */\nexport interface Transaction extends TransactionContext, Span {\n /**\n * @inheritDoc\n */\n spanId: string;\n\n /**\n * @inheritDoc\n */\n traceId: string;\n\n /**\n * @inheritDoc\n */\n startTimestamp: number;\n\n /**\n * @inheritDoc\n */\n tags: { [key: string]: string };\n\n /**\n * @inheritDoc\n */\n data: { [key: string]: any };\n\n /**\n * Set the name of the transaction\n */\n setName(name: string): void;\n}\n\n/**\n * Context data passed by the user when starting a transaction, to be used by the tracesSampler method.\n */\nexport interface CustomSamplingContext {\n [key: string]: any;\n}\n\n/**\n * Data passed to the `tracesSampler` function, which forms the basis for whatever decisions it might make.\n *\n * Adds default data to data provided by the user. See {@link Hub.startTransaction}\n */\nexport interface SamplingContext extends CustomSamplingContext {\n /**\n * Context data with which transaction being sampled was created\n */\n transactionContext: TransactionContext;\n\n /**\n * Sampling decision from the parent transaction, if any.\n */\n parentSampled?: boolean;\n\n /**\n * Object representing the URL of the current page or worker script. Passed by default in a browser or service worker\n * context.\n */\n location?: WorkerLocation;\n\n /**\n * Object representing the incoming request to a node server. Passed by default when using the TracingHandler.\n */\n request?: ExtractedNodeRequestData;\n}\n"]}
package/esm/hub.d.ts CHANGED
@@ -6,7 +6,7 @@ import { Integration, IntegrationClass } from './integration';
6
6
  import { Scope } from './scope';
7
7
  import { Severity } from './severity';
8
8
  import { Span, SpanContext } from './span';
9
- import { Transaction, TransactionContext } from './transaction';
9
+ import { CustomSamplingContext, Transaction, TransactionContext } from './transaction';
10
10
  import { User } from './user';
11
11
  /**
12
12
  * Internal class used to make sure we always have the latest internal functions
@@ -166,22 +166,22 @@ export interface Hub {
166
166
  */
167
167
  startSpan(context: SpanContext): Span;
168
168
  /**
169
- * Starts a new `Transaction` and returns it. This is the entry point to manual
170
- * tracing instrumentation.
169
+ * Starts a new `Transaction` and returns it. This is the entry point to manual tracing instrumentation.
171
170
  *
172
- * A tree structure can be built by adding child spans to the transaction, and
173
- * child spans to other spans. To start a new child span within the transaction
174
- * or any span, call the respective `.startChild()` method.
171
+ * A tree structure can be built by adding child spans to the transaction, and child spans to other spans. To start a
172
+ * new child span within the transaction or any span, call the respective `.startChild()` method.
175
173
  *
176
- * Every child span must be finished before the transaction is finished,
177
- * otherwise the unfinished spans are discarded.
174
+ * Every child span must be finished before the transaction is finished, otherwise the unfinished spans are discarded.
178
175
  *
179
- * The transaction must be finished with a call to its `.finish()` method, at
180
- * which point the transaction with all its finished child spans will be sent to
181
- * Sentry.
176
+ * The transaction must be finished with a call to its `.finish()` method, at which point the transaction with all its
177
+ * finished child spans will be sent to Sentry.
182
178
  *
183
179
  * @param context Properties of the new `Transaction`.
180
+ * @param customSamplingContext Information given to the transaction sampling function (along with context-dependent
181
+ * default values). See {@link Options.tracesSampler}.
182
+ *
183
+ * @returns The transaction which was just started
184
184
  */
185
- startTransaction(context: TransactionContext): Transaction;
185
+ startTransaction(context: TransactionContext, customSamplingContext?: CustomSamplingContext): Transaction;
186
186
  }
187
187
  //# sourceMappingURL=hub.d.ts.map
package/esm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,EAAE,OAAO,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;KAAE,GAAG,IAAI,GAAG,IAAI,CAAC;IAEvE;;;;OAIG;IACH,cAAc,CAAC,QAAQ,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,IAAI,GAAG,IAAI,CAAC;IAEvD;;;;OAIG;IACH,GAAG,CAAC,QAAQ,EAAE,CAAC,GAAG,EAAE,GAAG,KAAK,IAAI,GAAG,IAAI,CAAC;IAExC,kEAAkE;IAClE,cAAc,CAAC,CAAC,SAAS,WAAW,EAAE,WAAW,EAAE,gBAAgB,CAAC,CAAC,CAAC,GAAG,CAAC,GAAG,IAAI,CAAC;IAElF,qEAAqE;IACrE,YAAY,IAAI;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;IAE1C;;;;;OAKG;IACH,SAAS,CAAC,OAAO,EAAE,WAAW,GAAG,IAAI,CAAC;IAEtC;;;;;;;;;;;;;;;;OAgBG;IACH,gBAAgB,CAAC,OAAO,EAAE,kBAAkB,EAAE,qBAAqB,CAAC,EAAE,qBAAqB,GAAG,WAAW,CAAC;CAC3G"}
package/esm/hub.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"hub.js","sourceRoot":"","sources":["../src/hub.ts"],"names":[],"mappings":"","sourcesContent":["import { Breadcrumb, BreadcrumbHint } from './breadcrumb';\nimport { Client } from './client';\nimport { Event, EventHint } from './event';\nimport { Extra, Extras } from './extra';\nimport { Integration, IntegrationClass } from './integration';\nimport { Scope } from './scope';\nimport { Severity } from './severity';\nimport { Span, SpanContext } from './span';\nimport { Transaction, TransactionContext } from './transaction';\nimport { User } from './user';\n\n/**\n * Internal class used to make sure we always have the latest internal functions\n * working in case we have a version conflict.\n */\nexport interface Hub {\n /**\n * Checks if this hub's version is older than the given version.\n *\n * @param version A version number to compare to.\n * @return True if the given version is newer; otherwise false.\n *\n * @hidden\n */\n isOlderThan(version: number): boolean;\n\n /**\n * This binds the given client to the current scope.\n * @param client An SDK client (client) instance.\n */\n bindClient(client?: Client): void;\n\n /**\n * Create a new scope to store context information.\n *\n * The scope will be layered on top of the current one. It is isolated, i.e. all\n * breadcrumbs and context information added to this scope will be removed once\n * the scope ends. Be sure to always remove this scope with {@link this.popScope}\n * when the operation finishes or throws.\n *\n * @returns Scope, the new cloned scope\n */\n pushScope(): Scope;\n\n /**\n * Removes a previously pushed scope from the stack.\n *\n * This restores the state before the scope was pushed. All breadcrumbs and\n * context information added since the last call to {@link this.pushScope} are\n * discarded.\n */\n popScope(): boolean;\n\n /**\n * Creates a new scope with and executes the given operation within.\n * The scope is automatically removed once the operation\n * finishes or throws.\n *\n * This is essentially a convenience function for:\n *\n * pushScope();\n * callback();\n * popScope();\n *\n * @param callback that will be enclosed into push/popScope.\n */\n withScope(callback: (scope: Scope) => void): void;\n\n /** Returns the client of the top stack. */\n getClient(): Client | undefined;\n\n /**\n * Captures an exception event and sends it to Sentry.\n *\n * @param exception An exception-like object.\n * @param hint May contain additional information about the original exception.\n * @returns The generated eventId.\n */\n captureException(exception: any, hint?: EventHint): string;\n\n /**\n * Captures a message event and sends it to Sentry.\n *\n * @param message The message to send to Sentry.\n * @param level Define the level of the message.\n * @param hint May contain additional information about the original exception.\n * @returns The generated eventId.\n */\n captureMessage(message: string, level?: Severity, hint?: EventHint): string;\n\n /**\n * Captures a manually created event and sends it to Sentry.\n *\n * @param event The event to send to Sentry.\n * @param hint May contain additional information about the original exception.\n */\n captureEvent(event: Event, hint?: EventHint): string;\n\n /**\n * This is the getter for lastEventId.\n *\n * @returns The last event id of a captured event.\n */\n lastEventId(): string | undefined;\n\n /**\n * Records a new breadcrumb which will be attached to future events.\n *\n * Breadcrumbs will be added to subsequent events to provide more context on\n * user's actions prior to an error or crash.\n *\n * @param breadcrumb The breadcrumb to record.\n * @param hint May contain additional information about the original breadcrumb.\n */\n addBreadcrumb(breadcrumb: Breadcrumb, hint?: BreadcrumbHint): void;\n\n /**\n * Updates user context information for future events.\n *\n * @param user User context object to be set in the current context. Pass `null` to unset the user.\n */\n setUser(user: User | null): void;\n\n /**\n * Set an object that will be merged sent as tags data with the event.\n * @param tags Tags context object to merge into current context.\n */\n setTags(tags: { [key: string]: string }): void;\n\n /**\n * Set key:value that will be sent as tags data with the event.\n * @param key String key of tag\n * @param value String value of tag\n */\n setTag(key: string, value: string): void;\n\n /**\n * Set key:value that will be sent as extra data with the event.\n * @param key String of extra\n * @param extra Any kind of data. This data will be normalized.\n */\n setExtra(key: string, extra: Extra): void;\n\n /**\n * Set an object that will be merged sent as extra data with the event.\n * @param extras Extras object to merge into current context.\n */\n setExtras(extras: Extras): void;\n\n /**\n * Sets context data with the given name.\n * @param name of the context\n * @param context Any kind of data. This data will be normalized.\n */\n setContext(name: string, context: { [key: string]: any } | null): void;\n\n /**\n * Callback to set context information onto the scope.\n *\n * @param callback Callback function that receives Scope.\n */\n configureScope(callback: (scope: Scope) => void): void;\n\n /**\n * For the duraction of the callback, this hub will be set as the global current Hub.\n * This function is useful if you want to run your own client and hook into an already initialized one\n * e.g.: Reporting issues to your own sentry when running in your component while still using the users configuration.\n */\n run(callback: (hub: Hub) => void): void;\n\n /** Returns the integration if installed on the current client. */\n getIntegration<T extends Integration>(integration: IntegrationClass<T>): T | null;\n\n /** Returns all trace headers that are currently on the top scope. */\n traceHeaders(): { [key: string]: string };\n\n /**\n * Starts a new `Span` and returns it. If there is a `Span` on the `Scope`,\n * the new `Span` will be a child of the existing `Span`.\n *\n * @param context Properties of the new `Span`.\n */\n startSpan(context: SpanContext): Span;\n\n /**\n * Starts a new `Transaction` and returns it. This is the entry point to manual\n * tracing instrumentation.\n *\n * A tree structure can be built by adding child spans to the transaction, and\n * child spans to other spans. To start a new child span within the transaction\n * or any span, call the respective `.startChild()` method.\n *\n * Every child span must be finished before the transaction is finished,\n * otherwise the unfinished spans are discarded.\n *\n * The transaction must be finished with a call to its `.finish()` method, at\n * which point the transaction with all its finished child spans will be sent to\n * Sentry.\n *\n * @param context Properties of the new `Transaction`.\n */\n startTransaction(context: TransactionContext): Transaction;\n}\n"]}
1
+ {"version":3,"file":"hub.js","sourceRoot":"","sources":["../src/hub.ts"],"names":[],"mappings":"","sourcesContent":["import { Breadcrumb, BreadcrumbHint } from './breadcrumb';\nimport { Client } from './client';\nimport { Event, EventHint } from './event';\nimport { Extra, Extras } from './extra';\nimport { Integration, IntegrationClass } from './integration';\nimport { Scope } from './scope';\nimport { Severity } from './severity';\nimport { Span, SpanContext } from './span';\nimport { CustomSamplingContext, Transaction, TransactionContext } from './transaction';\nimport { User } from './user';\n\n/**\n * Internal class used to make sure we always have the latest internal functions\n * working in case we have a version conflict.\n */\nexport interface Hub {\n /**\n * Checks if this hub's version is older than the given version.\n *\n * @param version A version number to compare to.\n * @return True if the given version is newer; otherwise false.\n *\n * @hidden\n */\n isOlderThan(version: number): boolean;\n\n /**\n * This binds the given client to the current scope.\n * @param client An SDK client (client) instance.\n */\n bindClient(client?: Client): void;\n\n /**\n * Create a new scope to store context information.\n *\n * The scope will be layered on top of the current one. It is isolated, i.e. all\n * breadcrumbs and context information added to this scope will be removed once\n * the scope ends. Be sure to always remove this scope with {@link this.popScope}\n * when the operation finishes or throws.\n *\n * @returns Scope, the new cloned scope\n */\n pushScope(): Scope;\n\n /**\n * Removes a previously pushed scope from the stack.\n *\n * This restores the state before the scope was pushed. All breadcrumbs and\n * context information added since the last call to {@link this.pushScope} are\n * discarded.\n */\n popScope(): boolean;\n\n /**\n * Creates a new scope with and executes the given operation within.\n * The scope is automatically removed once the operation\n * finishes or throws.\n *\n * This is essentially a convenience function for:\n *\n * pushScope();\n * callback();\n * popScope();\n *\n * @param callback that will be enclosed into push/popScope.\n */\n withScope(callback: (scope: Scope) => void): void;\n\n /** Returns the client of the top stack. */\n getClient(): Client | undefined;\n\n /**\n * Captures an exception event and sends it to Sentry.\n *\n * @param exception An exception-like object.\n * @param hint May contain additional information about the original exception.\n * @returns The generated eventId.\n */\n captureException(exception: any, hint?: EventHint): string;\n\n /**\n * Captures a message event and sends it to Sentry.\n *\n * @param message The message to send to Sentry.\n * @param level Define the level of the message.\n * @param hint May contain additional information about the original exception.\n * @returns The generated eventId.\n */\n captureMessage(message: string, level?: Severity, hint?: EventHint): string;\n\n /**\n * Captures a manually created event and sends it to Sentry.\n *\n * @param event The event to send to Sentry.\n * @param hint May contain additional information about the original exception.\n */\n captureEvent(event: Event, hint?: EventHint): string;\n\n /**\n * This is the getter for lastEventId.\n *\n * @returns The last event id of a captured event.\n */\n lastEventId(): string | undefined;\n\n /**\n * Records a new breadcrumb which will be attached to future events.\n *\n * Breadcrumbs will be added to subsequent events to provide more context on\n * user's actions prior to an error or crash.\n *\n * @param breadcrumb The breadcrumb to record.\n * @param hint May contain additional information about the original breadcrumb.\n */\n addBreadcrumb(breadcrumb: Breadcrumb, hint?: BreadcrumbHint): void;\n\n /**\n * Updates user context information for future events.\n *\n * @param user User context object to be set in the current context. Pass `null` to unset the user.\n */\n setUser(user: User | null): void;\n\n /**\n * Set an object that will be merged sent as tags data with the event.\n * @param tags Tags context object to merge into current context.\n */\n setTags(tags: { [key: string]: string }): void;\n\n /**\n * Set key:value that will be sent as tags data with the event.\n * @param key String key of tag\n * @param value String value of tag\n */\n setTag(key: string, value: string): void;\n\n /**\n * Set key:value that will be sent as extra data with the event.\n * @param key String of extra\n * @param extra Any kind of data. This data will be normalized.\n */\n setExtra(key: string, extra: Extra): void;\n\n /**\n * Set an object that will be merged sent as extra data with the event.\n * @param extras Extras object to merge into current context.\n */\n setExtras(extras: Extras): void;\n\n /**\n * Sets context data with the given name.\n * @param name of the context\n * @param context Any kind of data. This data will be normalized.\n */\n setContext(name: string, context: { [key: string]: any } | null): void;\n\n /**\n * Callback to set context information onto the scope.\n *\n * @param callback Callback function that receives Scope.\n */\n configureScope(callback: (scope: Scope) => void): void;\n\n /**\n * For the duraction of the callback, this hub will be set as the global current Hub.\n * This function is useful if you want to run your own client and hook into an already initialized one\n * e.g.: Reporting issues to your own sentry when running in your component while still using the users configuration.\n */\n run(callback: (hub: Hub) => void): void;\n\n /** Returns the integration if installed on the current client. */\n getIntegration<T extends Integration>(integration: IntegrationClass<T>): T | null;\n\n /** Returns all trace headers that are currently on the top scope. */\n traceHeaders(): { [key: string]: string };\n\n /**\n * Starts a new `Span` and returns it. If there is a `Span` on the `Scope`,\n * the new `Span` will be a child of the existing `Span`.\n *\n * @param context Properties of the new `Span`.\n */\n startSpan(context: SpanContext): Span;\n\n /**\n * Starts a new `Transaction` and returns it. This is the entry point to manual tracing instrumentation.\n *\n * A tree structure can be built by adding child spans to the transaction, and child spans to other spans. To start a\n * new child span within the transaction or any span, call the respective `.startChild()` method.\n *\n * Every child span must be finished before the transaction is finished, otherwise the unfinished spans are discarded.\n *\n * The transaction must be finished with a call to its `.finish()` method, at which point the transaction with all its\n * finished child spans will be sent to Sentry.\n *\n * @param context Properties of the new `Transaction`.\n * @param customSamplingContext Information given to the transaction sampling function (along with context-dependent\n * default values). See {@link Options.tracesSampler}.\n *\n * @returns The transaction which was just started\n */\n startTransaction(context: TransactionContext, customSamplingContext?: CustomSamplingContext): Transaction;\n}\n"]}
package/esm/index.d.ts CHANGED
@@ -10,6 +10,7 @@ export { Hub } from './hub';
10
10
  export { Integration, IntegrationClass } from './integration';
11
11
  export { LogLevel } from './loglevel';
12
12
  export { Mechanism } from './mechanism';
13
+ export { ExtractedNodeRequestData, WorkerLocation } from './misc';
13
14
  export { Options } from './options';
14
15
  export { Package } from './package';
15
16
  export { Request } from './request';
@@ -22,7 +23,7 @@ export { Span, SpanContext } from './span';
22
23
  export { StackFrame } from './stackframe';
23
24
  export { Stacktrace } from './stacktrace';
24
25
  export { Status } from './status';
25
- export { Transaction, TransactionContext } from './transaction';
26
+ export { CustomSamplingContext, SamplingContext, TraceparentData, Transaction, TransactionContext, } from './transaction';
26
27
  export { Thread } from './thread';
27
28
  export { Transport, TransportOptions, TransportClass } from './transport';
28
29
  export { User } from './user';
@@ -1 +1 @@
1
- {"version":3,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AAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,cAAc,EAAE,KAAK,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAC9D,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,IAAI,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAC;AAC3C,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAClC,OAAO,EACL,qBAAqB,EACrB,eAAe,EACf,eAAe,EACf,WAAW,EACX,kBAAkB,GACnB,MAAM,eAAe,CAAC;AACvB,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAClC,OAAO,EAAE,SAAS,EAAE,gBAAgB,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAC1E,OAAO,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AAC9B,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC"}
package/esm/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAUA,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAStC,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAItC,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC","sourcesContent":["export { Breadcrumb, BreadcrumbHint } from './breadcrumb';\nexport { Client } from './client';\nexport { Dsn, DsnComponents, DsnLike, DsnProtocol } from './dsn';\nexport { ExtendedError } from './error';\nexport { Event, EventHint } from './event';\nexport { EventProcessor } from './eventprocessor';\nexport { Exception } from './exception';\nexport { Extra, Extras } from './extra';\nexport { Hub } from './hub';\nexport { Integration, IntegrationClass } from './integration';\nexport { LogLevel } from './loglevel';\nexport { Mechanism } from './mechanism';\nexport { Options } from './options';\nexport { Package } from './package';\nexport { Request } from './request';\nexport { Response } from './response';\nexport { Runtime } from './runtime';\nexport { CaptureContext, Scope, ScopeContext } from './scope';\nexport { SdkInfo } from './sdkinfo';\nexport { Severity } from './severity';\nexport { Span, SpanContext } from './span';\nexport { StackFrame } from './stackframe';\nexport { Stacktrace } from './stacktrace';\nexport { Status } from './status';\nexport { Transaction, TransactionContext } from './transaction';\nexport { Thread } from './thread';\nexport { Transport, TransportOptions, TransportClass } from './transport';\nexport { User } from './user';\nexport { WrappedFunction } from './wrappedfunction';\n"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAUA,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAUtC,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAItC,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC","sourcesContent":["export { Breadcrumb, BreadcrumbHint } from './breadcrumb';\nexport { Client } from './client';\nexport { Dsn, DsnComponents, DsnLike, DsnProtocol } from './dsn';\nexport { ExtendedError } from './error';\nexport { Event, EventHint } from './event';\nexport { EventProcessor } from './eventprocessor';\nexport { Exception } from './exception';\nexport { Extra, Extras } from './extra';\nexport { Hub } from './hub';\nexport { Integration, IntegrationClass } from './integration';\nexport { LogLevel } from './loglevel';\nexport { Mechanism } from './mechanism';\nexport { ExtractedNodeRequestData, WorkerLocation } from './misc';\nexport { Options } from './options';\nexport { Package } from './package';\nexport { Request } from './request';\nexport { Response } from './response';\nexport { Runtime } from './runtime';\nexport { CaptureContext, Scope, ScopeContext } from './scope';\nexport { SdkInfo } from './sdkinfo';\nexport { Severity } from './severity';\nexport { Span, SpanContext } from './span';\nexport { StackFrame } from './stackframe';\nexport { Stacktrace } from './stacktrace';\nexport { Status } from './status';\nexport {\n CustomSamplingContext,\n SamplingContext,\n TraceparentData,\n Transaction,\n TransactionContext,\n} from './transaction';\nexport { Thread } from './thread';\nexport { Transport, TransportOptions, TransportClass } from './transport';\nexport { User } from './user';\nexport { WrappedFunction } from './wrappedfunction';\n"]}
package/esm/misc.d.ts ADDED
@@ -0,0 +1,50 @@
1
+ /**
2
+ * Data extracted from an incoming request to a node server
3
+ */
4
+ export interface ExtractedNodeRequestData {
5
+ [key: string]: any;
6
+ /** Specific headers from the request */
7
+ headers?: {
8
+ [key: string]: string;
9
+ };
10
+ /** The request's method */
11
+ method?: string;
12
+ /** The request's URL, including query string */
13
+ url?: string;
14
+ /** String representing the cookies sent along with the request */
15
+ cookies?: {
16
+ [key: string]: string;
17
+ };
18
+ /** The request's query string, without the leading '?' */
19
+ query_string?: string;
20
+ /** Any data sent in the request's body, as a JSON string */
21
+ data?: string;
22
+ }
23
+ /**
24
+ * Location object on a service worker's `self` object.
25
+ *
26
+ * See https://developer.mozilla.org/en-US/docs/Web/API/WorkerLocation.
27
+ */
28
+ export interface WorkerLocation {
29
+ /** The protocol scheme of the URL of the script executed in the Worker, including the final ':'. */
30
+ readonly protocol: string;
31
+ /** The host, that is the hostname, a ':', and the port of the URL of the script executed in the Worker. */
32
+ readonly host: string;
33
+ /** The domain of the URL of the script executed in the Worker. */
34
+ readonly hostname: string;
35
+ /** The canonical form of the origin of the specific location. */
36
+ readonly origin: string;
37
+ /** The port number of the URL of the script executed in the Worker. */
38
+ readonly port: string;
39
+ /** The path of the URL of the script executed in the Worker, beginning with a '/'. */
40
+ readonly pathname: string;
41
+ /** The parameters (query string) of the URL of the script executed in the Worker, beginning with a '?'. */
42
+ readonly search: string;
43
+ /** The fragment identifier of the URL of the script executed in the Worker, beginning with a '#'. */
44
+ readonly hash: string;
45
+ /** Stringifier that returns the whole URL of the script executed in the Worker. */
46
+ readonly href: string;
47
+ /** Synonym for `href` attribute */
48
+ toString(): string;
49
+ }
50
+ //# sourceMappingURL=misc.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"misc.d.ts","sourceRoot":"","sources":["../src/misc.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,WAAW,wBAAwB;IACvC,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAC;IAEnB,wCAAwC;IACxC,OAAO,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;IAEpC,4BAA4B;IAC5B,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB,gDAAgD;IAChD,GAAG,CAAC,EAAE,MAAM,CAAC;IAEb,kEAAkE;IAClE,OAAO,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;IAEpC,0DAA0D;IAC1D,YAAY,CAAC,EAAE,MAAM,CAAC;IAEtB,4DAA4D;IAC5D,IAAI,CAAC,EAAE,MAAM,CAAC;CACf;AAED;;;;GAIG;AACH,MAAM,WAAW,cAAc;IAC7B,oGAAoG;IACpG,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAE1B,2GAA2G;IAC3G,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IAEtB,kEAAkE;IAClE,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAE1B,iEAAiE;IACjE,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IAExB,uEAAuE;IACvE,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IAEtB,sFAAsF;IACtF,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAE1B,2GAA2G;IAC3G,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IAExB,qGAAqG;IACrG,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IAEtB,mFAAmF;IACnF,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IAEtB,mCAAmC;IACnC,QAAQ,IAAI,MAAM,CAAC;CACpB"}
package/esm/misc.js ADDED
@@ -0,0 +1 @@
1
+ //# sourceMappingURL=misc.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"misc.js","sourceRoot":"","sources":["../src/misc.ts"],"names":[],"mappings":"","sourcesContent":["/**\n * Data extracted from an incoming request to a node server\n */\nexport interface ExtractedNodeRequestData {\n [key: string]: any;\n\n /** Specific headers from the request */\n headers?: { [key: string]: string };\n\n /** The request's method */\n method?: string;\n\n /** The request's URL, including query string */\n url?: string;\n\n /** String representing the cookies sent along with the request */\n cookies?: { [key: string]: string };\n\n /** The request's query string, without the leading '?' */\n query_string?: string;\n\n /** Any data sent in the request's body, as a JSON string */\n data?: string;\n}\n\n/**\n * Location object on a service worker's `self` object.\n *\n * See https://developer.mozilla.org/en-US/docs/Web/API/WorkerLocation.\n */\nexport interface WorkerLocation {\n /** The protocol scheme of the URL of the script executed in the Worker, including the final ':'. */\n readonly protocol: string;\n\n /** The host, that is the hostname, a ':', and the port of the URL of the script executed in the Worker. */\n readonly host: string;\n\n /** The domain of the URL of the script executed in the Worker. */\n readonly hostname: string;\n\n /** The canonical form of the origin of the specific location. */\n readonly origin: string;\n\n /** The port number of the URL of the script executed in the Worker. */\n readonly port: string;\n\n /** The path of the URL of the script executed in the Worker, beginning with a '/'. */\n readonly pathname: string;\n\n /** The parameters (query string) of the URL of the script executed in the Worker, beginning with a '?'. */\n readonly search: string;\n\n /** The fragment identifier of the URL of the script executed in the Worker, beginning with a '#'. */\n readonly hash: string;\n\n /** Stringifier that returns the whole URL of the script executed in the Worker. */\n readonly href: string;\n\n /** Synonym for `href` attribute */\n toString(): string;\n}\n"]}
package/esm/options.d.ts CHANGED
@@ -2,6 +2,7 @@ import { Breadcrumb, BreadcrumbHint } from './breadcrumb';
2
2
  import { Event, EventHint } from './event';
3
3
  import { Integration } from './integration';
4
4
  import { LogLevel } from './loglevel';
5
+ import { SamplingContext } from './transaction';
5
6
  import { Transport, TransportClass, TransportOptions } from './transport';
6
7
  /** Base configuration options for every SDK. */
7
8
  export interface Options {
@@ -63,15 +64,6 @@ export interface Options {
63
64
  logLevel?: LogLevel;
64
65
  /** A global sample rate to apply to all events (0 - 1). */
65
66
  sampleRate?: number;
66
- /**
67
- * Sample rate to determine trace sampling.
68
- *
69
- * 0.0 = 0% chance of a given trace being sent (send no traces)
70
- * 1.0 = 100% chance of a given trace being sent (send all traces)
71
- *
72
- * Default: 0.0
73
- */
74
- tracesSampleRate?: number;
75
67
  /** Attaches stacktraces to pure capture message / log integrations */
76
68
  attachStacktrace?: boolean;
77
69
  /** Maxium number of chars a single value can have before it will be truncated. */
@@ -94,9 +86,35 @@ export interface Options {
94
86
  * problems.
95
87
  */
96
88
  shutdownTimeout?: number;
89
+ /**
90
+ * Options which are in beta, or otherwise not guaranteed to be stable.
91
+ */
97
92
  _experiments?: {
98
93
  [key: string]: any;
99
94
  };
95
+ /**
96
+ * Sample rate to determine trace sampling.
97
+ *
98
+ * 0.0 = 0% chance of a given trace being sent (send no traces) 1.0 = 100% chance of a given trace being sent (send
99
+ * all traces)
100
+ *
101
+ * Tracing is enabled if either this or `tracesSampler` is defined. If both are defined, `tracesSampleRate` is
102
+ * ignored.
103
+ */
104
+ tracesSampleRate?: number;
105
+ /**
106
+ * Function to compute tracing sample rate dynamically and filter unwanted traces.
107
+ *
108
+ * Tracing is enabled if either this or `tracesSampleRate` is defined. If both are defined, `tracesSampleRate` is
109
+ * ignored.
110
+ *
111
+ * Will automatically be passed a context object of default and optional custom data. See
112
+ * {@link Transaction.samplingContext} and {@link Hub.startTransaction}.
113
+ *
114
+ * @returns A sample rate between 0 and 1 (0 drops the trace, 1 guarantees it will be sent). Returning `true` is
115
+ * equivalent to returning 1 and returning `false` is equivalent to returning 0.
116
+ */
117
+ tracesSampler?(samplingContext: SamplingContext): number | boolean;
100
118
  /**
101
119
  * A callback invoked during event submission, allowing to optionally modify
102
120
  * the event before it is sent to Sentry.
@@ -1 +1 @@
1
- {"version":3,"file":"options.d.ts","sourceRoot":"","sources":["../src/options.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AAC1D,OAAO,EAAE,KAAK,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAC3C,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,SAAS,EAAE,cAAc,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAE1E,gDAAgD;AAChD,MAAM,WAAW,OAAO;IACtB;;OAEG;IACH,KAAK,CAAC,EAAE,OAAO,CAAC;IAEhB;;;;OAIG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAElB;;;OAGG;IACH,GAAG,CAAC,EAAE,MAAM,CAAC;IAEb;;;OAGG;IACH,mBAAmB,CAAC,EAAE,KAAK,GAAG,WAAW,EAAE,CAAC;IAE5C;;;;OAIG;IACH,YAAY,CAAC,EAAE,WAAW,EAAE,GAAG,CAAC,CAAC,YAAY,EAAE,WAAW,EAAE,KAAK,WAAW,EAAE,CAAC,CAAC;IAEhF;;;OAGG;IACH,YAAY,CAAC,EAAE,KAAK,CAAC,MAAM,GAAG,MAAM,CAAC,CAAC;IAEtC;;OAEG;IACH,SAAS,CAAC,EAAE,cAAc,CAAC,SAAS,CAAC,CAAC;IAEtC;;OAEG;IACH,gBAAgB,CAAC,EAAE,gBAAgB,CAAC;IAEpC;;;;OAIG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB,uEAAuE;IACvE,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB,2CAA2C;IAC3C,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd;;;OAGG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC;IAExB,oDAAoD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C,CAAC,eAAe,EAAE,eAAe,GAAG,MAAM,GAAG,OAAO,CAAC;IAEnE;;;;;;;;;;;OAWG;IACH,UAAU,CAAC,CAAC,KAAK,EAAE,KAAK,EAAE,IAAI,CAAC,EAAE,SAAS,GAAG,WAAW,CAAC,KAAK,GAAG,IAAI,CAAC,GAAG,KAAK,GAAG,IAAI,CAAC;IAEtF;;;;;;;;;;OAUG;IACH,gBAAgB,CAAC,CAAC,UAAU,EAAE,UAAU,EAAE,IAAI,CAAC,EAAE,cAAc,GAAG,UAAU,GAAG,IAAI,CAAC;CACrF"}
@@ -1 +1 @@
1
- {"version":3,"file":"options.js","sourceRoot":"","sources":["../src/options.ts"],"names":[],"mappings":"","sourcesContent":["import { Breadcrumb, BreadcrumbHint } from './breadcrumb';\nimport { Event, EventHint } from './event';\nimport { Integration } from './integration';\nimport { LogLevel } from './loglevel';\nimport { Transport, TransportClass, TransportOptions } from './transport';\n\n/** Base configuration options for every SDK. */\nexport interface Options {\n /**\n * Enable debug functionality in the SDK itself\n */\n debug?: boolean;\n\n /**\n * Specifies whether this SDK should activate and send events to Sentry.\n * Disabling the SDK reduces all overhead from instrumentation, collecting\n * breadcrumbs and capturing events. Defaults to true.\n */\n enabled?: boolean;\n\n /**\n * The Dsn used to connect to Sentry and identify the project. If omitted, the\n * SDK will not send any data to Sentry.\n */\n dsn?: string;\n\n /**\n * If this is set to false, default integrations will not be added, otherwise this will internally be set to the\n * recommended default integrations.\n */\n defaultIntegrations?: false | Integration[];\n\n /**\n * List of integrations that should be installed after SDK was initialized.\n * Accepts either a list of integrations or a function that receives\n * default integrations and returns a new, updated list.\n */\n integrations?: Integration[] | ((integrations: Integration[]) => Integration[]);\n\n /**\n * A pattern for error messages which should not be sent to Sentry.\n * By default, all errors will be sent.\n */\n ignoreErrors?: Array<string | RegExp>;\n\n /**\n * Transport object that should be used to send events to Sentry\n */\n transport?: TransportClass<Transport>;\n\n /**\n * Options for the default transport that the SDK uses.\n */\n transportOptions?: TransportOptions;\n\n /**\n * The release identifier used when uploading respective source maps. Specify\n * this value to allow Sentry to resolve the correct source maps when\n * processing events.\n */\n release?: string;\n\n /** The current environment of your application (e.g. \"production\"). */\n environment?: string;\n\n /** Sets the distribution for all events */\n dist?: string;\n\n /**\n * The maximum number of breadcrumbs sent with events. Defaults to 30.\n * Values over 100 will be ignored and 100 used instead.\n */\n maxBreadcrumbs?: number;\n\n /** Console logging verbosity for the SDK Client. */\n logLevel?: LogLevel;\n\n /** A global sample rate to apply to all events (0 - 1). */\n sampleRate?: number;\n\n /**\n * Sample rate to determine trace sampling.\n *\n * 0.0 = 0% chance of a given trace being sent (send no traces)\n * 1.0 = 100% chance of a given trace being sent (send all traces)\n *\n * Default: 0.0\n */\n tracesSampleRate?: number;\n\n /** Attaches stacktraces to pure capture message / log integrations */\n attachStacktrace?: boolean;\n\n /** Maxium number of chars a single value can have before it will be truncated. */\n maxValueLength?: number;\n\n /**\n * Maximum number of levels that normalization algorithm will traverse in objects and arrays.\n * Used when normalizing an event before sending, on all of the listed attributes:\n * - `breadcrumbs.data`\n * - `user`\n * - `contexts`\n * - `extra`\n * Defaults to `3`. Set to `0` to disable.\n */\n normalizeDepth?: number;\n\n /**\n * Controls how many milliseconds to wait before shutting down. The default is\n * SDK-specific but typically around 2 seconds. Setting this too low can cause\n * problems for sending events from command line applications. Setting it too\n * high can cause the application to block for users with network connectivity\n * problems.\n */\n shutdownTimeout?: number;\n\n _experiments?: {\n [key: string]: any;\n };\n\n /**\n * A callback invoked during event submission, allowing to optionally modify\n * the event before it is sent to Sentry.\n *\n * Note that you must return a valid event from this callback. If you do not\n * wish to modify the event, simply return it at the end.\n * Returning null will cause the event to be dropped.\n *\n * @param event The error or message event generated by the SDK.\n * @param hint May contain additional information about the original exception.\n * @returns A new event that will be sent | null.\n */\n beforeSend?(event: Event, hint?: EventHint): PromiseLike<Event | null> | Event | null;\n\n /**\n * A callback invoked when adding a breadcrumb, allowing to optionally modify\n * it before adding it to future events.\n *\n * Note that you must return a valid breadcrumb from this callback. If you do\n * not wish to modify the breadcrumb, simply return it at the end.\n * Returning null will cause the breadcrumb to be dropped.\n *\n * @param breadcrumb The breadcrumb as created by the SDK.\n * @returns The breadcrumb that will be added | null.\n */\n beforeBreadcrumb?(breadcrumb: Breadcrumb, hint?: BreadcrumbHint): Breadcrumb | null;\n}\n"]}
1
+ {"version":3,"file":"options.js","sourceRoot":"","sources":["../src/options.ts"],"names":[],"mappings":"","sourcesContent":["import { Breadcrumb, BreadcrumbHint } from './breadcrumb';\nimport { Event, EventHint } from './event';\nimport { Integration } from './integration';\nimport { LogLevel } from './loglevel';\nimport { SamplingContext } from './transaction';\nimport { Transport, TransportClass, TransportOptions } from './transport';\n\n/** Base configuration options for every SDK. */\nexport interface Options {\n /**\n * Enable debug functionality in the SDK itself\n */\n debug?: boolean;\n\n /**\n * Specifies whether this SDK should activate and send events to Sentry.\n * Disabling the SDK reduces all overhead from instrumentation, collecting\n * breadcrumbs and capturing events. Defaults to true.\n */\n enabled?: boolean;\n\n /**\n * The Dsn used to connect to Sentry and identify the project. If omitted, the\n * SDK will not send any data to Sentry.\n */\n dsn?: string;\n\n /**\n * If this is set to false, default integrations will not be added, otherwise this will internally be set to the\n * recommended default integrations.\n */\n defaultIntegrations?: false | Integration[];\n\n /**\n * List of integrations that should be installed after SDK was initialized.\n * Accepts either a list of integrations or a function that receives\n * default integrations and returns a new, updated list.\n */\n integrations?: Integration[] | ((integrations: Integration[]) => Integration[]);\n\n /**\n * A pattern for error messages which should not be sent to Sentry.\n * By default, all errors will be sent.\n */\n ignoreErrors?: Array<string | RegExp>;\n\n /**\n * Transport object that should be used to send events to Sentry\n */\n transport?: TransportClass<Transport>;\n\n /**\n * Options for the default transport that the SDK uses.\n */\n transportOptions?: TransportOptions;\n\n /**\n * The release identifier used when uploading respective source maps. Specify\n * this value to allow Sentry to resolve the correct source maps when\n * processing events.\n */\n release?: string;\n\n /** The current environment of your application (e.g. \"production\"). */\n environment?: string;\n\n /** Sets the distribution for all events */\n dist?: string;\n\n /**\n * The maximum number of breadcrumbs sent with events. Defaults to 30.\n * Values over 100 will be ignored and 100 used instead.\n */\n maxBreadcrumbs?: number;\n\n /** Console logging verbosity for the SDK Client. */\n logLevel?: LogLevel;\n\n /** A global sample rate to apply to all events (0 - 1). */\n sampleRate?: number;\n\n /** Attaches stacktraces to pure capture message / log integrations */\n attachStacktrace?: boolean;\n\n /** Maxium number of chars a single value can have before it will be truncated. */\n maxValueLength?: number;\n\n /**\n * Maximum number of levels that normalization algorithm will traverse in objects and arrays.\n * Used when normalizing an event before sending, on all of the listed attributes:\n * - `breadcrumbs.data`\n * - `user`\n * - `contexts`\n * - `extra`\n * Defaults to `3`. Set to `0` to disable.\n */\n normalizeDepth?: number;\n\n /**\n * Controls how many milliseconds to wait before shutting down. The default is\n * SDK-specific but typically around 2 seconds. Setting this too low can cause\n * problems for sending events from command line applications. Setting it too\n * high can cause the application to block for users with network connectivity\n * problems.\n */\n shutdownTimeout?: number;\n\n /**\n * Options which are in beta, or otherwise not guaranteed to be stable.\n */\n _experiments?: {\n [key: string]: any;\n };\n\n /**\n * Sample rate to determine trace sampling.\n *\n * 0.0 = 0% chance of a given trace being sent (send no traces) 1.0 = 100% chance of a given trace being sent (send\n * all traces)\n *\n * Tracing is enabled if either this or `tracesSampler` is defined. If both are defined, `tracesSampleRate` is\n * ignored.\n */\n tracesSampleRate?: number;\n\n /**\n * Function to compute tracing sample rate dynamically and filter unwanted traces.\n *\n * Tracing is enabled if either this or `tracesSampleRate` is defined. If both are defined, `tracesSampleRate` is\n * ignored.\n *\n * Will automatically be passed a context object of default and optional custom data. See\n * {@link Transaction.samplingContext} and {@link Hub.startTransaction}.\n *\n * @returns A sample rate between 0 and 1 (0 drops the trace, 1 guarantees it will be sent). Returning `true` is\n * equivalent to returning 1 and returning `false` is equivalent to returning 0.\n */\n tracesSampler?(samplingContext: SamplingContext): number | boolean;\n\n /**\n * A callback invoked during event submission, allowing to optionally modify\n * the event before it is sent to Sentry.\n *\n * Note that you must return a valid event from this callback. If you do not\n * wish to modify the event, simply return it at the end.\n * Returning null will cause the event to be dropped.\n *\n * @param event The error or message event generated by the SDK.\n * @param hint May contain additional information about the original exception.\n * @returns A new event that will be sent | null.\n */\n beforeSend?(event: Event, hint?: EventHint): PromiseLike<Event | null> | Event | null;\n\n /**\n * A callback invoked when adding a breadcrumb, allowing to optionally modify\n * it before adding it to future events.\n *\n * Note that you must return a valid breadcrumb from this callback. If you do\n * not wish to modify the breadcrumb, simply return it at the end.\n * Returning null will cause the breadcrumb to be dropped.\n *\n * @param breadcrumb The breadcrumb as created by the SDK.\n * @returns The breadcrumb that will be added | null.\n */\n beforeBreadcrumb?(breadcrumb: Breadcrumb, hint?: BreadcrumbHint): Breadcrumb | null;\n}\n"]}
package/esm/request.d.ts CHANGED
@@ -1,4 +1,6 @@
1
- /** JSDoc */
1
+ /**
2
+ * Request data included in an event as sent to Sentry
3
+ */
2
4
  export interface Request {
3
5
  url?: string;
4
6
  method?: string;
@@ -1 +1 @@
1
- {"version":3,"file":"request.d.ts","sourceRoot":"","sources":["../src/request.ts"],"names":[],"mappings":"AAAA,YAAY;AACZ,MAAM,WAAW,OAAO;IACtB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,IAAI,CAAC,EAAE,GAAG,CAAC;IACX,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,OAAO,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;IACpC,GAAG,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;IAChC,OAAO,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;CACrC"}
1
+ {"version":3,"file":"request.d.ts","sourceRoot":"","sources":["../src/request.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,WAAW,OAAO;IACtB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,IAAI,CAAC,EAAE,GAAG,CAAC;IACX,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,OAAO,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;IACpC,GAAG,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;IAChC,OAAO,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;CACrC"}
@@ -1 +1 @@
1
- {"version":3,"file":"request.js","sourceRoot":"","sources":["../src/request.ts"],"names":[],"mappings":"","sourcesContent":["/** JSDoc */\nexport interface Request {\n url?: string;\n method?: string;\n data?: any;\n query_string?: string;\n cookies?: { [key: string]: string };\n env?: { [key: string]: string };\n headers?: { [key: string]: string };\n}\n"]}
1
+ {"version":3,"file":"request.js","sourceRoot":"","sources":["../src/request.ts"],"names":[],"mappings":"","sourcesContent":["/**\n * Request data included in an event as sent to Sentry\n */\nexport interface Request {\n url?: string;\n method?: string;\n data?: any;\n query_string?: string;\n cookies?: { [key: string]: string };\n env?: { [key: string]: string };\n headers?: { [key: string]: string };\n}\n"]}
package/esm/scope.d.ts CHANGED
@@ -91,7 +91,7 @@ export interface Scope {
91
91
  */
92
92
  getSpan(): Span | undefined;
93
93
  /**
94
- * Returns the `Transaction` if there is one
94
+ * Returns the `Transaction` attached to the scope (if there is one)
95
95
  */
96
96
  getTransaction(): Transaction | undefined;
97
97
  /**
package/esm/scope.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"scope.js","sourceRoot":"","sources":["../src/scope.ts"],"names":[],"mappings":"","sourcesContent":["import { Breadcrumb } from './breadcrumb';\nimport { EventProcessor } from './eventprocessor';\nimport { Extra, Extras } from './extra';\nimport { Severity } from './severity';\nimport { Span } from './span';\nimport { Transaction } from './transaction';\nimport { User } from './user';\n\n/** JSDocs */\nexport type CaptureContext = Scope | Partial<ScopeContext> | ((scope: Scope) => Scope);\n\n/** JSDocs */\nexport interface ScopeContext {\n user: User;\n level: Severity;\n extra: { [key: string]: any };\n contexts: { [key: string]: any };\n tags: { [key: string]: string };\n fingerprint: string[];\n}\n\n/**\n * Holds additional event information. {@link Scope.applyToEvent} will be\n * called by the client before an event will be sent.\n */\nexport interface Scope {\n /** Add new event processor that will be called after {@link applyToEvent}. */\n addEventProcessor(callback: EventProcessor): this;\n\n /**\n * Updates user context information for future events.\n *\n * @param user User context object to be set in the current context. Pass `null` to unset the user.\n */\n setUser(user: User | null): this;\n\n /**\n * Set an object that will be merged sent as tags data with the event.\n * @param tags Tags context object to merge into current context.\n */\n setTags(tags: { [key: string]: string }): this;\n\n /**\n * Set key:value that will be sent as tags data with the event.\n * @param key String key of tag\n * @param value String value of tag\n */\n setTag(key: string, value: string): this;\n\n /**\n * Set an object that will be merged sent as extra data with the event.\n * @param extras Extras object to merge into current context.\n */\n setExtras(extras: Extras): this;\n\n /**\n * Set key:value that will be sent as extra data with the event.\n * @param key String of extra\n * @param extra Any kind of data. This data will be normailzed.\n */\n setExtra(key: string, extra: Extra): this;\n\n /**\n * Sets the fingerprint on the scope to send with the events.\n * @param fingerprint string[] to group events in Sentry.\n */\n setFingerprint(fingerprint: string[]): this;\n\n /**\n * Sets the level on the scope for future events.\n * @param level string {@link Severity}\n */\n setLevel(level: Severity): this;\n\n /**\n * Sets the transaction name on the scope for future events.\n */\n setTransactionName(name?: string): this;\n\n /**\n * Sets context data with the given name.\n * @param name of the context\n * @param context Any kind of data. This data will be normailzed.\n */\n setContext(name: string, context: { [key: string]: any } | null): this;\n\n /**\n * Sets the Span on the scope.\n * @param span Span\n */\n setSpan(span?: Span): this;\n\n /**\n * Returns the `Span` if there is one\n */\n getSpan(): Span | undefined;\n\n /**\n * Returns the `Transaction` if there is one\n */\n getTransaction(): Transaction | undefined;\n\n /**\n * Updates the scope with provided data. Can work in three variations:\n * - plain object containing updatable attributes\n * - Scope instance that'll extract the attributes from\n * - callback function that'll receive the current scope as an argument and allow for modifications\n * @param captureContext scope modifier to be used\n */\n update(captureContext?: CaptureContext): this;\n\n /** Clears the current scope and resets its properties. */\n clear(): this;\n\n /**\n * Sets the breadcrumbs in the scope\n * @param breadcrumbs Breadcrumb\n * @param maxBreadcrumbs number of max breadcrumbs to merged into event.\n */\n addBreadcrumb(breadcrumb: Breadcrumb, maxBreadcrumbs?: number): this;\n\n /**\n * Clears all currently set Breadcrumbs.\n */\n clearBreadcrumbs(): this;\n}\n"]}
1
+ {"version":3,"file":"scope.js","sourceRoot":"","sources":["../src/scope.ts"],"names":[],"mappings":"","sourcesContent":["import { Breadcrumb } from './breadcrumb';\nimport { EventProcessor } from './eventprocessor';\nimport { Extra, Extras } from './extra';\nimport { Severity } from './severity';\nimport { Span } from './span';\nimport { Transaction } from './transaction';\nimport { User } from './user';\n\n/** JSDocs */\nexport type CaptureContext = Scope | Partial<ScopeContext> | ((scope: Scope) => Scope);\n\n/** JSDocs */\nexport interface ScopeContext {\n user: User;\n level: Severity;\n extra: { [key: string]: any };\n contexts: { [key: string]: any };\n tags: { [key: string]: string };\n fingerprint: string[];\n}\n\n/**\n * Holds additional event information. {@link Scope.applyToEvent} will be\n * called by the client before an event will be sent.\n */\nexport interface Scope {\n /** Add new event processor that will be called after {@link applyToEvent}. */\n addEventProcessor(callback: EventProcessor): this;\n\n /**\n * Updates user context information for future events.\n *\n * @param user User context object to be set in the current context. Pass `null` to unset the user.\n */\n setUser(user: User | null): this;\n\n /**\n * Set an object that will be merged sent as tags data with the event.\n * @param tags Tags context object to merge into current context.\n */\n setTags(tags: { [key: string]: string }): this;\n\n /**\n * Set key:value that will be sent as tags data with the event.\n * @param key String key of tag\n * @param value String value of tag\n */\n setTag(key: string, value: string): this;\n\n /**\n * Set an object that will be merged sent as extra data with the event.\n * @param extras Extras object to merge into current context.\n */\n setExtras(extras: Extras): this;\n\n /**\n * Set key:value that will be sent as extra data with the event.\n * @param key String of extra\n * @param extra Any kind of data. This data will be normailzed.\n */\n setExtra(key: string, extra: Extra): this;\n\n /**\n * Sets the fingerprint on the scope to send with the events.\n * @param fingerprint string[] to group events in Sentry.\n */\n setFingerprint(fingerprint: string[]): this;\n\n /**\n * Sets the level on the scope for future events.\n * @param level string {@link Severity}\n */\n setLevel(level: Severity): this;\n\n /**\n * Sets the transaction name on the scope for future events.\n */\n setTransactionName(name?: string): this;\n\n /**\n * Sets context data with the given name.\n * @param name of the context\n * @param context Any kind of data. This data will be normailzed.\n */\n setContext(name: string, context: { [key: string]: any } | null): this;\n\n /**\n * Sets the Span on the scope.\n * @param span Span\n */\n setSpan(span?: Span): this;\n\n /**\n * Returns the `Span` if there is one\n */\n getSpan(): Span | undefined;\n\n /**\n * Returns the `Transaction` attached to the scope (if there is one)\n */\n getTransaction(): Transaction | undefined;\n\n /**\n * Updates the scope with provided data. Can work in three variations:\n * - plain object containing updatable attributes\n * - Scope instance that'll extract the attributes from\n * - callback function that'll receive the current scope as an argument and allow for modifications\n * @param captureContext scope modifier to be used\n */\n update(captureContext?: CaptureContext): this;\n\n /** Clears the current scope and resets its properties. */\n clear(): this;\n\n /**\n * Sets the breadcrumbs in the scope\n * @param breadcrumbs Breadcrumb\n * @param maxBreadcrumbs number of max breadcrumbs to merged into event.\n */\n addBreadcrumb(breadcrumb: Breadcrumb, maxBreadcrumbs?: number): this;\n\n /**\n * Clears all currently set Breadcrumbs.\n */\n clearBreadcrumbs(): this;\n}\n"]}
@@ -1,8 +1,12 @@
1
+ import { ExtractedNodeRequestData, WorkerLocation } from './misc';
1
2
  import { Span, SpanContext } from './span';
2
3
  /**
3
4
  * Interface holding Transaction-specific properties
4
5
  */
5
6
  export interface TransactionContext extends SpanContext {
7
+ /**
8
+ * Human-readable identifier for the transaction
9
+ */
6
10
  name: string;
7
11
  /**
8
12
  * If true, sets the end timestamp of the transaction to the highest timestamp of child spans, trimming
@@ -11,7 +15,15 @@ export interface TransactionContext extends SpanContext {
11
15
  * transaction after a given "idle time" and we don't want this "idle time" to be part of the transaction.
12
16
  */
13
17
  trimEnd?: boolean;
18
+ /**
19
+ * If this transaction has a parent, the parent's sampling decision
20
+ */
21
+ parentSampled?: boolean;
14
22
  }
23
+ /**
24
+ * Data pulled from a `sentry-trace` header
25
+ */
26
+ export declare type TraceparentData = Pick<TransactionContext, 'traceId' | 'parentSpanId' | 'parentSampled'>;
15
27
  /**
16
28
  * Transaction "Class", inherits Span only has `setName`
17
29
  */
@@ -45,4 +57,34 @@ export interface Transaction extends TransactionContext, Span {
45
57
  */
46
58
  setName(name: string): void;
47
59
  }
60
+ /**
61
+ * Context data passed by the user when starting a transaction, to be used by the tracesSampler method.
62
+ */
63
+ export interface CustomSamplingContext {
64
+ [key: string]: any;
65
+ }
66
+ /**
67
+ * Data passed to the `tracesSampler` function, which forms the basis for whatever decisions it might make.
68
+ *
69
+ * Adds default data to data provided by the user. See {@link Hub.startTransaction}
70
+ */
71
+ export interface SamplingContext extends CustomSamplingContext {
72
+ /**
73
+ * Context data with which transaction being sampled was created
74
+ */
75
+ transactionContext: TransactionContext;
76
+ /**
77
+ * Sampling decision from the parent transaction, if any.
78
+ */
79
+ parentSampled?: boolean;
80
+ /**
81
+ * Object representing the URL of the current page or worker script. Passed by default in a browser or service worker
82
+ * context.
83
+ */
84
+ location?: WorkerLocation;
85
+ /**
86
+ * Object representing the incoming request to a node server. Passed by default when using the TracingHandler.
87
+ */
88
+ request?: ExtractedNodeRequestData;
89
+ }
48
90
  //# sourceMappingURL=transaction.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"transaction.d.ts","sourceRoot":"","sources":["../src/transaction.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAC;AAE3C;;GAEG;AACH,MAAM,WAAW,kBAAmB,SAAQ,WAAW;IACrD,IAAI,EAAE,MAAM,CAAC;I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AAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;IAEhC;;OAEG;IACH,IAAI,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;KAAE,CAAC;IAE7B;;OAEG;IACH,OAAO,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,CAAC;CAC7B;AAED;;GAEG;AACH,MAAM,WAAW,qBAAqB;IACpC,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAC;CACpB;AAED;;;;GAIG;AACH,MAAM,WAAW,eAAgB,SAAQ,qBAAqB;IAC5D;;OAEG;IACH,kBAAkB,EAAE,kBAAkB,CAAC;IAEvC;;OAEG;IACH,aAAa,CAAC,EAAE,OAAO,CAAC;IAExB;;;OAGG;IACH,QAAQ,CAAC,EAAE,cAAc,CAAC;IAE1B;;OAEG;IACH,OAAO,CAAC,EAAE,wBAAwB,CAAC;CACpC"}
@@ -1 +1 @@
1
- {"version":3,"file":"transaction.js","sourceRoot":"","sources":["../src/transaction.ts"],"names":[],"mappings":"","sourcesContent":["import { Span, SpanContext } from './span';\n\n/**\n * Interface holding Transaction-specific properties\n */\nexport interface TransactionContext extends SpanContext {\n name: string;\n /**\n * If true, sets the end timestamp of the transaction to the highest timestamp of child spans, trimming\n * the duration of the transaction. This is useful to discard extra time in the transaction that is not\n * accounted for in child spans, like what happens in the idle transaction Tracing integration, where we finish the\n * transaction after a given \"idle time\" and we don't want this \"idle time\" to be part of the transaction.\n */\n trimEnd?: boolean;\n}\n\n/**\n * Transaction \"Class\", inherits Span only has `setName`\n */\nexport interface Transaction extends TransactionContext, Span {\n /**\n * @inheritDoc\n */\n spanId: string;\n\n /**\n * @inheritDoc\n */\n traceId: string;\n\n /**\n * @inheritDoc\n */\n startTimestamp: number;\n\n /**\n * @inheritDoc\n */\n tags: { [key: string]: string };\n\n /**\n * @inheritDoc\n */\n data: { [key: string]: any };\n\n /**\n * Set the name of the transaction\n */\n setName(name: string): void;\n}\n"]}
1
+ {"version":3,"file":"transaction.js","sourceRoot":"","sources":["../src/transaction.ts"],"names":[],"mappings":"","sourcesContent":["import { ExtractedNodeRequestData, WorkerLocation } from './misc';\nimport { Span, SpanContext } from './span';\n\n/**\n * Interface holding Transaction-specific properties\n */\nexport interface TransactionContext extends SpanContext {\n /**\n * Human-readable identifier for the transaction\n */\n name: string;\n\n /**\n * If true, sets the end timestamp of the transaction to the highest timestamp of child spans, trimming\n * the duration of the transaction. This is useful to discard extra time in the transaction that is not\n * accounted for in child spans, like what happens in the idle transaction Tracing integration, where we finish the\n * transaction after a given \"idle time\" and we don't want this \"idle time\" to be part of the transaction.\n */\n trimEnd?: boolean;\n\n /**\n * If this transaction has a parent, the parent's sampling decision\n */\n parentSampled?: boolean;\n}\n\n/**\n * Data pulled from a `sentry-trace` header\n */\nexport type TraceparentData = Pick<TransactionContext, 'traceId' | 'parentSpanId' | 'parentSampled'>;\n\n/**\n * Transaction \"Class\", inherits Span only has `setName`\n */\nexport interface Transaction extends TransactionContext, Span {\n /**\n * @inheritDoc\n */\n spanId: string;\n\n /**\n * @inheritDoc\n */\n traceId: string;\n\n /**\n * @inheritDoc\n */\n startTimestamp: number;\n\n /**\n * @inheritDoc\n */\n tags: { [key: string]: string };\n\n /**\n * @inheritDoc\n */\n data: { [key: string]: any };\n\n /**\n * Set the name of the transaction\n */\n setName(name: string): void;\n}\n\n/**\n * Context data passed by the user when starting a transaction, to be used by the tracesSampler method.\n */\nexport interface CustomSamplingContext {\n [key: string]: any;\n}\n\n/**\n * Data passed to the `tracesSampler` function, which forms the basis for whatever decisions it might make.\n *\n * Adds default data to data provided by the user. See {@link Hub.startTransaction}\n */\nexport interface SamplingContext extends CustomSamplingContext {\n /**\n * Context data with which transaction being sampled was created\n */\n transactionContext: TransactionContext;\n\n /**\n * Sampling decision from the parent transaction, if any.\n */\n parentSampled?: boolean;\n\n /**\n * Object representing the URL of the current page or worker script. Passed by default in a browser or service worker\n * context.\n */\n location?: WorkerLocation;\n\n /**\n * Object representing the incoming request to a node server. Passed by default when using the TracingHandler.\n */\n request?: ExtractedNodeRequestData;\n}\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sentry/types",
3
- "version": "5.22.3",
3
+ "version": "5.24.2",
4
4
  "description": "Types for all Sentry JavaScript SDKs",
5
5
  "repository": "git://github.com/getsentry/sentry-javascript.git",
6
6
  "homepage": "https://github.com/getsentry/sentry-javascript/tree/master/packages/types",
@@ -16,7 +16,7 @@
16
16
  "access": "public"
17
17
  },
18
18
  "devDependencies": {
19
- "@sentry-internal/eslint-config-sdk": "5.22.3",
19
+ "@sentry-internal/eslint-config-sdk": "5.24.2",
20
20
  "eslint": "7.6.0",
21
21
  "npm-run-all": "^4.1.2",
22
22
  "prettier": "1.19.0",