react-native-efilli-sdk
Version:
Efilli SDK for React Native - Consent Management Solution
48 lines (47 loc) • 1.37 kB
TypeScript
import { ConsentResult } from './models';
import { NetworkManager } from './models';
export interface EfilliOptions {
endpointUrl: string;
language: string;
}
/**
* Main Efilli SDK interface
*/
export declare const EfilliSDK: {
/**
* Initialize the SDK with required parameters
* @param options Configuration options for the SDK
*/
initialize: (options: EfilliOptions) => Promise<void>;
/**
* Check if the SDK is initialized and ready
*/
isReady: () => Promise<boolean>;
/**
* Present the consent form to the user
* @returns Promise resolving with consent result
*/
showConsentForm: () => Promise<ConsentResult>;
/**
* Get the stored consent result
* @returns Promise resolving with consent result or null if not available
*/
getStoredConsent: () => Promise<ConsentResult | null>;
/**
* Change the SDK language
* @param language The language code to change to
*/
changeLanguage: (language: string) => Promise<void>;
/**
* Clear all stored consent data
*/
clearAllData: () => Promise<void>;
/**
* Close the SDK and clean up resources
*/
closeSDK: () => Promise<void>;
};
/**
* Network management functions for error reporting and connection detection
*/
export declare const EfilliNetwork: NetworkManager;