@lightsparkdev/lightspark-sdk 0.4.10 → 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (125) hide show
  1. package/CHANGELOG.md +30 -0
  2. package/README.md +1 -1
  3. package/dist/{chunk-NXUFC5J7.js → chunk-LZC5C5NI.js} +2908 -635
  4. package/dist/{index-3ffe9e7b.d.ts → index-09d4ac20.d.ts} +373 -62
  5. package/dist/index.cjs +3395 -842
  6. package/dist/index.d.ts +2 -2
  7. package/dist/index.js +390 -94
  8. package/dist/objects/index.cjs +2735 -553
  9. package/dist/objects/index.d.ts +1 -1
  10. package/dist/objects/index.js +17 -5
  11. package/package.json +12 -9
  12. package/src/NodeKeyLoaderCache.ts +87 -0
  13. package/src/SigningKeyLoader.ts +177 -0
  14. package/src/auth/AccountTokenAuthProvider.ts +4 -4
  15. package/src/client.ts +209 -118
  16. package/src/graphql/CreateInvoice.ts +3 -2
  17. package/src/graphql/CreateLnurlInvoice.ts +2 -0
  18. package/src/graphql/CreateUmaInvoice.ts +23 -0
  19. package/src/graphql/MultiNodeDashboard.ts +0 -3
  20. package/src/graphql/PayUmaInvoice.ts +29 -0
  21. package/src/graphql/RecoverNodeSigningKey.ts +1 -1
  22. package/src/graphql/SingleNodeDashboard.ts +0 -1
  23. package/src/lightspark_crypto/lightspark_crypto.d.ts +157 -0
  24. package/src/lightspark_crypto/lightspark_crypto.js +1010 -0
  25. package/src/lightspark_crypto/lightspark_crypto_bg.wasm +0 -0
  26. package/src/lightspark_crypto/lightspark_crypto_bg.wasm.d.ts +120 -0
  27. package/src/lightspark_crypto/package.json +11 -0
  28. package/src/objects/Account.ts +437 -120
  29. package/src/objects/AccountToApiTokensConnection.ts +3 -3
  30. package/src/objects/AccountToChannelsConnection.ts +4 -4
  31. package/src/objects/AccountToNodesConnection.ts +2 -15
  32. package/src/objects/AccountToPaymentRequestsConnection.ts +3 -3
  33. package/src/objects/AccountToTransactionsConnection.ts +6 -6
  34. package/src/objects/AccountToWalletsConnection.ts +2 -2
  35. package/src/objects/Balances.ts +2 -2
  36. package/src/objects/Channel.ts +4 -4
  37. package/src/objects/ChannelClosingTransaction.ts +2 -2
  38. package/src/objects/ChannelOpeningTransaction.ts +2 -2
  39. package/src/objects/ChannelToTransactionsConnection.ts +4 -4
  40. package/src/objects/{CryptoSanctionsScreeningProvider.ts → ComplianceProvider.ts} +3 -3
  41. package/src/objects/Connection.ts +25 -31
  42. package/src/objects/CreateApiTokenInput.ts +1 -1
  43. package/src/objects/CreateApiTokenOutput.ts +1 -1
  44. package/src/objects/CreateInvoiceInput.ts +0 -6
  45. package/src/objects/CreateLnurlInvoiceInput.ts +1 -7
  46. package/src/objects/CreateNodeWalletAddressInput.ts +1 -1
  47. package/src/objects/CreateNodeWalletAddressOutput.ts +1 -1
  48. package/src/objects/CreateTestModeInvoiceInput.ts +1 -1
  49. package/src/objects/CreateTestModeInvoiceOutput.ts +1 -1
  50. package/src/objects/CreateTestModePaymentInput.ts +1 -1
  51. package/src/objects/CreateTestModePaymentoutput.ts +14 -2
  52. package/src/objects/CreateUmaInvoiceInput.ts +24 -0
  53. package/src/objects/DeclineToSignMessagesInput.ts +16 -0
  54. package/src/objects/DeclineToSignMessagesOutput.ts +28 -0
  55. package/src/objects/DeleteApiTokenOutput.ts +1 -1
  56. package/src/objects/Entity.ts +401 -66
  57. package/src/objects/GraphNode.ts +3 -3
  58. package/src/objects/IdAndSignature.ts +16 -0
  59. package/src/objects/IncomingPayment.ts +21 -8
  60. package/src/objects/IncomingPaymentAttempt.ts +2 -2
  61. package/src/objects/IncomingPaymentToAttemptsConnection.ts +3 -3
  62. package/src/objects/Invoice.ts +118 -21
  63. package/src/objects/InvoiceData.ts +118 -21
  64. package/src/objects/LightningFeeEstimateForInvoiceInput.ts +1 -1
  65. package/src/objects/LightningFeeEstimateForNodeInput.ts +1 -1
  66. package/src/objects/LightningFeeEstimateOutput.ts +2 -2
  67. package/src/objects/LightningTransaction.ts +155 -31
  68. package/src/objects/LightsparkNode.ts +272 -112
  69. package/src/objects/LightsparkNodeOwner.ts +8 -4
  70. package/src/objects/LightsparkNodeToChannelsConnection.ts +3 -3
  71. package/src/objects/LightsparkNodeWithOSK.ts +389 -0
  72. package/src/objects/LightsparkNodeWithRemoteSigning.ts +384 -0
  73. package/src/objects/Node.ts +213 -60
  74. package/src/objects/NodeToAddressesConnection.ts +2 -2
  75. package/src/objects/OnChainTransaction.ts +2 -2
  76. package/src/objects/OutgoingPayment.ts +139 -24
  77. package/src/objects/OutgoingPaymentAttempt.ts +5 -5
  78. package/src/objects/OutgoingPaymentAttemptToHopsConnection.ts +3 -3
  79. package/src/objects/OutgoingPaymentToAttemptsConnection.ts +3 -3
  80. package/src/objects/OutgoingPaymentsForInvoiceQueryInput.ts +25 -0
  81. package/src/objects/OutgoingPaymentsForInvoiceQueryOutput.ts +28 -0
  82. package/src/objects/PayUmaInvoiceInput.ts +25 -0
  83. package/src/objects/{LightsparkNodePurpose.ts → PaymentDirection.ts} +5 -7
  84. package/src/objects/PaymentRequest.ts +119 -22
  85. package/src/objects/PaymentRequestData.ts +119 -22
  86. package/src/objects/PostTransactionData.ts +39 -0
  87. package/src/objects/RegisterPaymentInput.ts +31 -0
  88. package/src/objects/RegisterPaymentOutput.ts +23 -0
  89. package/src/objects/ReleaseChannelPerCommitmentSecretInput.ts +23 -0
  90. package/src/objects/ReleaseChannelPerCommitmentSecretOutput.ts +23 -0
  91. package/src/objects/ReleasePaymentPreimageInput.ts +20 -0
  92. package/src/objects/ReleasePaymentPreimageOutput.ts +23 -0
  93. package/src/objects/RemoteSigningSubEventType.ts +26 -0
  94. package/src/objects/RequestWithdrawalInput.ts +1 -1
  95. package/src/objects/RequestWithdrawalOutput.ts +1 -1
  96. package/src/objects/RoutingTransaction.ts +1 -1
  97. package/src/objects/ScreenNodeInput.ts +20 -0
  98. package/src/objects/ScreenNodeOutput.ts +22 -0
  99. package/src/objects/SetInvoicePaymentHashInput.ts +24 -0
  100. package/src/objects/SetInvoicePaymentHashOutput.ts +23 -0
  101. package/src/objects/SignInvoiceInput.ts +19 -0
  102. package/src/objects/SignInvoiceOutput.ts +21 -0
  103. package/src/objects/SignMessagesInput.ts +18 -0
  104. package/src/objects/SignMessagesOutput.ts +26 -0
  105. package/src/objects/Signable.ts +58 -0
  106. package/src/objects/SignablePayload.ts +93 -0
  107. package/src/objects/SignablePayloadStatus.ts +17 -0
  108. package/src/objects/SingleNodeDashboard.ts +0 -2
  109. package/src/objects/Transaction.ts +153 -29
  110. package/src/objects/TransactionFailures.ts +1 -1
  111. package/src/objects/UpdateChannelPerCommitmentPointInput.ts +25 -0
  112. package/src/objects/UpdateChannelPerCommitmentPointOutput.ts +23 -0
  113. package/src/objects/UpdateNodeSharedSecretInput.ts +18 -0
  114. package/src/objects/UpdateNodeSharedSecretOutput.ts +23 -0
  115. package/src/objects/Wallet.ts +271 -51
  116. package/src/objects/WalletToPaymentRequestsConnection.ts +3 -3
  117. package/src/objects/WalletToTransactionsConnection.ts +3 -3
  118. package/src/objects/WithdrawalRequest.ts +6 -6
  119. package/src/objects/WithdrawalRequestToChannelClosingTransactionsConnection.ts +2 -2
  120. package/src/objects/WithdrawalRequestToChannelOpeningTransactionsConnection.ts +2 -2
  121. package/src/objects/index.ts +37 -4
  122. package/src/{__tests__ → tests}/webhooks.test.ts +1 -1
  123. package/src/webhooks.ts +1 -1
  124. package/src/objects/ScreenBitcoinAddressesInput.ts +0 -23
  125. package/src/objects/ScreenBitcoinAddressesOutput.ts +0 -25
