@transia/ripple-binary-codec 1.4.6-alpha.8 → 1.4.6-alpha.9

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.
@@ -141,40 +141,40 @@
141
141
  [
142
142
  "LedgerEntry",
143
143
  {
144
- "nth": 1,
144
+ "nth": 257,
145
145
  "isVLEncoded": false,
146
146
  "isSerialized": false,
147
- "isSigningField": true,
147
+ "isSigningField": false,
148
148
  "type": "LedgerEntry"
149
149
  }
150
150
  ],
151
151
  [
152
152
  "Transaction",
153
153
  {
154
- "nth": 1,
154
+ "nth": 257,
155
155
  "isVLEncoded": false,
156
156
  "isSerialized": false,
157
- "isSigningField": true,
157
+ "isSigningField": false,
158
158
  "type": "Transaction"
159
159
  }
160
160
  ],
161
161
  [
162
162
  "Validation",
163
163
  {
164
- "nth": 1,
164
+ "nth": 257,
165
165
  "isVLEncoded": false,
166
166
  "isSerialized": false,
167
- "isSigningField": true,
167
+ "isSigningField": false,
168
168
  "type": "Validation"
169
169
  }
170
170
  ],
171
171
  [
172
172
  "Metadata",
173
173
  {
174
- "nth": 1,
174
+ "nth": 257,
175
175
  "isVLEncoded": false,
176
- "isSerialized": true,
177
- "isSigningField": true,
176
+ "isSerialized": false,
177
+ "isSigningField": false,
178
178
  "type": "Metadata"
179
179
  }
180
180
  ],
@@ -1998,6 +1998,16 @@
1998
1998
  "type": "AccountID"
1999
1999
  }
2000
2000
  ],
2001
+ [
2002
+ "Inform",
2003
+ {
2004
+ "nth": 99,
2005
+ "isVLEncoded": true,
2006
+ "isSerialized": true,
2007
+ "isSigningField": true,
2008
+ "type": "AccountID"
2009
+ }
2010
+ ],
2001
2011
  [
2002
2012
  "Indexes",
2003
2013
  {
@@ -2048,6 +2058,16 @@
2048
2058
  "type": "Vector256"
2049
2059
  }
2050
2060
  ],
2061
+ [
2062
+ "URITokenIDs",
2063
+ {
2064
+ "nth": 99,
2065
+ "isVLEncoded": true,
2066
+ "isSerialized": true,
2067
+ "isSigningField": true,
2068
+ "type": "Vector256"
2069
+ }
2070
+ ],
2051
2071
  [
2052
2072
  "Paths",
2053
2073
  {
@@ -2308,6 +2328,26 @@
2308
2328
  "type": "STObject"
2309
2329
  }
2310
2330
  ],
2331
+ [
2332
+ "MintURIToken",
2333
+ {
2334
+ "nth": 92,
2335
+ "isVLEncoded": false,
2336
+ "isSerialized": true,
2337
+ "isSigningField": true,
2338
+ "type": "STObject"
2339
+ }
2340
+ ],
2341
+ [
2342
+ "AmountEntry",
2343
+ {
2344
+ "nth": 91,
2345
+ "isVLEncoded": false,
2346
+ "isSerialized": true,
2347
+ "isSigningField": true,
2348
+ "type": "STObject"
2349
+ }
2350
+ ],
2311
2351
  [
2312
2352
  "Signers",
2313
2353
  {
@@ -2487,6 +2527,16 @@
2487
2527
  "isSigningField": true,
2488
2528
  "type": "STArray"
2489
2529
  }
2530
+ ],
2531
+ [
2532
+ "Amounts",
2533
+ {
2534
+ "nth": 92,
2535
+ "isVLEncoded": false,
2536
+ "isSerialized": true,
2537
+ "isSigningField": true,
2538
+ "type": "STArray"
2539
+ }
2490
2540
  ]
2491
2541
  ],
