@curvefi/api 1.14.0 → 1.15.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 (31) hide show
  1. package/README.md +30 -0
  2. package/lib/constants/abis/abis-ethereum.js +78 -16
  3. package/lib/constants/abis/abis-polygon.js +13 -5
  4. package/lib/constants/abis/json/aave/rewards.json +107 -0
  5. package/lib/constants/abis/json/atricrypto3/swap.json +63 -63
  6. package/lib/constants/abis/json/atricrypto3/zap.json +8 -8
  7. package/lib/constants/abis/json/crveth/swap.json +61 -61
  8. package/lib/constants/abis/json/eurt/swap.json +29 -29
  9. package/lib/constants/abis/json/eurtusd/deposit.json +13 -13
  10. package/lib/constants/abis/json/eurtusd/swap.json +59 -59
  11. package/lib/constants/abis/json/gauge.json +1 -1
  12. package/lib/constants/abis/json/gauge_factory.json +879 -0
  13. package/lib/constants/abis/json/gauge_rewards_only.json +649 -0
  14. package/lib/constants/abis/json/gauge_synthetix.json +590 -0
  15. package/lib/constants/abis/json/gauge_v2.json +942 -0
  16. package/lib/constants/abis/json/gauge_v3.json +954 -0
  17. package/lib/constants/abis/json/gauge_v4.json +913 -0
  18. package/lib/constants/abis/json/minter.json +165 -0
  19. package/lib/constants/abis/json/ren-polygon/swap.json +46 -46
  20. package/lib/constants/abis/json/reth/swap.json +38 -38
  21. package/lib/constants/abis/json/tricrypto2/deposit.json +3 -3
  22. package/lib/constants/abis/json/tricrypto2/swap.json +60 -60
  23. package/lib/constants/aliases.d.ts +2 -0
  24. package/lib/constants/aliases.js +2 -0
  25. package/lib/constants/coins-polygon.js +3 -2
  26. package/lib/curve.d.ts +1 -0
  27. package/lib/curve.js +43 -23
  28. package/lib/interfaces.d.ts +7 -1
  29. package/lib/pools.d.ts +13 -2
  30. package/lib/pools.js +187 -25
  31. package/package.json +1 -1
@@ -376,7 +376,7 @@
376
376
  "type": "uint256"
377
377
  }
378
378
  ],
379
- "gas": 3361
379
+ "gas": "3361"
380
380
  },
381
381
  {
382
382
  "stateMutability": "view",
@@ -394,7 +394,7 @@
394
394
  "type": "uint256"
395
395
  }
396
396
  ],
397
- "gas": 3391
397
+ "gas": "3391"
398
398
  },
399
399
  {
400
400
  "stateMutability": "view",
@@ -412,7 +412,7 @@
412
412
  "type": "uint256"
413
413
  }
414
414
  ],
415
- "gas": 3421
415
+ "gas": "3421"
416
416
  },
417
417
  {
418
418
  "stateMutability": "view",
@@ -425,7 +425,7 @@
425
425
  "type": "address"
426
426
  }
427
427
  ],
428
- "gas": 468
428
+ "gas": "468"
429
429
  },
430
430
  {
431
431
  "stateMutability": "view",
@@ -443,7 +443,7 @@
443
443
  "type": "address"
444
444
  }
445
445
  ],
446
- "gas": 582
446
+ "gas": "582"
447
447
  },
448
448
  {
449
449
  "stateMutability": "view",
@@ -456,7 +456,7 @@
456
456
  "type": "uint256"
457
457
  }
458
458
  ],
459
- "gas": 597
459
+ "gas": "597"
460
460
  },
461
461
  {
462
462
  "stateMutability": "view",
@@ -469,7 +469,7 @@
469
469
  "type": "uint256"
470
470
  }
471
471
  ],
472
- "gas": 11991
472
+ "gas": "11991"
473
473
  },
474
474
  {
475
475
  "stateMutability": "view",
@@ -482,7 +482,7 @@
482
482
  "type": "uint256"
483
483
  }
484
484
  ],
485
- "gas": 21673
485
+ "gas": "21673"
486
486
  },
487
487
  {
488
488
  "stateMutability": "view",
@@ -500,7 +500,7 @@
500
500
  "type": "uint256"
501
501
  }
502
502
  ],
503
- "gas": 11096
503
+ "gas": "11096"
504
504
  },
505
505
  {
506
506
  "stateMutability": "view",
@@ -513,7 +513,7 @@
513
513
  "type": "uint256"
514
514
  }
515
515
  ],
516
- "gas": 11582
516
+ "gas": "11582"
517
517
  },
