IntentGuard SDK
    Preparing search index...

    Interface IntentGuardButtonProps

    interface IntentGuardButtonProps {
        action: string;
        appId: PublicKey;
        className?: string;
        connection: Connection;
        onError?: (error: Error) => void;
        onVerified: (intentHash: number[]) => void;
        params: Record<string, string>;
        pollInterval?: number;
        ttl?: number;
        userPublicKey: PublicKey;
    }
    Index

    Properties

    action: string

    Action label (e.g., "swap", "transfer")

    appId: PublicKey

    Target app/program ID

    className?: string

    Custom class name

    connection: Connection

    Solana RPC connection

    onError?: (error: Error) => void

    Called on error

    onVerified: (intentHash: number[]) => void

    Called when intent is verified on-chain

    params: Record<string, string>

    Intent parameters — keys are sorted before hashing

    pollInterval?: number

    Poll interval in ms (default: 2000)

    ttl?: number

    TTL in seconds (default: 300)

    userPublicKey: PublicKey

    User's wallet public key