2492
2542
  "TRANSACTION_RESULTS": {
@@ -2705,6 +2755,7 @@
2705
2755
  "URITokenBuy": 47,
2706
2756
  "URITokenCreateSellOffer": 48,
2707
2757
  "URITokenCancelSellOffer": 49,
2758
+ "Remit": 95,
2708
2759
  "GenesisMint": 96,
2709
2760
  "Import": 97,
2710
2761
  "ClaimReward": 98,
@@ -141,40 +141,40 @@
141
141
  [
142
142
  "LedgerEntry",
143
143
  {
144
- "nth": 1,
144
+ "nth": 257,
145
145
  "isVLEncoded": false,
146
146
  "isSerialized": false,
147
- "isSigningField": true,
147
+ "isSigningField": false,
148
148
  "type": "LedgerEntry"
149
149
  }
150
150
  ],
151
151
  [
152
152
  "Transaction",
153
153
  {
154
- "nth": 1,
154
+ "nth": 257,
155
155
  "isVLEncoded": false,
156
156
  "isSerialized": false,
157
- "isSigningField": true,
157
+ "isSigningField": false,
158
158
  "type": "Transaction"
159
159
  }
160
160
  ],
161
161
  [
162
162
  "Validation",
163
163
  {
164
- "nth": 1,
164
+ "nth": 257,
165
165
  "isVLEncoded": false,
166
166
  "isSerialized": false,
167
- "isSigningField": true,
167
+ "isSigningField": false,
168
168
  "type": "Validation"
169
169
  }
170
170
  ],
171
171
  [
172
172
  "Metadata",
173
173
  {
174
- "nth": 1,
174
+ "nth": 257,
175
175
  "isVLEncoded": false,
176
- "isSerialized": true,
177
- "isSigningField": true,
176
+ "isSerialized": false,
177
+ "isSigningField": false,
178
178
  "type": "Metadata"
179
179
  }
180
180
  ],
@@ -1998,6 +1998,16 @@
1998
1998
  "type": "AccountID"
1999
1999
  }
2000
2000
  ],
2001
+ [
2002
+ "Inform",
2003
+ {
2004
+ "nth": 99,
2005
+ "isVLEncoded": true,
2006
+ "isSerialized": true,
2007
+ "isSigningField": true,
2008
+ "type": "AccountID"
2009
+ }
2010
+ ],
2001
2011
  [
2002
2012
  "Indexes",
2003
2013
  {
@@ -2048,6 +2058,16 @@
2048
2058
  "type": "Vector256"
2049
2059
  }
2050
2060
  ],
2061
+ [
2062
+ "URITokenIDs",
2063
+ {
2064
+ "nth": 99,
2065
+ "isVLEncoded": true,
2066
+ "isSerialized": true,
2067
+ "isSigningField": true,
2068
+ "type": "Vector256"
2069
+ }
2070
+ ],
2051
2071
  [
2052
2072
  "Paths",
2053
2073
  {
@@ -2308,6 +2328,26 @@
2308
2328
  "type": "STObject"
2309
2329
  }
2310
2330
  ],
2331
+ [
2332
+ "MintURIToken",
2333
+ {
2334
+ "nth": 92,
2335
+ "isVLEncoded": false,
2336
+ "isSerialized": true,
2337
+ "isSigningField": true,
2338
+ "type": "STObject"
2339
+ }
2340
+ ],
2341
+ [
2342
+ "AmountEntry",
2343
+ {
2344
+ "nth": 91,
2345
+ "isVLEncoded": false,
2346
+ "isSerialized": true,
2347
+ "isSigningField": true,
2348
+ "type": "STObject"
2349
+ }
2350
+ ],
2311
2351
  [
2312
2352
  "Signers",
2313
2353
  {
@@ -2487,6 +2527,16 @@
2487
2527
  "isSigningField": true,
2488
2528
  "type": "STArray"
2489
2529
  }
2530
+ ],
2531
+ [
2532
+ "Amounts",
2533
+ {
2534
+ "nth": 92,
2535
+ "isVLEncoded": false,
2536
+ "isSerialized": true,
2537
+ "isSigningField": true,
2538
+ "type": "STArray"
2539
+ }
2490
2540
  ]
2491
2541
  ],