518
518
  {
519
519
  "stateMutability": "payable",
@@ -567,7 +567,7 @@
567
567
  "type": "uint256"
568
568
  }
569
569
  ],
570
- "gas": 3122
570
+ "gas": "3122"
571
571
  },
572
572
  {
573
573
  "stateMutability": "view",
@@ -589,7 +589,7 @@
589
589
  "type": "uint256"
590
590
  }
591
591
  ],
592
- "gas": 26582
592
+ "gas": "26582"
593
593
  },
594
594
  {
595
595
  "stateMutability": "nonpayable",
@@ -606,7 +606,7 @@
606
606
  }
607
607
  ],
608
608
  "outputs": [],
609
- "gas": 738687
609
+ "gas": "738687"
610
610
  },
611
611
  {
612
612
  "stateMutability": "nonpayable",
@@ -623,7 +623,7 @@
623
623
  }
624
624
  ],
625
625
  "outputs": [],
626
- "gas": 233981
626
+ "gas": "233981"
627
627
  },
628
628
  {
629
629
  "stateMutability": "view",
@@ -645,7 +645,7 @@
645
645
  "type": "uint256"
646
646
  }
647
647
  ],
648
- "gas": 3429
648
+ "gas": "3429"
649
649
  },
650
650
  {
651
651
  "stateMutability": "view",
@@ -667,7 +667,7 @@
667
667
  "type": "uint256"
668
668
  }
669
669
  ],
670
- "gas": 13432
670
+ "gas": "13432"
671
671
  },
672
672
  {
673
673
  "stateMutability": "nonpayable",
@@ -688,7 +688,7 @@
688
688
  }
689
689
  ],
690
690
  "outputs": [],
691
- "gas": 648579
691
+ "gas": "648579"
692
692
  },
693
693
  {
694
694
  "stateMutability": "nonpayable",
@@ -696,7 +696,7 @@
696
696
  "name": "claim_admin_fees",
697
697
  "inputs": [],
698
698
  "outputs": [],
699
- "gas": 389808
699
+ "gas": "389808"
700
700
  },
701
701
  {
702
702
  "stateMutability": "nonpayable",
@@ -717,7 +717,7 @@
717
717
  }
718
718
  ],
719
719
  "outputs": [],
720
- "gas": 163102
720
+ "gas": "163102"
721
721
  },
722
722
  {
723
723
  "stateMutability": "nonpayable",
@@ -725,7 +725,7 @@
725
725
  "name": "stop_ramp_A_gamma",
726
726
  "inputs": [],
727
727
  "outputs": [],
728
- "gas": 157247
728
+ "gas": "157247"
729
729
  },
730
730
  {
731
731
  "stateMutability": "nonpayable",
@@ -762,7 +762,7 @@
762
762
  }
763
763
  ],
764
764
  "outputs": [],
765
- "gas": 306190
765
+ "gas": "306190"
766
766
  },
767
767
  {
768
768
  "stateMutability": "nonpayable",
@@ -770,7 +770,7 @@
770
770
  "name": "apply_new_parameters",
771
771
  "inputs": [],
772
772
  "outputs": [],
773
- "gas": 683438
773
+ "gas": "683438"
774
774
  },
775
775
  {
776
776
  "stateMutability": "nonpayable",
@@ -778,7 +778,7 @@
778
778
  "name": "revert_new_parameters",
779
779
  "inputs": [],
780
780
  "outputs": [],
781
- "gas": 23222
781
+ "gas": "23222"
782
782
  },
783
783
  {
784
784
  "stateMutability": "nonpayable",
@@ -791,7 +791,7 @@
791
791
  }
792
792
  ],
793
793
  "outputs": [],
794
- "gas": 77260
794
+ "gas": "77260"
795
795
  },
796
796
  {
797
797
  "stateMutability": "nonpayable",
@@ -799,7 +799,7 @@
799
799
  "name": "apply_transfer_ownership",
800
800
  "inputs": [],
801
801
  "outputs": [],
802
- "gas": 65937
802
+ "gas": "65937"
803
803
  },
804
804
  {
805
805
  "stateMutability": "nonpayable",
@@ -807,7 +807,7 @@
807
807
  "name": "revert_transfer_ownership",
808
808
  "inputs": [],
809
809
  "outputs": [],
810
- "gas": 23312
810
+ "gas": "23312"
811
811
  },
812
812
  {
813
813
  "stateMutability": "nonpayable",
@@ -815,7 +815,7 @@
815
815
  "name": "kill_me",
816
816
  "inputs": [],
817
817
  "outputs": [],
818
- "gas": 40535
818
+ "gas": "40535"
819
819
  },
