ripple-binary-codec 1.8.0 → 1.9.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.
- package/dist/enums/definitions.json +249 -1
- package/dist/enums/src/enums/definitions.json +249 -1
- package/dist/types/index.js +2 -0
- package/dist/types/index.js.map +1 -1
- package/dist/types/issue.d.ts +39 -0
- package/dist/types/issue.js +81 -0
- package/dist/types/issue.js.map +1 -0
- package/dist/types/xchain-bridge.d.ts +45 -0
- package/dist/types/xchain-bridge.js +102 -0
- package/dist/types/xchain-bridge.js.map +1 -0
- package/package.json +3 -4
- package/src/README.md +3 -0
- package/src/binary.ts +188 -0
- package/src/coretypes.ts +31 -0
- package/src/enums/README.md +144 -0
- package/src/enums/bytes.ts +75 -0
- package/src/enums/constants.ts +4 -0
- package/src/enums/definitions.json +2599 -0
- package/src/enums/field.ts +85 -0
- package/src/enums/index.ts +34 -0
- package/src/enums/utils-renumber.ts +134 -0
- package/src/enums/xrpl-definitions-base.ts +111 -0
- package/src/enums/xrpl-definitions.ts +32 -0
- package/src/hash-prefixes.ts +40 -0
- package/src/hashes.ts +76 -0
- package/src/index.ts +141 -0
- package/src/ledger-hashes.ts +187 -0
- package/src/quality.ts +39 -0
- package/src/serdes/binary-parser.ts +217 -0
- package/src/serdes/binary-serializer.ts +166 -0
- package/src/shamap.ts +186 -0
- package/src/types/account-id.ts +86 -0
- package/src/types/amount.ts +256 -0
- package/src/types/blob.ts +43 -0
- package/src/types/currency.ts +140 -0
- package/src/types/hash-128.ts +33 -0
- package/src/types/hash-160.ts +20 -0
- package/src/types/hash-256.ts +16 -0
- package/src/types/hash.ts +81 -0
- package/src/types/index.ts +61 -0
- package/src/types/issue.ts +96 -0
- package/src/types/path-set.ts +290 -0
- package/src/types/serialized-type.ts +120 -0
- package/src/types/st-array.ts +107 -0
- package/src/types/st-object.ts +192 -0
- package/src/types/uint-16.ts +49 -0
- package/src/types/uint-32.ts +56 -0
- package/src/types/uint-64.ts +105 -0
- package/src/types/uint-8.ts +49 -0
- package/src/types/uint.ts +57 -0
- package/src/types/vector-256.ts +84 -0
- package/test/amount.test.js +0 -43
- package/test/binary-json.test.js +0 -45
- package/test/binary-parser.test.js +0 -396
- package/test/binary-serializer.test.js +0 -289
- package/test/definitions.test.js +0 -160
- package/test/fixtures/account-tx-transactions.db +0 -0
- package/test/fixtures/codec-fixtures.json +0 -4466
- package/test/fixtures/data-driven-tests.json +0 -2919
- package/test/fixtures/delivermin-tx-binary.json +0 -1
- package/test/fixtures/delivermin-tx.json +0 -98
- package/test/fixtures/deposit-preauth-tx-binary.json +0 -1
- package/test/fixtures/deposit-preauth-tx-meta-binary.json +0 -1
- package/test/fixtures/deposit-preauth-tx.json +0 -58
- package/test/fixtures/escrow-cancel-binary.json +0 -1
- package/test/fixtures/escrow-cancel-tx.json +0 -6
- package/test/fixtures/escrow-create-binary.json +0 -1
- package/test/fixtures/escrow-create-tx.json +0 -10
- package/test/fixtures/escrow-finish-binary.json +0 -1
- package/test/fixtures/escrow-finish-meta-binary.json +0 -1
- package/test/fixtures/escrow-finish-tx.json +0 -95
- package/test/fixtures/ledger-full-38129.json +0 -1
- package/test/fixtures/ledger-full-40000.json +0 -1
- package/test/fixtures/negative-unl.json +0 -12
- package/test/fixtures/nf-token.json +0 -547
- package/test/fixtures/payment-channel-claim-binary.json +0 -1
- package/test/fixtures/payment-channel-claim-tx.json +0 -8
- package/test/fixtures/payment-channel-create-binary.json +0 -1
- package/test/fixtures/payment-channel-create-tx.json +0 -11
- package/test/fixtures/payment-channel-fund-binary.json +0 -1
- package/test/fixtures/payment-channel-fund-tx.json +0 -7
- package/test/fixtures/signerlistset-tx-binary.json +0 -1
- package/test/fixtures/signerlistset-tx-meta-binary.json +0 -1
- package/test/fixtures/signerlistset-tx.json +0 -94
- package/test/fixtures/ticket-create-binary.json +0 -1
- package/test/fixtures/ticket-create-tx.json +0 -7
- package/test/fixtures/x-codec-fixtures.json +0 -188
- package/test/hash.test.js +0 -135
- package/test/ledger.test.js +0 -29
- package/test/lower-case-hex.test.js +0 -46
- package/test/pseudo-transaction.test.js +0 -38
- package/test/quality.test.js +0 -15
- package/test/shamap.test.js +0 -89
- package/test/signing-data-encoding.test.js +0 -242
- package/test/tx-encode-decode.test.js +0 -119
- package/test/types.test.js +0 -34
- package/test/uint.test.js +0 -148
- package/test/utils.js +0 -30
- package/test/x-address.test.js +0 -181
|
@@ -21,6 +21,7 @@
|
|
|
21
21
|
"UInt192": 21,
|
|
22
22
|
"UInt384": 22,
|
|
23
23
|
"UInt512": 23,
|
|
24
|
+
"Issue": 24,
|
|
24
25
|
"Transaction": 10001,
|
|
25
26
|
"LedgerEntry": 10002,
|
|
26
27
|
"Validation": 10003,
|
|
@@ -44,6 +45,7 @@
|
|
|
44
45
|
"NegativeUNL": 78,
|
|
45
46
|
"NFTokenPage": 80,
|
|
46
47
|
"NFTokenOffer": 55,
|
|
48
|
+
"AMM": 121,
|
|
47
49
|
"Any": -3,
|
|
48
50
|
"Child": -2,
|
|
49
51
|
"Nickname": 110,
|
|
@@ -271,6 +273,26 @@
|
|
|
271
273
|
"type": "UInt16"
|
|
272
274
|
}
|
|
273
275
|
],
|
|
276
|
+
[
|
|
277
|
+
"TradingFee",
|
|
278
|
+
{
|
|
279
|
+
"nth": 5,
|
|
280
|
+
"isVLEncoded": false,
|
|
281
|
+
"isSerialized": true,
|
|
282
|
+
"isSigningField": true,
|
|
283
|
+
"type": "UInt16"
|
|
284
|
+
}
|
|
285
|
+
],
|
|
286
|
+
[
|
|
287
|
+
"DiscountedFee",
|
|
288
|
+
{
|
|
289
|
+
"nth": 6,
|
|
290
|
+
"isVLEncoded": false,
|
|
291
|
+
"isSerialized": true,
|
|
292
|
+
"isSigningField": true,
|
|
293
|
+
"type": "UInt16"
|
|
294
|
+
}
|
|
295
|
+
],
|
|
274
296
|
[
|
|
275
297
|
"Version",
|
|
276
298
|
{
|
|
@@ -771,6 +793,26 @@
|
|
|
771
793
|
"type": "UInt32"
|
|
772
794
|
}
|
|
773
795
|
],
|
|
796
|
+
[
|
|
797
|
+
"VoteWeight",
|
|
798
|
+
{
|
|
799
|
+
"nth": 48,
|
|
800
|
+
"isVLEncoded": false,
|
|
801
|
+
"isSerialized": true,
|
|
802
|
+
"isSigningField": true,
|
|
803
|
+
"type": "UInt32"
|
|
804
|
+
}
|
|
805
|
+
],
|
|
806
|
+
[
|
|
807
|
+
"FirstNFTokenSequence",
|
|
808
|
+
{
|
|
809
|
+
"nth": 50,
|
|
810
|
+
"isVLEncoded": false,
|
|
811
|
+
"isSerialized": true,
|
|
812
|
+
"isSigningField": true,
|
|
813
|
+
"type": "UInt32"
|
|
814
|
+
}
|
|
815
|
+
],
|
|
774
816
|
[
|
|
775
817
|
"IndexNext",
|
|
776
818
|
{
|
|
@@ -1121,6 +1163,16 @@
|
|
|
1121
1163
|
"type": "Hash256"
|
|
1122
1164
|
}
|
|
1123
1165
|
],
|
|
1166
|
+
[
|
|
1167
|
+
"AMMID",
|
|
1168
|
+
{
|
|
1169
|
+
"nth": 14,
|
|
1170
|
+
"isVLEncoded": false,
|
|
1171
|
+
"isSerialized": true,
|
|
1172
|
+
"isSigningField": true,
|
|
1173
|
+
"type": "Hash256"
|
|
1174
|
+
}
|
|
1175
|
+
],
|
|
1124
1176
|
[
|
|
1125
1177
|
"BookDirectory",
|
|
1126
1178
|
{
|
|
@@ -1391,6 +1443,36 @@
|
|
|
1391
1443
|
"type": "Amount"
|
|
1392
1444
|
}
|
|
1393
1445
|
],
|
|
1446
|
+
[
|
|
1447
|
+
"Amount2",
|
|
1448
|
+
{
|
|
1449
|
+
"nth": 11,
|
|
1450
|
+
"isVLEncoded": false,
|
|
1451
|
+
"isSerialized": true,
|
|
1452
|
+
"isSigningField": true,
|
|
1453
|
+
"type": "Amount"
|
|
1454
|
+
}
|
|
1455
|
+
],
|
|
1456
|
+
[
|
|
1457
|
+
"BidMin",
|
|
1458
|
+
{
|
|
1459
|
+
"nth": 12,
|
|
1460
|
+
"isVLEncoded": false,
|
|
1461
|
+
"isSerialized": true,
|
|
1462
|
+
"isSigningField": true,
|
|
1463
|
+
"type": "Amount"
|
|
1464
|
+
}
|
|
1465
|
+
],
|
|
1466
|
+
[
|
|
1467
|
+
"BidMax",
|
|
1468
|
+
{
|
|
1469
|
+
"nth": 13,
|
|
1470
|
+
"isVLEncoded": false,
|
|
1471
|
+
"isSerialized": true,
|
|
1472
|
+
"isSigningField": true,
|
|
1473
|
+
"type": "Amount"
|
|
1474
|
+
}
|
|
1475
|
+
],
|
|
1394
1476
|
[
|
|
1395
1477
|
"MinimumOffer",
|
|
1396
1478
|
{
|
|
@@ -1431,6 +1513,86 @@
|
|
|
1431
1513
|
"type": "Amount"
|
|
1432
1514
|
}
|
|
1433
1515
|
],
|
|
1516
|
+
[
|
|
1517
|
+
"BaseFeeDrops",
|
|
1518
|
+
{
|
|
1519
|
+
"nth": 22,
|
|
1520
|
+
"isVLEncoded": false,
|
|
1521
|
+
"isSerialized": true,
|
|
1522
|
+
"isSigningField": true,
|
|
1523
|
+
"type": "Amount"
|
|
1524
|
+
}
|
|
1525
|
+
],
|
|
1526
|
+
[
|
|
1527
|
+
"ReserveBaseDrops",
|
|
1528
|
+
{
|
|
1529
|
+
"nth": 23,
|
|
1530
|
+
"isVLEncoded": false,
|
|
1531
|
+
"isSerialized": true,
|
|
1532
|
+
"isSigningField": true,
|
|
1533
|
+
"type": "Amount"
|
|
1534
|
+
}
|
|
1535
|
+
],
|
|
1536
|
+
[
|
|
1537
|
+
"ReserveIncrementDrops",
|
|
1538
|
+
{
|
|
1539
|
+
"nth": 24,
|
|
1540
|
+
"isVLEncoded": false,
|
|
1541
|
+
"isSerialized": true,
|
|
1542
|
+
"isSigningField": true,
|
|
1543
|
+
"type": "Amount"
|
|
1544
|
+
}
|
|
1545
|
+
],
|
|
1546
|
+
[
|
|
1547
|
+
"LPTokenOut",
|
|
1548
|
+
{
|
|
1549
|
+
"nth": 25,
|
|
1550
|
+
"isVLEncoded": false,
|
|
1551
|
+
"isSerialized": true,
|
|
1552
|
+
"isSigningField": true,
|
|
1553
|
+
"type": "Amount"
|
|
1554
|
+
}
|
|
1555
|
+
],
|
|
1556
|
+
[
|
|
1557
|
+
"LPTokenIn",
|
|
1558
|
+
{
|
|
1559
|
+
"nth": 26,
|
|
1560
|
+
"isVLEncoded": false,
|
|
1561
|
+
"isSerialized": true,
|
|
1562
|
+
"isSigningField": true,
|
|
1563
|
+
"type": "Amount"
|
|
1564
|
+
}
|
|
1565
|
+
],
|
|
1566
|
+
[
|
|
1567
|
+
"EPrice",
|
|
1568
|
+
{
|
|
1569
|
+
"nth": 27,
|
|
1570
|
+
"isVLEncoded": false,
|
|
1571
|
+
"isSerialized": true,
|
|
1572
|
+
"isSigningField": true,
|
|
1573
|
+
"type": "Amount"
|
|
1574
|
+
}
|
|
1575
|
+
],
|
|
1576
|
+
[
|
|
1577
|
+
"Price",
|
|
1578
|
+
{
|
|
1579
|
+
"nth": 28,
|
|
1580
|
+
"isVLEncoded": false,
|
|
1581
|
+
"isSerialized": true,
|
|
1582
|
+
"isSigningField": true,
|
|
1583
|
+
"type": "Amount"
|
|
1584
|
+
}
|
|
1585
|
+
],
|
|
1586
|
+
[
|
|
1587
|
+
"LPTokenBalance",
|
|
1588
|
+
{
|
|
1589
|
+
"nth": 31,
|
|
1590
|
+
"isVLEncoded": false,
|
|
1591
|
+
"isSerialized": true,
|
|
1592
|
+
"isSigningField": true,
|
|
1593
|
+
"type": "Amount"
|
|
1594
|
+
}
|
|
1595
|
+
],
|
|
1434
1596
|
[
|
|
1435
1597
|
"PublicKey",
|
|
1436
1598
|
{
|
|
@@ -1821,6 +1983,26 @@
|
|
|
1821
1983
|
"type": "PathSet"
|
|
1822
1984
|
}
|
|
1823
1985
|
],
|
|
1986
|
+
[
|
|
1987
|
+
"Asset",
|
|
1988
|
+
{
|
|
1989
|
+
"nth": 3,
|
|
1990
|
+
"isVLEncoded": false,
|
|
1991
|
+
"isSerialized": true,
|
|
1992
|
+
"isSigningField": true,
|
|
1993
|
+
"type": "Issue"
|
|
1994
|
+
}
|
|
1995
|
+
],
|
|
1996
|
+
[
|
|
1997
|
+
"Asset2",
|
|
1998
|
+
{
|
|
1999
|
+
"nth": 4,
|
|
2000
|
+
"isVLEncoded": false,
|
|
2001
|
+
"isSerialized": true,
|
|
2002
|
+
"isSigningField": true,
|
|
2003
|
+
"type": "Issue"
|
|
2004
|
+
}
|
|
2005
|
+
],
|
|
1824
2006
|
[
|
|
1825
2007
|
"TransactionMetaData",
|
|
1826
2008
|
{
|
|
@@ -2031,6 +2213,36 @@
|
|
|
2031
2213
|
"type": "STObject"
|
|
2032
2214
|
}
|
|
2033
2215
|
],
|
|
2216
|
+
[
|
|
2217
|
+
"VoteEntry",
|
|
2218
|
+
{
|
|
2219
|
+
"nth": 25,
|
|
2220
|
+
"isVLEncoded": false,
|
|
2221
|
+
"isSerialized": true,
|
|
2222
|
+
"isSigningField": true,
|
|
2223
|
+
"type": "STObject"
|
|
2224
|
+
}
|
|
2225
|
+
],
|
|
2226
|
+
[
|
|
2227
|
+
"AuctionSlot",
|
|
2228
|
+
{
|
|
2229
|
+
"nth": 26,
|
|
2230
|
+
"isVLEncoded": false,
|
|
2231
|
+
"isSerialized": true,
|
|
2232
|
+
"isSigningField": true,
|
|
2233
|
+
"type": "STObject"
|
|
2234
|
+
}
|
|
2235
|
+
],
|
|
2236
|
+
[
|
|
2237
|
+
"AuthAccount",
|
|
2238
|
+
{
|
|
2239
|
+
"nth": 27,
|
|
2240
|
+
"isVLEncoded": false,
|
|
2241
|
+
"isSerialized": true,
|
|
2242
|
+
"isSigningField": true,
|
|
2243
|
+
"type": "STObject"
|
|
2244
|
+
}
|
|
2245
|
+
],
|
|
2034
2246
|
[
|
|
2035
2247
|
"Signers",
|
|
2036
2248
|
{
|
|
@@ -2121,6 +2333,16 @@
|
|
|
2121
2333
|
"type": "STArray"
|
|
2122
2334
|
}
|
|
2123
2335
|
],
|
|
2336
|
+
[
|
|
2337
|
+
"VoteSlots",
|
|
2338
|
+
{
|
|
2339
|
+
"nth": 12,
|
|
2340
|
+
"isVLEncoded": false,
|
|
2341
|
+
"isSerialized": true,
|
|
2342
|
+
"isSigningField": true,
|
|
2343
|
+
"type": "STArray"
|
|
2344
|
+
}
|
|
2345
|
+
],
|
|
2124
2346
|
[
|
|
2125
2347
|
"Majorities",
|
|
2126
2348
|
{
|
|
@@ -2170,6 +2392,16 @@
|
|
|
2170
2392
|
"isSigningField": true,
|
|
2171
2393
|
"type": "STArray"
|
|
2172
2394
|
}
|
|
2395
|
+
],
|
|
2396
|
+
[
|
|
2397
|
+
"AuthAccounts",
|
|
2398
|
+
{
|
|
2399
|
+
"nth": 25,
|
|
2400
|
+
"isVLEncoded": false,
|
|
2401
|
+
"isSerialized": true,
|
|
2402
|
+
"isSigningField": true,
|
|
2403
|
+
"type": "STArray"
|
|
2404
|
+
}
|
|
2173
2405
|
]
|
|
2174
2406
|
],
|
|
2175
2407
|
"TRANSACTION_RESULTS": {
|
|
@@ -2227,6 +2459,7 @@
|
|
|
2227
2459
|
"temUNKNOWN": -264,
|
|
2228
2460
|
"temSEQ_AND_TICKET": -263,
|
|
2229
2461
|
"temBAD_NFTOKEN_TRANSFER_FEE": -262,
|
|
2462
|
+
"temBAD_AMM_TOKENS": -261,
|
|
2230
2463
|
"tefFAILURE": -199,
|
|
2231
2464
|
"tefALREADY": -198,
|
|
2232
2465
|
"tefBAD_ADD_AUTH": -197,
|
|
@@ -2260,6 +2493,7 @@
|
|
|
2260
2493
|
"terNO_RIPPLE": -90,
|
|
2261
2494
|
"terQUEUED": -89,
|
|
2262
2495
|
"terPRE_TICKET": -88,
|
|
2496
|
+
"terNO_AMM": -87,
|
|
2263
2497
|
"tesSUCCESS": 0,
|
|
2264
2498
|
"tecCLAIM": 100,
|
|
2265
2499
|
"tecPATH_PARTIAL": 101,
|
|
@@ -2306,7 +2540,15 @@
|
|
|
2306
2540
|
"tecCANT_ACCEPT_OWN_NFTOKEN_OFFER": 158,
|
|
2307
2541
|
"tecINSUFFICIENT_FUNDS": 159,
|
|
2308
2542
|
"tecOBJECT_NOT_FOUND": 160,
|
|
2309
|
-
"tecINSUFFICIENT_PAYMENT": 161
|
|
2543
|
+
"tecINSUFFICIENT_PAYMENT": 161,
|
|
2544
|
+
"tecUNFUNDED_AMM": 162,
|
|
2545
|
+
"tecAMM_BALANCE": 163,
|
|
2546
|
+
"tecAMM_FAILED": 164,
|
|
2547
|
+
"tecAMM_INVALID_TOKENS": 165,
|
|
2548
|
+
"tecAMM_EMPTY": 166,
|
|
2549
|
+
"tecAMM_NOT_EMPTY": 167,
|
|
2550
|
+
"tecAMM_ACCOUNT": 168,
|
|
2551
|
+
"tecINCOMPLETE": 169
|
|
2310
2552
|
},
|
|
2311
2553
|
"TRANSACTION_TYPES": {
|
|
2312
2554
|
"Invalid": -1,
|
|
@@ -2339,6 +2581,12 @@
|
|
|
2339
2581
|
"NFTokenCancelOffer": 28,
|
|
2340
2582
|
"NFTokenAcceptOffer": 29,
|
|
2341
2583
|
"Clawback": 30,
|
|
2584
|
+
"AMMCreate": 35,
|
|
2585
|
+
"AMMDeposit": 36,
|
|
2586
|
+
"AMMWithdraw": 37,
|
|
2587
|
+
"AMMVote": 38,
|
|
2588
|
+
"AMMBid": 39,
|
|
2589
|
+
"AMMDelete": 40,
|
|
2342
2590
|
"EnableAmendment": 100,
|
|
2343
2591
|
"SetFee": 101,
|
|
2344
2592
|
"UNLModify": 102
|
|
@@ -21,6 +21,7 @@
|
|
|
21
21
|
"UInt192": 21,
|
|
22
22
|
"UInt384": 22,
|
|
23
23
|
"UInt512": 23,
|
|
24
|
+
"Issue": 24,
|
|
24
25
|
"Transaction": 10001,
|
|
25
26
|
"LedgerEntry": 10002,
|
|
26
27
|
"Validation": 10003,
|
|
@@ -44,6 +45,7 @@
|
|
|
44
45
|
"NegativeUNL": 78,
|
|
45
46
|
"NFTokenPage": 80,
|
|
46
47
|
"NFTokenOffer": 55,
|
|
48
|
+
"AMM": 121,
|
|
47
49
|
"Any": -3,
|
|
48
50
|
"Child": -2,
|
|
49
51
|
"Nickname": 110,
|
|
@@ -271,6 +273,26 @@
|
|
|
271
273
|
"type": "UInt16"
|
|
272
274
|
}
|
|
273
275
|
],
|
|
276
|
+
[
|
|
277
|
+
"TradingFee",
|
|
278
|
+
{
|
|
279
|
+
"nth": 5,
|
|
280
|
+
"isVLEncoded": false,
|
|
281
|
+
"isSerialized": true,
|
|
282
|
+
"isSigningField": true,
|
|
283
|
+
"type": "UInt16"
|
|
284
|
+
}
|
|
285
|
+
],
|
|
286
|
+
[
|
|
287
|
+
"DiscountedFee",
|
|
288
|
+
{
|
|
289
|
+
"nth": 6,
|
|
290
|
+
"isVLEncoded": false,
|
|
291
|
+
"isSerialized": true,
|
|
292
|
+
"isSigningField": true,
|
|
293
|
+
"type": "UInt16"
|
|
294
|
+
}
|
|
295
|
+
],
|
|
274
296
|
[
|
|
275
297
|
"Version",
|
|
276
298
|
{
|
|
@@ -771,6 +793,26 @@
|
|
|
771
793
|
"type": "UInt32"
|
|
772
794
|
}
|
|
773
795
|
],
|
|
796
|
+
[
|
|
797
|
+
"VoteWeight",
|
|
798
|
+
{
|
|
799
|
+
"nth": 48,
|
|
800
|
+
"isVLEncoded": false,
|
|
801
|
+
"isSerialized": true,
|
|
802
|
+
"isSigningField": true,
|
|
803
|
+
"type": "UInt32"
|
|
804
|
+
}
|
|
805
|
+
],
|
|
806
|
+
[
|
|
807
|
+
"FirstNFTokenSequence",
|
|
808
|
+
{
|
|
809
|
+
"nth": 50,
|
|
810
|
+
"isVLEncoded": false,
|
|
811
|
+
"isSerialized": true,
|
|
812
|
+
"isSigningField": true,
|
|
813
|
+
"type": "UInt32"
|
|
814
|
+
}
|
|
815
|
+
],
|
|
774
816
|
[
|
|
775
817
|
"IndexNext",
|
|
776
818
|
{
|
|
@@ -1121,6 +1163,16 @@
|
|
|
1121
1163
|
"type": "Hash256"
|
|
1122
1164
|
}
|
|
1123
1165
|
],
|
|
1166
|
+
[
|
|
1167
|
+
"AMMID",
|
|
1168
|
+
{
|
|
1169
|
+
"nth": 14,
|
|
1170
|
+
"isVLEncoded": false,
|
|
1171
|
+
"isSerialized": true,
|
|
1172
|
+
"isSigningField": true,
|
|
1173
|
+
"type": "Hash256"
|
|
1174
|
+
}
|
|
1175
|
+
],
|
|
1124
1176
|
[
|
|
1125
1177
|
"BookDirectory",
|
|
1126
1178
|
{
|
|
@@ -1391,6 +1443,36 @@
|
|
|
1391
1443
|
"type": "Amount"
|
|
1392
1444
|
}
|
|
1393
1445
|
],
|
|
1446
|
+
[
|
|
1447
|
+
"Amount2",
|
|
1448
|
+
{
|
|
1449
|
+
"nth": 11,
|
|
1450
|
+
"isVLEncoded": false,
|
|
1451
|
+
"isSerialized": true,
|
|
1452
|
+
"isSigningField": true,
|
|
1453
|
+
"type": "Amount"
|
|
1454
|
+
}
|
|
1455
|
+
],
|
|
1456
|
+
[
|
|
1457
|
+
"BidMin",
|
|
1458
|
+
{
|
|
1459
|
+
"nth": 12,
|
|
1460
|
+
"isVLEncoded": false,
|
|
1461
|
+
"isSerialized": true,
|
|
1462
|
+
"isSigningField": true,
|
|
1463
|
+
"type": "Amount"
|
|
1464
|
+
}
|
|
1465
|
+
],
|
|
1466
|
+
[
|
|
1467
|
+
"BidMax",
|
|
1468
|
+
{
|
|
1469
|
+
"nth": 13,
|
|
1470
|
+
"isVLEncoded": false,
|
|
1471
|
+
"isSerialized": true,
|
|
1472
|
+
"isSigningField": true,
|
|
1473
|
+
"type": "Amount"
|
|
1474
|
+
}
|
|
1475
|
+
],
|
|
1394
1476
|
[
|
|
1395
1477
|
"MinimumOffer",
|
|
1396
1478
|
{
|
|
@@ -1431,6 +1513,86 @@
|
|
|
1431
1513
|
"type": "Amount"
|
|
1432
1514
|
}
|
|
1433
1515
|
],
|
|
1516
|
+
[
|
|
1517
|
+
"BaseFeeDrops",
|
|
1518
|
+
{
|
|
1519
|
+
"nth": 22,
|
|
1520
|
+
"isVLEncoded": false,
|
|
1521
|
+
"isSerialized": true,
|
|
1522
|
+
"isSigningField": true,
|
|
1523
|
+
"type": "Amount"
|
|
1524
|
+
}
|
|
1525
|
+
],
|
|
1526
|
+
[
|
|
1527
|
+
"ReserveBaseDrops",
|
|
1528
|
+
{
|
|
1529
|
+
"nth": 23,
|
|
1530
|
+
"isVLEncoded": false,
|
|
1531
|
+
"isSerialized": true,
|
|
1532
|
+
"isSigningField": true,
|
|
1533
|
+
"type": "Amount"
|
|
1534
|
+
}
|
|
1535
|
+
],
|
|
1536
|
+
[
|
|
1537
|
+
"ReserveIncrementDrops",
|
|
1538
|
+
{
|
|
1539
|
+
"nth": 24,
|
|
1540
|
+
"isVLEncoded": false,
|
|
1541
|
+
"isSerialized": true,
|
|
1542
|
+
"isSigningField": true,
|
|
1543
|
+
"type": "Amount"
|
|
1544
|
+
}
|
|
1545
|
+
],
|
|
1546
|
+
[
|
|
1547
|
+
"LPTokenOut",
|
|
1548
|
+
{
|
|
1549
|
+
"nth": 25,
|
|
1550
|
+
"isVLEncoded": false,
|
|
1551
|
+
"isSerialized": true,
|
|
1552
|
+
"isSigningField": true,
|
|
1553
|
+
"type": "Amount"
|
|
1554
|
+
}
|
|
1555
|
+
],
|
|
1556
|
+
[
|
|
1557
|
+
"LPTokenIn",
|
|
1558
|
+
{
|
|
1559
|
+
"nth": 26,
|
|
1560
|
+
"isVLEncoded": false,
|
|
1561
|
+
"isSerialized": true,
|
|
1562
|
+
"isSigningField": true,
|
|
1563
|
+
"type": "Amount"
|
|
1564
|
+
}
|
|
1565
|
+
],
|
|
1566
|
+
[
|
|
1567
|
+
"EPrice",
|
|
1568
|
+
{
|
|
1569
|
+
"nth": 27,
|
|
1570
|
+
"isVLEncoded": false,
|
|
1571
|
+
"isSerialized": true,
|
|
1572
|
+
"isSigningField": true,
|
|
1573
|
+
"type": "Amount"
|
|
1574
|
+
}
|
|
1575
|
+
],
|
|
1576
|
+
[
|
|
1577
|
+
"Price",
|
|
1578
|
+
{
|
|
1579
|
+
"nth": 28,
|
|
1580
|
+
"isVLEncoded": false,
|
|
1581
|
+
"isSerialized": true,
|
|
1582
|
+
"isSigningField": true,
|
|
1583
|
+
"type": "Amount"
|
|
1584
|
+
}
|
|
1585
|
+
],
|
|
1586
|
+
[
|
|
1587
|
+
"LPTokenBalance",
|
|
1588
|
+
{
|
|
1589
|
+
"nth": 31,
|
|
1590
|
+
"isVLEncoded": false,
|
|
1591
|
+
"isSerialized": true,
|
|
1592
|
+
"isSigningField": true,
|
|
1593
|
+
"type": "Amount"
|
|
1594
|
+
}
|
|
1595
|
+
],
|
|
1434
1596
|
[
|
|
1435
1597
|
"PublicKey",
|
|
1436
1598
|
{
|
|
@@ -1821,6 +1983,26 @@
|
|
|
1821
1983
|
"type": "PathSet"
|
|
1822
1984
|
}
|
|
1823
1985
|
],
|
|
1986
|
+
[
|
|
1987
|
+
"Asset",
|
|
1988
|
+
{
|
|
1989
|
+
"nth": 3,
|
|
1990
|
+
"isVLEncoded": false,
|
|
1991
|
+
"isSerialized": true,
|
|
1992
|
+
"isSigningField": true,
|
|
1993
|
+
"type": "Issue"
|
|
1994
|
+
}
|
|
1995
|
+
],
|
|
1996
|
+
[
|
|
1997
|
+
"Asset2",
|
|
1998
|
+
{
|
|
1999
|
+
"nth": 4,
|
|
2000
|
+
"isVLEncoded": false,
|
|
2001
|
+
"isSerialized": true,
|
|
2002
|
+
"isSigningField": true,
|
|
2003
|
+
"type": "Issue"
|
|
2004
|
+
}
|
|
2005
|
+
],
|
|
1824
2006
|
[
|
|
1825
2007
|
"TransactionMetaData",
|
|
1826
2008
|
{
|
|
@@ -2031,6 +2213,36 @@
|
|
|
2031
2213
|
"type": "STObject"
|
|
2032
2214
|
}
|
|
2033
2215
|
],
|
|
2216
|
+
[
|
|
2217
|
+
"VoteEntry",
|
|
2218
|
+
{
|
|
2219
|
+
"nth": 25,
|
|
2220
|
+
"isVLEncoded": false,
|
|
2221
|
+
"isSerialized": true,
|
|
2222
|
+
"isSigningField": true,
|
|
2223
|
+
"type": "STObject"
|
|
2224
|
+
}
|
|
2225
|
+
],
|
|
2226
|
+
[
|
|
2227
|
+
"AuctionSlot",
|
|
2228
|
+
{
|
|
2229
|
+
"nth": 26,
|
|
2230
|
+
"isVLEncoded": false,
|
|
2231
|
+
"isSerialized": true,
|
|
2232
|
+
"isSigningField": true,
|
|
2233
|
+
"type": "STObject"
|
|
2234
|
+
}
|
|
2235
|
+
],
|
|
2236
|
+
[
|
|
2237
|
+
"AuthAccount",
|
|
2238
|
+
{
|
|
2239
|
+
"nth": 27,
|
|
2240
|
+
"isVLEncoded": false,
|
|
2241
|
+
"isSerialized": true,
|
|
2242
|
+
"isSigningField": true,
|
|
2243
|
+
"type": "STObject"
|
|
2244
|
+
}
|
|
2245
|
+
],
|
|
2034
2246
|
[
|
|
2035
2247
|
"Signers",
|
|
2036
2248
|
{
|
|
@@ -2121,6 +2333,16 @@
|
|
|
2121
2333
|
"type": "STArray"
|
|
2122
2334
|
}
|
|
2123
2335
|
],
|
|
2336
|
+
[
|
|
2337
|
+
"VoteSlots",
|
|
2338
|
+
{
|
|
2339
|
+
"nth": 12,
|
|
2340
|
+
"isVLEncoded": false,
|
|
2341
|
+
"isSerialized": true,
|
|
2342
|
+
"isSigningField": true,
|
|
2343
|
+
"type": "STArray"
|
|
2344
|
+
}
|
|
2345
|
+
],
|
|
2124
2346
|
[
|
|
2125
2347
|
"Majorities",
|
|
2126
2348
|
{
|
|
@@ -2170,6 +2392,16 @@
|
|
|
2170
2392
|
"isSigningField": true,
|
|
2171
2393
|
"type": "STArray"
|
|
2172
2394
|
}
|
|
2395
|
+
],
|
|
2396
|
+
[
|
|
2397
|
+
"AuthAccounts",
|
|
2398
|
+
{
|
|
2399
|
+
"nth": 25,
|
|
2400
|
+
"isVLEncoded": false,
|
|
2401
|
+
"isSerialized": true,
|
|
2402
|
+
"isSigningField": true,
|
|
2403
|
+
"type": "STArray"
|
|
2404
|
+
}
|
|
2173
2405
|
]
|
|
2174
2406
|
],
|
|
2175
2407
|
"TRANSACTION_RESULTS": {
|
|
@@ -2228,6 +2460,7 @@
|
|
|
2228
2460
|
"temUNKNOWN": -264,
|
|
2229
2461
|
"temSEQ_AND_TICKET": -263,
|
|
2230
2462
|
"temBAD_NFTOKEN_TRANSFER_FEE": -262,
|
|
2463
|
+
"temBAD_AMM_TOKENS": -261,
|
|
2231
2464
|
|
|
2232
2465
|
"tefFAILURE": -199,
|
|
2233
2466
|
"tefALREADY": -198,
|
|
@@ -2263,6 +2496,7 @@
|
|
|
2263
2496
|
"terNO_RIPPLE": -90,
|
|
2264
2497
|
"terQUEUED": -89,
|
|
2265
2498
|
"terPRE_TICKET": -88,
|
|
2499
|
+
"terNO_AMM": -87,
|
|
2266
2500
|
|
|
2267
2501
|
"tesSUCCESS": 0,
|
|
2268
2502
|
|
|
@@ -2311,7 +2545,15 @@
|
|
|
2311
2545
|
"tecCANT_ACCEPT_OWN_NFTOKEN_OFFER": 158,
|
|
2312
2546
|
"tecINSUFFICIENT_FUNDS": 159,
|
|
2313
2547
|
"tecOBJECT_NOT_FOUND": 160,
|
|
2314
|
-
"tecINSUFFICIENT_PAYMENT": 161
|
|
2548
|
+
"tecINSUFFICIENT_PAYMENT": 161,
|
|
2549
|
+
"tecUNFUNDED_AMM": 162,
|
|
2550
|
+
"tecAMM_BALANCE": 163,
|
|
2551
|
+
"tecAMM_FAILED": 164,
|
|
2552
|
+
"tecAMM_INVALID_TOKENS": 165,
|
|
2553
|
+
"tecAMM_EMPTY": 166,
|
|
2554
|
+
"tecAMM_NOT_EMPTY": 167,
|
|
2555
|
+
"tecAMM_ACCOUNT": 168,
|
|
2556
|
+
"tecINCOMPLETE": 169
|
|
2315
2557
|
},
|
|
2316
2558
|
"TRANSACTION_TYPES": {
|
|
2317
2559
|
"Invalid": -1,
|
|
@@ -2344,6 +2586,12 @@
|
|
|
2344
2586
|
"NFTokenCancelOffer": 28,
|
|
2345
2587
|
"NFTokenAcceptOffer": 29,
|
|
2346
2588
|
"Clawback": 30,
|
|
2589
|
+
"AMMCreate": 35,
|
|
2590
|
+
"AMMDeposit": 36,
|
|
2591
|
+
"AMMWithdraw": 37,
|
|
2592
|
+
"AMMVote": 38,
|
|
2593
|
+
"AMMBid": 39,
|
|
2594
|
+
"AMMDelete": 40,
|
|
2347
2595
|
"EnableAmendment": 100,
|
|
2348
2596
|
"SetFee": 101,
|
|
2349
2597
|
"UNLModify": 102
|
package/dist/types/index.js
CHANGED
|
@@ -15,6 +15,7 @@ const hash_160_1 = require("./hash-160");
|
|
|
15
15
|
Object.defineProperty(exports, "Hash160", { enumerable: true, get: function () { return hash_160_1.Hash160; } });
|
|
16
16
|
const hash_256_1 = require("./hash-256");
|
|
17
17
|
Object.defineProperty(exports, "Hash256", { enumerable: true, get: function () { return hash_256_1.Hash256; } });
|
|
18
|
+
const issue_1 = require("./issue");
|
|
18
19
|
const path_set_1 = require("./path-set");
|
|
19
20
|
Object.defineProperty(exports, "PathSet", { enumerable: true, get: function () { return path_set_1.PathSet; } });
|
|
20
21
|
const st_array_1 = require("./st-array");
|
|
@@ -40,6 +41,7 @@ const coreTypes = {
|
|
|
40
41
|
Hash128: hash_128_1.Hash128,
|
|
41
42
|
Hash160: hash_160_1.Hash160,
|
|
42
43
|
Hash256: hash_256_1.Hash256,
|
|
44
|
+
Issue: issue_1.Issue,
|
|
43
45
|
PathSet: path_set_1.PathSet,
|
|
44
46
|
STArray: st_array_1.STArray,
|
|
45
47
|
STObject: st_object_1.STObject,
|