caip-api
Version:
CAIP Blockchain API and JSON-RPC Config
75 lines • 1.66 kB
TypeScript
export interface AssetMetadata {
symbol: string;
name: string;
decimals: string;
}
export interface ChainConfig {
name: string;
chainId: string;
rpcUrl: string;
testNet: boolean;
derivationPath: string;
nativeAsset: AssetMetadata;
}
export interface NamespaceConfig {
[reference: string]: ChainConfig;
}
export interface SupportedChains {
[chainId: string]: ChainConfig;
}
export declare namespace Ethereum {
interface AssetData {
symbol: string;
name: string;
decimals: string;
contractAddress: string;
balance?: string;
}
interface Transaction {
timestamp: string;
hash: string;
from: string;
to: string;
nonce: string;
gasPrice: string;
gasUsed: string;
fee: string;
value: string;
input: string;
error: boolean;
asset: AssetData;
operations: Operation[];
}
interface Operation {
asset: AssetData;
value: string;
from: string;
to: string;
functionName: string;
}
interface GasPrice {
time: number;
price: number;
}
interface GasPrices {
timestamp: number;
slow: GasPrice;
average: GasPrice;
fast: GasPrice;
}
interface GasGuzzler {
address: string;
pct: number;
gasused: number;
id: string;
}
interface MethodArgument {
type: string;
}
interface Method {
signature: string;
name: string;
args: MethodArgument[];
}
}
//# sourceMappingURL=types.d.ts.map