import { Chain } from '@yoroi/types'; import { DRepId } from './types'; import { Fetcher } from '@yoroi/common'; export type GovernanceApi = { getDRepById: (drepId: DRepId) => Promise<{ txId: string; epoch: number; } | null>; getStakingKeyState: (stakeKeyHash: string) => Promise; }; export declare const governanceApiMaker: ({ network, client, }: { network: Chain.SupportedNetworks; client?: Fetcher | undefined; }) => Api; declare class Api implements GovernanceApi { private config; constructor(config: Config); getDRepById(drepId: DRepId): Promise<{ txId: string; epoch: number; } | null>; getStakingKeyState(stakeKeyHash: string): Promise<{ drepDelegation: { tx: string; epoch: number; slot: number; drep: string; drepKind?: "scripthash" | "keyhash" | undefined; } | undefined; } | { drepDelegation?: undefined; }>; } type Config = { network: Chain.SupportedNetworks; client: Fetcher; }; type GetStakingKeyStateResponse = { drepDelegation?: { tx: string; epoch: number; slot: number; drep: 'no_confidence' | 'abstain' | string; drepKind?: 'scripthash' | 'keyhash'; }; }; export type GetDRepByIdResponse = { registration?: { tx: string; epoch: number; slot: number; deposit: string; anchor?: { url?: string; contentHash?: string; }; }; deregistration?: { tx: string; epoch: number; slot: number; }; }; export {}; //# sourceMappingURL=api.d.ts.map