import { Base64String, HexString, Nillable, NonNil, Promisy } from '../utils/types'; import { BytesEncodingStatus, PayloadBytesTypes } from './enums'; export interface Signature { sig: Nillable; type: CustomSignatureType; } export declare enum SignatureType { SIGNATURE_TYPE_INVALID = "invalid", SECP256K1_PERSONAL = "secp256k1_ep", ED25519 = "ed25519" } export type EthSigner = { signMessage: (message: string | Uint8Array) => Promise; }; export type CustomSigner = NonNil<(message: Uint8Array) => Promise>; export type SignerSupplier = Promisy; export interface AuthBody { signature: Base64String; challenge: HexString; } export type CustomSignatureType = string; export type AnySignatureType = SignatureType | CustomSignatureType; export declare function getSignatureType(signer: SignerSupplier): SignatureType; export declare function isEthersSigner(signer: SignerSupplier): boolean; export declare function executeSign(msg: Uint8Array, signer: SignerSupplier, signatureType: AnySignatureType): Promise;