2492
2542
  "TRANSACTION_RESULTS": {
@@ -2710,6 +2760,7 @@
2710
2760
  "URITokenBuy": 47,
2711
2761
  "URITokenCreateSellOffer": 48,
2712
2762
  "URITokenCancelSellOffer": 49,
2763
+ "Remit": 95,
2713
2764
  "GenesisMint": 96,
2714
2765
  "Import": 97,
2715
2766
  "ClaimReward": 98,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@transia/ripple-binary-codec",
3
- "version": "1.4.6-alpha.8",
3
+ "version": "1.4.6-alpha.9",
4
4
  "description": "XRP Ledger binary codec",
5
5
  "files": [
6
6
  "dist/*",
@@ -40,5 +40,5 @@
40
40
  "engines": {
41
41
  "node": ">= 10"
42
42
  },
43
- "gitHead": "036312d3616ebc761b0096ba6828a29764f01221"
43
+ "gitHead": "8ae372bb08e78ebc79be547eb497d14f9bf3e32c"
44
44
  }
@@ -111,6 +111,11 @@ const UNLReport = {
111
111
  meta: require('./fixtures/unl-report-meta-binary.json'),
112
112
  }
113
113
 
114
+ const Remit = {
115
+ tx: require('./fixtures/remit-tx.json'),
116
+ binary: require('./fixtures/remit-binary.json'),
117
+ }
118
+
114
119
  function bytesListTest() {
115
120
  const list = new BytesList()
116
121
  .put(Buffer.from([0]))
@@ -291,6 +296,12 @@ function nfTokenTest() {
291
296
  }
292
297
  }
293
298
 
299
+ function RemitTest() {
300
+ test('can serialize Remit', () => {
301
+ expect(encode(Remit.tx)).toEqual(Remit.binary)
302
+ })
303
+ }
304
+
294
305
  describe('Binary Serialization', function () {
295
306
  describe('nestedObjectTests', nestedObjectTests)
296
307
  describe('BytesList', bytesListTest)
@@ -304,4 +315,5 @@ describe('Binary Serialization', function () {
304
315
  describe('TicketTest', ticketTest)
305
316
  describe('NFToken', nfTokenTest)
306
317
  describe('UNLReport', UNLReportTest)
318
+ describe('Remit', RemitTest)
307
319
  })
@@ -0,0 +1 @@
1
+ "12005F22000000002403EDEB4A2E00000001201B03EE5D3150116F1DFD1D0FE8A32E40E1F2C05CF1C15545BAB56B617F9C6C2D63A6B704BEF59B68400000000000000C732102F9E33F16DF9507705EC954E3F94EB5F10D1FC4A354606DBE6297DBB1096FE65474473045022100E3FAE0EDEC3D6A8FF6D81BC9CF8288A61B7EEDE8071E90FF9314CB4621058D10022043545CF631706D700CEE65A1DB83EFDD185413808292D9D90F14D87D3DC2D8CB701A04DEADBEEF81147990EC5D1D8DF69E070A968D4B186986FDF06ED0831449FF0C73CA6AF9733DA805F76CA2C37776B7C46B806314757C4A9ED08284D61F3D8807280795F858BAB61DE05C220000000150156F1DFD1D0FE8A32E40E1F2C05CF1C15545BAB56B617F9C6C2D63A6B704BEF59B7504DEADBEEFE1F05CE05B6140000000000003E8E1E05B61D4838D7EA4C68000000000000000000000000000555344000000000006B80F0F1D98AEDA846ED981F741C398FB2C4FD1E1F100136320AED08CC1F50DD5F23A1948AF86153A3F3B7593E5EC77D65A02BB1B29E05AB6AE"
@@ -0,0 +1,39 @@
1
+ {
2
+ "TransactionType": "Remit",
3
+ "Account": "rUn84CUYbNjRoTQ6mSW7BVJPSVJNLb1QLo",
4
+ "Destination": "rfkE1aSy9G8Upk4JssnwBxhEv5p4mn2KTy",
5
+ "DestinationTag": 1,
6
+ "Fee": "12",
7
+ "Flags": 0,
8
+ "LastLedgerSequence": 65953073,
9
+ "Sequence": 65923914,
10
+ "SigningPubKey": "02F9E33F16DF9507705EC954E3F94EB5F10D1FC4A354606DBE6297DBB1096FE654",
11
+ "TxnSignature": "3045022100E3FAE0EDEC3D6A8FF6D81BC9CF8288A61B7EEDE8071E90FF9314CB4621058D10022043545CF631706D700CEE65A1DB83EFDD185413808292D9D90F14D87D3DC2D8CB",
12
+ "Amounts": [
13
+ {
14
+ "AmountEntry": {
15
+ "Amount": "1000"
16
+ }
17
+ },
18
+ {
19
+ "AmountEntry": {
20
+ "Amount": {
21
+ "currency": "USD",
22
+ "issuer": "rcXY84C4g14iFp6taFXjjQGVeHqSCh9RX",
23
+ "value": "1"
24
+ }
25
+ }
26
+ }
27
+ ],
28
+ "MintURIToken": {
29
+ "URI": "DEADBEEF",
30
+ "Digest": "6F1DFD1D0FE8A32E40E1F2C05CF1C15545BAB56B617F9C6C2D63A6B704BEF59B",
31
+ "Flags": 1
32
+ },
33
+ "URITokenIDs": [
34
+ "AED08CC1F50DD5F23A1948AF86153A3F3B7593E5EC77D65A02BB1B29E05AB6AE"
35
+ ],
36
+ "InvoiceID": "6F1DFD1D0FE8A32E40E1F2C05CF1C15545BAB56B617F9C6C2D63A6B704BEF59B",
37
+ "Blob": "DEADBEEF",
38
+ "Inform": "rB5Ux4Lv2nRx6eeoAAsZmtctnBQ2LiACnk"
39
+ }