import { WebRequestTracer } from './WebRequestTracer'; /** * Action public interface */ export interface Action { /** * Report a value with given name to Dynatrace. * If the name or value is longer than 250 characters, it is truncated to this value. * * @param name The name of the reported value. * @param value The value to report. */ reportValue(name: string, value: number | string): void; /** * Report an event with a given name to Dynatrace. * If the name is longer than 250 characters, it is truncated to this length. * * @param name The name of the event */ reportEvent(name: string): void; /** * Allows tracing and timing of a web request handled by any HTTP Client * (e.g. XMLHttpRequest, fetch, 'http'-module, ...). * In this case the Dynatrace HTTP header ({@link webRequestTagHeader}) has to be set manually to the tag value of this * WebRequestTracer.
* If the web request is continued on a server-side Agent (e.g. Java, .NET, ...) this Session will be correlated to * the resulting server-side PurePath. * * @see {@link webRequestTagHeader} * @param url the URL of the web request to be tagged and timed * @return a WebRequestTracer which allows getting the tag value and adding timing information */ traceWebRequest(url: string): WebRequestTracer; /** * Reports an error with a specified name, error code and reason to Dynatrace. * If the message is longer than 1000 characters, it is truncated to this value. * * @param name The name of the error. * @param code The error code. */ reportError(name: string, code: number): void; /** * Leave the action. */ leaveAction(): null; } //# sourceMappingURL=Action.d.ts.map