/**
 * RPC Provider types, enums, type guards, and Zod schemas.
 *
 * @packageDocumentation
 */
import { z } from "zod";
import { providers } from "ethers";
import { ConnectionInfo } from "ethers/lib/utils";
import type { AxiosRequestConfig } from "axios";
import type { ClientSession } from "@tinycloud/sdk-core";
/** Enum of supported EthersJS providers. */
export declare enum RPCProviders {
    AlchemyProvider = "alchemy",
    AnkrProvider = "ankr",
    CloudflareProvider = "cloudflare",
    CustomProvider = "custom",
    EtherscanProvider = "etherscan",
    InfuraProvider = "infura",
    PocketProvider = "pocket"
}
/** Enum of supported networks for Etherscan. */
export declare enum EtherscanProviderNetworks {
    MAINNET = "homestead",
    ROPSTEN = "ropsten",
    RINKEBY = "rinkeby",
    GOERLI = "goerli",
    KOVAN = "kovan"
}
/** Enum of supported networks for Infura. */
export declare enum InfuraProviderNetworks {
    MAINNET = "homestead",
    ROPSTEN = "ropsten",
    RINKEBY = "rinkeby",
    GOERLI = "goerli",
    KOVAN = "kovan",
    POLYGON = "matic",
    POLYGON_MUMBAI = "maticmum",
    OPTIMISM = "optimism",
    OPTIMISM_KOVAN = "optimism-kovan",
    ARBITRUM = "arbitrum",
    ARBITRUM_RINKEBY = "arbitrum-rinkeby"
}
/** Enum of supported networks for Alchemy. */
export declare enum AlchemyProviderNetworks {
    MAINNET = "homestead",
    ROPSTEN = "ropsten",
    RINKEBY = "rinkeby",
    GOERLI = "goerli",
    KOVAN = "kovan",
    POLYGON = "matic",
    POLYGON_MUMBAI = "maticmum",
    OPTIMISM = "optimism",
    OPTIMISM_KOVAN = "optimism-kovan",
    ARBITRUM = "arbitrum",
    ARBITRUM_RINKEBY = "arbitrum-rinkeby"
}
/** Enum of supported networks for Pocket. */
export declare enum PocketProviderNetworks {
    MAINNET = "homestead",
    ROPSTEN = "ropsten",
    RINKEBY = "rinkeby",
    GOERLI = "goerli"
}
/** Enum of supported networks for Ankr. */
export declare enum AnkrProviderNetworks {
    MAINNET = "homestead",
    POLYGON = "matic",
    ARBITRUM = "arbitrum"
}
/** Infura provider project settings. */
export type InfuraProviderProjectSettings = {
    projectId: string;
    projectSecret: string;
};
/** Etherscan provider settings. */
export type EtherscanProvider = {
    service: RPCProviders.EtherscanProvider;
    apiKey?: string;
    network?: EtherscanProviderNetworks;
};
/** Infura provider settings. */
export type InfuraProvider = {
    service: RPCProviders.InfuraProvider;
    apiKey: string | InfuraProviderProjectSettings;
    network?: InfuraProviderNetworks;
};
/** Alchemy provider settings. */
export type AlchemyProvider = {
    service: RPCProviders.AlchemyProvider;
    apiKey?: string;
    network?: AlchemyProviderNetworks;
};
/** Cloudflare provider settings. */
export type CloudflareProvider = {
    service: RPCProviders.CloudflareProvider;
};
/** Pocket provider settings. */
export type PocketProvider = {
    service: RPCProviders.PocketProvider;
    apiKey?: string;
    network?: PocketProviderNetworks;
};
/** Ankr provider settings. */
export type AnkrProvider = {
    service: RPCProviders.AnkrProvider;
    apiKey?: string;
    network?: AnkrProviderNetworks;
};
/** Custom provider settings. */
export type CustomProvider = {
    service: RPCProviders.CustomProvider;
    url?: string | ConnectionInfo;
    network?: providers.Networkish;
};
/** Generic provider settings. */
export type GenericProvider = {
    service: RPCProviders;
    url?: string | ConnectionInfo;
    network?: providers.Networkish;
    apiKey?: string | InfuraProviderProjectSettings;
};
/** Supported provider types. */
export type RPCProvider = GenericProvider | EtherscanProvider | InfuraProvider | AlchemyProvider | CloudflareProvider | PocketProvider | AnkrProvider | CustomProvider;
export declare const isEtherscanProvider: (provider: RPCProvider) => provider is EtherscanProvider;
export declare const isInfuraProvider: (provider: RPCProvider) => provider is InfuraProvider;
export declare const isAlchemyProvider: (provider: RPCProvider) => provider is AlchemyProvider;
export declare const isCloudflareProvider: (provider: RPCProvider) => provider is CloudflareProvider;
/** Type-Guard for PocketProvider. */
export declare const isPocketProvider: (provider: RPCProvider) => provider is PocketProvider;
/** Type-Guard for AnkrProvider. */
export declare const isAnkrProvider: (provider: RPCProvider) => provider is AnkrProvider;
/** Type-Guard for CustomProvider. */
export declare const isCustomProvider: (provider: RPCProvider) => provider is CustomProvider;
/** TCW Route Configuration.
 *  This configuration is used to override the default endpoint paths.
 * The config options here are a subset of the
 * [AxiosRequestConfig](https://axios-http.com/docs/req_config).
 * This type does not explicitly extend AxiosRequestConfig,
 * but those options are supported by the client.
 */
