-
Notifications
You must be signed in to change notification settings - Fork 71
/
models.ts
63 lines (56 loc) · 1.28 KB
/
models.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
export interface ProposedTransaction {
id: number
contractInterface: ContractInterface | null
description: {
to: string
value: string
customTransactionData?: string
contractMethod?: ContractMethod
contractFieldsValues?: Record<string, string>
contractMethodIndex?: string
nativeCurrencySymbol?: string
networkPrefix?: string
}
raw: { to: string; value: string; data: string }
}
export interface ContractInterface {
methods: ContractMethod[]
}
export interface Batch {
id: number | string
name: string
transactions: ProposedTransaction[]
}
export interface BatchFile {
version: string
chainId: string
createdAt: number
meta: BatchFileMeta
transactions: BatchTransaction[]
}
export interface BatchFileMeta {
txBuilderVersion?: string
checksum?: string
createdFromSafeAddress?: string
createdFromOwnerAddress?: string
name: string
description?: string
}
export interface BatchTransaction {
to: string
value: string
data?: string
contractMethod?: ContractMethod
contractInputsValues?: { [key: string]: string }
}
export interface ContractMethod {
inputs: ContractInput[]
name: string
payable: boolean
}
export interface ContractInput {
internalType: string
name: string
type: string
components?: ContractInput[]
}