gotake-contracts
Version:
TypeChain generated types and ABIs for GoTake contracts
59 lines (51 loc) • 1.17 kB
text/typescript
// Generic contract interface types that work across different ethers versions
export interface GenericContractABI {
[key: string]: any[];
}
export interface ContractInterface {
address: string;
abi: GenericContractABI;
}
export interface DeployedContract {
address: string;
chainId: number;
networkName: string;
}
export interface NetworkConfig {
name: string;
rpc: string;
chainId: number;
contracts: Record<string, string>;
tokens: Array<{
address: string;
name: string;
symbol: string;
decimals: number;
}>;
}
export interface ContractAddresses {
[networkName: string]: NetworkConfig;
}
// Generic function signature types
export interface ContractFunction {
name: string;
inputs: ContractInput[];
outputs: ContractOutput[];
stateMutability: string;
type: string;
}
export interface ContractInput {
name: string;
type: string;
indexed?: boolean;
}
export interface ContractOutput {
name: string;
type: string;
}
export interface ContractEvent {
name: string;
inputs: ContractInput[];
anonymous: boolean;
type: string;
}