forked from ruhutsiruncing404/tiny-friend.tech
-
Notifications
You must be signed in to change notification settings - Fork 0
/
abi.mjs
164 lines (164 loc) · 5.84 KB
/
abi.mjs
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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
export const FRIENDS_TECH_ABI = [
{
anonymous: false,
inputs: [
{ indexed: true, internalType: "address", name: "previousOwner", type: "address" },
{ indexed: true, internalType: "address", name: "newOwner", type: "address" },
],
name: "OwnershipTransferred",
type: "event",
},
{
anonymous: false,
inputs: [
{ indexed: false, internalType: "address", name: "trader", type: "address" },
{ indexed: false, internalType: "address", name: "subject", type: "address" },
{ indexed: false, internalType: "bool", name: "isBuy", type: "bool" },
{ indexed: false, internalType: "uint256", name: "shareAmount", type: "uint256" },
{ indexed: false, internalType: "uint256", name: "ethAmount", type: "uint256" },
{ indexed: false, internalType: "uint256", name: "protocolEthAmount", type: "uint256" },
{ indexed: false, internalType: "uint256", name: "subjectEthAmount", type: "uint256" },
{ indexed: false, internalType: "uint256", name: "supply", type: "uint256" },
],
name: "Trade",
type: "event",
},
{
inputs: [
{ internalType: "address", name: "sharesSubject", type: "address" },
{ internalType: "uint256", name: "amount", type: "uint256" },
],
name: "buyShares",
outputs: [],
stateMutability: "payable",
type: "function",
},
{
inputs: [
{ internalType: "address", name: "sharesSubject", type: "address" },
{ internalType: "uint256", name: "amount", type: "uint256" },
],
name: "getBuyPrice",
outputs: [{ internalType: "uint256", name: "", type: "uint256" }],
stateMutability: "view",
type: "function",
},
{
inputs: [
{ internalType: "address", name: "sharesSubject", type: "address" },
{ internalType: "uint256", name: "amount", type: "uint256" },
],
name: "getBuyPriceAfterFee",
outputs: [{ internalType: "uint256", name: "", type: "uint256" }],
stateMutability: "view",
type: "function",
},
{
inputs: [
{ internalType: "uint256", name: "supply", type: "uint256" },
{ internalType: "uint256", name: "amount", type: "uint256" },
],
name: "getPrice",
outputs: [{ internalType: "uint256", name: "", type: "uint256" }],
stateMutability: "pure",
type: "function",
},
{
inputs: [
{ internalType: "address", name: "sharesSubject", type: "address" },
{ internalType: "uint256", name: "amount", type: "uint256" },
],
name: "getSellPrice",
outputs: [{ internalType: "uint256", name: "", type: "uint256" }],
stateMutability: "view",
type: "function",
},
{
inputs: [
{ internalType: "address", name: "sharesSubject", type: "address" },
{ internalType: "uint256", name: "amount", type: "uint256" },
],
name: "getSellPriceAfterFee",
outputs: [{ internalType: "uint256", name: "", type: "uint256" }],
stateMutability: "view",
type: "function",
},
{ inputs: [], name: "owner", outputs: [{ internalType: "address", name: "", type: "address" }], stateMutability: "view", type: "function" },
{
inputs: [],
name: "protocolFeeDestination",
outputs: [{ internalType: "address", name: "", type: "address" }],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "protocolFeePercent",
outputs: [{ internalType: "uint256", name: "", type: "uint256" }],
stateMutability: "view",
type: "function",
},
{ inputs: [], name: "renounceOwnership", outputs: [], stateMutability: "nonpayable", type: "function" },
{
inputs: [
{ internalType: "address", name: "sharesSubject", type: "address" },
{ internalType: "uint256", name: "amount", type: "uint256" },
],
name: "sellShares",
outputs: [],
stateMutability: "payable",
type: "function",
},
{
inputs: [{ internalType: "address", name: "_feeDestination", type: "address" }],
name: "setFeeDestination",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [{ internalType: "uint256", name: "_feePercent", type: "uint256" }],
name: "setProtocolFeePercent",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [{ internalType: "uint256", name: "_feePercent", type: "uint256" }],
name: "setSubjectFeePercent",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{ internalType: "address", name: "", type: "address" },
{ internalType: "address", name: "", type: "address" },
],
name: "sharesBalance",
outputs: [{ internalType: "uint256", name: "", type: "uint256" }],
stateMutability: "view",
type: "function",
},
{
inputs: [{ internalType: "address", name: "", type: "address" }],
name: "sharesSupply",
outputs: [{ internalType: "uint256", name: "", type: "uint256" }],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "subjectFeePercent",
outputs: [{ internalType: "uint256", name: "", type: "uint256" }],
stateMutability: "view",
type: "function",
},
{
inputs: [{ internalType: "address", name: "newOwner", type: "address" }],
name: "transferOwnership",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
];