Crypto SDK
    Preparing search index...

    Interface ClientOptions

    TypeScript SDK for the Crypto Service Suite v2 API.

    Zero-dependency, fetch-based typed client for all cryptographic operations.

    import { CryptoClient } from '@sebastienrousseau/crypto-sdk';

    const client = new CryptoClient({ baseUrl: 'http://localhost:3000' });
    const { data } = await client.hash({ algorithm: 'sha256', data: 'hello' });
    console.log(data.digest);
    interface ClientOptions {
        baseUrl: string;
        apiKey?: string;
        token?: string;
        fetch?: (
            input: string | URL | Request,
            init?: RequestInit,
        ) => Promise<Response>;
    }
    Index
    baseUrl: string

    Base URL of the crypto server (e.g., "http://localhost:3000").

    apiKey?: string

    API key for x-api-key header authentication.

    token?: string

    JWT Bearer token for Authorization header.

    fetch?: (input: string | URL | Request, init?: RequestInit) => Promise<Response>

    Custom fetch implementation (defaults to global fetch).