@logswap/sdk 0.5.39 → 0.5.41
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.
- package/dist/client.d.ts +1 -1
- package/dist/client.js +11 -1
- package/dist/fpool.d.ts +208 -349
- package/dist/fpool.js +125 -58
- package/dist/generated.d.ts +114 -282
- package/dist/generated.js +93 -219
- package/package.json +1 -1
- package/src/client.ts +11 -1
- package/src/fpool.ts +159 -92
- package/src/generated.ts +93 -219
package/dist/fpool.d.ts
CHANGED
|
@@ -61,16 +61,6 @@ export declare const fPoolManagerAbi: readonly [{
|
|
|
61
61
|
readonly type: "uint256";
|
|
62
62
|
}];
|
|
63
63
|
readonly stateMutability: "view";
|
|
64
|
-
}, {
|
|
65
|
-
readonly type: "function";
|
|
66
|
-
readonly inputs: readonly [];
|
|
67
|
-
readonly name: "LEVER_FLOOR";
|
|
68
|
-
readonly outputs: readonly [{
|
|
69
|
-
readonly name: "";
|
|
70
|
-
readonly internalType: "uint256";
|
|
71
|
-
readonly type: "uint256";
|
|
72
|
-
}];
|
|
73
|
-
readonly stateMutability: "view";
|
|
74
64
|
}, {
|
|
75
65
|
readonly type: "function";
|
|
76
66
|
readonly inputs: readonly [];
|
|
@@ -416,9 +406,9 @@ export declare const fPoolManagerAbi: readonly [{
|
|
|
416
406
|
readonly internalType: "address";
|
|
417
407
|
readonly type: "address";
|
|
418
408
|
}, {
|
|
419
|
-
readonly name: "
|
|
420
|
-
readonly internalType: "
|
|
421
|
-
readonly type: "
|
|
409
|
+
readonly name: "kind";
|
|
410
|
+
readonly internalType: "enum Kind";
|
|
411
|
+
readonly type: "uint8";
|
|
422
412
|
}, {
|
|
423
413
|
readonly name: "seeded";
|
|
424
414
|
readonly internalType: "bool";
|
|
@@ -464,7 +454,7 @@ export declare const fPoolManagerAbi: readonly [{
|
|
|
464
454
|
readonly internalType: "int256";
|
|
465
455
|
readonly type: "int256";
|
|
466
456
|
}, {
|
|
467
|
-
readonly name: "
|
|
457
|
+
readonly name: "harvestedTheta";
|
|
468
458
|
readonly internalType: "int256";
|
|
469
459
|
readonly type: "int256";
|
|
470
460
|
}, {
|
|
@@ -476,9 +466,9 @@ export declare const fPoolManagerAbi: readonly [{
|
|
|
476
466
|
readonly internalType: "address";
|
|
477
467
|
readonly type: "address";
|
|
478
468
|
}, {
|
|
479
|
-
readonly name: "
|
|
480
|
-
readonly internalType: "
|
|
481
|
-
readonly type: "
|
|
469
|
+
readonly name: "pendingOperator";
|
|
470
|
+
readonly internalType: "address";
|
|
471
|
+
readonly type: "address";
|
|
482
472
|
}, {
|
|
483
473
|
readonly name: "incomeTaken";
|
|
484
474
|
readonly internalType: "uint256";
|
|
@@ -527,9 +517,9 @@ export declare const fPoolManagerAbi: readonly [{
|
|
|
527
517
|
readonly internalType: "uint256";
|
|
528
518
|
readonly type: "uint256";
|
|
529
519
|
}, {
|
|
530
|
-
readonly name: "
|
|
531
|
-
readonly internalType: "
|
|
532
|
-
readonly type: "
|
|
520
|
+
readonly name: "kind";
|
|
521
|
+
readonly internalType: "enum Kind";
|
|
522
|
+
readonly type: "uint8";
|
|
533
523
|
}, {
|
|
534
524
|
readonly name: "authority";
|
|
535
525
|
readonly internalType: "address";
|
|
@@ -570,9 +560,9 @@ export declare const fPoolManagerAbi: readonly [{
|
|
|
570
560
|
readonly internalType: "uint256";
|
|
571
561
|
readonly type: "uint256";
|
|
572
562
|
}, {
|
|
573
|
-
readonly name: "
|
|
574
|
-
readonly internalType: "
|
|
575
|
-
readonly type: "
|
|
563
|
+
readonly name: "kind";
|
|
564
|
+
readonly internalType: "enum Kind";
|
|
565
|
+
readonly type: "uint8";
|
|
576
566
|
}, {
|
|
577
567
|
readonly name: "authority";
|
|
578
568
|
readonly internalType: "address";
|
|
@@ -1357,26 +1347,6 @@ export declare const fPoolManagerAbi: readonly [{
|
|
|
1357
1347
|
readonly indexed: true;
|
|
1358
1348
|
}];
|
|
1359
1349
|
readonly name: "CollectorProposed";
|
|
1360
|
-
}, {
|
|
1361
|
-
readonly type: "event";
|
|
1362
|
-
readonly anonymous: false;
|
|
1363
|
-
readonly inputs: readonly [{
|
|
1364
|
-
readonly name: "poolId";
|
|
1365
|
-
readonly internalType: "bytes32";
|
|
1366
|
-
readonly type: "bytes32";
|
|
1367
|
-
readonly indexed: true;
|
|
1368
|
-
}, {
|
|
1369
|
-
readonly name: "from";
|
|
1370
|
-
readonly internalType: "address";
|
|
1371
|
-
readonly type: "address";
|
|
1372
|
-
readonly indexed: true;
|
|
1373
|
-
}, {
|
|
1374
|
-
readonly name: "amount";
|
|
1375
|
-
readonly internalType: "uint256";
|
|
1376
|
-
readonly type: "uint256";
|
|
1377
|
-
readonly indexed: false;
|
|
1378
|
-
}];
|
|
1379
|
-
readonly name: "Deepen";
|
|
1380
1350
|
}, {
|
|
1381
1351
|
readonly type: "event";
|
|
1382
1352
|
readonly anonymous: false;
|
|
@@ -1536,9 +1506,9 @@ export declare const fPoolManagerAbi: readonly [{
|
|
|
1536
1506
|
readonly type: "uint256";
|
|
1537
1507
|
readonly indexed: false;
|
|
1538
1508
|
}, {
|
|
1539
|
-
readonly name: "
|
|
1540
|
-
readonly internalType: "
|
|
1541
|
-
readonly type: "
|
|
1509
|
+
readonly name: "kind";
|
|
1510
|
+
readonly internalType: "enum Kind";
|
|
1511
|
+
readonly type: "uint8";
|
|
1542
1512
|
readonly indexed: false;
|
|
1543
1513
|
}];
|
|
1544
1514
|
readonly name: "Initialize";
|
|
@@ -1551,62 +1521,22 @@ export declare const fPoolManagerAbi: readonly [{
|
|
|
1551
1521
|
readonly type: "bytes32";
|
|
1552
1522
|
readonly indexed: true;
|
|
1553
1523
|
}, {
|
|
1554
|
-
readonly name: "
|
|
1524
|
+
readonly name: "gen";
|
|
1555
1525
|
readonly internalType: "uint256";
|
|
1556
1526
|
readonly type: "uint256";
|
|
1557
1527
|
readonly indexed: true;
|
|
1558
1528
|
}, {
|
|
1559
|
-
readonly name: "
|
|
1560
|
-
readonly internalType: "address";
|
|
1561
|
-
readonly type: "address";
|
|
1562
|
-
readonly indexed: false;
|
|
1563
|
-
}, {
|
|
1564
|
-
readonly name: "newLj";
|
|
1565
|
-
readonly internalType: "uint256";
|
|
1566
|
-
readonly type: "uint256";
|
|
1567
|
-
readonly indexed: false;
|
|
1568
|
-
}, {
|
|
1569
|
-
readonly name: "reserve";
|
|
1570
|
-
readonly internalType: "uint256";
|
|
1571
|
-
readonly type: "uint256";
|
|
1572
|
-
readonly indexed: false;
|
|
1573
|
-
}, {
|
|
1574
|
-
readonly name: "L";
|
|
1575
|
-
readonly internalType: "uint256";
|
|
1576
|
-
readonly type: "uint256";
|
|
1577
|
-
readonly indexed: false;
|
|
1578
|
-
}, {
|
|
1579
|
-
readonly name: "theta0";
|
|
1580
|
-
readonly internalType: "int256";
|
|
1581
|
-
readonly type: "int256";
|
|
1582
|
-
readonly indexed: false;
|
|
1583
|
-
}, {
|
|
1584
|
-
readonly name: "dReserve";
|
|
1585
|
-
readonly internalType: "int256";
|
|
1586
|
-
readonly type: "int256";
|
|
1587
|
-
readonly indexed: false;
|
|
1588
|
-
}, {
|
|
1589
|
-
readonly name: "dShares";
|
|
1590
|
-
readonly internalType: "int256";
|
|
1591
|
-
readonly type: "int256";
|
|
1529
|
+
readonly name: "bases";
|
|
1530
|
+
readonly internalType: "address[]";
|
|
1531
|
+
readonly type: "address[]";
|
|
1592
1532
|
readonly indexed: false;
|
|
1593
|
-
}];
|
|
1594
|
-
readonly name: "LegSet";
|
|
1595
|
-
}, {
|
|
1596
|
-
readonly type: "event";
|
|
1597
|
-
readonly anonymous: false;
|
|
1598
|
-
readonly inputs: readonly [{
|
|
1599
|
-
readonly name: "poolId";
|
|
1600
|
-
readonly internalType: "bytes32";
|
|
1601
|
-
readonly type: "bytes32";
|
|
1602
|
-
readonly indexed: true;
|
|
1603
1533
|
}, {
|
|
1604
|
-
readonly name: "
|
|
1605
|
-
readonly internalType: "uint256";
|
|
1606
|
-
readonly type: "uint256";
|
|
1534
|
+
readonly name: "weights";
|
|
1535
|
+
readonly internalType: "uint256[]";
|
|
1536
|
+
readonly type: "uint256[]";
|
|
1607
1537
|
readonly indexed: false;
|
|
1608
1538
|
}];
|
|
1609
|
-
readonly name: "
|
|
1539
|
+
readonly name: "LegsSet";
|
|
1610
1540
|
}, {
|
|
1611
1541
|
readonly type: "event";
|
|
1612
1542
|
readonly anonymous: false;
|
|
@@ -1652,6 +1582,26 @@ export declare const fPoolManagerAbi: readonly [{
|
|
|
1652
1582
|
readonly indexed: false;
|
|
1653
1583
|
}];
|
|
1654
1584
|
readonly name: "NameSet";
|
|
1585
|
+
}, {
|
|
1586
|
+
readonly type: "event";
|
|
1587
|
+
readonly anonymous: false;
|
|
1588
|
+
readonly inputs: readonly [{
|
|
1589
|
+
readonly name: "poolId";
|
|
1590
|
+
readonly internalType: "bytes32";
|
|
1591
|
+
readonly type: "bytes32";
|
|
1592
|
+
readonly indexed: true;
|
|
1593
|
+
}, {
|
|
1594
|
+
readonly name: "current";
|
|
1595
|
+
readonly internalType: "address";
|
|
1596
|
+
readonly type: "address";
|
|
1597
|
+
readonly indexed: true;
|
|
1598
|
+
}, {
|
|
1599
|
+
readonly name: "proposed";
|
|
1600
|
+
readonly internalType: "address";
|
|
1601
|
+
readonly type: "address";
|
|
1602
|
+
readonly indexed: true;
|
|
1603
|
+
}];
|
|
1604
|
+
readonly name: "OperatorProposed";
|
|
1655
1605
|
}, {
|
|
1656
1606
|
readonly type: "event";
|
|
1657
1607
|
readonly anonymous: false;
|
|
@@ -1886,35 +1836,35 @@ export declare const fPoolManagerAbi: readonly [{
|
|
|
1886
1836
|
}, {
|
|
1887
1837
|
readonly type: "error";
|
|
1888
1838
|
readonly inputs: readonly [];
|
|
1889
|
-
readonly name: "
|
|
1839
|
+
readonly name: "BadWeights";
|
|
1890
1840
|
}, {
|
|
1891
1841
|
readonly type: "error";
|
|
1892
1842
|
readonly inputs: readonly [];
|
|
1893
|
-
readonly name: "
|
|
1843
|
+
readonly name: "BalanceOverflow";
|
|
1894
1844
|
}, {
|
|
1895
1845
|
readonly type: "error";
|
|
1896
1846
|
readonly inputs: readonly [];
|
|
1897
|
-
readonly name: "
|
|
1847
|
+
readonly name: "FloorLocked";
|
|
1898
1848
|
}, {
|
|
1899
1849
|
readonly type: "error";
|
|
1900
1850
|
readonly inputs: readonly [];
|
|
1901
|
-
readonly name: "
|
|
1851
|
+
readonly name: "InsufficientBalance";
|
|
1902
1852
|
}, {
|
|
1903
1853
|
readonly type: "error";
|
|
1904
1854
|
readonly inputs: readonly [];
|
|
1905
|
-
readonly name: "
|
|
1855
|
+
readonly name: "InsufficientPermission";
|
|
1906
1856
|
}, {
|
|
1907
1857
|
readonly type: "error";
|
|
1908
1858
|
readonly inputs: readonly [];
|
|
1909
|
-
readonly name: "
|
|
1859
|
+
readonly name: "InsufficientQuote";
|
|
1910
1860
|
}, {
|
|
1911
1861
|
readonly type: "error";
|
|
1912
1862
|
readonly inputs: readonly [];
|
|
1913
|
-
readonly name: "
|
|
1863
|
+
readonly name: "InvalidToken";
|
|
1914
1864
|
}, {
|
|
1915
1865
|
readonly type: "error";
|
|
1916
1866
|
readonly inputs: readonly [];
|
|
1917
|
-
readonly name: "
|
|
1867
|
+
readonly name: "LegHeld";
|
|
1918
1868
|
}, {
|
|
1919
1869
|
readonly type: "error";
|
|
1920
1870
|
readonly inputs: readonly [{
|
|
@@ -1954,15 +1904,15 @@ export declare const fPoolManagerAbi: readonly [{
|
|
|
1954
1904
|
}, {
|
|
1955
1905
|
readonly type: "error";
|
|
1956
1906
|
readonly inputs: readonly [];
|
|
1957
|
-
readonly name: "
|
|
1907
|
+
readonly name: "NotPrivate";
|
|
1958
1908
|
}, {
|
|
1959
1909
|
readonly type: "error";
|
|
1960
1910
|
readonly inputs: readonly [];
|
|
1961
|
-
readonly name: "
|
|
1911
|
+
readonly name: "NotRetired";
|
|
1962
1912
|
}, {
|
|
1963
1913
|
readonly type: "error";
|
|
1964
1914
|
readonly inputs: readonly [];
|
|
1965
|
-
readonly name: "
|
|
1915
|
+
readonly name: "NotSeeded";
|
|
1966
1916
|
}, {
|
|
1967
1917
|
readonly type: "error";
|
|
1968
1918
|
readonly inputs: readonly [];
|
|
@@ -2003,10 +1953,6 @@ export declare const fPoolManagerAbi: readonly [{
|
|
|
2003
1953
|
readonly type: "error";
|
|
2004
1954
|
readonly inputs: readonly [];
|
|
2005
1955
|
readonly name: "Slippage";
|
|
2006
|
-
}, {
|
|
2007
|
-
readonly type: "error";
|
|
2008
|
-
readonly inputs: readonly [];
|
|
2009
|
-
readonly name: "StrikeLocked";
|
|
2010
1956
|
}, {
|
|
2011
1957
|
readonly type: "error";
|
|
2012
1958
|
readonly inputs: readonly [];
|
|
@@ -2055,16 +2001,6 @@ export declare const fPoolManagerAbi: readonly [{
|
|
|
2055
2001
|
readonly type: "uint256";
|
|
2056
2002
|
}];
|
|
2057
2003
|
readonly stateMutability: "view";
|
|
2058
|
-
}, {
|
|
2059
|
-
readonly type: "function";
|
|
2060
|
-
readonly inputs: readonly [];
|
|
2061
|
-
readonly name: "LEVER_FLOOR";
|
|
2062
|
-
readonly outputs: readonly [{
|
|
2063
|
-
readonly name: "";
|
|
2064
|
-
readonly internalType: "uint256";
|
|
2065
|
-
readonly type: "uint256";
|
|
2066
|
-
}];
|
|
2067
|
-
readonly stateMutability: "view";
|
|
2068
2004
|
}, {
|
|
2069
2005
|
readonly type: "function";
|
|
2070
2006
|
readonly inputs: readonly [];
|
|
@@ -2107,29 +2043,9 @@ export declare const fPoolManagerAbi: readonly [{
|
|
|
2107
2043
|
readonly name: "poolId";
|
|
2108
2044
|
readonly internalType: "bytes32";
|
|
2109
2045
|
readonly type: "bytes32";
|
|
2110
|
-
}, {
|
|
2111
|
-
readonly name: "base";
|
|
2112
|
-
readonly internalType: "address";
|
|
2113
|
-
readonly type: "address";
|
|
2114
|
-
}, {
|
|
2115
|
-
readonly name: "Lj";
|
|
2116
|
-
readonly internalType: "uint256";
|
|
2117
|
-
readonly type: "uint256";
|
|
2118
|
-
}, {
|
|
2119
|
-
readonly name: "R";
|
|
2120
|
-
readonly internalType: "uint256";
|
|
2121
|
-
readonly type: "uint256";
|
|
2122
|
-
}];
|
|
2123
|
-
readonly name: "admitLeg";
|
|
2124
|
-
readonly outputs: readonly [{
|
|
2125
|
-
readonly name: "dReserve";
|
|
2126
|
-
readonly internalType: "int256";
|
|
2127
|
-
readonly type: "int256";
|
|
2128
|
-
}, {
|
|
2129
|
-
readonly name: "dShares";
|
|
2130
|
-
readonly internalType: "int256";
|
|
2131
|
-
readonly type: "int256";
|
|
2132
2046
|
}];
|
|
2047
|
+
readonly name: "acceptOperator";
|
|
2048
|
+
readonly outputs: readonly [];
|
|
2133
2049
|
readonly stateMutability: "nonpayable";
|
|
2134
2050
|
}, {
|
|
2135
2051
|
readonly type: "function";
|
|
@@ -2343,20 +2259,6 @@ export declare const fPoolManagerAbi: readonly [{
|
|
|
2343
2259
|
readonly type: "uint8";
|
|
2344
2260
|
}];
|
|
2345
2261
|
readonly stateMutability: "view";
|
|
2346
|
-
}, {
|
|
2347
|
-
readonly type: "function";
|
|
2348
|
-
readonly inputs: readonly [{
|
|
2349
|
-
readonly name: "poolId";
|
|
2350
|
-
readonly internalType: "bytes32";
|
|
2351
|
-
readonly type: "bytes32";
|
|
2352
|
-
}, {
|
|
2353
|
-
readonly name: "amount";
|
|
2354
|
-
readonly internalType: "uint256";
|
|
2355
|
-
readonly type: "uint256";
|
|
2356
|
-
}];
|
|
2357
|
-
readonly name: "deepen";
|
|
2358
|
-
readonly outputs: readonly [];
|
|
2359
|
-
readonly stateMutability: "nonpayable";
|
|
2360
2262
|
}, {
|
|
2361
2263
|
readonly type: "function";
|
|
2362
2264
|
readonly inputs: readonly [{
|
|
@@ -2573,20 +2475,6 @@ export declare const fPoolManagerAbi: readonly [{
|
|
|
2573
2475
|
readonly name: "proposeCollector";
|
|
2574
2476
|
readonly outputs: readonly [];
|
|
2575
2477
|
readonly stateMutability: "nonpayable";
|
|
2576
|
-
}, {
|
|
2577
|
-
readonly type: "function";
|
|
2578
|
-
readonly inputs: readonly [{
|
|
2579
|
-
readonly name: "poolId";
|
|
2580
|
-
readonly internalType: "bytes32";
|
|
2581
|
-
readonly type: "bytes32";
|
|
2582
|
-
}, {
|
|
2583
|
-
readonly name: "minBuffer";
|
|
2584
|
-
readonly internalType: "uint256";
|
|
2585
|
-
readonly type: "uint256";
|
|
2586
|
-
}];
|
|
2587
|
-
readonly name: "raiseMinBuffer";
|
|
2588
|
-
readonly outputs: readonly [];
|
|
2589
|
-
readonly stateMutability: "nonpayable";
|
|
2590
2478
|
}, {
|
|
2591
2479
|
readonly type: "function";
|
|
2592
2480
|
readonly inputs: readonly [{
|
|
@@ -2658,28 +2546,16 @@ export declare const fPoolManagerAbi: readonly [{
|
|
|
2658
2546
|
readonly internalType: "bytes32";
|
|
2659
2547
|
readonly type: "bytes32";
|
|
2660
2548
|
}, {
|
|
2661
|
-
readonly name: "
|
|
2662
|
-
readonly internalType: "uint256";
|
|
2663
|
-
readonly type: "uint256";
|
|
2664
|
-
}, {
|
|
2665
|
-
readonly name: "newLj";
|
|
2666
|
-
readonly internalType: "uint256";
|
|
2667
|
-
readonly type: "uint256";
|
|
2668
|
-
}, {
|
|
2669
|
-
readonly name: "rIfNew";
|
|
2670
|
-
readonly internalType: "uint256";
|
|
2671
|
-
readonly type: "uint256";
|
|
2672
|
-
}];
|
|
2673
|
-
readonly name: "setLegL";
|
|
2674
|
-
readonly outputs: readonly [{
|
|
2675
|
-
readonly name: "dReserve";
|
|
2676
|
-
readonly internalType: "int256";
|
|
2677
|
-
readonly type: "int256";
|
|
2549
|
+
readonly name: "weights";
|
|
2550
|
+
readonly internalType: "uint256[]";
|
|
2551
|
+
readonly type: "uint256[]";
|
|
2678
2552
|
}, {
|
|
2679
|
-
readonly name: "
|
|
2680
|
-
readonly internalType: "
|
|
2681
|
-
readonly type: "
|
|
2553
|
+
readonly name: "newBases";
|
|
2554
|
+
readonly internalType: "address[]";
|
|
2555
|
+
readonly type: "address[]";
|
|
2682
2556
|
}];
|
|
2557
|
+
readonly name: "setLegs";
|
|
2558
|
+
readonly outputs: readonly [];
|
|
2683
2559
|
readonly stateMutability: "nonpayable";
|
|
2684
2560
|
}, {
|
|
2685
2561
|
readonly type: "function";
|
|
@@ -3070,26 +2946,6 @@ export declare const fPoolManagerAbi: readonly [{
|
|
|
3070
2946
|
readonly indexed: true;
|
|
3071
2947
|
}];
|
|
3072
2948
|
readonly name: "CollectorProposed";
|
|
3073
|
-
}, {
|
|
3074
|
-
readonly type: "event";
|
|
3075
|
-
readonly anonymous: false;
|
|
3076
|
-
readonly inputs: readonly [{
|
|
3077
|
-
readonly name: "poolId";
|
|
3078
|
-
readonly internalType: "bytes32";
|
|
3079
|
-
readonly type: "bytes32";
|
|
3080
|
-
readonly indexed: true;
|
|
3081
|
-
}, {
|
|
3082
|
-
readonly name: "from";
|
|
3083
|
-
readonly internalType: "address";
|
|
3084
|
-
readonly type: "address";
|
|
3085
|
-
readonly indexed: true;
|
|
3086
|
-
}, {
|
|
3087
|
-
readonly name: "amount";
|
|
3088
|
-
readonly internalType: "uint256";
|
|
3089
|
-
readonly type: "uint256";
|
|
3090
|
-
readonly indexed: false;
|
|
3091
|
-
}];
|
|
3092
|
-
readonly name: "Deepen";
|
|
3093
2949
|
}, {
|
|
3094
2950
|
readonly type: "event";
|
|
3095
2951
|
readonly anonymous: false;
|
|
@@ -3249,9 +3105,9 @@ export declare const fPoolManagerAbi: readonly [{
|
|
|
3249
3105
|
readonly type: "uint256";
|
|
3250
3106
|
readonly indexed: false;
|
|
3251
3107
|
}, {
|
|
3252
|
-
readonly name: "
|
|
3253
|
-
readonly internalType: "
|
|
3254
|
-
readonly type: "
|
|
3108
|
+
readonly name: "kind";
|
|
3109
|
+
readonly internalType: "enum Kind";
|
|
3110
|
+
readonly type: "uint8";
|
|
3255
3111
|
readonly indexed: false;
|
|
3256
3112
|
}];
|
|
3257
3113
|
readonly name: "Initialize";
|
|
@@ -3264,62 +3120,22 @@ export declare const fPoolManagerAbi: readonly [{
|
|
|
3264
3120
|
readonly type: "bytes32";
|
|
3265
3121
|
readonly indexed: true;
|
|
3266
3122
|
}, {
|
|
3267
|
-
readonly name: "
|
|
3123
|
+
readonly name: "gen";
|
|
3268
3124
|
readonly internalType: "uint256";
|
|
3269
3125
|
readonly type: "uint256";
|
|
3270
3126
|
readonly indexed: true;
|
|
3271
3127
|
}, {
|
|
3272
|
-
readonly name: "
|
|
3273
|
-
readonly internalType: "address";
|
|
3274
|
-
readonly type: "address";
|
|
3275
|
-
readonly indexed: false;
|
|
3276
|
-
}, {
|
|
3277
|
-
readonly name: "newLj";
|
|
3278
|
-
readonly internalType: "uint256";
|
|
3279
|
-
readonly type: "uint256";
|
|
3280
|
-
readonly indexed: false;
|
|
3281
|
-
}, {
|
|
3282
|
-
readonly name: "reserve";
|
|
3283
|
-
readonly internalType: "uint256";
|
|
3284
|
-
readonly type: "uint256";
|
|
3285
|
-
readonly indexed: false;
|
|
3286
|
-
}, {
|
|
3287
|
-
readonly name: "L";
|
|
3288
|
-
readonly internalType: "uint256";
|
|
3289
|
-
readonly type: "uint256";
|
|
3290
|
-
readonly indexed: false;
|
|
3291
|
-
}, {
|
|
3292
|
-
readonly name: "theta0";
|
|
3293
|
-
readonly internalType: "int256";
|
|
3294
|
-
readonly type: "int256";
|
|
3295
|
-
readonly indexed: false;
|
|
3296
|
-
}, {
|
|
3297
|
-
readonly name: "dReserve";
|
|
3298
|
-
readonly internalType: "int256";
|
|
3299
|
-
readonly type: "int256";
|
|
3300
|
-
readonly indexed: false;
|
|
3301
|
-
}, {
|
|
3302
|
-
readonly name: "dShares";
|
|
3303
|
-
readonly internalType: "int256";
|
|
3304
|
-
readonly type: "int256";
|
|
3128
|
+
readonly name: "bases";
|
|
3129
|
+
readonly internalType: "address[]";
|
|
3130
|
+
readonly type: "address[]";
|
|
3305
3131
|
readonly indexed: false;
|
|
3306
|
-
}];
|
|
3307
|
-
readonly name: "LegSet";
|
|
3308
|
-
}, {
|
|
3309
|
-
readonly type: "event";
|
|
3310
|
-
readonly anonymous: false;
|
|
3311
|
-
readonly inputs: readonly [{
|
|
3312
|
-
readonly name: "poolId";
|
|
3313
|
-
readonly internalType: "bytes32";
|
|
3314
|
-
readonly type: "bytes32";
|
|
3315
|
-
readonly indexed: true;
|
|
3316
3132
|
}, {
|
|
3317
|
-
readonly name: "
|
|
3318
|
-
readonly internalType: "uint256";
|
|
3319
|
-
readonly type: "uint256";
|
|
3133
|
+
readonly name: "weights";
|
|
3134
|
+
readonly internalType: "uint256[]";
|
|
3135
|
+
readonly type: "uint256[]";
|
|
3320
3136
|
readonly indexed: false;
|
|
3321
3137
|
}];
|
|
3322
|
-
readonly name: "
|
|
3138
|
+
readonly name: "LegsSet";
|
|
3323
3139
|
}, {
|
|
3324
3140
|
readonly type: "event";
|
|
3325
3141
|
readonly anonymous: false;
|
|
@@ -3365,6 +3181,26 @@ export declare const fPoolManagerAbi: readonly [{
|
|
|
3365
3181
|
readonly indexed: false;
|
|
3366
3182
|
}];
|
|
3367
3183
|
readonly name: "NameSet";
|
|
3184
|
+
}, {
|
|
3185
|
+
readonly type: "event";
|
|
3186
|
+
readonly anonymous: false;
|
|
3187
|
+
readonly inputs: readonly [{
|
|
3188
|
+
readonly name: "poolId";
|
|
3189
|
+
readonly internalType: "bytes32";
|
|
3190
|
+
readonly type: "bytes32";
|
|
3191
|
+
readonly indexed: true;
|
|
3192
|
+
}, {
|
|
3193
|
+
readonly name: "current";
|
|
3194
|
+
readonly internalType: "address";
|
|
3195
|
+
readonly type: "address";
|
|
3196
|
+
readonly indexed: true;
|
|
3197
|
+
}, {
|
|
3198
|
+
readonly name: "proposed";
|
|
3199
|
+
readonly internalType: "address";
|
|
3200
|
+
readonly type: "address";
|
|
3201
|
+
readonly indexed: true;
|
|
3202
|
+
}];
|
|
3203
|
+
readonly name: "OperatorProposed";
|
|
3368
3204
|
}, {
|
|
3369
3205
|
readonly type: "event";
|
|
3370
3206
|
readonly anonymous: false;
|
|
@@ -3599,35 +3435,35 @@ export declare const fPoolManagerAbi: readonly [{
|
|
|
3599
3435
|
}, {
|
|
3600
3436
|
readonly type: "error";
|
|
3601
3437
|
readonly inputs: readonly [];
|
|
3602
|
-
readonly name: "
|
|
3438
|
+
readonly name: "BadWeights";
|
|
3603
3439
|
}, {
|
|
3604
3440
|
readonly type: "error";
|
|
3605
3441
|
readonly inputs: readonly [];
|
|
3606
|
-
readonly name: "
|
|
3442
|
+
readonly name: "BalanceOverflow";
|
|
3607
3443
|
}, {
|
|
3608
3444
|
readonly type: "error";
|
|
3609
3445
|
readonly inputs: readonly [];
|
|
3610
|
-
readonly name: "
|
|
3446
|
+
readonly name: "FloorLocked";
|
|
3611
3447
|
}, {
|
|
3612
3448
|
readonly type: "error";
|
|
3613
3449
|
readonly inputs: readonly [];
|
|
3614
|
-
readonly name: "
|
|
3450
|
+
readonly name: "InsufficientBalance";
|
|
3615
3451
|
}, {
|
|
3616
3452
|
readonly type: "error";
|
|
3617
3453
|
readonly inputs: readonly [];
|
|
3618
|
-
readonly name: "
|
|
3454
|
+
readonly name: "InsufficientPermission";
|
|
3619
3455
|
}, {
|
|
3620
3456
|
readonly type: "error";
|
|
3621
3457
|
readonly inputs: readonly [];
|
|
3622
|
-
readonly name: "
|
|
3458
|
+
readonly name: "InsufficientQuote";
|
|
3623
3459
|
}, {
|
|
3624
3460
|
readonly type: "error";
|
|
3625
3461
|
readonly inputs: readonly [];
|
|
3626
|
-
readonly name: "
|
|
3462
|
+
readonly name: "InvalidToken";
|
|
3627
3463
|
}, {
|
|
3628
3464
|
readonly type: "error";
|
|
3629
3465
|
readonly inputs: readonly [];
|
|
3630
|
-
readonly name: "
|
|
3466
|
+
readonly name: "LegHeld";
|
|
3631
3467
|
}, {
|
|
3632
3468
|
readonly type: "error";
|
|
3633
3469
|
readonly inputs: readonly [];
|
|
@@ -3663,15 +3499,15 @@ export declare const fPoolManagerAbi: readonly [{
|
|
|
3663
3499
|
}, {
|
|
3664
3500
|
readonly type: "error";
|
|
3665
3501
|
readonly inputs: readonly [];
|
|
3666
|
-
readonly name: "
|
|
3502
|
+
readonly name: "NotPrivate";
|
|
3667
3503
|
}, {
|
|
3668
3504
|
readonly type: "error";
|
|
3669
3505
|
readonly inputs: readonly [];
|
|
3670
|
-
readonly name: "
|
|
3506
|
+
readonly name: "NotRetired";
|
|
3671
3507
|
}, {
|
|
3672
3508
|
readonly type: "error";
|
|
3673
3509
|
readonly inputs: readonly [];
|
|
3674
|
-
readonly name: "
|
|
3510
|
+
readonly name: "NotSeeded";
|
|
3675
3511
|
}, {
|
|
3676
3512
|
readonly type: "error";
|
|
3677
3513
|
readonly inputs: readonly [];
|
|
@@ -3712,10 +3548,6 @@ export declare const fPoolManagerAbi: readonly [{
|
|
|
3712
3548
|
readonly type: "error";
|
|
3713
3549
|
readonly inputs: readonly [];
|
|
3714
3550
|
readonly name: "Slippage";
|
|
3715
|
-
}, {
|
|
3716
|
-
readonly type: "error";
|
|
3717
|
-
readonly inputs: readonly [];
|
|
3718
|
-
readonly name: "StrikeLocked";
|
|
3719
3551
|
}, {
|
|
3720
3552
|
readonly type: "error";
|
|
3721
3553
|
readonly inputs: readonly [];
|
|
@@ -3766,28 +3598,27 @@ export interface FPoolState {
|
|
|
3766
3598
|
compositeX: bigint;
|
|
3767
3599
|
/** Σ = ∫ Σ_j w_j (dx_j)², accrued even though the fee is fixed — the kernel stays calculable. */
|
|
3768
3600
|
bigSigma: bigint;
|
|
3769
|
-
/**
|
|
3601
|
+
/** The cold key (decisions 037): seeds the pool, hands it over, names it, gates it (private). A creator, a treasury, a governance contract. */
|
|
3770
3602
|
authority: Address;
|
|
3771
3603
|
/** The proposed next authority, until it accepts — zero when nothing is pending (decisions 020). */
|
|
3772
3604
|
pendingAuthority: Address;
|
|
3773
|
-
/**
|
|
3605
|
+
/**
|
|
3606
|
+
* The hot key that RUNS the pool (decisions 037): `harvest`, `dissolve`, `setLegs`. Zero means
|
|
3607
|
+
* the authority itself — see {@link fPoolOperatorOf}. Appointed two-step on a private pool.
|
|
3608
|
+
*/
|
|
3774
3609
|
operator: Address;
|
|
3610
|
+
/** The proposed next operator, until it accepts — zero when nothing is pending. */
|
|
3611
|
+
pendingOperator: Address;
|
|
3775
3612
|
/** The sponsor's own label for this pool, mutable and never identity. "" when unnamed. */
|
|
3776
3613
|
name: string;
|
|
3777
|
-
/** `harvest` may not take Q/L under this (WAD log-distance); raise-only (decisions 021). */
|
|
3778
|
-
minBuffer: bigint;
|
|
3779
3614
|
/** Only `allowed` accounts may receive minted shares. */
|
|
3780
3615
|
gateMint: boolean;
|
|
3781
3616
|
/** Only `allowed` takers may swap. */
|
|
3782
3617
|
gateSwap: boolean;
|
|
3783
|
-
/** The block of the last
|
|
3618
|
+
/** The block of the last harvest / composition action: no swap runs in it. */
|
|
3784
3619
|
restructureBlock: number;
|
|
3785
|
-
/**
|
|
3786
|
-
|
|
3787
|
-
* and never past it, so only income can leave; and the pool cannot be dissolved while it bids.
|
|
3788
|
-
* The pad's promise. Pairs with a locked seed (shares at 0xdead) — the class is the two bits.
|
|
3789
|
-
*/
|
|
3790
|
-
lockStrike: boolean;
|
|
3620
|
+
/** The rung — see {@link FPoolKind}. */
|
|
3621
|
+
kind: FPoolKind;
|
|
3791
3622
|
/** False before the first seed — and between a dissolve and the next one (decisions 032). */
|
|
3792
3623
|
seeded: boolean;
|
|
3793
3624
|
/**
|
|
@@ -3802,7 +3633,26 @@ export interface FPoolState {
|
|
|
3802
3633
|
}
|
|
3803
3634
|
/** Read a basket pool whole. Batched — viem multicalls these when the transport allows. */
|
|
3804
3635
|
export declare function getFPool(c: LogswapClient, poolId: Hex): Promise<FPoolState>;
|
|
3805
|
-
/**
|
|
3636
|
+
/**
|
|
3637
|
+
* The kind of pool (decisions 036, 038). `public`: the protocol's own pool — born with the fee
|
|
3638
|
+
* collector as its authority (which may hand it to a governance contract); no gates, no operator.
|
|
3639
|
+
* `private`, the desk: every entry — gates, a list, an operator that reshapes the legs between
|
|
3640
|
+
* generations, an unbounded harvest, the seed kept. `pol`, a treasury's pool or a basket: no
|
|
3641
|
+
* gates, no operator — composition and access fixed at birth; harvest unbounded, seed the
|
|
3642
|
+
* seeder's. `pad`, a launch: a POL whose harvest never lifts the floor above the seed floor and
|
|
3643
|
+
* whose seed the contract minted to 0xdead — one asset, open to all. private → pol → pad is the
|
|
3644
|
+
* ladder of rigidity; public is a pol held by the protocol.
|
|
3645
|
+
*/
|
|
3646
|
+
export type FPoolKind = "public" | "private" | "pol" | "pad";
|
|
3647
|
+
/** The key's enum values. */
|
|
3648
|
+
export declare const F_KIND: {
|
|
3649
|
+
readonly public: 0;
|
|
3650
|
+
readonly private: 1;
|
|
3651
|
+
readonly pol: 2;
|
|
3652
|
+
readonly pad: 3;
|
|
3653
|
+
};
|
|
3654
|
+
export declare function fPoolKindOf(n: number | bigint): FPoolKind;
|
|
3655
|
+
/** Which of the two products a pool is configured as — a pad is a launch, anything else a basket/pool. A UI has to choose what to render. */
|
|
3806
3656
|
export type FPoolShape = "launch" | "basket";
|
|
3807
3657
|
export interface FPoolDescription {
|
|
3808
3658
|
shape: FPoolShape;
|
|
@@ -3939,8 +3789,9 @@ export declare function fPoolPreviewRollIn(c: LogswapClient, poolId: Hex, gen: b
|
|
|
3939
3789
|
* Remove quote, lifting θ — price-neutral, no base moves, and since decisions 028 a DIVIDEND to
|
|
3940
3790
|
* every share: the amount goes into the pool's pot and each holder's slice is settled lazily on
|
|
3941
3791
|
* their next transfer, mint or burn, or pulled with {@link fPoolClaim}. The sponsor's own slice —
|
|
3942
|
-
* its shares' and the locked seed's at 0xdead — is pushed to `to` at once.
|
|
3943
|
-
* the lift stops at θ₀ (income only);
|
|
3792
|
+
* its shares' and the locked seed's at 0xdead — is pushed to `to` at once. On a pad
|
|
3793
|
+
* the lift stops at the seed floor θ₀ (income only); nothing else bounds it (decisions 035) — an
|
|
3794
|
+
* unlocked pool's authority may take Q to zero.
|
|
3944
3795
|
*/
|
|
3945
3796
|
export declare function fPoolHarvest(c: LogswapClient, a: {
|
|
3946
3797
|
poolId: Hex;
|
|
@@ -3961,14 +3812,6 @@ export declare function fPoolClaim(c: LogswapClient, a: {
|
|
|
3961
3812
|
}): Promise<`0x${string}`>;
|
|
3962
3813
|
/** A holder's dividend as of now on generation `gen` (the live one by default) — banked plus pending on the current balance (decisions 028). */
|
|
3963
3814
|
export declare function fPoolDividendOf(c: LogswapClient, poolId: Hex, holder: Address, gen?: bigint | number): Promise<bigint>;
|
|
3964
|
-
/** The lever's floor: `harvest` may not take Q/L under ln 1.25 — the floor stays ≥ 20% below the mark (decisions 025). */
|
|
3965
|
-
export declare const LEVER_FLOOR = 223143551314209755n;
|
|
3966
|
-
/** Commit quote, deepening θ — the other sign of `harvest`, the same word as the C floor edit (decisions 011). The mark does not move: governance may write θ, never x. */
|
|
3967
|
-
export declare function fPoolDeepen(c: LogswapClient, a: {
|
|
3968
|
-
poolId: Hex;
|
|
3969
|
-
amount: bigint;
|
|
3970
|
-
account: Address;
|
|
3971
|
-
}): Promise<`0x${string}`>;
|
|
3972
3815
|
/** Plain ERC-20 approval to the F manager — the allowance every DIRECT call pulls against. */
|
|
3973
3816
|
export declare function approveTokenForFPoolManager(c: LogswapClient, token: Address): Promise<Hash>;
|
|
3974
3817
|
/** Does `owner` have enough allowance on `token` for the MANAGER to pull `need`? */
|
|
@@ -4048,8 +3891,8 @@ export interface FPoolCreateArgs {
|
|
|
4048
3891
|
weights: bigint[];
|
|
4049
3892
|
/** Fixed fee, WAD. The base-for-base fee is pinned at 2φ on-chain. */
|
|
4050
3893
|
phi: bigint;
|
|
4051
|
-
/**
|
|
4052
|
-
|
|
3894
|
+
/** The rung (decisions 036) — see {@link FPoolKind}. In the key: the pool's identity, never changed after. */
|
|
3895
|
+
kind: FPoolKind;
|
|
4053
3896
|
authority: Address;
|
|
4054
3897
|
/**
|
|
4055
3898
|
* The differentiator, and nothing else. Identity is the key's hash, so one sponsor cannot run
|
|
@@ -4099,30 +3942,60 @@ export declare function fPoolSeed(c: LogswapClient, a: {
|
|
|
4099
3942
|
weights: bigint[];
|
|
4100
3943
|
})): Promise<`0x${string}`>;
|
|
4101
3944
|
/**
|
|
4102
|
-
* Retire the live generation (decisions 025, 032)
|
|
4103
|
-
*
|
|
4104
|
-
*
|
|
4105
|
-
* ({@link
|
|
4106
|
-
*
|
|
3945
|
+
* Retire the live generation (decisions 025, 032, 035) — the raw entry. Allowed only at an empty
|
|
3946
|
+
* bid, Q ≤ L/1e9, on every pool: the market took it, or the authority harvested it out first
|
|
3947
|
+
* ({@link fPoolRetire} does both in one transaction). The live (S, Q, R_j) become a frozen bundle
|
|
3948
|
+
* every share of this generation redeems ({@link fPoolRedeem}) or rolls ({@link fPoolRollIn}),
|
|
3949
|
+
* forever; the pool is unseeded until the next {@link fPoolSeed}, which opens generation
|
|
3950
|
+
* `gen + 1` under the same id, gates and lists.
|
|
4107
3951
|
*/
|
|
4108
3952
|
export declare function fPoolDissolve(c: LogswapClient, a: {
|
|
4109
3953
|
poolId: Hex;
|
|
4110
3954
|
account: Address;
|
|
4111
3955
|
}): Promise<`0x${string}`>;
|
|
4112
3956
|
/**
|
|
4113
|
-
*
|
|
4114
|
-
*
|
|
4115
|
-
*
|
|
4116
|
-
*
|
|
4117
|
-
|
|
4118
|
-
|
|
3957
|
+
* Retire the live generation as ONE transaction: the harvests that empty the bid
|
|
3958
|
+
* ({@link fPoolEmptyingHarvests} — a dividend to every share; none when it is already empty),
|
|
3959
|
+
* then `dissolve` — the manager's `multicall`, the authority as sender. What a sponsor's
|
|
3960
|
+
* "dissolve" button should call. Throws before sending on a pad that still bids.
|
|
3961
|
+
*/
|
|
3962
|
+
export declare function fPoolRetire(c: LogswapClient, a: {
|
|
3963
|
+
poolId: Hex;
|
|
3964
|
+
account: Address;
|
|
3965
|
+
}): Promise<`0x${string}`>;
|
|
3966
|
+
/**
|
|
3967
|
+
* The harvests that empty an unlocked pool's bid, in order — what a relaunch sends before its
|
|
3968
|
+
* `dissolve` (decisions 035: a dissolve needs an empty bid on every pool). One `harvest(Q)` when a
|
|
3969
|
+
* collector is set. With none, the cut on income STAYS in the pool as LP quote (decisions 002)
|
|
3970
|
+
* and reads as taken income, so a second harvest — capital, no cut — takes the rest; the
|
|
3971
|
+
* contract's own arithmetic, replayed. `[]` when the bid is already empty. Throws on a
|
|
3972
|
+
* pad that still bids (its bid empties only as the market sells it down), and in
|
|
3973
|
+
* the one shape two harvests cannot empty (no collector, income above Q — harvest by hand).
|
|
3974
|
+
*/
|
|
3975
|
+
export declare function fPoolEmptyingHarvests(c: LogswapClient, poolId: Hex): Promise<bigint[]>;
|
|
3976
|
+
/**
|
|
3977
|
+
* The relaunch as ONE transaction (decisions 025, 032, 035, 037): `harvest` the bid out — a
|
|
3978
|
+
* dividend to every share, {@link fPoolEmptyingHarvests} — `dissolve` the live generation at the
|
|
3979
|
+
* empty bid, `redeem` the caller's own shares of it (when `shares` > 0), optionally `setLegs` the
|
|
3980
|
+
* next generation's composition (`legs`: a private pool's reshape — retire, admit, reweight), and
|
|
3981
|
+
* `seed` it with what came back — the manager's `multicall`, one sender throughout, the same
|
|
3982
|
+
* pool. The operator's when one is appointed and the seed's inventory is its own; by default the
|
|
3983
|
+
* authority's. Gates, allowlist and names carry over; anything else goes in `extra`, pre-encoded
|
|
3984
|
+
* against {@link fPoolManagerAbi}. The seed names reserves (decisions 029): `r0` outright — one
|
|
3985
|
+
* per leg of the NEXT table, 0 for a retired leg — or `x0` marks against the next table's
|
|
3986
|
+
* `weights`.
|
|
4119
3987
|
*/
|
|
4120
3988
|
export declare function fPoolRelaunch(c: LogswapClient, a: {
|
|
4121
3989
|
poolId: Hex;
|
|
4122
|
-
/** the
|
|
3990
|
+
/** the caller's shares of the retiring generation to redeem inside the batch — its whole balance, usually; 0 to keep the claim */
|
|
4123
3991
|
shares: bigint;
|
|
4124
3992
|
L0: bigint;
|
|
4125
3993
|
Q0: bigint;
|
|
3994
|
+
/** the next generation's composition (decisions 037): one weight per existing leg (0 retires it), then one per new base */
|
|
3995
|
+
legs?: {
|
|
3996
|
+
weights: bigint[];
|
|
3997
|
+
newBases?: Address[];
|
|
3998
|
+
};
|
|
4126
3999
|
extra?: Hex[];
|
|
4127
4000
|
account: Address;
|
|
4128
4001
|
} & ({
|
|
@@ -4131,20 +4004,14 @@ export declare function fPoolRelaunch(c: LogswapClient, a: {
|
|
|
4131
4004
|
x0: bigint[];
|
|
4132
4005
|
weights: bigint[];
|
|
4133
4006
|
})): Promise<`0x${string}`>;
|
|
4134
|
-
/**
|
|
4007
|
+
/** Where a pad's seed lives (decisions 036): `seed` mints every share of a pad here itself. */
|
|
4135
4008
|
export declare const DEAD_ADDRESS: Address;
|
|
4136
|
-
/** The manager's `MIN_SHARES`: the seed mints this much to 0xdead
|
|
4009
|
+
/** The manager's `MIN_SHARES`: the seed mints this much to 0xdead on every pool, the rest to the seeder — or, on a pad, to 0xdead too. */
|
|
4137
4010
|
export declare const F_MIN_SHARES = 1000n;
|
|
4138
4011
|
export interface FPoolLaunchArgs extends Omit<FPoolCreateArgs, "account"> {
|
|
4139
4012
|
L0: bigint;
|
|
4140
4013
|
/** Quote the seed pulls. A pad seeds at 0 — pure float, a resting ask, nothing raised. */
|
|
4141
4014
|
Q0: bigint;
|
|
4142
|
-
/**
|
|
4143
|
-
* Send every share the seed mints to the creator (`L0 − MIN_SHARES`) to 0xdead in the same
|
|
4144
|
-
* batch: the float and the raise can never be burned out from under the buyers. The lever
|
|
4145
|
-
* (harvest) is the authority's and survives it; the exit does not. A pad's default posture.
|
|
4146
|
-
*/
|
|
4147
|
-
lockSeed?: boolean;
|
|
4148
4015
|
/**
|
|
4149
4016
|
* An opening buy of leg `j` (an index into `bases` AS GIVEN) for `amountIn` of quote, ON THE
|
|
4150
4017
|
* MANAGER — the same sender, a plain allowance to the manager, the router nowhere near it. A
|
|
@@ -4159,8 +4026,6 @@ export interface FPoolLaunchArgs extends Omit<FPoolCreateArgs, "account"> {
|
|
|
4159
4026
|
};
|
|
4160
4027
|
/** The pool's label, set in the batch (≤ 31 bytes of UTF-8). */
|
|
4161
4028
|
name?: string;
|
|
4162
|
-
/** Gate minting, list the creator, appoint them operator (decisions 021) — three calls, in the batch. */
|
|
4163
|
-
privatePool?: boolean;
|
|
4164
4029
|
/**
|
|
4165
4030
|
* The pool already exists (a previous launch got as far as `initialize` and no further — a seed
|
|
4166
4031
|
* that reverted, a closed tab, before the launch was one transaction), so `initialize` is left
|
|
@@ -4255,47 +4120,41 @@ export declare function fPoolSetSponsorName(c: LogswapClient, a: {
|
|
|
4255
4120
|
}): Promise<`0x${string}`>;
|
|
4256
4121
|
/** The protocol's attestation for an address, or "" when unattested — which most addresses are. */
|
|
4257
4122
|
export declare function fPoolSponsorName(c: LogswapClient, who: Address): Promise<string>;
|
|
4258
|
-
/**
|
|
4123
|
+
/** Who runs the pool (decisions 037): the appointed operator, or the authority until one is. */
|
|
4124
|
+
export declare function fPoolOperatorOf(s: Pick<FPoolState, "authority" | "operator">): Address;
|
|
4125
|
+
/**
|
|
4126
|
+
* Propose the operator (authority; private pools only) — the hot key that runs the pool: `harvest`,
|
|
4127
|
+
* `dissolve`, `setLegs`. Two-step: the proposed address takes the role with
|
|
4128
|
+
* {@link fPoolAcceptOperator}. The zero address clears at once — the role returns to the authority.
|
|
4129
|
+
*/
|
|
4259
4130
|
export declare function fPoolAppointOperator(c: LogswapClient, a: {
|
|
4260
4131
|
poolId: Hex;
|
|
4261
4132
|
operator: Address;
|
|
4262
4133
|
account: Address;
|
|
4263
4134
|
}): Promise<`0x${string}`>;
|
|
4264
|
-
/**
|
|
4265
|
-
|
|
4266
|
-
* spot is ln 1.25 ≈ 0.223e18). Raise-only — a commitment the authority cannot walk back.
|
|
4267
|
-
*/
|
|
4268
|
-
export declare function fPoolRaiseMinBuffer(c: LogswapClient, a: {
|
|
4135
|
+
/** The proposed operator takes the role. */
|
|
4136
|
+
export declare function fPoolAcceptOperator(c: LogswapClient, a: {
|
|
4269
4137
|
poolId: Hex;
|
|
4270
|
-
minBuffer: bigint;
|
|
4271
4138
|
account: Address;
|
|
4272
4139
|
}): Promise<`0x${string}`>;
|
|
4273
4140
|
/**
|
|
4274
|
-
*
|
|
4275
|
-
*
|
|
4276
|
-
*
|
|
4277
|
-
*
|
|
4278
|
-
*
|
|
4141
|
+
* The next generation's composition (operator; private pools only; ONLY while the pool is
|
|
4142
|
+
* unseeded — between a dissolve and the seed that prices it, decisions 037). `weights` has one
|
|
4143
|
+
* entry per leg the pool has ever had, in index order (0 retires a leg; indices are never reused),
|
|
4144
|
+
* then one per base in `newBases`, appended; they sum to 1e18 exactly. No value moves: the
|
|
4145
|
+
* following {@link fPoolSeed} names every reserve. A live reshape is {@link fPoolRelaunch} with
|
|
4146
|
+
* `legs` set.
|
|
4279
4147
|
*/
|
|
4280
|
-
export declare function
|
|
4148
|
+
export declare function fPoolSetLegs(c: LogswapClient, a: {
|
|
4281
4149
|
poolId: Hex;
|
|
4282
|
-
|
|
4283
|
-
|
|
4284
|
-
r?: bigint;
|
|
4285
|
-
account: Address;
|
|
4286
|
-
}): Promise<`0x${string}`>;
|
|
4287
|
-
/** Admit a base the pool has never held: `R` of it against liquidity `Lj`, so at `p = Lj / R` (operator, sole LP only). */
|
|
4288
|
-
export declare function fPoolAdmitLeg(c: LogswapClient, a: {
|
|
4289
|
-
poolId: Hex;
|
|
4290
|
-
base: Address;
|
|
4291
|
-
Lj: bigint;
|
|
4292
|
-
R: bigint;
|
|
4150
|
+
weights: bigint[];
|
|
4151
|
+
newBases?: Address[];
|
|
4293
4152
|
account: Address;
|
|
4294
4153
|
}): Promise<`0x${string}`>;
|
|
4295
4154
|
/**
|
|
4296
4155
|
* Move shares (ERC-6909 `transfer`) — to another holder, or to `0xdead` to lock them for good.
|
|
4297
4156
|
* Burning to the dead address is a sponsor's way to make its liquidity permanent: the shares can
|
|
4298
|
-
* never be redeemed
|
|
4157
|
+
* never be redeemed.
|
|
4299
4158
|
*/
|
|
4300
4159
|
export declare function fPoolTransferShares(c: LogswapClient, a: {
|
|
4301
4160
|
poolId: Hex;
|
|
@@ -4310,7 +4169,7 @@ export interface DiscoveredFPool {
|
|
|
4310
4169
|
bases: Address[];
|
|
4311
4170
|
weights: bigint[];
|
|
4312
4171
|
phi: bigint;
|
|
4313
|
-
|
|
4172
|
+
kind: FPoolKind;
|
|
4314
4173
|
authority: Address;
|
|
4315
4174
|
/** The block the pool was initialized in — its age, for annualising realized income. */
|
|
4316
4175
|
block: bigint;
|
|
@@ -4328,7 +4187,7 @@ export interface DiscoveredFPool {
|
|
|
4328
4187
|
}
|
|
4329
4188
|
/**
|
|
4330
4189
|
* Every F pool ever created, from `Initialize` logs alone. Possible only because the event
|
|
4331
|
-
* carries the full key preimage (bases, weights, phi,
|
|
4190
|
+
* carries the full key preimage (bases, weights, phi, pad) — the poolId is a hash and could
|
|
4332
4191
|
* never be inverted; contracts PR #17 exists for exactly this call.
|
|
4333
4192
|
*/
|
|
4334
4193
|
export declare function discoverFPools(c: LogswapClient, opts?: {
|
|
@@ -4347,7 +4206,7 @@ export declare function fPoolShareHolders(c: LogswapClient, poolIdHex: Hex, opts
|
|
|
4347
4206
|
holder: Address;
|
|
4348
4207
|
shares: bigint;
|
|
4349
4208
|
}>>;
|
|
4350
|
-
/** Every F pool's state in one lens call (the raw manager struct: quote, phi, authority,
|
|
4209
|
+
/** Every F pool's state in one lens call (the raw manager struct: quote, phi, authority, kind, seeded, gen, n, Q, L, shares, theta0, bigSigma, harvestedTheta). */
|
|
4351
4210
|
export declare function getFPoolsRaw(c: LogswapClient, poolIds: Hex[]): Promise<readonly unknown[]>;
|
|
4352
4211
|
/** Share value from the lens — (L + Q)/shares, WAD per share — the same figure as `fPoolShareValue`, from one source. */
|
|
4353
4212
|
export declare function shareValueOnChain(c: LogswapClient, poolId: Hex): Promise<bigint>;
|