impermax-sdk 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (103) hide show
  1. package/.idea/impermax-sdk.iml +12 -0
  2. package/.idea/misc.xml +6 -0
  3. package/.idea/modules.xml +8 -0
  4. package/.idea/workspace.xml +642 -0
  5. package/abis/ImpermaxABI.ts +3 -0
  6. package/abis/contracts/BAllowance.json +4735 -0
  7. package/abis/contracts/BDeployer.json +1195 -0
  8. package/abis/contracts/BInterestRateModel.json +10796 -0
  9. package/abis/contracts/BSetter.json +6219 -0
  10. package/abis/contracts/BStorage.json +2613 -0
  11. package/abis/contracts/Borrowable.json +19937 -0
  12. package/abis/contracts/CDeployer.json +1104 -0
  13. package/abis/contracts/CSetter.json +5094 -0
  14. package/abis/contracts/CStorage.json +516 -0
  15. package/abis/contracts/ClaimAggregator.json +2015 -0
  16. package/abis/contracts/Collateral.json +21615 -0
  17. package/abis/contracts/ERC20.json +819 -0
  18. package/abis/contracts/Factory.json +21986 -0
  19. package/abis/contracts/FarmingPool.json +8601 -0
  20. package/abis/contracts/IBDeployer.json +351 -0
  21. package/abis/contracts/IBorrowTracker.json +346 -0
  22. package/abis/contracts/IBorrowable.json +13207 -0
  23. package/abis/contracts/ICDeployer.json +294 -0
  24. package/abis/contracts/IClaimable.json +406 -0
  25. package/abis/contracts/ICollateral.json +8952 -0
  26. package/abis/contracts/IERC20.json +2376 -0
  27. package/abis/contracts/IFactory.json +3660 -0
  28. package/abis/contracts/IFarmingPool.json +3584 -0
  29. package/abis/contracts/IImpermaxCallee.json +679 -0
  30. package/abis/contracts/IMerkleDistributor.json +1134 -0
  31. package/abis/contracts/IPoolToken.json +5343 -0
  32. package/abis/contracts/IRouter01.json +6891 -0
  33. package/abis/contracts/IRouter02.json +7283 -0
  34. package/abis/contracts/ISimpleUniswapOracle.json +1469 -0
  35. package/abis/contracts/IStakedLPToken.json +7309 -0
  36. package/abis/contracts/IStakingRewards.json +1036 -0
  37. package/abis/contracts/IUniswapV2Callee.json +403 -0
  38. package/abis/contracts/IUniswapV2ERC20.json +3155 -0
  39. package/abis/contracts/IUniswapV2Factory.json +1690 -0
  40. package/abis/contracts/IUniswapV2Pair.json +6761 -0
  41. package/abis/contracts/IWETH.json +561 -0
  42. package/abis/contracts/ImpermaxChef.json +20945 -0
  43. package/abis/contracts/ImpermaxERC20.json +12095 -0
  44. package/abis/contracts/Math.json +1966 -0
  45. package/abis/contracts/MockERC20.json +8884 -0
  46. package/abis/contracts/PoolToken.json +10784 -0
  47. package/abis/contracts/Router01.json +43963 -0
  48. package/abis/contracts/SafeMath.json +6828 -0
  49. package/abis/contracts/SimpleUniswapOracle.json +9640 -0
  50. package/abis/contracts/TransferHelper.json +4875 -0
  51. package/abis/contracts/UQ112x112.json +1201 -0
  52. package/abis/contracts/UniswapV2ERC20.json +10969 -0
  53. package/abis/contracts/UniswapV2Factory.json +5521 -0
  54. package/abis/contracts/UniswapV2Library.json +13789 -0
  55. package/abis/contracts/UniswapV2Pair.json +30782 -0
  56. package/abis/contracts/WETH9.json +6613 -0
  57. package/config/amms.ts +199 -0
  58. package/config/contracts/claim-aggregators.ts +16 -0
  59. package/config/contracts/impermax-chef.ts +16 -0
  60. package/config/contracts/imxes.ts +16 -0
  61. package/config/contracts/merkle-distributors.ts +13 -0
  62. package/config/contracts/routers.ts +36 -0
  63. package/config/contracts/simple-uniswap-oracles.ts +33 -0
  64. package/config/contracts/weths.ts +18 -0
  65. package/config/debank-ids.ts +15 -0
  66. package/config/endpoints/merkle-distributors.ts +13 -0
  67. package/config/eth.ts +32 -0
  68. package/config/factories.ts +26 -0
  69. package/config/farms.ts +119 -0
  70. package/config/general.ts +8 -0
  71. package/config/subgraphs.ts +69 -0
  72. package/config/types.ts +81 -0
  73. package/impermax-router/Account.ts +123 -0
  74. package/impermax-router/AccountBorrowable.ts +110 -0
  75. package/impermax-router/AccountCollateral.ts +40 -0
  76. package/impermax-router/AccountLendingPool.ts +231 -0
  77. package/impermax-router/AccountPoolToken.ts +76 -0
  78. package/impermax-router/Borrowable.ts +86 -0
  79. package/impermax-router/Collateral.ts +26 -0
  80. package/impermax-router/ContractsHelper.ts +64 -0
  81. package/impermax-router/ImpermaxFactory.ts +47 -0
  82. package/impermax-router/Interactions.ts +94 -0
  83. package/impermax-router/InteractionsLendingPool.ts +129 -0
  84. package/impermax-router/InteractionsPoolToken.ts +187 -0
  85. package/impermax-router/LendingPool.ts +256 -0
  86. package/impermax-router/PoolToken.ts +112 -0
  87. package/impermax-router/index.ts +49 -0
  88. package/impermax-router/interfaces.ts +233 -0
  89. package/index.ts +5 -0
  90. package/package.json +23 -0
  91. package/subgraph/Account.ts +93 -0
  92. package/subgraph/AccountLendingPool.ts +60 -0
  93. package/subgraph/AccountPoolToken.ts +60 -0
  94. package/subgraph/LendingPool.ts +179 -0
  95. package/subgraph/PoolToken.ts +381 -0
  96. package/subgraph/PriceHelper.ts +150 -0
  97. package/subgraph/SolidexHelper.ts +54 -0
  98. package/subgraph/index.ts +166 -0
  99. package/subgraph/initializer.ts +509 -0
  100. package/subgraph/query.ts +224 -0
  101. package/tsconfig.json +16 -0
  102. package/utils/ether-utils.ts +22 -0
  103. package/utils/index.ts +12 -0
