@lifi/types
Version:
Types for the LI.FI stack
54 lines • 1.43 kB
TypeScript
import type { ChainId } from '../chains/base.js';
import type { CoinKey } from './base.js';
export type VerificationStatus = 'verified' | 'unverified' | 'flagged';
export type VerificationStatusBreakdown = {
provider: string;
result: VerificationStatus;
providerResult?: string;
reason?: string;
};
export interface BaseToken {
chainId: ChainId;
address: string;
}
export interface StaticToken extends BaseToken {
symbol: string;
decimals: number;
name: string;
coinKey?: CoinKey;
logoURI?: string;
tags?: TokenTag[];
verificationStatus?: VerificationStatus;
verificationStatusBreakdown?: VerificationStatusBreakdown[];
}
export interface Token extends StaticToken {
priceUSD: string;
}
export interface TokenExtended extends Token {
marketCapUSD?: number | null;
volumeUSD24H?: number | null;
fdvUSD?: number | null;
}
export interface TokenAmount extends Token {
amount?: bigint;
blockNumber?: bigint;
}
export interface TokenAmountExtended extends TokenExtended, TokenAmount {
}
export interface Coin {
key: CoinKey;
name: string;
logoURI: string;
verified: boolean;
chains: {
[ChainId: string]: StaticToken;
};
}
export declare enum TokenTag {
STABLECOIN = "stablecoin",
MAJOR_ASSET = "major_asset",
RWA = "rwa",
SUPERTOKEN = "supertoken",
TESTNET = "testnet"
}
//# sourceMappingURL=token.d.ts.map