export declare function isErrorResponse(response: any): response is NostrConnectErrorResponse;
export declare enum Permission {
    GetPublicKey = "get_pubic_key",
    SignEvent = "sign_event",
    Nip04Encrypt = "nip04_encrypt",
    Nip04Decrypt = "nip04_decrypt",
    Nip44Encrypt = "nip44_encrypt",
    Nip44Decrypt = "nip44_decrypt"
}
export declare enum NostrConnectMethod {
    Connect = "connect",
    CreateAccount = "create_account",
    GetPublicKey = "get_public_key",
    SignEvent = "sign_event",
    Nip04Encrypt = "nip04_encrypt",
    Nip04Decrypt = "nip04_decrypt",
    Nip44Encrypt = "nip44_encrypt",
    Nip44Decrypt = "nip44_decrypt"
}
export type ConnectRequestParams = {
    [NostrConnectMethod.Connect]: [string] | [string, string] | [string, string, string];
    [NostrConnectMethod.CreateAccount]: [string, string] | [string, string, string] | [string, string, string, string];
    [NostrConnectMethod.GetPublicKey]: [];
    [NostrConnectMethod.SignEvent]: [string];
    [NostrConnectMethod.Nip04Encrypt]: [string, string];
    [NostrConnectMethod.Nip04Decrypt]: [string, string];
    [NostrConnectMethod.Nip44Encrypt]: [string, string];
    [NostrConnectMethod.Nip44Decrypt]: [string, string];
};
export type ConnectResponseResults = {
    [NostrConnectMethod.Connect]: "ack" | string;
    [NostrConnectMethod.CreateAccount]: string;
    [NostrConnectMethod.GetPublicKey]: string;
    [NostrConnectMethod.SignEvent]: string;
    [NostrConnectMethod.Nip04Encrypt]: string;
    [NostrConnectMethod.Nip04Decrypt]: string;
    [NostrConnectMethod.Nip44Encrypt]: string;
    [NostrConnectMethod.Nip44Decrypt]: string;
};
export type NostrConnectRequest<N extends NostrConnectMethod> = {
    id: string;
    method: N;
    params: ConnectRequestParams[N];
};
export type NostrConnectResponse<N extends NostrConnectMethod> = {
    id: string;
    result: ConnectResponseResults[N];
    error?: string;
};
export type NostrConnectErrorResponse = {
    id: string;
    result: string;
    error: string;
};
/** A bunker:// URI */
export type BunkerURI = {
    remote: string;
    relays: string[];
    secret?: string;
};
/** Parse a bunker:// URI */
export declare function parseBunkerURI(uri: string): BunkerURI;
/** Creates a bunker:// URI from a {@link BunkerURI} object */
export declare function createBunkerURI(data: BunkerURI): string;
/** App metadata for a nostrconnect:// URI */
export type NostrConnectAppMetadata = {
    /** The name of the client */
    name?: string;
    /** An image for the client */
    image?: string;
    /** The url of the client */
    url?: string | URL;
    /** The permissions the client has */
    permissions?: string[];
};
/** A nostrconnect:// URI */
export type NostrConnectURI = {
    /** The pubkey of the client */
    client: string;
    /** The secret used by the signer to connect to the client */
    secret: string;
    /** The relays used to communicate with the remote signer */
    relays: string[];
    /** The metadata of the client */
    metadata?: NostrConnectAppMetadata;
};
/** Parse a nostrconnect:// URI */
export declare function parseNostrConnectURI(uri: string): NostrConnectURI;
/** Create a nostrconnect:// URI from a {@link NostrConnectURI} object */
export declare function createNostrConnectURI(data: NostrConnectURI): string;
/** Build an array of signing permissions for event kinds */
export declare function buildSigningPermissions(kinds: number[]): string[];
