lending-apy-fetcher-ts
Version:
TypeScript library for fetching APYs from DeFi lending protocols
47 lines • 1.99 kB
TypeScript
import { NetworkTokenMappings } from '../types';
export declare class AddressConfig {
private mappings;
constructor(customMappings?: NetworkTokenMappings);
private getDefaultMappings;
getSymbol(address: string, network: string): string | undefined;
addMapping(address: string, symbol: string, network: string): void;
getAllMappings(): NetworkTokenMappings;
}
export declare class KaminoConfig {
readonly baseUrl: string;
readonly lendingPath: string;
readonly stakingPath: string;
readonly timeout: number;
readonly retryAttempts: number;
readonly retryDelay: number;
constructor(baseUrl?: string, lendingPath?: string, stakingPath?: string, timeout?: number, retryAttempts?: number, retryDelay?: number);
getLendingUrl(): string;
getStakingUrl(): string;
}
export declare class AaveEthConfig {
readonly subgraphId: string;
readonly poolId: string;
readonly graphGatewayUrl: string;
readonly timeout: number;
readonly retryAttempts: number;
readonly retryDelay: number;
constructor(subgraphId?: string, poolId?: string, graphGatewayUrl?: string, timeout?: number, retryAttempts?: number, retryDelay?: number);
getSubgraphUrl(apiKey: string): string;
}
export declare class ApiConfig {
readonly defaultTimeout: number;
readonly userAgent: string;
readonly retryAttempts: number;
readonly retryDelay: number;
readonly enableLogging: boolean;
constructor(defaultTimeout?: number, userAgent?: string, retryAttempts?: number, retryDelay?: number, enableLogging?: boolean);
}
export declare class AppConfig {
readonly addressConfig: AddressConfig;
readonly kaminoConfig: KaminoConfig;
readonly aaveEthConfig: AaveEthConfig;
readonly apiConfig: ApiConfig;
constructor(addressConfig?: AddressConfig, kaminoConfig?: KaminoConfig, aaveEthConfig?: AaveEthConfig, apiConfig?: ApiConfig);
static fromEnvironment(): AppConfig;
}
//# sourceMappingURL=index.d.ts.map