820
820
  {
821
821
  "stateMutability": "nonpayable",
@@ -823,7 +823,7 @@
823
823
  "name": "unkill_me",
824
824
  "inputs": [],
825
825
  "outputs": [],
826
- "gas": 23372
826
+ "gas": "23372"
827
827
  },
828
828
  {
829
829
  "stateMutability": "nonpayable",
@@ -836,7 +836,7 @@
836
836
  }
837
837
  ],
838
838
  "outputs": [],
839
- "gas": 38505
839
+ "gas": "38505"
840
840
  },
841
841
  {
842
842
  "stateMutability": "view",
@@ -849,7 +849,7 @@
849
849
  "type": "uint256"
850
850
  }
851
851
  ],
852
- "gas": 3378
852
+ "gas": "3378"
853
853
  },
854
854
  {
855
855
  "stateMutability": "view",
@@ -862,7 +862,7 @@
862
862
  "type": "uint256"
863
863
  }
864
864
  ],
865
- "gas": 3408
865
+ "gas": "3408"
866
866
  },
867
867
  {
868
868
  "stateMutability": "view",
@@ -875,7 +875,7 @@
875
875
  "type": "uint256"
876
876
  }
877
877
  ],
878
- "gas": 3438
878
+ "gas": "3438"
879
879
  },
880
880
  {
881
881
  "stateMutability": "view",
@@ -888,7 +888,7 @@
888
888
  "type": "uint256"
889
889
  }
890
890
  ],
891
- "gas": 3468
891
+ "gas": "3468"
892
892
  },
893
893
  {
894
894
  "stateMutability": "view",
@@ -901,7 +901,7 @@
901
901
  "type": "uint256"
902
902
  }
903
903
  ],
904
- "gas": 3498
904
+ "gas": "3498"
905
905
  },
906
906
  {
907
907
  "stateMutability": "view",
@@ -914,7 +914,7 @@
914
914
  "type": "uint256"
915
915
  }
916
916
  ],
917
- "gas": 3528
917
+ "gas": "3528"
918
918
  },
919
919
  {
920
920
  "stateMutability": "view",
@@ -927,7 +927,7 @@
927
927
  "type": "uint256"
928
928
  }
929
929
  ],
930
- "gas": 3558
930
+ "gas": "3558"
931
931
  },
932
932
  {
933
933
  "stateMutability": "view",
@@ -940,7 +940,7 @@
940
940
  "type": "uint256"
941
941
  }
942
942
  ],
943
- "gas": 3588
943
+ "gas": "3588"
944
944
  },
945
945
  {
946
946
  "stateMutability": "view",
@@ -953,7 +953,7 @@
953
953
  "type": "uint256"
954
954
  }
955
955
  ],
956
- "gas": 3618
956
+ "gas": "3618"
957
957
  },
958
958
  {
959
959
  "stateMutability": "view",
@@ -966,7 +966,7 @@
966
966
  "type": "uint256"
967
967
  }
968
968
  ],
969
- "gas": 3648
969
+ "gas": "3648"
970
970
  },
971
971
  {
972
972
  "stateMutability": "view",
@@ -979,7 +979,7 @@
979
979
  "type": "uint256"
980
980
  }
981
981
  ],
982
- "gas": 3678
982
+ "gas": "3678"
983
983
  },
984
984
  {
985
985
  "stateMutability": "view",
@@ -992,7 +992,7 @@
992
992
  "type": "uint256"
993
993
  }
994
994
  ],
995
- "gas": 3708
995
+ "gas": "3708"
996
996
  },
997
997
  {
998
998
  "stateMutability": "view",
@@ -1005,7 +1005,7 @@
1005
1005
  "type": "uint256"
1006
1006
  }
1007
1007
  ],
1008
- "gas": 3738
1008
+ "gas": "3738"
1009
1009
  },
1010
1010
  {
1011
1011
  "stateMutability": "view",
@@ -1018,7 +1018,7 @@
1018
1018
  "type": "uint256"
1019
1019
  }
1020
1020
  ],
1021
- "gas": 3768
1021
+ "gas": "3768"
1022
1022
  },
1023
1023
  {
1024
1024
  "stateMutability": "view",
@@ -1031,7 +1031,7 @@
1031
1031
  "type": "uint256"
1032
1032
  }
1033
1033
  ],
1034
- "gas": 3798
1034
+ "gas": "3798"
1035
1035
  },
1036
1036
  {
1037
1037
  "stateMutability": "view",
@@ -1044,7 +1044,7 @@
1044
1044
  "type": "uint256"
1045
1045
  }