export interface RouteConfig {
    /** Endpoint path. */
    url?: string;
    /** Endpoint request method. */
    method?: "get" | "post" | "put" | "delete";
    /** Custom Operation.
     * Replace the tcw function called with a function of your own
     **/
    customAPIOperation?(params: ClientSession | Record<string, any> | any): Promise<any>;
}
export interface ServerMiddlewareConfig {
    path: string;
    callback?: (req: any, body?: Record<string, any>) => Promise<void> | void;
}
/** Type-Guard for ServerMiddlewareConfig. */
export declare const isServerMiddlewareConfig: (config: ServerRouteEndpointType) => config is ServerMiddlewareConfig;
export type ServerRouteEndpointType = Partial<RouteConfig> | AxiosRequestConfig | string | ServerMiddlewareConfig;
/** Server endpoints configuration. */
export interface ServerRoutes {
    /** Get nonce endpoint path. /tcw-nonce as default. */
    nonce?: ServerRouteEndpointType;
    /** Post login endpoint path. /tcw-login as default. */
    login?: ServerRouteEndpointType;
    /** Post logout endpoint path. /tcw-logout as default. */
    logout?: ServerRouteEndpointType;
}
/** Server endpoints name configuration. */
export interface ServerRouteNames {
    /** Get nonce endpoint path. /tcw-nonce as default. */
    nonce?: string;
    /** Post login endpoint path. /tcw-login as default. */
    login?: string;
    /** Post logout endpoint path. /tcw-logout as default. */
    logout?: string;
}
/** ENS data supported by TCW. */
export interface EnsData {
    /** ENS name/domain. */
    domain?: string | null;
    /** ENS avatar. */
    avatarUrl?: string | null;
}
/** ENS data schema. */
export declare const EnsDataSchema: z.ZodObject<{
    /** ENS name/domain. */
    domain: z.ZodOptional<z.ZodNullable<z.ZodString>>;
    /** ENS avatar. */
    avatarUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
}, "strip", z.ZodTypeAny, {
    domain?: string;
    avatarUrl?: string;
}, {
    domain?: string;
    avatarUrl?: string;
}>;
/** Enum of supported EthersJS providers (Zod schema). */
export declare const RPCProvidersSchema: z.ZodEnum<["alchemy", "ankr", "cloudflare", "custom", "etherscan", "infura", "pocket"]>;
/**
 * Enum values for RPCProviders (const object form).
 * Both the enum and const object exist and serve different purposes:
 * the enum for type-level discrimination, the const for runtime factory constructors.
 */
