/** * @deprecated The symbol `DevRevSDK` has been deprecated. Use `DevRev` instead. */ export declare const DevRevSDK: any; import type { ArticleSearchFilter, ArticleSearchFilterOperand, ArticleSearchFilterOperandValue, ArticleSearchFilters, ConversationPageOptions, FeatureConfiguration, FilterOperator, FilterValueType, Identity, SupportWidgetTheme, UserTraits, OrganizationTraits, AccountTraits } from './types'; export type { ArticleSearchFilter, ArticleSearchFilterOperand, ArticleSearchFilterOperandValue, ArticleSearchFilters, ConversationPageOptions, FeatureConfiguration, FilterOperator, FilterValueType, Identity, SupportWidgetTheme, UserTraits, OrganizationTraits, AccountTraits, }; /** * Configures the SDK with the app ID and optional feature configuration. * * This is a mandatory method before using any other features. * * @param appID An identifier unique to your app. * @param featureConfiguration Optional feature configuration for the SDK. * * @category Configuration */ export declare function configure(appID: string, featureConfiguration?: FeatureConfiguration): void; /** * Updates the feature configuration for the SDK. * * This method can be called after the SDK has been configured to update * the feature configuration. Pass a full feature configuration object. * * @param featureConfiguration The full feature configuration to apply. * * @category Configuration */ export declare function updateFeatureConfiguration(featureConfiguration: FeatureConfiguration): void; /** * Identifies a non-verified user after the SDK has been configured. * * The identification method should be called when you receive a callback or you have your user's data ready. * * @remarks * Make sure that you have called the `configure(appID)` method before. * * @param userID - A string used to identify the user (can be an email). * @param organizationID - An optional unique identifier of the organization the user belongs to. * * @category Identification */ export declare function identifyUnverifiedUser(userID: string, organizationID?: string): void; /** * Identifies a verified user after the SDK has been configured. * * The verification process is done between your and DevRev's backend. * The identification method should be called when you receive a callback or you have your user's data ready. * * @remarks * Make sure that you have called the `configure(appID)` method before. * * @param userID - A string used to identify the user (can be an email). * @param sessionToken - A session token generated by your backend. * * @category Identification */ export declare function identifyVerifiedUser(userID: string, sessionToken: string): void; /** * Identifies an anonymous user after the SDK has been configured. * * The identification method should be called when you receive a callback or you have your user's data ready. * * @deprecated Use {@link identifyUnverifiedUser} instead: * ```ts * identifyUnverifiedUser(userId); * ``` * * @remarks * Make sure that you have called the `configure(appID)` method before. * * @param userID - A string used to identify the user (can be an email). * * @category Identification */ export declare function identifyAnonymousUser(userID: string): void; /** * Updates the user information with the provided identity. * * This method should be called to update the user's information after the SDK has been configured. * * @remarks * Make sure that you have called the `configure(appID)` method before. * The `userID` property can *not* be updated. * * @param identity - An object containing the user's identity information. * * @category Identification */ export declare function updateUser(identity: Identity): void; /** * Logs out the current identified user and resets the session. * The process will also unregister the user's device from receiving push notifications, and stop any ongoing * session recording. * * @param deviceID - A unique device ID. This should be either an identifier **unique** to your system, or the app vendor * identifier i.e. Android ID (`Settings.Secure.ANDROID_ID`) for Android and IDFV (`UIDevice.identifierForVendor`) for iOS, * or Firebase installation ID. * * @see {@link https://developer.apple.com/documentation/uikit/uidevice/1620059-identifierforvendor/ UIDevice.identifierForVendor} * @see {@link https://developer.android.com/reference/android/provider/Settings.Secure#ANDROID_ID Settings.Secure.ANDROID_ID} * @see {@link https://firebase.google.com/docs/projects/manage-installations#monitor-id-lifecycle Firebase installation ID} * * @category Identification */ export declare function logout(deviceID: string): void; /** * Presents the support feature modally. * * @category Support */ export declare function showSupport(): void; /** * Creates a new support conversation and presents it modally. * * @param prefillMessage - An optional message to pre-fill in the conversation input. * * @category Support */ export declare function createSupportConversation(prefillMessage?: string): void; /** * Tracks an event with the given name and properties. * * This method should be called to log custom events in the application. * * @remarks * Make sure that you have called the `configure(appID)` method before. * * @param name - The name of the event to be tracked. * @param properties - An object containing additional properties for the event. * * @category Analytics */ export declare function trackEvent(name: string, properties?: { [key: string]: string; }): void; /** * Starts a user session recording. * * @remarks * Make sure that you have called the `configure(appID)` method before. * * @category Session recording */ export declare function startRecording(): void; /** * Stops an ongoing user recording sessions and uploads the session to the portal. * * @category Session recording */ export declare function stopRecording(): void; /** * Pauses the ongoing user recording session. * * @category Session recording */ export declare function pauseRecording(): void; /** * Resumes a paused recording session. * * @category Session recording */ export declare function resumeRecording(): void; /** * Pauses user interaction tracking. * * @category Session recording */ export declare function pauseUserInteractionTracking(): void; /** * Resumes user interaction tracking. * * @category Session recording */ export declare function resumeUserInteractionTracking(): void; /** * Adds properties to the session. The properties will be sent along any analytic events. * * Any new properties in the map will be added to the session properties. If a property already exists, the * new value takes precedence and will override the existing value. * * @remarks * - Any date that would be a part of the properties map **should** be sent in the `YYYY/MM/DD` format. * - In cases when you want to clear out the stored session properties, you can call the `clearSessionProperties()` method. * * @param properties - A map of custom session properties. * * @category Session properties */ export declare function addSessionProperties(properties: { [key: string]: string; }): void; /** * Clears the session properties. * * @category Session properties */ export declare function clearSessionProperties(): void; /** * Mark the passed view tags as sensitive. * * The views will be shown as masked in the portal playbacks. * * @param tags - An array of tags that should be masked. * * @category Sensitive field masking */ export declare function markSensitiveViews(tags: any[]): void; /** * Unmark the passed view tags as being sensitive. * * They will no longer be shown as masked in the portal playbacks, unless they are auto masked. * * @param tags - An array of views you want to stop masking. * * @category Sensitive field masking */ export declare function unmarkSensitiveViews(tags: any[]): void; /** * Starts a timer at any point in the app in order to measure time metrics for events such as load or response time. * * This method needs to be balanced with an `endTimer(name, properties)` method call. * * @param name - A timer name. The timer name can have up to 250 characters. * @param properties - A property map. * * @category Timer control */ export declare function startTimer(name: string, properties: { [key: string]: string; }): void; /** * Ends a previously started timer. * * This method will calculate the complete time from the start of the event. The method acts as a balanced call to * `startTimer(name, properties)`. * * @param name - A timer name. The timer name can have up to 250 characters. * @param properties - A property map. * * @category Timer control */ export declare function endTimer(name: string, properties: { [key: string]: string; }): void; /** * Sets a flag that resumes the session monitoring. * * The main purpose of this method is to get the consent (opt-in) of the end-user that their session will be monitored * and data might be collected. * * @remarks * - The monitoring flag is **opt-in** by default. In case you want to opt-out of the automatic monitoring, * it is your responsibility to call the `stopAllMonitoring()` method at the place of your convenience. * - This method will only store a monitoring permission flag, it will **not** provide any UI or dialog. * The responsibility of implementing a UI is yours as a developer integrating the SDK. * * @see `stopAllMonitoring()` * * @category Monitoring */ export declare function resumeAllMonitoring(): void; /** * Sets a flag that stops all session monitoring. * * The method will revoke the consent given by the end-users for monitoring their sessions. * * @remarks * - The monitoring flag is **opt-in** by default. In case you want to opt-out of the automatic monitoring, * it is your responsibility to call the `stopAllMonitoring()` method at the place of your convenience. * - This method will only store a monitoring permission flag, it will **not** provide any UI or dialog. * The responsibility of implementing a UI is yours as a developer integrating the SDK. * * @see `resumeAllMonitoring()` * * @category Monitoring */ export declare function stopAllMonitoring(): void; /** * Sets a flag that controls whether the modals should be dismissed after an in-app link is opened. * * @param value - A flag controling whether modals are dismissed when opening a link. * * @category In-app link handling */ export declare function setShouldDismissModalsOnOpenLink(value: boolean): void; /** * Sets a flag uses the default theme for the support feature. * * @param value - A flag to enforce the preferred theme for the DevRev UI, overriding system theme when enabled. * * @category Dynamic theme configuration */ export declare function setPrefersSystemTheme(value: boolean): void; /** * Manually tracks a screen name for identification. * * While view controllers are automatically defined as screens by the DevRev SDK, there might be cases when you need * to manually track certain screens. * This function allows you to manually track the screens that will be missed during the auto-capture process. * * @param name - A string value of the screen name. * * @deprecated This method is deprecated. Use `trackScreenName()` instead. * * @category Screen tracking */ export declare function trackScreen(name: string): void; /** * Manually tracks a screen name for identification. * * While view controllers are automatically defined as screens by the DevRev SDK, there might be cases when you need * to manually track certain screens. * This function allows you to manually track the screens that will be missed during the auto-capture process. * * @param screenName - A string value of the screen name. * * @category Screen tracking */ export declare function trackScreenName(screenName: string): void; /** * Registers the device token provided by the native platform for receiving push notifications from DevRev. * * @param deviceToken - The device token as provided by the native platform. * @param deviceID - A unique device ID. This should be either an identifier **unique** to your system, or the app vendor * identifier i.e. Android ID (`Settings.Secure.ANDROID_ID`) for Android and IDFV (`UIDevice.identifierForVendor`) for iOS, or Firebase installation ID. * * @see {@link https://developer.apple.com/documentation/uikit/uidevice/1620059-identifierforvendor/ UIDevice.identifierForVendor} * @see {@link https://developer.android.com/reference/android/provider/Settings.Secure#ANDROID_ID Settings.Secure.ANDROID_ID} * @see {@link https://firebase.google.com/docs/projects/manage-installations#monitor-id-lifecycle Firebase installation ID} * * @category Push notifications */ export declare function registerDeviceToken(deviceToken: string, deviceID: string): void; /** * Unregisters the device from receiving push notifications from DevRev. * * @param deviceID - A unique device ID. This should be either an identifier **unique** to your system, or the app vendor * identifier i.e. Android ID (`Settings.Secure.ANDROID_ID`) for Android and IDFV (`UIDevice.identifierForVendor`) for iOS, or Firebase installation ID. * * @see {@link https://developer.apple.com/documentation/uikit/uidevice/1620059-identifierforvendor/ UIDevice.identifierForVendor} * @see {@link https://developer.android.com/reference/android/provider/Settings.Secure#ANDROID_ID Settings.Secure.ANDROID_ID} * @see {@link https://firebase.google.com/docs/projects/manage-installations#monitor-id-lifecycle Firebase installation ID} * * @category Push notifications */ export declare function unregisterDevice(deviceID: string): void; /** * Processes the push notification and performs the necessary actions. * * @param payload - The push notification JSON payload. * * @category Push notifications */ export declare function processPushNotification(payload: string): void; /** * Captures an error with automatic stack trace extraction. * This is the recommended method for capturing errors - simply pass the error object and tag. * * The function automatically: * - Extracts the error message from Error objects or uses the string directly * - Extracts the stack trace from Error objects * - Passes everything to the native SDK which handles stack trace processing * * @param error - The error object (Error instance) or error message string * @param tag - Tag to categorize the exception (e.g., 'login-failure', 'api-error') * * @remarks * Make sure that you have called the `configure(appID)` method before. * * @category Error capture */ export declare function captureError(error: Error | string, tag: string): void; /** * An optional in app links handler for external URLs, deeplinks, etc. in the PLuG support widget. * * @param handler: callback that receives URL */ export declare function setInAppLinkHandler(handler: (url: string) => void): (() => void) | null; /** * Marks the beginning of a screen transition. * * This method should be called when a screen transition starts. It helps track UI navigation events * and ensures that relevant actions are delayed until the transition is complete. * * @remarks * - It is the developer's responsibility to call this method at the appropriate time in the navigation flow. * * @category Screen transition * * @deprecated This method is deprecated. Use `setInScreenTransitioning(true)` instead. */ export declare function startScreenTransition(): void; /** * Marks the end of a screen transition. * * This method should be called when a screen transition completes. It ensures that the application * can resume any actions that were delayed due to the transition. * * @remarks * - It is the developer's responsibility to call this method at the appropriate time in the navigation flow. * * @category Screen transition * * @deprecated This method is deprecated. Use `setInScreenTransitioning(false)` instead. */ export declare function endScreenTransition(): void; /** * Sets the screen transition state of the application. * * This method marks whether the application is currently undergoing a screen transition, * allowing event tracking and UI updates to be managed accordingly. * * @param inScreenTransitioning A boolean flag indicating if the screen is in transition. * * @category Screen Transition */ export declare function setInScreenTransitioning(value: boolean): void; /** * Processes all on-demand sessions. * * This method triggers the processing of all on-demand sessions, ensuring that any recorded data * is handled appropriately. It is typically used when sessions need to be uploaded. * * @remarks * - It is the developer's responsibility to call this method at the appropriate time in the app's lifecycle. * * @category Session Upload */ export declare function processAllOnDemandSessions(): void; //# sourceMappingURL=index.d.ts.map