1046
1046
  ],
1047
- "gas": 3828
1047
+ "gas": "3828"
1048
1048
  },
1049
1049
  {
1050
1050
  "stateMutability": "view",
@@ -1057,7 +1057,7 @@
1057
1057
  "type": "uint256"
1058
1058
  }
1059
1059
  ],
1060
- "gas": 3858
1060
+ "gas": "3858"
1061
1061
  },
1062
1062
  {
1063
1063
  "stateMutability": "view",
@@ -1070,7 +1070,7 @@
1070
1070
  "type": "uint256"
1071
1071
  }
1072
1072
  ],
1073
- "gas": 3888
1073
+ "gas": "3888"
1074
1074
  },
1075
1075
  {
1076
1076
  "stateMutability": "view",
@@ -1083,7 +1083,7 @@
1083
1083
  "type": "uint256"
1084
1084
  }
1085
1085
  ],
1086
- "gas": 3918
1086
+ "gas": "3918"
1087
1087
  },
1088
1088
  {
1089
1089
  "stateMutability": "view",
@@ -1101,7 +1101,7 @@
1101
1101
  "type": "uint256"
1102
1102
  }
1103
1103
  ],
1104
- "gas": 4057
1104
+ "gas": "4057"
1105
1105
  },
1106
1106
  {
1107
1107
  "stateMutability": "view",
@@ -1114,7 +1114,7 @@
1114
1114
  "type": "uint256"
1115
1115
  }
1116
1116
  ],
1117
- "gas": 3978
1117
+ "gas": "3978"
1118
1118
  },
1119
1119
  {
1120
1120
  "stateMutability": "view",
@@ -1127,7 +1127,7 @@
1127
1127
  "type": "address"
1128
1128
  }
1129
1129
  ],
1130
- "gas": 4008
1130
+ "gas": "4008"
1131
1131
  },
1132
1132
  {
1133
1133
  "stateMutability": "view",
@@ -1140,7 +1140,7 @@
1140
1140
  "type": "address"
1141
1141
  }
1142
1142
  ],
1143
- "gas": 4038
1143
+ "gas": "4038"
1144
1144
  },
1145
1145
  {
1146
1146
  "stateMutability": "view",
@@ -1153,7 +1153,7 @@
1153
1153
  "type": "uint256"
1154
1154
  }
1155
1155
  ],
1156
- "gas": 4068
1156
+ "gas": "4068"
1157
1157
  },
1158
1158
  {
1159
1159
  "stateMutability": "view",
@@ -1166,7 +1166,7 @@
1166
1166
  "type": "uint256"
1167
1167
  }
1168
1168
  ],
1169
- "gas": 4098
1169
+ "gas": "4098"
1170
1170
  },
1171
1171
  {
1172
1172
  "stateMutability": "view",
@@ -1179,7 +1179,7 @@
1179
1179
  "type": "uint256"
1180
1180
  }
1181
1181
  ],
1182
- "gas": 4128
1182
+ "gas": "4128"
1183
1183
  },
1184
1184
  {
1185
1185
  "stateMutability": "view",
@@ -1192,7 +1192,7 @@
1192
1192
  "type": "bool"
1193
1193
  }
1194
1194
  ],
1195
- "gas": 4158
1195
+ "gas": "4158"
1196
1196
  },
1197
1197
  {
1198
1198
  "stateMutability": "view",
@@ -1205,7 +1205,7 @@
1205
1205
  "type": "uint256"
1206
1206
  }
1207
1207
  ],
1208
- "gas": 4188
1208
+ "gas": "4188"
1209
1209
  },
1210
1210
  {
1211
1211
  "stateMutability": "view",
@@ -1218,7 +1218,7 @@
1218
1218
  "type": "uint256"
1219
1219
  }
1220
1220
  ],
1221
- "gas": 4218
1221
+ "gas": "4218"
1222
1222
  },
1223
1223
  {
1224
1224
  "stateMutability": "view",
@@ -1231,7 +1231,7 @@
1231
1231
  "type": "uint256"
1232
1232
  }
1233
1233
  ],
1234
- "gas": 4248
1234
+ "gas": "4248"
1235
1235
  },
1236
1236
  {
1237
1237
  "stateMutability": "view",
@@ -1244,6 +1244,6 @@
1244
1244
  "type": "address"
1245
1245
  }
1246
1246
  ],
1247
- "gas": 4278
1247
+ "gas": "4278"
1248
1248
  }
1249
1249
  ]
