@bsv/sdk 1.2.15 → 1.2.18

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 (76) hide show
  1. package/dist/cjs/package.json +2 -2
  2. package/dist/cjs/src/primitives/BigNumber.js +85 -89
  3. package/dist/cjs/src/primitives/BigNumber.js.map +1 -1
  4. package/dist/cjs/src/primitives/PublicKey.js +5 -2
  5. package/dist/cjs/src/primitives/PublicKey.js.map +1 -1
  6. package/dist/cjs/src/primitives/Random.js +3 -2
  7. package/dist/cjs/src/primitives/Random.js.map +1 -1
  8. package/dist/cjs/src/primitives/utils.js +71 -62
  9. package/dist/cjs/src/primitives/utils.js.map +1 -1
  10. package/dist/cjs/src/totp/totp.js +0 -1
  11. package/dist/cjs/src/totp/totp.js.map +1 -1
  12. package/dist/cjs/src/transaction/Beef.js +61 -49
  13. package/dist/cjs/src/transaction/Beef.js.map +1 -1
  14. package/dist/cjs/src/transaction/BeefParty.js +1 -1
  15. package/dist/cjs/src/transaction/BeefTx.js +75 -73
  16. package/dist/cjs/src/transaction/BeefTx.js.map +1 -1
  17. package/dist/cjs/src/transaction/MerklePath.js +4 -4
  18. package/dist/cjs/src/transaction/MerklePath.js.map +1 -1
  19. package/dist/cjs/src/transaction/Transaction.js +70 -96
  20. package/dist/cjs/src/transaction/Transaction.js.map +1 -1
  21. package/dist/cjs/tsconfig.cjs.tsbuildinfo +1 -1
  22. package/dist/esm/src/primitives/BigNumber.js +85 -89
  23. package/dist/esm/src/primitives/BigNumber.js.map +1 -1
  24. package/dist/esm/src/primitives/PublicKey.js +5 -2
  25. package/dist/esm/src/primitives/PublicKey.js.map +1 -1
  26. package/dist/esm/src/primitives/Random.js +2 -2
  27. package/dist/esm/src/primitives/Random.js.map +1 -1
  28. package/dist/esm/src/primitives/utils.js +70 -61
  29. package/dist/esm/src/primitives/utils.js.map +1 -1
  30. package/dist/esm/src/totp/totp.js +0 -1
  31. package/dist/esm/src/totp/totp.js.map +1 -1
  32. package/dist/esm/src/transaction/Beef.js +60 -48
  33. package/dist/esm/src/transaction/Beef.js.map +1 -1
  34. package/dist/esm/src/transaction/BeefParty.js +1 -1
  35. package/dist/esm/src/transaction/BeefTx.js +76 -74
  36. package/dist/esm/src/transaction/BeefTx.js.map +1 -1
  37. package/dist/esm/src/transaction/MerklePath.js +4 -4
  38. package/dist/esm/src/transaction/MerklePath.js.map +1 -1
  39. package/dist/esm/src/transaction/Transaction.js +71 -97
  40. package/dist/esm/src/transaction/Transaction.js.map +1 -1
  41. package/dist/esm/tsconfig.esm.tsbuildinfo +1 -1
  42. package/dist/types/src/primitives/BigNumber.d.ts +24 -22
  43. package/dist/types/src/primitives/BigNumber.d.ts.map +1 -1
  44. package/dist/types/src/primitives/PublicKey.d.ts.map +1 -1
  45. package/dist/types/src/primitives/utils.d.ts +17 -17
  46. package/dist/types/src/primitives/utils.d.ts.map +1 -1
  47. package/dist/types/src/transaction/Beef.d.ts +17 -14
  48. package/dist/types/src/transaction/Beef.d.ts.map +1 -1
  49. package/dist/types/src/transaction/BeefParty.d.ts +1 -1
  50. package/dist/types/src/transaction/BeefTx.d.ts +5 -2
  51. package/dist/types/src/transaction/BeefTx.d.ts.map +1 -1
  52. package/dist/types/src/transaction/MerklePath.d.ts +2 -2
  53. package/dist/types/src/transaction/MerklePath.d.ts.map +1 -1
  54. package/dist/types/src/transaction/Transaction.d.ts +6 -0
  55. package/dist/types/src/transaction/Transaction.d.ts.map +1 -1
  56. package/dist/types/tsconfig.types.tsbuildinfo +1 -1
  57. package/dist/umd/bundle.js +1 -1
  58. package/docs/compat.md +13 -11
  59. package/docs/primitives.md +152 -188
  60. package/docs/transaction.md +87 -79
  61. package/docs/wallet-substrates.md +1410 -1
  62. package/package.json +2 -2
  63. package/src/primitives/BigNumber.ts +111 -111
  64. package/src/primitives/PublicKey.ts +5 -2
  65. package/src/primitives/Random.ts +2 -2
  66. package/src/primitives/utils.ts +92 -77
  67. package/src/totp/totp.ts +0 -1
  68. package/src/transaction/Beef.ts +60 -42
  69. package/src/transaction/BeefParty.ts +1 -1
  70. package/src/transaction/BeefTx.ts +89 -57
  71. package/src/transaction/MerklePath.ts +4 -4
  72. package/src/transaction/Transaction.ts +77 -100
  73. package/src/transaction/__tests/Beef.test.ts +32 -13
  74. package/src/transaction/__tests/Transaction.benchmarks.test.ts +1 -1
  75. package/src/transaction/__tests/Transaction.test.ts +3 -3
  76. package/src/transaction/broadcasters/__tests/WhatsOnChainBroadcaster.test.ts +2 -2
