import { RiskIntelligenceErrorCode } from "./error"; import { APIEndpoint } from "./widget"; /** * Options for configuring a Risk Intelligence request. * @public */ export interface RiskIntelligenceOptions { /** * Sitekey of your application, starts with `FC`. */ sitekey: string; /** * A custom endpoint from which the agent is loaded and to which Risk Intelligence * requests are made. */ apiEndpoint?: APIEndpoint; /** * Whether to bypass the token cache and force the request of a new token from the * API. */ bypassCache?: boolean; } /** * Options for clearing cached Risk Intelligence tokens. * @public */ export interface RiskIntelligenceClearOptions { /** * Sitekey of your application, starts with `FC`. Tokens associated with this application * will be cleared. If not passed, all tokens will be cleared. */ sitekey?: string; /** * Tokens generated by this API endpoint will be cleared. */ apiEndpoint?: APIEndpoint; } /** * Data returned by the Risk Intelligence API request. * @public */ export interface RiskIntelligenceGenerateData { /** * The Risk Intelligence token, which can be used to retrieve Risk Intelligence * from the Friendly Captcha API. */ token: string; /** * A timestamp, represented as a Unix epoch, for when the Risk Intelligence token will expire. */ expiresAt: number; } /** * Error data returned by a failed Risk Intelligence request. * @public */ export interface RiskIntelligenceErrorData { /** * The error code. */ code: RiskIntelligenceErrorCode; /** * More details about the error to help debugging. * This value is not localized and will change between versions. * * You can print this to the console, but make sure not to depend on it in your code. */ detail: string; } //# sourceMappingURL=riskIntelligence.d.ts.map