@@ -1,5 +1,6 @@
1
1
  export declare const ALIASES_ETHEREUM: {
2
2
  crv: string;
3
+ minter: string;
3
4
  voting_escrow: string;
4
5
  gauge_controller: string;
5
6
  address_provider: string;
@@ -8,6 +9,7 @@ export declare const ALIASES_ETHEREUM: {
8
9
  };
9
10
  export declare const ALIASES_POLYGON: {
10
11
  crv: string;
12
+ minter: string;
11
13
  voting_escrow: string;
12
14
  gauge_controller: string;
13
15
  address_provider: string;
@@ -3,6 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.ALIASES_POLYGON = exports.ALIASES_ETHEREUM = void 0;
4
4
  exports.ALIASES_ETHEREUM = {
5
5
  "crv": "0xD533a949740bb3306d119CC777fa900bA034cd52",
6
+ "minter": "0xd061D61a4d941c39E5453435B6345Dc261C2fcE0",
6
7
  "voting_escrow": "0x5f3b5DfEb7B28CDbD7FAba78963EE202a494e2A2",
7
8
  "gauge_controller": "0x2F50D538606Fa9EDD2B11E2446BEb18C9D5846bB",
8
9
  "address_provider": "0x0000000022d53366457f9d5e68ec105046fc4383",
@@ -11,6 +12,7 @@ exports.ALIASES_ETHEREUM = {
11
12
  };
12
13
  exports.ALIASES_POLYGON = {
13
14
  "crv": "0x172370d5cd63279efa6d502dab29171933a610af",
15
+ "minter": "",
14
16
  "voting_escrow": "0x5f3b5DfEb7B28CDbD7FAba78963EE202a494e2A2",
15
17
  "gauge_controller": "0x2F50D538606Fa9EDD2B11E2446BEb18C9D5846bB",
16
18
  "address_provider": "0x0000000022d53366457f9d5e68ec105046fc4383",
@@ -44,7 +44,7 @@ exports.USD_COINS_POLYGON = {
44
44
  };
45
45
  // @ts-ignore
46
46
  exports.USD_COINS_LOWER_CASE_POLYGON = Object.fromEntries(Object.entries(exports.USD_COINS_POLYGON).map(function (entry) { return [entry[0], entry[1].toLowerCase()]; }));
47
- exports.COINS_POLYGON = __assign(__assign(__assign(__assign(__assign({}, exports.BTC_COINS_POLYGON), exports.ETH_COINS_POLYGON), exports.LINK_COINS_POLYGON), exports.EUR_COINS_POLYGON), exports.USD_COINS_POLYGON);
47
+ exports.COINS_POLYGON = __assign(__assign(__assign(__assign(__assign(__assign({}, exports.BTC_COINS_POLYGON), exports.ETH_COINS_POLYGON), exports.LINK_COINS_POLYGON), exports.EUR_COINS_POLYGON), exports.USD_COINS_POLYGON), { crv: "0x172370d5cd63279efa6d502dab29171933a610af" });
48
48
  exports.DECIMALS_POLYGON = {
49
49
  "0x8f3cf7ad23cd3cadbd9735aff958023239c6a063": 18,
50
50
  "0x2791bca1f2de4661ed88a30c99a7a9449aa84174": 6,
@@ -58,7 +58,8 @@ exports.DECIMALS_POLYGON = {
58
58
  "0x5c2ed810328349100A66B82b78a1791B101C9D61": 8,
59
59
  "0x7ceB23fD6bC0adD59E62ac25578270cFf1b9f619": 18,
60
60
  "0x28424507fefb6f7f8E9D3860F56504E4e5f5f390": 18,
61
- "0x7BDF330f423Ea880FF95fC41A280fD5eCFD3D09f": 6, // EURT
61
+ "0x7BDF330f423Ea880FF95fC41A280fD5eCFD3D09f": 6,
62
+ "0x172370d5cd63279efa6d502dab29171933a610af": 18, // CRV
62
63
  };
63
64
  // @ts-ignore
64
65
  exports.DECIMALS_LOWER_CASE_POLYGON = Object.fromEntries(Object.entries(exports.DECIMALS_POLYGON).map(function (entry) { return [entry[0].toLowerCase(), entry[1]]; }));
package/lib/curve.d.ts CHANGED
@@ -22,6 +22,7 @@ export declare let DECIMALS: DictInterface<number>;
22
22
  export declare let DECIMALS_LOWER_CASE: DictInterface<number>;
23
23
  export declare let ALIASES: {
24
24
  crv: string;
25
+ minter: string;
25
26
  voting_escrow: string;
26
27
  gauge_controller: string;
27
28
  address_provider: string;