/// <reference types="react" />
import { BCTurnstileRef } from '../../generic/components/BCTurnstile';
export interface UseTurnstileResult {
    /** The current turnstile token, or null if not verified */
    token: string | null;
    /** Whether turnstile verification is in progress */
    isVerifying: boolean;
    /** Whether turnstile verification has failed */
    hasError: boolean;
    /** Reset the turnstile widget and token */
    reset: () => void;
    /** Callback for when turnstile verification succeeds */
    onSuccess: (token: string) => void;
    /** Callback for when turnstile verification fails */
    onError: () => void;
    /** Callback for when turnstile token expires */
    onExpire: () => void;
    /** The turnstile site key from config */
    siteKey: string;
    /** Reference to attach to BCTurnstile component */
    turnstileRef: React.RefObject<BCTurnstileRef>;
}
/**
 * Hook for managing Cloudflare Turnstile verification state
 *
 * Usage:
 * ```tsx
 * const { token, isVerifying, hasError, reset, onSuccess, onError, onExpire, siteKey, turnstileRef } = useTurnstile();
 *
 * // In your JSX:
 * <BCTurnstile
 *   ref={turnstileRef}
 *   siteKey={siteKey}
 *   onSuccess={onSuccess}
 *   onError={onError}
 *   onExpire={onExpire}
 * />
 *
 * // In your submit handler:
 * const handleSubmit = () => {
 *   if (!token) {
 *     // Show error - turnstile not verified
 *     return;
 *   }
 *   // Call your mutation with turnstile: token
 *   checkout({ variables: { input: { ..., turnstile: token } } });
 * };
 * ```
 */
export declare function useTurnstile(): UseTurnstileResult;
export default useTurnstile;