@@ -1,6 +1,6 @@
1
1
  # API
2
2
 
3
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
3
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
4
4
 
5
5
  ## Interfaces
6
6
 
@@ -15,7 +15,7 @@ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](
15
15
  | [FetchOptions](#interface-fetchoptions) | [WhatsOnChainConfig](#interface-whatsonchainconfig) |
16
16
  | [HttpClient](#interface-httpclient) | |
17
17
 
18
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
18
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
19
19
 
20
20
  ---
21
21
 
@@ -91,7 +91,7 @@ See also: [HttpClient](#interface-httpclient)
91
91
 
92
92
  </details>
93
93
 
94
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
94
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
95
95
 
96
96
  ---
97
97
  ### Interface: BroadcastFailure
@@ -108,7 +108,7 @@ export interface BroadcastFailure {
108
108
  }
109
109
  ```
110
110
 
111
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
111
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
112
112
 
113
113
  ---
114
114
  ### Interface: BroadcastResponse
@@ -124,7 +124,7 @@ export interface BroadcastResponse {
124
124
  }
125
125
  ```
126
126
 
127
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
127
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
128
128
 
129
129
  ---
130
130
  ### Interface: Broadcaster
@@ -141,7 +141,7 @@ export interface Broadcaster {
141
141
 
142
142
  See also: [BroadcastFailure](#interface-broadcastfailure), [BroadcastResponse](#interface-broadcastresponse), [Transaction](#class-transaction)
143
143
 
144
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
144
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
145
145
 
146
146
  ---
147
147
  ### Interface: ChainTracker
@@ -169,7 +169,7 @@ export default interface ChainTracker {
169
169
  }
170
170
  ```
171
171
 
172
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
172
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
173
173
 
174
174
  ---
175
175
  ### Interface: FeeModel
@@ -185,7 +185,7 @@ export default interface FeeModel {
185
185
 
186
186
  See also: [Transaction](#class-transaction)
187
187
 
188
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
188
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
189
189
 
190
190
  ---
191
191
  ### Interface: FetchOptions
@@ -231,7 +231,7 @@ method?: string
231
231
 
232
232
  </details>
233
233
 
234
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
234
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
235
235
 
236
236
  ---
237
237
  ### Interface: HttpClient
@@ -261,7 +261,7 @@ See also: [HttpClientRequestOptions](#interface-httpclientrequestoptions), [Http
261
261
 
262
262
  </details>
263
263
 
264
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
264
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
265
265
 
266
266
  ---
267
267
  ### Interface: HttpClientRequestOptions
@@ -306,7 +306,7 @@ method?: string
306
306
 
307
307
  </details>
308
308
 
309
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
309
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
310
310
 
311
311
  ---
312
312
  ### Interface: HttpsNodejs
@@ -321,7 +321,7 @@ export interface HttpsNodejs {
321
321
 
322
322
  See also: [HttpClientRequestOptions](#interface-httpclientrequestoptions), [NodejsHttpClientRequest](#interface-nodejshttpclientrequest)
323
323
 
324
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
324
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
325
325
 
326
326
  ---
327
327
  ### Interface: MerklePathLeaf
@@ -335,7 +335,7 @@ export interface MerklePathLeaf {
335
335
  }
336
336
  ```
337
337
 
338
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
338
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
339
339
 
340
340
  ---
341
341
  ### Interface: NodejsHttpClientRequest
@@ -350,7 +350,7 @@ export interface NodejsHttpClientRequest {
350
350
  }
351
351
  ```
352
352
 
353
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
353
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
354
354
 
355
355
  ---
356
356
  ### Interface: TransactionInput
@@ -392,7 +392,7 @@ export default interface TransactionInput {
392
392
 
393
393
  See also: [Transaction](#class-transaction), [UnlockingScript](#class-unlockingscript), [sign](#variable-sign)
394
394
 
395
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
395
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
396
396
 
397
397
  ---
398
398
  ### Interface: TransactionOutput
@@ -422,7 +422,7 @@ export default interface TransactionOutput {
422
422
 
423
423
  See also: [LockingScript](#class-lockingscript)
424
424
 
425
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
425
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
426
426
 
427
427
  ---
428
428
  ### Interface: WhatsOnChainConfig
@@ -461,7 +461,7 @@ See also: [HttpClient](#interface-httpclient)
461
461
 
462
462
  </details>
463
463
 
464
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
464
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
465
465
 
466
466
  ---
467
467
  ## Classes
@@ -479,7 +479,7 @@ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](
479
479
  | [Transaction](#class-transaction) |
480
480
  | [WhatsOnChain](#class-whatsonchain) |
481
481
 
482
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
482
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
483
483
 
484
484
  ---
485
485
 
@@ -579,7 +579,7 @@ Argument Details
579
579
 
580
580
  </details>
581
581
 
582
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
582
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
583
583
 
584
584
  ---
585
585
  ### Class: Beef
@@ -588,10 +588,9 @@ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](
588
588
  export class Beef {
589
589
  bumps: MerklePath[] = [];
590
590
  txs: BeefTx[] = [];
591
- version: BeefVersion = undefined;
591
+ version: number = BEEF_V2;
592
592
  atomicTxid: string | undefined = undefined;
593
- constructor(version?: BeefVersion)
594
- get magic(): number
593
+ constructor(version: number = BEEF_V2)
595
594
  findTxid(txid: string): BeefTx | undefined
596
595
  makeTxidOnly(txid: string): BeefTx | undefined
597
596
  findBump(txid: string): MerklePath | undefined
@@ -612,7 +611,7 @@ export class Beef {
612
611
  toHex(): string
613
612
  static fromReader(br: Reader): Beef
614
613
  static fromBinary(bin: number[]): Beef
615
- static fromString(s: string, enc?: "hex" | "utf8" | "base64"): Beef
614
+ static fromString(s: string, enc: "hex" | "utf8" | "base64" = "hex"): Beef
616
615
  sortTxs(): {
617
616
  missingInputs: string[];
618
617
  notValid: string[];
@@ -624,15 +623,25 @@ export class Beef {
624
623
  trimKnownTxids(knownTxids: string[])
625
624
  getValidTxids(): string[]
626
625
  toLogString(): string
626
+ addComputedLeaves()
627
627
  }
628
628
  ```
629
629
 
630
- See also: [BeefTx](#class-beeftx), [BeefVersion](#type-beefversion), [ChainTracker](#interface-chaintracker), [MerklePath](#class-merklepath), [Reader](#class-reader), [Transaction](#class-transaction), [Writer](#class-writer), [toHex](#variable-tohex), [verify](#variable-verify)
630
+ See also: [BEEF_V2](#variable-beef_v2), [BeefTx](#class-beeftx), [ChainTracker](#interface-chaintracker), [MerklePath](#class-merklepath), [Reader](#class-reader), [Transaction](#class-transaction), [Writer](#class-writer), [toHex](#variable-tohex), [verify](#variable-verify)
631
631
 
632
632
  <details>
633
633
 
634
634
  <summary>Class Beef Details</summary>
635
635
 
636
+ #### Method addComputedLeaves
637
+
638
+ In some circumstances it may be helpful for the BUMP MerkePaths to include
639
+ leaves that can be computed from row zero.
640
+
641
+ ```ts
642
+ addComputedLeaves()
643
+ ```
644
+
636
645
  #### Method clone
637
646
 
638
647
  ```ts
@@ -735,7 +744,7 @@ Argument Details
735
744
  Constructs an instance of the Beef class based on the provided string
736
745
 
737
746
  ```ts
738
- static fromString(s: string, enc?: "hex" | "utf8" | "base64"): Beef
747
+ static fromString(s: string, enc: "hex" | "utf8" | "base64" = "hex"): Beef
739
748
  ```
740
749
  See also: [Beef](#class-beef)
741
750
 
@@ -902,8 +911,9 @@ A binary array representing the BEEF
902
911
 
903
912
  Serialize this Beef as AtomicBEEF.
904
913
 
905
- `txid` must exist and be the last transaction
906
- in sorted (dependency) order.
914
+ `txid` must exist
915
+
916
+ after sorting, if txid is not last txid, creates a clone and removes newer txs
907
917
 
908
918
  ```ts
909
919
  toBinaryAtomic(txid: string)
@@ -978,7 +988,7 @@ Argument Details
978
988
 
979
989
  </details>
980
990
 
981
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
991
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
982
992
 
983
993
  ---
984
994
  ### Class: BeefParty
@@ -1108,7 +1118,7 @@ See also: [Beef](#class-beef)
1108
1118
 
1109
1119
  </details>
1110
1120
 
1111
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
1121
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
1112
1122
 
1113
1123
  ---
1114
1124
  ### Class: BeefTx
@@ -1137,8 +1147,11 @@ export default class BeefTx {
1137
1147
  get tx()
1138
1148
  get rawTx()
1139
1149
  constructor(tx: Transaction | number[] | string, bumpIndex?: number)
1140
- toWriter(writer: Writer, magic: number): void
1141
- static fromReader(br: Reader, magic: number): BeefTx
1150
+ static fromTx(tx: Transaction, bumpIndex?: number): BeefTx
1151
+ static fromRawTx(rawTx: number[], bumpIndex?: number): BeefTx
1152
+ static fromTxid(txid: string, bumpIndex?: number): BeefTx
1153
+ toWriter(writer: Writer, version: number): void
1154
+ static fromReader(br: Reader, version: number): BeefTx
1142
1155
  }
1143
1156
  ```
1144
1157
 
@@ -1174,7 +1187,7 @@ isValid?: boolean = undefined
1174
1187
 
1175
1188
  </details>
1176
1189
 
1177
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
1190
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
1178
1191
 
1179
1192
  ---
1180
1193
  ### Class: FetchHttpClient
@@ -1190,7 +1203,7 @@ export class FetchHttpClient implements HttpClient {
1190
1203
 
1191
1204
  See also: [Fetch](#type-fetch), [HttpClient](#interface-httpclient), [HttpClientRequestOptions](#interface-httpclientrequestoptions), [HttpClientResponse](#type-httpclientresponse)
1192
1205
 
1193
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
1206
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
1194
1207
 
1195
1208
  ---
1196
1209
  ### Class: MerklePath
@@ -1217,7 +1230,7 @@ export default class MerklePath {
1217
1230
  duplicate?: boolean;
1218
1231
  }>>;
1219
1232
  static fromHex(hex: string): MerklePath
1220
- static fromReader(reader: Reader): MerklePath
1233
+ static fromReader(reader: Reader, legalOffsetsOnly: boolean = true): MerklePath
1221
1234
  static fromBinary(bump: number[]): MerklePath
1222
1235
  static fromCoinbaseTxidAndHeight(txid: string, height: number): MerklePath
1223
1236
  constructor(blockHeight: number, path: Array<Array<{
@@ -1225,7 +1238,7 @@ export default class MerklePath {
1225
1238
  hash?: string;
1226
1239
  txid?: boolean;
1227
1240
  duplicate?: boolean;
1228
- }>>)
1241
+ }>>, legalOffsetsOnly: boolean = true)
1229
1242
  toBinary(): number[]
1230
1243
  toHex(): string
1231
1244
  computeRoot(txid?: string): string
@@ -1402,7 +1415,7 @@ Argument Details
1402
1415
 
1403
1416
  </details>
1404
1417
 
1405
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
1418
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
1406
1419
 
1407
1420
  ---
1408
1421
  ### Class: NodejsHttpClient
@@ -1418,7 +1431,7 @@ export class NodejsHttpClient implements HttpClient {
1418
1431
 
1419
1432
  See also: [HttpClient](#interface-httpclient), [HttpClientRequestOptions](#interface-httpclientrequestoptions), [HttpClientResponse](#type-httpclientresponse), [HttpsNodejs](#interface-httpsnodejs)
1420
1433
 
1421
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
1434
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
1422
1435
 
1423
1436
  ---
1424
1437
  ### Class: SatoshisPerKilobyte
@@ -1472,7 +1485,7 @@ Argument Details
1472
1485
 
1473
1486
  </details>
1474
1487
 
1475
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
1488
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
1476
1489
 
1477
1490
  ---
1478
1491
  ### Class: Transaction
@@ -2050,7 +2063,7 @@ tx.verify(new WhatsOnChain(), new SatoshisPerKilobyte(1))
2050
2063
 
2051
2064
  </details>
2052
2065
 
2053
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
2066
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
2054
2067
 
2055
2068
  ---
2056
2069
  ### Class: WhatsOnChain
@@ -2090,7 +2103,7 @@ Argument Details
2090
2103
 
2091
2104
  </details>
2092
2105
 
2093
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
2106
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
2094
2107
 
2095
2108
  ---
2096
2109
  ## Functions
@@ -2103,7 +2116,7 @@ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](
2103
2116
  | [isBroadcastFailure](#function-isbroadcastfailure) |
2104
2117
  | [isBroadcastResponse](#function-isbroadcastresponse) |
2105
2118
 
2106
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
2119
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
2107
2120
 
2108
2121
  ---
2109
2122
 
@@ -2115,7 +2128,7 @@ export function defaultBroadcaster(isTestnet: boolean = false, config: ArcConfig
2115
2128
 
2116
2129
  See also: [ArcConfig](#interface-arcconfig), [Broadcaster](#interface-broadcaster)
2117
2130
 
2118
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
2131
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
2119
2132
 
2120
2133
  ---
2121
2134
  ### Function: defaultChainTracker
@@ -2126,7 +2139,7 @@ export function defaultChainTracker(): ChainTracker
2126
2139
 
2127
2140
  See also: [ChainTracker](#interface-chaintracker)
2128
2141
 
2129
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
2142
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
2130
2143
 
2131
2144
  ---
2132
2145
  ### Function: defaultHttpClient
@@ -2141,7 +2154,7 @@ export function defaultHttpClient(): HttpClient
2141
2154
 
2142
2155
  See also: [HttpClient](#interface-httpclient)
2143
2156
 
2144
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
2157
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
2145
2158
 
2146
2159
  ---
2147
2160
  ### Function: isBroadcastFailure
@@ -2154,7 +2167,7 @@ export function isBroadcastFailure(r: BroadcastResponse | BroadcastFailure): r i
2154
2167
 
2155
2168
  See also: [BroadcastFailure](#interface-broadcastfailure), [BroadcastResponse](#interface-broadcastresponse)
2156
2169
 
2157
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
2170
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
2158
2171
 
2159
2172
  ---
2160
2173
  ### Function: isBroadcastResponse
@@ -2167,30 +2180,20 @@ export function isBroadcastResponse(r: BroadcastResponse | BroadcastFailure): r
2167
2180
 
2168
2181
  See also: [BroadcastFailure](#interface-broadcastfailure), [BroadcastResponse](#interface-broadcastresponse)
2169
2182
 
2170
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
2183
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
2171
2184
 
2172
2185
  ---
2173
2186
  ## Types
2174
2187
 
2175
2188
  | |
2176
2189
  | --- |
2177
- | [BeefVersion](#type-beefversion) |
2178
2190
  | [Fetch](#type-fetch) |
2179
2191
  | [HttpClientResponse](#type-httpclientresponse) |
2180
2192
 
2181
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
2193
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
2182
2194
 
2183
2195
  ---
2184
2196
 
2185
- ### Type: BeefVersion
2186
-
2187
- ```ts
2188
- export type BeefVersion = undefined | "V1" | "V2"
2189
- ```
2190
-
2191
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
2192
-
2193
- ---
2194
2197
  ### Type: Fetch
2195
2198
 
2196
2199
  fetch function interface limited to options needed by ts-sdk
@@ -2203,7 +2206,7 @@ export type Fetch = (url: string, options: FetchOptions) => Promise<Response>
2203
2206
 
2204
2207
  See also: [FetchOptions](#interface-fetchoptions)
2205
2208
 
2206
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
2209
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
2207
2210
 
2208
2211
  ---
2209
2212
  ### Type: HttpClientResponse
@@ -2224,7 +2227,22 @@ export type HttpClientResponse<T = any> = {
2224
2227
  }
2225
2228
  ```
2226
2229
 
2227
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
2230
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
2231
+
2232
+ ---
2233
+ ## Enums
2234
+
2235
+ ### Enum: TX_DATA_FORMAT
2236
+
2237
+ ```ts
2238
+ export enum TX_DATA_FORMAT {
2239
+ RAWTX = 0,
2240
+ RAWTX_AND_BUMP_INDEX = 1,
2241
+ TXID_ONLY = 2
2242
+ }
2243
+ ```
2244
+
2245
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
2228
2246
 
2229
2247
  ---
2230
2248
  ## Variables
@@ -2232,11 +2250,10 @@ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](
2232
2250
  | |
2233
2251
  | --- |
2234
2252
  | [ATOMIC_BEEF](#variable-atomic_beef) |
2235
- | [BEEF_MAGIC](#variable-beef_magic) |
2236
- | [BEEF_MAGIC_TXID_ONLY_EXTENSION](#variable-beef_magic_txid_only_extension) |
2237
- | [BEEF_MAGIC_V2](#variable-beef_magic_v2) |
2253
+ | [BEEF_V1](#variable-beef_v1) |
2254
+ | [BEEF_V2](#variable-beef_v2) |
2238
2255
 
2239
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
2256
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
2240
2257
 
2241
2258
  ---
2242
2259
 
@@ -2246,33 +2263,24 @@ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](
2246
2263
  ATOMIC_BEEF = 16843009
2247
2264
  ```
2248
2265
 
2249
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
2250
-
2251
- ---
2252
- ### Variable: BEEF_MAGIC
2253
-
2254
- ```ts
2255
- BEEF_MAGIC = 4022206465
2256
- ```
2257
-
2258
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
2266
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
2259
2267
 
2260
2268
  ---
2261
- ### Variable: BEEF_MAGIC_TXID_ONLY_EXTENSION
2269
+ ### Variable: BEEF_V1
2262
2270
 
2263
2271
  ```ts
2264
- BEEF_MAGIC_TXID_ONLY_EXTENSION = 4022206465
2272
+ BEEF_V1 = 4022206465
2265
2273
  ```
2266
2274
 
2267
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
2275
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
2268
2276
 
2269
2277
  ---
2270
- ### Variable: BEEF_MAGIC_V2
2278
+ ### Variable: BEEF_V2
2271
2279
 
2272
2280
  ```ts
2273
- BEEF_MAGIC_V2 = 4022206466
2281
+ BEEF_V2 = 4022206466
2274
2282
  ```
2275
2283
 
2276
- Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
2284
+ Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Enums](#enums), [Variables](#variables)
2277
2285
 
2278
2286
  ---