@@ -8,6 +8,7 @@ import IncomingPayment from "./IncomingPayment.js";
8
8
  import OutgoingPayment from "./OutgoingPayment.js";
9
9
  import PaymentFailureReason from "./PaymentFailureReason.js";
10
10
  import { PaymentRequestDataFromJson } from "./PaymentRequestData.js";
11
+ import { PostTransactionDataFromJson } from "./PostTransactionData.js";
11
12
  import { RichTextFromJson } from "./RichText.js";
12
13
  import type RoutingTransaction from "./RoutingTransaction.js";
13
14
  import RoutingTransactionFailureReason from "./RoutingTransactionFailureReason.js";
@@ -46,7 +47,7 @@ type LightningTransaction = Transaction &
46
47
  };
47
48
 
48
49
  export const LightningTransactionFromJson = (
49
- obj: any
50
+ obj: any,
50
51
  ): LightningTransaction => {
51
52
  if (obj["__typename"] == "IncomingPayment") {
52
53
  return new IncomingPayment(
@@ -60,8 +61,10 @@ export const LightningTransactionFromJson = (
60
61
  "IncomingPayment",
61
62
  obj["incoming_payment_resolved_at"],
62
63
  obj["incoming_payment_transaction_hash"],
63
- obj["incoming_payment_origin"]?.id ?? undefined,
64
- obj["incoming_payment_payment_request"]?.id ?? undefined
64
+ obj["incoming_payment_payment_request"]?.id ?? undefined,
65
+ obj["incoming_payment_uma_post_transaction_data"]?.map((e) =>
66
+ PostTransactionDataFromJson(e),
67
+ ),
65
68
  );
66
69
  }
67
70
  if (obj["__typename"] == "OutgoingPayment") {
@@ -82,7 +85,7 @@ export const LightningTransactionFromJson = (
82
85
  : undefined,
83
86
  !!obj["outgoing_payment_payment_request_data"]
84
87
  ? PaymentRequestDataFromJson(
85
- obj["outgoing_payment_payment_request_data"]
88
+ obj["outgoing_payment_payment_request_data"],
86
89
  )
87
90
  : undefined,
88
91
  !!obj["outgoing_payment_failure_reason"]
@@ -91,7 +94,10 @@ export const LightningTransactionFromJson = (
91
94
  : null,
92
95
  !!obj["outgoing_payment_failure_message"]
93
96
  ? RichTextFromJson(obj["outgoing_payment_failure_message"])
94
- : undefined
97
+ : undefined,
98
+ obj["outgoing_payment_uma_post_transaction_data"]?.map((e) =>
99
+ PostTransactionDataFromJson(e),
100
+ ),
95
101
  );
96
102
  }
97
103
  if (obj["__typename"] == "RoutingTransaction") {
@@ -125,7 +131,7 @@ export const LightningTransactionFromJson = (
125
131
  }
126
132
  throw new LightsparkException(
127
133
  "DeserializationError",
128
- `Couldn't find a concrete type for interface LightningTransaction corresponding to the typename=${obj["__typename"]}`
134
+ `Couldn't find a concrete type for interface LightningTransaction corresponding to the typename=${obj["__typename"]}`,
129
135
  );
130
136
  };
131
137
 
@@ -148,15 +154,24 @@ fragment LightningTransactionFragment on LightningTransaction {
148
154
  currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
149
155
  }
150
156
  incoming_payment_transaction_hash: transaction_hash
151
- incoming_payment_origin: origin {
152
- id
153
- }
154
157
  incoming_payment_destination: destination {
155
158
  id
156
159
  }
157
160
  incoming_payment_payment_request: payment_request {
158
161
  id
159
162
  }
163
+ incoming_payment_uma_post_transaction_data: uma_post_transaction_data {
164
+ __typename
165
+ post_transaction_data_utxo: utxo
166
+ post_transaction_data_amount: amount {
167
+ __typename
168
+ currency_amount_original_value: original_value
169
+ currency_amount_original_unit: original_unit
170
+ currency_amount_preferred_currency_unit: preferred_currency_unit
171
+ currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
172
+ currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
173
+ }
174
+ }
160
175
  }
161
176
  ... on OutgoingPayment {
162
177
  __typename
@@ -220,24 +235,54 @@ fragment LightningTransactionFragment on LightningTransaction {
220
235
  graph_node_display_name: display_name
221
236
  graph_node_public_key: public_key
222
237
  }
223
- ... on LightsparkNode {
238
+ ... on LightsparkNodeWithOSK {
224
239
  __typename
225
- lightspark_node_id: id
226
- lightspark_node_created_at: created_at
227
- lightspark_node_updated_at: updated_at
228
- lightspark_node_alias: alias
229
- lightspark_node_bitcoin_network: bitcoin_network
230
- lightspark_node_color: color
231
- lightspark_node_conductivity: conductivity
232
- lightspark_node_display_name: display_name
233
- lightspark_node_public_key: public_key
234
- lightspark_node_account: account {
240
+ lightspark_node_with_o_s_k_id: id
241
+ lightspark_node_with_o_s_k_created_at: created_at
242
+ lightspark_node_with_o_s_k_updated_at: updated_at
243
+ lightspark_node_with_o_s_k_alias: alias
244
+ lightspark_node_with_o_s_k_bitcoin_network: bitcoin_network
245
+ lightspark_node_with_o_s_k_color: color
246
+ lightspark_node_with_o_s_k_conductivity: conductivity
247
+ lightspark_node_with_o_s_k_display_name: display_name
248
+ lightspark_node_with_o_s_k_public_key: public_key
249
+ lightspark_node_with_o_s_k_owner: owner {
235
250
  id
236
251
  }
237
- lightspark_node_owner: owner {
238
- id
252
+ lightspark_node_with_o_s_k_status: status
253
+ lightspark_node_with_o_s_k_total_balance: total_balance {
254
+ __typename
255
+ currency_amount_original_value: original_value
256
+ currency_amount_original_unit: original_unit
257
+ currency_amount_preferred_currency_unit: preferred_currency_unit
258
+ currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
259
+ currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
260
+ }
261
+ lightspark_node_with_o_s_k_total_local_balance: total_local_balance {
262
+ __typename
263
+ currency_amount_original_value: original_value
264
+ currency_amount_original_unit: original_unit
265
+ currency_amount_preferred_currency_unit: preferred_currency_unit
266
+ currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
267
+ currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
239
268
  }
240
- lightspark_node_blockchain_balance: blockchain_balance {
269
+ lightspark_node_with_o_s_k_local_balance: local_balance {
270
+ __typename
271
+ currency_amount_original_value: original_value
272
+ currency_amount_original_unit: original_unit
273
+ currency_amount_preferred_currency_unit: preferred_currency_unit
274
+ currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
275
+ currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
276
+ }
277
+ lightspark_node_with_o_s_k_remote_balance: remote_balance {
278
+ __typename
279
+ currency_amount_original_value: original_value
280
+ currency_amount_original_unit: original_unit
281
+ currency_amount_preferred_currency_unit: preferred_currency_unit
282
+ currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
283
+ currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
284
+ }
285
+ lightspark_node_with_o_s_k_blockchain_balance: blockchain_balance {
241
286
  __typename
242
287
  blockchain_balance_total_balance: total_balance {
243
288
  __typename
@@ -288,12 +333,29 @@ fragment LightningTransactionFragment on LightningTransaction {
288
333
  currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
289
334
  }
290
335
  }
291
- lightspark_node_encrypted_signing_private_key: encrypted_signing_private_key {
336
+ lightspark_node_with_o_s_k_uma_prescreening_utxos: uma_prescreening_utxos
337
+ lightspark_node_with_o_s_k_encrypted_signing_private_key: encrypted_signing_private_key {
292
338
  __typename
293
339
  secret_encrypted_value: encrypted_value
294
340
  secret_cipher: cipher
295
341
  }
296
- lightspark_node_total_balance: total_balance {
342
+ }
343
+ ... on LightsparkNodeWithRemoteSigning {
344
+ __typename
345
+ lightspark_node_with_remote_signing_id: id
346
+ lightspark_node_with_remote_signing_created_at: created_at
347
+ lightspark_node_with_remote_signing_updated_at: updated_at
348
+ lightspark_node_with_remote_signing_alias: alias
349
+ lightspark_node_with_remote_signing_bitcoin_network: bitcoin_network
350
+ lightspark_node_with_remote_signing_color: color
351
+ lightspark_node_with_remote_signing_conductivity: conductivity
352
+ lightspark_node_with_remote_signing_display_name: display_name
353
+ lightspark_node_with_remote_signing_public_key: public_key
354
+ lightspark_node_with_remote_signing_owner: owner {
355
+ id
356
+ }
357
+ lightspark_node_with_remote_signing_status: status
358
+ lightspark_node_with_remote_signing_total_balance: total_balance {
297
359
  __typename
298
360
  currency_amount_original_value: original_value
299
361
  currency_amount_original_unit: original_unit
@@ -301,7 +363,7 @@ fragment LightningTransactionFragment on LightningTransaction {
301
363
  currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
302
364
  currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
303
365
  }
304
- lightspark_node_total_local_balance: total_local_balance {
366
+ lightspark_node_with_remote_signing_total_local_balance: total_local_balance {
305
367
  __typename
306
368
  currency_amount_original_value: original_value
307
369
  currency_amount_original_unit: original_unit
@@ -309,7 +371,7 @@ fragment LightningTransactionFragment on LightningTransaction {
309
371
  currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
310
372
  currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
311
373
  }
312
- lightspark_node_local_balance: local_balance {
374
+ lightspark_node_with_remote_signing_local_balance: local_balance {
313
375
  __typename
314
376
  currency_amount_original_value: original_value
315
377
  currency_amount_original_unit: original_unit
@@ -317,8 +379,7 @@ fragment LightningTransactionFragment on LightningTransaction {
317
379
  currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
318
380
  currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
319
381
  }
320
- lightspark_node_purpose: purpose
321
- lightspark_node_remote_balance: remote_balance {
382
+ lightspark_node_with_remote_signing_remote_balance: remote_balance {
322
383
  __typename
323
384
  currency_amount_original_value: original_value
324
385
  currency_amount_original_unit: original_unit
@@ -326,7 +387,58 @@ fragment LightningTransactionFragment on LightningTransaction {
326
387
  currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
327
388
  currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
328
389
  }
329
- lightspark_node_status: status
390
+ lightspark_node_with_remote_signing_blockchain_balance: blockchain_balance {
391
+ __typename
392
+ blockchain_balance_total_balance: total_balance {
393
+ __typename
394
+ currency_amount_original_value: original_value
395
+ currency_amount_original_unit: original_unit
396
+ currency_amount_preferred_currency_unit: preferred_currency_unit
397
+ currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
398
+ currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
399
+ }
400
+ blockchain_balance_confirmed_balance: confirmed_balance {
401
+ __typename
402
+ currency_amount_original_value: original_value
403
+ currency_amount_original_unit: original_unit
404
+ currency_amount_preferred_currency_unit: preferred_currency_unit
405
+ currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
406
+ currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
407
+ }
408
+ blockchain_balance_unconfirmed_balance: unconfirmed_balance {
409
+ __typename
410
+ currency_amount_original_value: original_value
411
+ currency_amount_original_unit: original_unit
412
+ currency_amount_preferred_currency_unit: preferred_currency_unit
413
+ currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
414
+ currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
415
+ }
416
+ blockchain_balance_locked_balance: locked_balance {
417
+ __typename
418
+ currency_amount_original_value: original_value
419
+ currency_amount_original_unit: original_unit
420
+ currency_amount_preferred_currency_unit: preferred_currency_unit
421
+ currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
422
+ currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
423
+ }
424
+ blockchain_balance_required_reserve: required_reserve {
425
+ __typename
426
+ currency_amount_original_value: original_value
427
+ currency_amount_original_unit: original_unit
428
+ currency_amount_preferred_currency_unit: preferred_currency_unit
429
+ currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
430
+ currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
431
+ }
432
+ blockchain_balance_available_balance: available_balance {
433
+ __typename
434
+ currency_amount_original_value: original_value
435
+ currency_amount_original_unit: original_unit
436
+ currency_amount_preferred_currency_unit: preferred_currency_unit
437
+ currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
438
+ currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
439
+ }
440
+ }
441
+ lightspark_node_with_remote_signing_uma_prescreening_utxos: uma_prescreening_utxos
330
442
  }
331
443
  }
332
444
  }
@@ -336,6 +448,18 @@ fragment LightningTransactionFragment on LightningTransaction {
336
448
  __typename
337
449
  rich_text_text: text
338
450
  }
451
+ outgoing_payment_uma_post_transaction_data: uma_post_transaction_data {
452
+ __typename
453
+ post_transaction_data_utxo: utxo
454
+ post_transaction_data_amount: amount {
455
+ __typename
456
+ currency_amount_original_value: original_value
457
+ currency_amount_original_unit: original_unit
458
+ currency_amount_preferred_currency_unit: preferred_currency_unit
459
+ currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
460
+ currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
461
+ }
462
+ }
339
463
  }
340
464
  ... on RoutingTransaction {
341
465
  __typename
@@ -376,7 +500,7 @@ fragment LightningTransactionFragment on LightningTransaction {
376
500
  }`;
377
501
 
378
502
  export const getLightningTransactionQuery = (
379
- id: string
503
+ id: string,
380
504
  ): Query<LightningTransaction> => {
381
505
  return {
382
506
  queryPayload: `