export declare const RPCProvidersConst: {
    readonly AlchemyProvider: "alchemy";
    readonly AnkrProvider: "ankr";
    readonly CloudflareProvider: "cloudflare";
    readonly CustomProvider: "custom";
    readonly EtherscanProvider: "etherscan";
    readonly InfuraProvider: "infura";
    readonly PocketProvider: "pocket";
};
export declare const EtherscanProviderNetworksSchema: z.ZodEnum<["homestead", "ropsten", "rinkeby", "goerli", "kovan"]>;
export declare const EtherscanProviderNetworksConst: {
    readonly MAINNET: "homestead";
    readonly ROPSTEN: "ropsten";
    readonly RINKEBY: "rinkeby";
    readonly GOERLI: "goerli";
    readonly KOVAN: "kovan";
};
export declare const InfuraProviderNetworksSchema: z.ZodEnum<["homestead", "ropsten", "rinkeby", "goerli", "kovan", "matic", "maticmum", "optimism", "optimism-kovan", "arbitrum", "arbitrum-rinkeby"]>;
export declare const InfuraProviderNetworksConst: {
    readonly MAINNET: "homestead";
    readonly ROPSTEN: "ropsten";
    readonly RINKEBY: "rinkeby";
    readonly GOERLI: "goerli";
    readonly KOVAN: "kovan";
    readonly POLYGON: "matic";
    readonly POLYGON_MUMBAI: "maticmum";
    readonly OPTIMISM: "optimism";
    readonly OPTIMISM_KOVAN: "optimism-kovan";
    readonly ARBITRUM: "arbitrum";
    readonly ARBITRUM_RINKEBY: "arbitrum-rinkeby";
};
export declare const AlchemyProviderNetworksSchema: z.ZodEnum<["homestead", "ropsten", "rinkeby", "goerli", "kovan", "matic", "maticmum", "optimism", "optimism-kovan", "arbitrum", "arbitrum-rinkeby"]>;
export declare const AlchemyProviderNetworksConst: {
    readonly MAINNET: "homestead";
    readonly ROPSTEN: "ropsten";
    readonly RINKEBY: "rinkeby";
    readonly GOERLI: "goerli";
    readonly KOVAN: "kovan";
    readonly POLYGON: "matic";
    readonly POLYGON_MUMBAI: "maticmum";
    readonly OPTIMISM: "optimism";
    readonly OPTIMISM_KOVAN: "optimism-kovan";
    readonly ARBITRUM: "arbitrum";
    readonly ARBITRUM_RINKEBY: "arbitrum-rinkeby";
};
export declare const PocketProviderNetworksSchema: z.ZodEnum<["homestead", "ropsten", "rinkeby", "goerli"]>;
export declare const PocketProviderNetworksConst: {
    readonly MAINNET: "homestead";
    readonly ROPSTEN: "ropsten";
    readonly RINKEBY: "rinkeby";
    readonly GOERLI: "goerli";
};
export declare const AnkrProviderNetworksSchema: z.ZodEnum<["homestead", "matic", "arbitrum"]>;
export declare const AnkrProviderNetworksConst: {
    readonly MAINNET: "homestead";
    readonly POLYGON: "matic";
    readonly ARBITRUM: "arbitrum";
};
export declare const InfuraProviderProjectSettingsSchema: z.ZodObject<{
    projectId: z.ZodString;
    projectSecret: z.ZodString;
}, "strip", z.ZodTypeAny, {
    projectId?: string;
    projectSecret?: string;
}, {
    projectId?: string;
    projectSecret?: string;
}>;
export declare const EtherscanProviderSchema: z.ZodObject<{
    service: z.ZodLiteral<"etherscan">;
    apiKey: z.ZodOptional<z.ZodString>;
    network: z.ZodOptional<z.ZodEnum<["homestead", "ropsten", "rinkeby", "goerli", "kovan"]>>;
}, "strip", z.ZodTypeAny, {
    service?: "etherscan";
    apiKey?: string;
    network?: "homestead" | "ropsten" | "rinkeby" | "goerli" | "kovan";
}, {
    service?: "etherscan";
    apiKey?: string;
    network?: "homestead" | "ropsten" | "rinkeby" | "goerli" | "kovan";
}>;
export declare const InfuraProviderSchema: z.ZodObject<{
    service: z.ZodLiteral<"infura">;
    apiKey: z.ZodUnion<[z.ZodString, z.ZodObject<{
        projectId: z.ZodString;
        projectSecret: z.ZodString;
    }, "strip", z.ZodTypeAny, {
        projectId?: string;
        projectSecret?: string;
    }, {
        projectId?: string;
        projectSecret?: string;
    }>]>;
    network: z.ZodOptional<z.ZodEnum<["homestead", "ropsten", "rinkeby", "goerli", "kovan", "matic", "maticmum", "optimism", "optimism-kovan", "arbitrum", "arbitrum-rinkeby"]>>;
}, "strip", z.ZodTypeAny, {
    service?: "infura";
    apiKey?: string | {
        projectId?: string;
        projectSecret?: string;
    };
    network?: "homestead" | "ropsten" | "rinkeby" | "goerli" | "kovan" | "matic" | "maticmum" | "optimism" | "optimism-kovan" | "arbitrum" | "arbitrum-rinkeby";
}, {
    service?: "infura";
    apiKey?: string | {
        projectId?: string;
        projectSecret?: string;
    };
    network?: "homestead" | "ropsten" | "rinkeby" | "goerli" | "kovan" | "matic" | "maticmum" | "optimism" | "optimism-kovan" | "arbitrum" | "arbitrum-rinkeby";
}>;
export declare const AlchemyProviderSchema: z.ZodObject<{
    service: z.ZodLiteral<"alchemy">;
    apiKey: z.ZodOptional<z.ZodString>;
    network: z.ZodOptional<z.ZodEnum<["homestead", "ropsten", "rinkeby", "goerli", "kovan", "matic", "maticmum", "optimism", "optimism-kovan", "arbitrum", "arbitrum-rinkeby"]>>;
}, "strip", z.ZodTypeAny, {
    service?: "alchemy";
    apiKey?: string;
    network?: "homestead" | "ropsten" | "rinkeby" | "goerli" | "kovan" | "matic" | "maticmum" | "optimism" | "optimism-kovan" | "arbitrum" | "arbitrum-rinkeby";
}, {
    service?: "alchemy";
    apiKey?: string;
    network?: "homestead" | "ropsten" | "rinkeby" | "goerli" | "kovan" | "matic" | "maticmum" | "optimism" | "optimism-kovan" | "arbitrum" | "arbitrum-rinkeby";
}>;
export declare const CloudflareProviderSchema: z.ZodObject<{
    service: z.ZodLiteral<"cloudflare">;
}, "strip", z.ZodTypeAny, {
    service?: "cloudflare";
}, {
    service?: "cloudflare";
}>;
export declare const PocketProviderSchema: z.ZodObject<{
    service: z.ZodLiteral<"pocket">;
    apiKey: z.ZodOptional<z.ZodString>;
    network: z.ZodOptional<z.ZodEnum<["homestead", "ropsten", "rinkeby", "goerli"]>>;
}, "strip", z.ZodTypeAny, {
    service?: "pocket";
    apiKey?: string;
    network?: "homestead" | "ropsten" | "rinkeby" | "goerli";
}, {
    service?: "pocket";
    apiKey?: string;
    network?: "homestead" | "ropsten" | "rinkeby" | "goerli";
}>;
export declare const AnkrProviderSchema: z.ZodObject<{
    service: z.ZodLiteral<"ankr">;
    apiKey: z.ZodOptional<z.ZodString>;
    network: z.ZodOptional<z.ZodEnum<["homestead", "matic", "arbitrum"]>>;
}, "strip", z.ZodTypeAny, {
    service?: "ankr";
    apiKey?: string;
    network?: "homestead" | "matic" | "arbitrum";
}, {
    service?: "ankr";
    apiKey?: string;
    network?: "homestead" | "matic" | "arbitrum";
}>;
/** Custom provider schema. url and network are ethers types, validated as unknown. */
export declare const CustomProviderSchema: z.ZodObject<{
    service: z.ZodLiteral<"custom">;
    url: z.ZodOptional<z.ZodUnknown>;
    network: z.ZodOptional<z.ZodUnknown>;
}, "strip", z.ZodTypeAny, {
    service?: "custom";
    network?: unknown;
    url?: unknown;
}, {
    service?: "custom";
    network?: unknown;
    url?: unknown;
}>;
/** Generic provider schema. url and network are ethers types, validated as unknown. */
export declare const GenericProviderSchema: z.ZodObject<{
    service: z.ZodEnum<["alchemy", "ankr", "cloudflare", "custom", "etherscan", "infura", "pocket"]>;
    url: z.ZodOptional<z.ZodUnknown>;
    network: z.ZodOptional<z.ZodUnknown>;
    apiKey: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodObject<{
        projectId: z.ZodString;
        projectSecret: z.ZodString;
    }, "strip", z.ZodTypeAny, {
        projectId?: string;
        projectSecret?: string;
    }, {
        projectId?: string;
        projectSecret?: string;
    }>]>>;
}, "strip", z.ZodTypeAny, {
    service?: "alchemy" | "ankr" | "cloudflare" | "custom" | "etherscan" | "infura" | "pocket";
    apiKey?: string | {
        projectId?: string;
        projectSecret?: string;
    };
    network?: unknown;
    url?: unknown;
}, {
    service?: "alchemy" | "ankr" | "cloudflare" | "custom" | "etherscan" | "infura" | "pocket";
    apiKey?: string | {
        projectId?: string;
        projectSecret?: string;
    };
    network?: unknown;
    url?: unknown;
}>;
/** Supported provider types (discriminated union schema). */
export declare const RPCProviderSchema: z.ZodDiscriminatedUnion<"service", [z.ZodObject<{
    service: z.ZodLiteral<"etherscan">;
    apiKey: z.ZodOptional<z.ZodString>;
    network: z.ZodOptional<z.ZodEnum<["homestead", "ropsten", "rinkeby", "goerli", "kovan"]>>;
}, "strip", z.ZodTypeAny, {
    service?: "etherscan";
    apiKey?: string;
    network?: "homestead" | "ropsten" | "rinkeby" | "goerli" | "kovan";
}, {
    service?: "etherscan";
    apiKey?: string;
    network?: "homestead" | "ropsten" | "rinkeby" | "goerli" | "kovan";
}>, z.ZodObject<{
    service: z.ZodLiteral<"infura">;
    apiKey: z.ZodUnion<[z.ZodString, z.ZodObject<{
        projectId: z.ZodString;
        projectSecret: z.ZodString;
    }, "strip", z.ZodTypeAny, {
        projectId?: string;
        projectSecret?: string;
    }, {
        projectId?: string;
        projectSecret?: string;
    }>]>;
    network: z.ZodOptional<z.ZodEnum<["homestead", "ropsten", "rinkeby", "goerli", "kovan", "matic", "maticmum", "optimism", "optimism-kovan", "arbitrum", "arbitrum-rinkeby"]>>;
}, "strip", z.ZodTypeAny, {
    service?: "infura";
    apiKey?: string | {
        projectId?: string;
        projectSecret?: string;
    };
    network?: "homestead" | "ropsten" | "rinkeby" | "goerli" | "kovan" | "matic" | "maticmum" | "optimism" | "optimism-kovan" | "arbitrum" | "arbitrum-rinkeby";
}, {
    service?: "infura";
    apiKey?: string | {
        projectId?: string;
        projectSecret?: string;
    };
    network?: "homestead" | "ropsten" | "rinkeby" | "goerli" | "kovan" | "matic" | "maticmum" | "optimism" | "optimism-kovan" | "arbitrum" | "arbitrum-rinkeby";
}>, z.ZodObject<{
    service: z.ZodLiteral<"alchemy">;
    apiKey: z.ZodOptional<z.ZodString>;
    network: z.ZodOptional<z.ZodEnum<["homestead", "ropsten", "rinkeby", "goerli", "kovan", "matic", "maticmum", "optimism", "optimism-kovan", "arbitrum", "arbitrum-rinkeby"]>>;
}, "strip", z.ZodTypeAny, {
    service?: "alchemy";
    apiKey?: string;
    network?: "homestead" | "ropsten" | "rinkeby" | "goerli" | "kovan" | "matic" | "maticmum" | "optimism" | "optimism-kovan" | "arbitrum" | "arbitrum-rinkeby";
}, {
    service?: "alchemy";
    apiKey?: string;
    network?: "homestead" | "ropsten" | "rinkeby" | "goerli" | "kovan" | "matic" | "maticmum" | "optimism" | "optimism-kovan" | "arbitrum" | "arbitrum-rinkeby";
}>, z.ZodObject<{
    service: z.ZodLiteral<"cloudflare">;
}, "strip", z.ZodTypeAny, {
    service?: "cloudflare";
}, {
    service?: "cloudflare";
}>, z.ZodObject<{
    service: z.ZodLiteral<"pocket">;
    apiKey: z.ZodOptional<z.ZodString>;
    network: z.ZodOptional<z.ZodEnum<["homestead", "ropsten", "rinkeby", "goerli"]>>;
}, "strip", z.ZodTypeAny, {
    service?: "pocket";
    apiKey?: string;
    network?: "homestead" | "ropsten" | "rinkeby" | "goerli";
}, {
    service?: "pocket";
    apiKey?: string;
    network?: "homestead" | "ropsten" | "rinkeby" | "goerli";
}>, z.ZodObject<{
    service: z.ZodLiteral<"ankr">;
    apiKey: z.ZodOptional<z.ZodString>;
    network: z.ZodOptional<z.ZodEnum<["homestead", "matic", "arbitrum"]>>;
}, "strip", z.ZodTypeAny, {
    service?: "ankr";
    apiKey?: string;
    network?: "homestead" | "matic" | "arbitrum";
}, {
    service?: "ankr";
    apiKey?: string;
    network?: "homestead" | "matic" | "arbitrum";
}>, z.ZodObject<{
    service: z.ZodLiteral<"custom">;
    url: z.ZodOptional<z.ZodUnknown>;
    network: z.ZodOptional<z.ZodUnknown>;
}, "strip", z.ZodTypeAny, {
    service?: "custom";
    network?: unknown;
    url?: unknown;
}, {
    service?: "custom";
    network?: unknown;
    url?: unknown;
}>]>;
export declare const RouteConfigSchema: z.ZodObject<{
    /** Endpoint path. */
    url: z.ZodOptional<z.ZodString>;
    /** Endpoint request method. */
    method: z.ZodOptional<z.ZodEnum<["get", "post", "put", "delete"]>>;
    /** Custom Operation - Replace the tcw function called with a function of your own. */
    customAPIOperation: z.ZodOptional<z.ZodFunction<z.ZodTuple<[], z.ZodUnknown>, z.ZodUnknown>>;
}, "strip", z.ZodTypeAny, {
    url?: string;
    method?: "get" | "put" | "delete" | "post";
    customAPIOperation?: (...args: unknown[]) => unknown;
}, {
    url?: string;
    method?: "get" | "put" | "delete" | "post";
    customAPIOperation?: (...args: unknown[]) => unknown;
}>;
export declare const ServerMiddlewareConfigSchema: z.ZodObject<{
    path: z.ZodString;
    callback: z.ZodOptional<z.ZodFunction<z.ZodTuple<[], z.ZodUnknown>, z.ZodUnknown>>;
}, "strip", z.ZodTypeAny, {
    path?: string;
    callback?: (...args: unknown[]) => unknown;
}, {
    path?: string;
    callback?: (...args: unknown[]) => unknown;
}>;
export declare const ServerRouteEndpointTypeSchema: z.ZodUnion<[z.ZodObject<{
    url: z.ZodOptional<z.ZodOptional<z.ZodString>>;
    method: z.ZodOptional<z.ZodOptional<z.ZodEnum<["get", "post", "put", "delete"]>>>;
    customAPIOperation: z.ZodOptional<z.ZodOptional<z.ZodFunction<z.ZodTuple<[], z.ZodUnknown>, z.ZodUnknown>>>;
}, "strip", z.ZodTypeAny, {
    url?: string;
    method?: "get" | "put" | "delete" | "post";
    customAPIOperation?: (...args: unknown[]) => unknown;
}, {
    url?: string;
    method?: "get" | "put" | "delete" | "post";
    customAPIOperation?: (...args: unknown[]) => unknown;
}>, z.ZodUnknown, z.ZodString, z.ZodObject<{
    path: z.ZodString;
    callback: z.ZodOptional<z.ZodFunction<z.ZodTuple<[], z.ZodUnknown>, z.ZodUnknown>>;
}, "strip", z.ZodTypeAny, {
    path?: string;
    callback?: (...args: unknown[]) => unknown;
}, {
    path?: string;
    callback?: (...args: unknown[]) => unknown;
}>]>;
export declare const ServerRoutesSchema: z.ZodObject<{
    /** Get nonce endpoint path. /tcw-nonce as default. */
    nonce: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
        url: z.ZodOptional<z.ZodOptional<z.ZodString>>;
        method: z.ZodOptional<z.ZodOptional<z.ZodEnum<["get", "post", "put", "delete"]>>>;
        customAPIOperation: z.ZodOptional<z.ZodOptional<z.ZodFunction<z.ZodTuple<[], z.ZodUnknown>, z.ZodUnknown>>>;
    }, "strip", z.ZodTypeAny, {
        url?: string;
        method?: "get" | "put" | "delete" | "post";
        customAPIOperation?: (...args: unknown[]) => unknown;
    }, {
        url?: string;
        method?: "get" | "put" | "delete" | "post";
        customAPIOperation?: (...args: unknown[]) => unknown;
    }>, z.ZodUnknown, z.ZodString, z.ZodObject<{
        path: z.ZodString;
        callback: z.ZodOptional<z.ZodFunction<z.ZodTuple<[], z.ZodUnknown>, z.ZodUnknown>>;
    }, "strip", z.ZodTypeAny, {
        path?: string;
        callback?: (...args: unknown[]) => unknown;
    }, {
        path?: string;
        callback?: (...args: unknown[]) => unknown;
    }>]>>;
    /** Post login endpoint path. /tcw-login as default. */
    login: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
        url: z.ZodOptional<z.ZodOptional<z.ZodString>>;
        method: z.ZodOptional<z.ZodOptional<z.ZodEnum<["get", "post", "put", "delete"]>>>;
        customAPIOperation: z.ZodOptional<z.ZodOptional<z.ZodFunction<z.ZodTuple<[], z.ZodUnknown>, z.ZodUnknown>>>;
    }, "strip", z.ZodTypeAny, {
        url?: string;
        method?: "get" | "put" | "delete" | "post";
        customAPIOperation?: (...args: unknown[]) => unknown;
    }, {
        url?: string;
        method?: "get" | "put" | "delete" | "post";
        customAPIOperation?: (...args: unknown[]) => unknown;
    }>, z.ZodUnknown, z.ZodString, z.ZodObject<{
        path: z.ZodString;
        callback: z.ZodOptional<z.ZodFunction<z.ZodTuple<[], z.ZodUnknown>, z.ZodUnknown>>;
    }, "strip", z.ZodTypeAny, {
        path?: string;
        callback?: (...args: unknown[]) => unknown;
    }, {
        path?: string;
        callback?: (...args: unknown[]) => unknown;
    }>]>>;
    /** Post logout endpoint path. /tcw-logout as default. */
    logout: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
        url: z.ZodOptional<z.ZodOptional<z.ZodString>>;
        method: z.ZodOptional<z.ZodOptional<z.ZodEnum<["get", "post", "put", "delete"]>>>;
        customAPIOperation: z.ZodOptional<z.ZodOptional<z.ZodFunction<z.ZodTuple<[], z.ZodUnknown>, z.ZodUnknown>>>;
    }, "strip", z.ZodTypeAny, {
        url?: string;
        method?: "get" | "put" | "delete" | "post";
        customAPIOperation?: (...args: unknown[]) => unknown;
    }, {
        url?: string;
        method?: "get" | "put" | "delete" | "post";
        customAPIOperation?: (...args: unknown[]) => unknown;
    }>, z.ZodUnknown, z.ZodString, z.ZodObject<{
        path: z.ZodString;
        callback: z.ZodOptional<z.ZodFunction<z.ZodTuple<[], z.ZodUnknown>, z.ZodUnknown>>;
    }, "strip", z.ZodTypeAny, {
        path?: string;
        callback?: (...args: unknown[]) => unknown;
    }, {
        path?: string;
        callback?: (...args: unknown[]) => unknown;
    }>]>>;
}, "strip", z.ZodTypeAny, {
    nonce?: unknown;
    login?: unknown;
    logout?: unknown;
}, {
    nonce?: unknown;
    login?: unknown;
    logout?: unknown;
}>;
export declare const ServerRouteNamesSchema: z.ZodObject<{
    /** Get nonce endpoint path. /tcw-nonce as default. */
    nonce: z.ZodOptional<z.ZodString>;
    /** Post login endpoint path. /tcw-login as default. */
    login: z.ZodOptional<z.ZodString>;
    /** Post logout endpoint path. /tcw-logout as default. */
    logout: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
    nonce?: string;
    login?: string;
    logout?: string;
}, {
    nonce?: string;
    login?: string;
    logout?: string;
}>;
export interface ValidationError {
    code: string;
    message: string;
    issues?: unknown[];
}
export type ValidationResult<T> = {
    ok: true;
    data: T;
} | {
    ok: false;
    error: ValidationError;
};
export declare function validateEnsData(data: unknown): ValidationResult<EnsData>;
export declare function validateRPCProvider(data: unknown): ValidationResult<z.infer<typeof RPCProviderSchema>>;
export declare function validateServerRoutes(data: unknown): ValidationResult<z.infer<typeof ServerRoutesSchema>>;
//# sourceMappingURL=types.d.ts.map