@@ -0,0 +1,1036 @@
1
+ {
2
+ "contractName": "IStakingRewards",
3
+ "abi": [
4
+ {
5
+ "constant": true,
6
+ "inputs": [],
7
+ "name": "rewardsToken",
8
+ "outputs": [
9
+ {
10
+ "internalType": "address",
11
+ "name": "",
12
+ "type": "address"
13
+ }
14
+ ],
15
+ "payable": false,
16
+ "stateMutability": "view",
17
+ "type": "function"
18
+ },
19
+ {
20
+ "constant": true,
21
+ "inputs": [],
22
+ "name": "stakingToken",
23
+ "outputs": [
24
+ {
25
+ "internalType": "address",
26
+ "name": "",
27
+ "type": "address"
28
+ }
29
+ ],
30
+ "payable": false,
31
+ "stateMutability": "view",
32
+ "type": "function"
33
+ },
34
+ {
35
+ "constant": true,
36
+ "inputs": [
37
+ {
38
+ "internalType": "address",
39
+ "name": "account",
40
+ "type": "address"
41
+ }
42
+ ],
43
+ "name": "balanceOf",
44
+ "outputs": [
45
+ {
46
+ "internalType": "uint256",
47
+ "name": "",
48
+ "type": "uint256"
49
+ }
50
+ ],
51
+ "payable": false,
52
+ "stateMutability": "view",
53
+ "type": "function"
54
+ },
55
+ {
56
+ "constant": true,
57
+ "inputs": [
58
+ {
59
+ "internalType": "address",
60
+ "name": "account",
61
+ "type": "address"
62
+ }
63
+ ],
64
+ "name": "earned",
65
+ "outputs": [
66
+ {
67
+ "internalType": "uint256",
68
+ "name": "",
69
+ "type": "uint256"
70
+ }
71
+ ],
72
+ "payable": false,
73
+ "stateMutability": "view",
74
+ "type": "function"
75
+ },
76
+ {
77
+ "constant": false,
78
+ "inputs": [
79
+ {
80
+ "internalType": "uint256",
81
+ "name": "amount",
82
+ "type": "uint256"
83
+ }
84
+ ],
85
+ "name": "stake",
86
+ "outputs": [],
87
+ "payable": false,
88
+ "stateMutability": "nonpayable",
89
+ "type": "function"
90
+ },
91
+ {
92
+ "constant": false,
93
+ "inputs": [
94
+ {
95
+ "internalType": "uint256",
96
+ "name": "amount",
97
+ "type": "uint256"
98
+ }
99
+ ],
100
+ "name": "withdraw",
101
+ "outputs": [],
102
+ "payable": false,
103
+ "stateMutability": "nonpayable",
104
+ "type": "function"
105
+ },
106
+ {
107
+ "constant": false,
108
+ "inputs": [],
109
+ "name": "getReward",
110
+ "outputs": [],
111
+ "payable": false,
112
+ "stateMutability": "nonpayable",
113
+ "type": "function"
114
+ }
115
+ ],
116
+ "metadata": "{\"compiler\":{\"version\":\"0.5.16+commit.9c3226ce\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"earned\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"getReward\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"rewardsToken\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"stake\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"stakingToken\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"withdraw\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"}],\"devdoc\":{\"methods\":{}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/C/Users/simor/Desktop/staked-lp-token/contracts/interfaces/IStakingRewards.sol\":\"IStakingRewards\"},\"evmVersion\":\"istanbul\",\"libraries\":{},\"optimizer\":{\"enabled\":true,\"runs\":999999},\"remappings\":[]},\"sources\":{\"/C/Users/simor/Desktop/staked-lp-token/contracts/interfaces/IStakingRewards.sol\":{\"keccak256\":\"0x8cf078d277b734d06324f8ee69829465fa50c7c8aef5abbceacd18fef1a3055c\",\"urls\":[\"bzz-raw://3f7f6c5e632fdc3162116509e53f0ca75c9cb57962687d3930cf059d778d6a73\",\"dweb:/ipfs/QmSBTmZwQuJ7skrLQ6WEi3CYnCpXFrXJzFjdjBdMefnpaN\"]}},\"version\":1}",
117
+ "bytecode": "0x",
118
+ "deployedBytecode": "0x",
119
+ "sourceMap": "",
120
+ "deployedSourceMap": "",
121
+ "source": "pragma solidity >=0.5.0;\r\n\r\ninterface IStakingRewards {\r\n function rewardsToken() external view returns (address);\r\n function stakingToken() external view returns (address);\r\n function balanceOf(address account) external view returns (uint256);\r\n function earned(address account) external view returns (uint256);\r\n\r\n function stake(uint256 amount) external;\r\n function withdraw(uint256 amount) external;\r\n function getReward() external;\r\n}",
122
+ "sourcePath": "C:\\Users\\simor\\Desktop\\staked-lp-token\\contracts\\interfaces\\IStakingRewards.sol",
123
+ "ast": {
124
+ "absolutePath": "/C/Users/simor/Desktop/staked-lp-token/contracts/interfaces/IStakingRewards.sol",
125
+ "exportedSymbols": {
126
+ "IStakingRewards": [
127
+ 2413
128
+ ]
129
+ },
130
+ "id": 2414,
131
+ "nodeType": "SourceUnit",
132
+ "nodes": [
133
+ {
134
+ "id": 2375,
135
+ "literals": [
136
+ "solidity",
137
+ ">=",
138
+ "0.5",
139
+ ".0"
140
+ ],
141
+ "nodeType": "PragmaDirective",
142
+ "src": "0:24:8"
143
+ },
144
+ {
145
+ "baseContracts": [],
146
+ "contractDependencies": [],
147
+ "contractKind": "interface",
148
+ "documentation": null,
149
+ "fullyImplemented": false,
150
+ "id": 2413,
151
+ "linearizedBaseContracts": [
152
+ 2413
153
+ ],
154
+ "name": "IStakingRewards",
155
+ "nodeType": "ContractDefinition",
156
+ "nodes": [
157
+ {
158
+ "body": null,
159
+ "documentation": null,
160
+ "id": 2380,
161
+ "implemented": false,
162
+ "kind": "function",
163
+ "modifiers": [],
164
+ "name": "rewardsToken",
165
+ "nodeType": "FunctionDefinition",
166
+ "parameters": {
167
+ "id": 2376,
168
+ "nodeType": "ParameterList",
169
+ "parameters": [],
170
+ "src": "82:2:8"
171
+ },
172
+ "returnParameters": {
173
+ "id": 2379,
174
+ "nodeType": "ParameterList",
175
+ "parameters": [
176
+ {
177
+ "constant": false,
178
+ "id": 2378,
179
+ "name": "",
180
+ "nodeType": "VariableDeclaration",
181
+ "scope": 2380,
182
+ "src": "108:7:8",
183
+ "stateVariable": false,
184
+ "storageLocation": "default",
185
+ "typeDescriptions": {
186
+ "typeIdentifier": "t_address",
187
+ "typeString": "address"
188
+ },
189
+ "typeName": {
190
+ "id": 2377,
191
+ "name": "address",
192
+ "nodeType": "ElementaryTypeName",
193
+ "src": "108:7:8",
194
+ "stateMutability": "nonpayable",
195
+ "typeDescriptions": {
196
+ "typeIdentifier": "t_address",
197
+ "typeString": "address"
198
+ }
199
+ },
200
+ "value": null,
201
+ "visibility": "internal"
202
+ }
203
+ ],
204
+ "src": "107:9:8"
205
+ },
206
+ "scope": 2413,
207
+ "src": "61:56:8",
208
+ "stateMutability": "view",
209
+ "superFunction": null,
210
+ "visibility": "external"
211
+ },
212
+ {
213
+ "body": null,
214
+ "documentation": null,
215
+ "id": 2385,
216
+ "implemented": false,
217
+ "kind": "function",
218
+ "modifiers": [],
219
+ "name": "stakingToken",
220
+ "nodeType": "FunctionDefinition",
221
+ "parameters": {
222
+ "id": 2381,
223
+ "nodeType": "ParameterList",
224
+ "parameters": [],
225
+ "src": "144:2:8"
226
+ },
227
+ "returnParameters": {
228
+ "id": 2384,
229
+ "nodeType": "ParameterList",
230
+ "parameters": [
231
+ {
232
+ "constant": false,
233
+ "id": 2383,
234
+ "name": "",
235
+ "nodeType": "VariableDeclaration",
236
+ "scope": 2385,
237
+ "src": "170:7:8",
238
+ "stateVariable": false,
239
+ "storageLocation": "default",
240
+ "typeDescriptions": {
241
+ "typeIdentifier": "t_address",
242
+ "typeString": "address"
243
+ },
244
+ "typeName": {
245
+ "id": 2382,
246
+ "name": "address",
247
+ "nodeType": "ElementaryTypeName",
248
+ "src": "170:7:8",
249
+ "stateMutability": "nonpayable",
250
+ "typeDescriptions": {
251
+ "typeIdentifier": "t_address",
252
+ "typeString": "address"
253
+ }
254
+ },
255
+ "value": null,
256
+ "visibility": "internal"
257
+ }
258
+ ],
259
+ "src": "169:9:8"
260
+ },
261
+ "scope": 2413,
262
+ "src": "123:56:8",
263
+ "stateMutability": "view",
264
+ "superFunction": null,
265
+ "visibility": "external"
266
+ },
267
+ {
268
+ "body": null,
269
+ "documentation": null,
270
+ "id": 2392,
271
+ "implemented": false,
272
+ "kind": "function",
273
+ "modifiers": [],
274
+ "name": "balanceOf",
275
+ "nodeType": "FunctionDefinition",
276
+ "parameters": {
277
+ "id": 2388,
278
+ "nodeType": "ParameterList",
279
+ "parameters": [
280
+ {
281
+ "constant": false,
282
+ "id": 2387,
283
+ "name": "account",
284
+ "nodeType": "VariableDeclaration",
285
+ "scope": 2392,
286
+ "src": "204:15:8",
287
+ "stateVariable": false,
288
+ "storageLocation": "default",
289
+ "typeDescriptions": {
290
+ "typeIdentifier": "t_address",
291
+ "typeString": "address"
292
+ },
293
+ "typeName": {
294
+ "id": 2386,
295
+ "name": "address",
296
+ "nodeType": "ElementaryTypeName",
297
+ "src": "204:7:8",
298
+ "stateMutability": "nonpayable",
299
+ "typeDescriptions": {
300
+ "typeIdentifier": "t_address",
301
+ "typeString": "address"
302
+ }
303
+ },
304
+ "value": null,
305
+ "visibility": "internal"
306
+ }
307
+ ],
308
+ "src": "203:17:8"
309
+ },
310
+ "returnParameters": {
311
+ "id": 2391,
312
+ "nodeType": "ParameterList",
313
+ "parameters": [
314
+ {
315
+ "constant": false,
316
+ "id": 2390,
317
+ "name": "",
318
+ "nodeType": "VariableDeclaration",
319
+ "scope": 2392,
320
+ "src": "244:7:8",
321
+ "stateVariable": false,
322
+ "storageLocation": "default",
323
+ "typeDescriptions": {
324
+ "typeIdentifier": "t_uint256",
325
+ "typeString": "uint256"
326
+ },
327
+ "typeName": {
328
+ "id": 2389,
329
+ "name": "uint256",
330
+ "nodeType": "ElementaryTypeName",
331
+ "src": "244:7:8",
332
+ "typeDescriptions": {
333
+ "typeIdentifier": "t_uint256",
334
+ "typeString": "uint256"
335
+ }
336
+ },
337
+ "value": null,
338
+ "visibility": "internal"
339
+ }
340
+ ],
341
+ "src": "243:9:8"
342
+ },
343
+ "scope": 2413,
344
+ "src": "185:68:8",
345
+ "stateMutability": "view",
346
+ "superFunction": null,
347
+ "visibility": "external"
348
+ },
349
+ {
350
+ "body": null,
351
+ "documentation": null,
352
+ "id": 2399,
353
+ "implemented": false,
354
+ "kind": "function",
355
+ "modifiers": [],
356
+ "name": "earned",
357
+ "nodeType": "FunctionDefinition",
358
+ "parameters": {
359
+ "id": 2395,
360
+ "nodeType": "ParameterList",
361
+ "parameters": [
362
+ {
363
+ "constant": false,
364
+ "id": 2394,
365
+ "name": "account",
366
+ "nodeType": "VariableDeclaration",
367
+ "scope": 2399,
368
+ "src": "275:15:8",
369
+ "stateVariable": false,
370
+ "storageLocation": "default",
371
+ "typeDescriptions": {
372
+ "typeIdentifier": "t_address",
373
+ "typeString": "address"
374
+ },
375
+ "typeName": {
376
+ "id": 2393,
377
+ "name": "address",
378
+ "nodeType": "ElementaryTypeName",
379
+ "src": "275:7:8",
380
+ "stateMutability": "nonpayable",
381
+ "typeDescriptions": {
382
+ "typeIdentifier": "t_address",
383
+ "typeString": "address"
384
+ }
385
+ },
386
+ "value": null,
387
+ "visibility": "internal"
388
+ }
389
+ ],
390
+ "src": "274:17:8"
391
+ },
392
+ "returnParameters": {
393
+ "id": 2398,
394
+ "nodeType": "ParameterList",
395
+ "parameters": [
396
+ {
397
+ "constant": false,
398
+ "id": 2397,
399
+ "name": "",
400
+ "nodeType": "VariableDeclaration",
401
+ "scope": 2399,
402
+ "src": "315:7:8",
403
+ "stateVariable": false,
404
+ "storageLocation": "default",
405
+ "typeDescriptions": {
406
+ "typeIdentifier": "t_uint256",
407
+ "typeString": "uint256"
408
+ },
409
+ "typeName": {
410
+ "id": 2396,
411
+ "name": "uint256",
412
+ "nodeType": "ElementaryTypeName",
413
+ "src": "315:7:8",
414
+ "typeDescriptions": {
415
+ "typeIdentifier": "t_uint256",
416
+ "typeString": "uint256"
417
+ }
418
+ },
419
+ "value": null,
420
+ "visibility": "internal"
421
+ }
422
+ ],
423
+ "src": "314:9:8"
424
+ },
425
+ "scope": 2413,
426
+ "src": "259:65:8",
427
+ "stateMutability": "view",
428
+ "superFunction": null,
429
+ "visibility": "external"
430
+ },
431
+ {
432
+ "body": null,
433
+ "documentation": null,
434
+ "id": 2404,
435
+ "implemented": false,
436
+ "kind": "function",
437
+ "modifiers": [],
438
+ "name": "stake",
439
+ "nodeType": "FunctionDefinition",
440
+ "parameters": {
441
+ "id": 2402,
442
+ "nodeType": "ParameterList",
443
+ "parameters": [
444
+ {
445
+ "constant": false,
446
+ "id": 2401,
447
+ "name": "amount",
448
+ "nodeType": "VariableDeclaration",
449
+ "scope": 2404,
450
+ "src": "347:14:8",
451
+ "stateVariable": false,
452
+ "storageLocation": "default",
453
+ "typeDescriptions": {
454
+ "typeIdentifier": "t_uint256",
455
+ "typeString": "uint256"
456
+ },
457
+ "typeName": {
458
+ "id": 2400,
459
+ "name": "uint256",
460
+ "nodeType": "ElementaryTypeName",
461
+ "src": "347:7:8",
462
+ "typeDescriptions": {
463
+ "typeIdentifier": "t_uint256",
464
+ "typeString": "uint256"
465
+ }
466
+ },
467
+ "value": null,
468
+ "visibility": "internal"
469
+ }
470
+ ],
471
+ "src": "346:16:8"
472
+ },
473
+ "returnParameters": {
474
+ "id": 2403,
475
+ "nodeType": "ParameterList",
476
+ "parameters": [],
477
+ "src": "371:0:8"
478
+ },
479
+ "scope": 2413,
480
+ "src": "332:40:8",
481
+ "stateMutability": "nonpayable",
482
+ "superFunction": null,
483
+ "visibility": "external"
484
+ },
485
+ {
486
+ "body": null,
487
+ "documentation": null,
488
+ "id": 2409,
489
+ "implemented": false,
490
+ "kind": "function",
491
+ "modifiers": [],
492
+ "name": "withdraw",
493
+ "nodeType": "FunctionDefinition",
494
+ "parameters": {
495
+ "id": 2407,
496
+ "nodeType": "ParameterList",
497
+ "parameters": [
498
+ {
499
+ "constant": false,
500
+ "id": 2406,
501
+ "name": "amount",
502
+ "nodeType": "VariableDeclaration",
503
+ "scope": 2409,
504
+ "src": "396:14:8",
505
+ "stateVariable": false,
506
+ "storageLocation": "default",
507
+ "typeDescriptions": {
508
+ "typeIdentifier": "t_uint256",
509
+ "typeString": "uint256"
510
+ },
511
+ "typeName": {
512
+ "id": 2405,
513
+ "name": "uint256",
514
+ "nodeType": "ElementaryTypeName",
515
+ "src": "396:7:8",
516
+ "typeDescriptions": {
517
+ "typeIdentifier": "t_uint256",
518
+ "typeString": "uint256"
519
+ }
520
+ },
521
+ "value": null,
522
+ "visibility": "internal"
523
+ }
524
+ ],
525
+ "src": "395:16:8"
526
+ },
527
+ "returnParameters": {
528
+ "id": 2408,
529
+ "nodeType": "ParameterList",
530
+ "parameters": [],
531
+ "src": "420:0:8"
532
+ },
533
+ "scope": 2413,
534
+ "src": "378:43:8",
535
+ "stateMutability": "nonpayable",
536
+ "superFunction": null,
537
+ "visibility": "external"
538
+ },
539
+ {
540
+ "body": null,
541
+ "documentation": null,
542
+ "id": 2412,
543
+ "implemented": false,
544
+ "kind": "function",
545
+ "modifiers": [],
546
+ "name": "getReward",
547
+ "nodeType": "FunctionDefinition",
548
+ "parameters": {
549
+ "id": 2410,
550
+ "nodeType": "ParameterList",
551
+ "parameters": [],
552
+ "src": "445:2:8"
553
+ },
554
+ "returnParameters": {
555
+ "id": 2411,
556
+ "nodeType": "ParameterList",
557
+ "parameters": [],
558
+ "src": "456:0:8"
559
+ },
560
+ "scope": 2413,
561
+ "src": "427:30:8",
562
+ "stateMutability": "nonpayable",
563
+ "superFunction": null,
564
+ "visibility": "external"
565
+ }
566
+ ],
567
+ "scope": 2414,
568
+ "src": "28:432:8"
569
+ }
570
+ ],
571
+ "src": "0:460:8"
572
+ },
573
+ "legacyAST": {
574
+ "absolutePath": "/C/Users/simor/Desktop/staked-lp-token/contracts/interfaces/IStakingRewards.sol",
575
+ "exportedSymbols": {
576
+ "IStakingRewards": [
577
+ 2413
578
+ ]
579
+ },
580
+ "id": 2414,
581
+ "nodeType": "SourceUnit",
582
+ "nodes": [
583
+ {
584
+ "id": 2375,
585
+ "literals": [
586
+ "solidity",
587
+ ">=",
588
+ "0.5",
589
+ ".0"
590
+ ],
591
+ "nodeType": "PragmaDirective",
592
+ "src": "0:24:8"
593
+ },
594
+ {
595
+ "baseContracts": [],
596
+ "contractDependencies": [],
597
+ "contractKind": "interface",
598
+ "documentation": null,
599
+ "fullyImplemented": false,
600
+ "id": 2413,
601
+ "linearizedBaseContracts": [
602
+ 2413
603
+ ],
604
+ "name": "IStakingRewards",
605
+ "nodeType": "ContractDefinition",
606
+ "nodes": [
607
+ {
608
+ "body": null,
609
+ "documentation": null,
610
+ "id": 2380,
611
+ "implemented": false,
612
+ "kind": "function",
613
+ "modifiers": [],
614
+ "name": "rewardsToken",
615
+ "nodeType": "FunctionDefinition",
616
+ "parameters": {
617
+ "id": 2376,
618
+ "nodeType": "ParameterList",
619
+ "parameters": [],
620
+ "src": "82:2:8"
621
+ },
622
+ "returnParameters": {
623
+ "id": 2379,
624
+ "nodeType": "ParameterList",
625
+ "parameters": [
626
+ {
627
+ "constant": false,
628
+ "id": 2378,
629
+ "name": "",
630
+ "nodeType": "VariableDeclaration",
631
+ "scope": 2380,
632
+ "src": "108:7:8",
633
+ "stateVariable": false,
634
+ "storageLocation": "default",
635
+ "typeDescriptions": {
636
+ "typeIdentifier": "t_address",
637
+ "typeString": "address"
638
+ },
639
+ "typeName": {
640
+ "id": 2377,
641
+ "name": "address",
642
+ "nodeType": "ElementaryTypeName",
643
+ "src": "108:7:8",
644
+ "stateMutability": "nonpayable",
645
+ "typeDescriptions": {
646
+ "typeIdentifier": "t_address",
647
+ "typeString": "address"
648
+ }
649
+ },
650
+ "value": null,
651
+ "visibility": "internal"
652
+ }
653
+ ],
654
+ "src": "107:9:8"
655
+ },
656
+ "scope": 2413,
657
+ "src": "61:56:8",
658
+ "stateMutability": "view",
659
+ "superFunction": null,
660
+ "visibility": "external"
661
+ },
662
+ {
663
+ "body": null,
664
+ "documentation": null,
665
+ "id": 2385,
666
+ "implemented": false,
667
+ "kind": "function",
668
+ "modifiers": [],
669
+ "name": "stakingToken",
670
+ "nodeType": "FunctionDefinition",
671
+ "parameters": {
672
+ "id": 2381,
673
+ "nodeType": "ParameterList",
674
+ "parameters": [],
675
+ "src": "144:2:8"
676
+ },
677
+ "returnParameters": {
678
+ "id": 2384,
679
+ "nodeType": "ParameterList",
680
+ "parameters": [
681
+ {
682
+ "constant": false,
683
+ "id": 2383,
684
+ "name": "",
685
+ "nodeType": "VariableDeclaration",
686
+ "scope": 2385,
687
+ "src": "170:7:8",
688
+ "stateVariable": false,
689
+ "storageLocation": "default",
690
+ "typeDescriptions": {
691
+ "typeIdentifier": "t_address",
692
+ "typeString": "address"
693
+ },
694
+ "typeName": {
695
+ "id": 2382,
696
+ "name": "address",
697
+ "nodeType": "ElementaryTypeName",
698
+ "src": "170:7:8",
699
+ "stateMutability": "nonpayable",
700
+ "typeDescriptions": {
701
+ "typeIdentifier": "t_address",
702
+ "typeString": "address"
703
+ }
704
+ },
705
+ "value": null,
706
+ "visibility": "internal"
707
+ }
708
+ ],
709
+ "src": "169:9:8"
710
+ },
711
+ "scope": 2413,
712
+ "src": "123:56:8",
713
+ "stateMutability": "view",
714
+ "superFunction": null,
715
+ "visibility": "external"
716
+ },
717
+ {
718
+ "body": null,
719
+ "documentation": null,
720
+ "id": 2392,
721
+ "implemented": false,
722
+ "kind": "function",
723
+ "modifiers": [],
724
+ "name": "balanceOf",
725
+ "nodeType": "FunctionDefinition",
726
+ "parameters": {
727
+ "id": 2388,
728
+ "nodeType": "ParameterList",
729
+ "parameters": [
730
+ {
731
+ "constant": false,
732
+ "id": 2387,
733
+ "name": "account",
734
+ "nodeType": "VariableDeclaration",
735
+ "scope": 2392,
736
+ "src": "204:15:8",
737
+ "stateVariable": false,
738
+ "storageLocation": "default",
739
+ "typeDescriptions": {
740
+ "typeIdentifier": "t_address",
741
+ "typeString": "address"
742
+ },
743
+ "typeName": {
744
+ "id": 2386,
745
+ "name": "address",
746
+ "nodeType": "ElementaryTypeName",
747
+ "src": "204:7:8",
748
+ "stateMutability": "nonpayable",
749
+ "typeDescriptions": {
750
+ "typeIdentifier": "t_address",
751
+ "typeString": "address"
752
+ }
753
+ },
754
+ "value": null,
755
+ "visibility": "internal"
756
+ }
757
+ ],
758
+ "src": "203:17:8"
759
+ },
760
+ "returnParameters": {
761
+ "id": 2391,
762
+ "nodeType": "ParameterList",
763
+ "parameters": [
764
+ {
765
+ "constant": false,
766
+ "id": 2390,
767
+ "name": "",
768
+ "nodeType": "VariableDeclaration",
769
+ "scope": 2392,
770
+ "src": "244:7:8",
771
+ "stateVariable": false,
772
+ "storageLocation": "default",
773
+ "typeDescriptions": {
774
+ "typeIdentifier": "t_uint256",
775
+ "typeString": "uint256"
776
+ },
777
+ "typeName": {
778
+ "id": 2389,
779
+ "name": "uint256",
780
+ "nodeType": "ElementaryTypeName",
781
+ "src": "244:7:8",
782
+ "typeDescriptions": {
783
+ "typeIdentifier": "t_uint256",
784
+ "typeString": "uint256"
785
+ }
786
+ },
787
+ "value": null,
788
+ "visibility": "internal"
789
+ }
790
+ ],
791
+ "src": "243:9:8"
792
+ },
793
+ "scope": 2413,
794
+ "src": "185:68:8",
795
+ "stateMutability": "view",
796
+ "superFunction": null,
797
+ "visibility": "external"
798
+ },
799
+ {
800
+ "body": null,
801
+ "documentation": null,
802
+ "id": 2399,
803
+ "implemented": false,
804
+ "kind": "function",
805
+ "modifiers": [],
806
+ "name": "earned",
807
+ "nodeType": "FunctionDefinition",
808
+ "parameters": {
809
+ "id": 2395,
810
+ "nodeType": "ParameterList",
811
+ "parameters": [
812
+ {
813
+ "constant": false,
814
+ "id": 2394,
815
+ "name": "account",
816
+ "nodeType": "VariableDeclaration",
817
+ "scope": 2399,
818
+ "src": "275:15:8",
819
+ "stateVariable": false,
820
+ "storageLocation": "default",
821
+ "typeDescriptions": {
822
+ "typeIdentifier": "t_address",
823
+ "typeString": "address"
824
+ },
825
+ "typeName": {
826
+ "id": 2393,
827
+ "name": "address",
828
+ "nodeType": "ElementaryTypeName",
829
+ "src": "275:7:8",
830
+ "stateMutability": "nonpayable",
831
+ "typeDescriptions": {
832
+ "typeIdentifier": "t_address",
833
+ "typeString": "address"
834
+ }
835
+ },
836
+ "value": null,
837
+ "visibility": "internal"
838
+ }
839
+ ],
840
+ "src": "274:17:8"
841
+ },
842
+ "returnParameters": {
843
+ "id": 2398,
844
+ "nodeType": "ParameterList",
845
+ "parameters": [
846
+ {
847
+ "constant": false,
848
+ "id": 2397,
849
+ "name": "",
850
+ "nodeType": "VariableDeclaration",
851
+ "scope": 2399,
852
+ "src": "315:7:8",
853
+ "stateVariable": false,
854
+ "storageLocation": "default",
855
+ "typeDescriptions": {
856
+ "typeIdentifier": "t_uint256",
857
+ "typeString": "uint256"
858
+ },
859
+ "typeName": {
860
+ "id": 2396,
861
+ "name": "uint256",
862
+ "nodeType": "ElementaryTypeName",
863
+ "src": "315:7:8",
864
+ "typeDescriptions": {
865
+ "typeIdentifier": "t_uint256",
866
+ "typeString": "uint256"
867
+ }
868
+ },
869
+ "value": null,
870
+ "visibility": "internal"
871
+ }
872
+ ],
873
+ "src": "314:9:8"
874
+ },
875
+ "scope": 2413,
876
+ "src": "259:65:8",
877
+ "stateMutability": "view",
878
+ "superFunction": null,
879
+ "visibility": "external"
880
+ },
881
+ {
882
+ "body": null,
883
+ "documentation": null,
884
+ "id": 2404,
885
+ "implemented": false,
886
+ "kind": "function",
887
+ "modifiers": [],
888
+ "name": "stake",
889
+ "nodeType": "FunctionDefinition",
890
+ "parameters": {
891
+ "id": 2402,
892
+ "nodeType": "ParameterList",
893
+ "parameters": [
894
+ {
895
+ "constant": false,
896
+ "id": 2401,
897
+ "name": "amount",
898
+ "nodeType": "VariableDeclaration",
899
+ "scope": 2404,
900
+ "src": "347:14:8",
901
+ "stateVariable": false,
902
+ "storageLocation": "default",
903
+ "typeDescriptions": {
904
+ "typeIdentifier": "t_uint256",
905
+ "typeString": "uint256"
906
+ },
907
+ "typeName": {
908
+ "id": 2400,
909
+ "name": "uint256",
910
+ "nodeType": "ElementaryTypeName",
911
+ "src": "347:7:8",
912
+ "typeDescriptions": {
913
+ "typeIdentifier": "t_uint256",
914
+ "typeString": "uint256"
915
+ }
916
+ },
917
+ "value": null,
918
+ "visibility": "internal"
919
+ }
920
+ ],
921
+ "src": "346:16:8"
922
+ },
923
+ "returnParameters": {
924
+ "id": 2403,
925
+ "nodeType": "ParameterList",
926
+ "parameters": [],
927
+ "src": "371:0:8"
928
+ },
929
+ "scope": 2413,
930
+ "src": "332:40:8",
931
+ "stateMutability": "nonpayable",
932
+ "superFunction": null,
933
+ "visibility": "external"
934
+ },
935
+ {
936
+ "body": null,
937
+ "documentation": null,
938
+ "id": 2409,
939
+ "implemented": false,
940
+ "kind": "function",
941
+ "modifiers": [],
942
+ "name": "withdraw",
943
+ "nodeType": "FunctionDefinition",
944
+ "parameters": {
945
+ "id": 2407,
946
+ "nodeType": "ParameterList",
947
+ "parameters": [
948
+ {
949
+ "constant": false,
950
+ "id": 2406,
951
+ "name": "amount",
952
+ "nodeType": "VariableDeclaration",
953
+ "scope": 2409,
954
+ "src": "396:14:8",
955
+ "stateVariable": false,
956
+ "storageLocation": "default",
957
+ "typeDescriptions": {
958
+ "typeIdentifier": "t_uint256",
959
+ "typeString": "uint256"
960
+ },
961
+ "typeName": {
962
+ "id": 2405,
963
+ "name": "uint256",
964
+ "nodeType": "ElementaryTypeName",
965
+ "src": "396:7:8",
966
+ "typeDescriptions": {
967
+ "typeIdentifier": "t_uint256",
968
+ "typeString": "uint256"
969
+ }
970
+ },
971
+ "value": null,
972
+ "visibility": "internal"
973
+ }
974
+ ],
975
+ "src": "395:16:8"
976
+ },
977
+ "returnParameters": {
978
+ "id": 2408,
979
+ "nodeType": "ParameterList",
980
+ "parameters": [],
981
+ "src": "420:0:8"
982
+ },
983
+ "scope": 2413,
984
+ "src": "378:43:8",
985
+ "stateMutability": "nonpayable",
986
+ "superFunction": null,
987
+ "visibility": "external"
988
+ },
989
+ {
990
+ "body": null,
991
+ "documentation": null,
992
+ "id": 2412,
993
+ "implemented": false,
994
+ "kind": "function",
995
+ "modifiers": [],
996
+ "name": "getReward",
997
+ "nodeType": "FunctionDefinition",
998
+ "parameters": {
999
+ "id": 2410,
1000
+ "nodeType": "ParameterList",
1001
+ "parameters": [],
1002
+ "src": "445:2:8"
1003
+ },
1004
+ "returnParameters": {
1005
+ "id": 2411,
1006
+ "nodeType": "ParameterList",
1007
+ "parameters": [],
1008
+ "src": "456:0:8"
1009
+ },
1010
+ "scope": 2413,
1011
+ "src": "427:30:8",
1012
+ "stateMutability": "nonpayable",
1013
+ "superFunction": null,
1014
+ "visibility": "external"
1015
+ }
1016
+ ],
1017
+ "scope": 2414,
1018
+ "src": "28:432:8"
1019
+ }
1020
+ ],
1021
+ "src": "0:460:8"
1022
+ },
1023
+ "compiler": {
1024
+ "name": "solc",
1025
+ "version": "0.5.16+commit.9c3226ce.Emscripten.clang"
1026
+ },
1027
+ "networks": {},
1028
+ "schemaVersion": "3.3.2",
1029
+ "updatedAt": "2021-06-04T15:59:20.444Z",
1030
+ "devdoc": {
1031
+ "methods": {}
1032
+ },
1033
+ "userdoc": {
1034
+ "methods": {}
1035
+ }
1036
+ }