@lightsparkdev/lightspark-sdk 1.0.7 → 1.1.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/index.cjs CHANGED
@@ -1938,7 +1938,7 @@ var import_core9 = require("@lightsparkdev/core");
1938
1938
  // package.json
1939
1939
  var package_default = {
1940
1940
  name: "@lightsparkdev/lightspark-sdk",
1941
- version: "1.0.7",
1941
+ version: "1.1.0",
1942
1942
  description: "Lightspark JS SDK",
1943
1943
  author: "Lightspark Inc.",
1944
1944
  keywords: [
@@ -4333,11 +4333,465 @@ mutation CreateTestModeInvoice(
4333
4333
  }
4334
4334
  `;
4335
4335
 
4336
+ // src/objects/IncomingPayment.ts
4337
+ var import_auto_bind7 = __toESM(require("auto-bind"), 1);
4338
+
4339
+ // src/objects/IncomingPaymentAttemptStatus.ts
4340
+ var IncomingPaymentAttemptStatus = /* @__PURE__ */ ((IncomingPaymentAttemptStatus2) => {
4341
+ IncomingPaymentAttemptStatus2["FUTURE_VALUE"] = "FUTURE_VALUE";
4342
+ IncomingPaymentAttemptStatus2["ACCEPTED"] = "ACCEPTED";
4343
+ IncomingPaymentAttemptStatus2["SETTLED"] = "SETTLED";
4344
+ IncomingPaymentAttemptStatus2["CANCELED"] = "CANCELED";
4345
+ IncomingPaymentAttemptStatus2["UNKNOWN"] = "UNKNOWN";
4346
+ return IncomingPaymentAttemptStatus2;
4347
+ })(IncomingPaymentAttemptStatus || {});
4348
+ var IncomingPaymentAttemptStatus_default = IncomingPaymentAttemptStatus;
4349
+
4350
+ // src/objects/IncomingPaymentAttempt.ts
4351
+ var IncomingPaymentAttemptFromJson = (obj) => {
4352
+ return {
4353
+ id: obj["incoming_payment_attempt_id"],
4354
+ createdAt: obj["incoming_payment_attempt_created_at"],
4355
+ updatedAt: obj["incoming_payment_attempt_updated_at"],
4356
+ status: IncomingPaymentAttemptStatus_default[obj["incoming_payment_attempt_status"]] ?? IncomingPaymentAttemptStatus_default.FUTURE_VALUE,
4357
+ amount: CurrencyAmountFromJson(obj["incoming_payment_attempt_amount"]),
4358
+ channelId: obj["incoming_payment_attempt_channel"].id,
4359
+ typename: "IncomingPaymentAttempt",
4360
+ resolvedAt: obj["incoming_payment_attempt_resolved_at"]
4361
+ };
4362
+ };
4363
+ var FRAGMENT11 = `
4364
+ fragment IncomingPaymentAttemptFragment on IncomingPaymentAttempt {
4365
+ __typename
4366
+ incoming_payment_attempt_id: id
4367
+ incoming_payment_attempt_created_at: created_at
4368
+ incoming_payment_attempt_updated_at: updated_at
4369
+ incoming_payment_attempt_status: status
4370
+ incoming_payment_attempt_resolved_at: resolved_at
4371
+ incoming_payment_attempt_amount: amount {
4372
+ __typename
4373
+ currency_amount_original_value: original_value
4374
+ currency_amount_original_unit: original_unit
4375
+ currency_amount_preferred_currency_unit: preferred_currency_unit
4376
+ currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
4377
+ currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
4378
+ }
4379
+ incoming_payment_attempt_channel: channel {
4380
+ id
4381
+ }
4382
+ }`;
4383
+ var getIncomingPaymentAttemptQuery = (id) => {
4384
+ return {
4385
+ queryPayload: `
4386
+ query GetIncomingPaymentAttempt($id: ID!) {
4387
+ entity(id: $id) {
4388
+ ... on IncomingPaymentAttempt {
4389
+ ...IncomingPaymentAttemptFragment
4390
+ }
4391
+ }
4392
+ }
4393
+
4394
+ ${FRAGMENT11}
4395
+ `,
4396
+ variables: { id },
4397
+ constructObject: (data) => IncomingPaymentAttemptFromJson(data.entity)
4398
+ };
4399
+ };
4400
+
4401
+ // src/objects/IncomingPaymentToAttemptsConnection.ts
4402
+ var IncomingPaymentToAttemptsConnectionFromJson = (obj) => {
4403
+ return {
4404
+ count: obj["incoming_payment_to_attempts_connection_count"],
4405
+ pageInfo: PageInfoFromJson(
4406
+ obj["incoming_payment_to_attempts_connection_page_info"]
4407
+ ),
4408
+ entities: obj["incoming_payment_to_attempts_connection_entities"].map(
4409
+ (e) => IncomingPaymentAttemptFromJson(e)
4410
+ ),
4411
+ typename: "IncomingPaymentToAttemptsConnection"
4412
+ };
4413
+ };
4414
+
4415
+ // src/objects/PostTransactionData.ts
4416
+ var PostTransactionDataFromJson = (obj) => {
4417
+ return {
4418
+ utxo: obj["post_transaction_data_utxo"],
4419
+ amount: CurrencyAmountFromJson(obj["post_transaction_data_amount"])
4420
+ };
4421
+ };
4422
+
4423
+ // src/objects/TransactionStatus.ts
4424
+ var TransactionStatus = /* @__PURE__ */ ((TransactionStatus2) => {
4425
+ TransactionStatus2["FUTURE_VALUE"] = "FUTURE_VALUE";
4426
+ TransactionStatus2["SUCCESS"] = "SUCCESS";
4427
+ TransactionStatus2["FAILED"] = "FAILED";
4428
+ TransactionStatus2["PENDING"] = "PENDING";
4429
+ TransactionStatus2["NOT_STARTED"] = "NOT_STARTED";
4430
+ TransactionStatus2["EXPIRED"] = "EXPIRED";
4431
+ TransactionStatus2["CANCELLED"] = "CANCELLED";
4432
+ return TransactionStatus2;
4433
+ })(TransactionStatus || {});
4434
+ var TransactionStatus_default = TransactionStatus;
4435
+
4436
+ // src/objects/IncomingPayment.ts
4437
+ var IncomingPayment = class {
4438
+ constructor(id, createdAt, updatedAt, status, amount, destinationId, typename, resolvedAt, transactionHash, paymentRequestId, umaPostTransactionData) {
4439
+ this.id = id;
4440
+ this.createdAt = createdAt;
4441
+ this.updatedAt = updatedAt;
4442
+ this.status = status;
4443
+ this.amount = amount;
4444
+ this.destinationId = destinationId;
4445
+ this.typename = typename;
4446
+ this.resolvedAt = resolvedAt;
4447
+ this.transactionHash = transactionHash;
4448
+ this.paymentRequestId = paymentRequestId;
4449
+ this.umaPostTransactionData = umaPostTransactionData;
4450
+ (0, import_auto_bind7.default)(this);
4451
+ }
4452
+ async getAttempts(client, first = void 0, statuses = void 0, after = void 0) {
4453
+ return await client.executeRawQuery({
4454
+ queryPayload: `
4455
+ query FetchIncomingPaymentToAttemptsConnection($entity_id: ID!, $first: Int, $statuses: [IncomingPaymentAttemptStatus!], $after: String) {
4456
+ entity(id: $entity_id) {
4457
+ ... on IncomingPayment {
4458
+ attempts(, first: $first, statuses: $statuses, after: $after) {
4459
+ __typename
4460
+ incoming_payment_to_attempts_connection_count: count
4461
+ incoming_payment_to_attempts_connection_page_info: page_info {
4462
+ __typename
4463
+ page_info_has_next_page: has_next_page
4464
+ page_info_has_previous_page: has_previous_page
4465
+ page_info_start_cursor: start_cursor
4466
+ page_info_end_cursor: end_cursor
4467
+ }
4468
+ incoming_payment_to_attempts_connection_entities: entities {
4469
+ __typename
4470
+ incoming_payment_attempt_id: id
4471
+ incoming_payment_attempt_created_at: created_at
4472
+ incoming_payment_attempt_updated_at: updated_at
4473
+ incoming_payment_attempt_status: status
4474
+ incoming_payment_attempt_resolved_at: resolved_at
4475
+ incoming_payment_attempt_amount: amount {
4476
+ __typename
4477
+ currency_amount_original_value: original_value
4478
+ currency_amount_original_unit: original_unit
4479
+ currency_amount_preferred_currency_unit: preferred_currency_unit
4480
+ currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
4481
+ currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
4482
+ }
4483
+ incoming_payment_attempt_channel: channel {
4484
+ id
4485
+ }
4486
+ }
4487
+ }
4488
+ }
4489
+ }
4490
+ }
4491
+ `,
4492
+ variables: {
4493
+ entity_id: this.id,
4494
+ first,
4495
+ statuses,
4496
+ after
4497
+ },
4498
+ constructObject: (json) => {
4499
+ const connection = json["entity"]["attempts"];
4500
+ return IncomingPaymentToAttemptsConnectionFromJson(connection);
4501
+ }
4502
+ });
4503
+ }
4504
+ static getIncomingPaymentQuery(id) {
4505
+ return {
4506
+ queryPayload: `
4507
+ query GetIncomingPayment($id: ID!) {
4508
+ entity(id: $id) {
4509
+ ... on IncomingPayment {
4510
+ ...IncomingPaymentFragment
4511
+ }
4512
+ }
4513
+ }
4514
+
4515
+ ${FRAGMENT12}
4516
+ `,
4517
+ variables: { id },
4518
+ constructObject: (data) => IncomingPaymentFromJson(data.entity)
4519
+ };
4520
+ }
4521
+ };
4522
+ var IncomingPaymentFromJson = (obj) => {
4523
+ return new IncomingPayment(
4524
+ obj["incoming_payment_id"],
4525
+ obj["incoming_payment_created_at"],
4526
+ obj["incoming_payment_updated_at"],
4527
+ TransactionStatus_default[obj["incoming_payment_status"]] ?? TransactionStatus_default.FUTURE_VALUE,
4528
+ CurrencyAmountFromJson(obj["incoming_payment_amount"]),
4529
+ obj["incoming_payment_destination"].id,
4530
+ "IncomingPayment",
4531
+ obj["incoming_payment_resolved_at"],
4532
+ obj["incoming_payment_transaction_hash"],
4533
+ obj["incoming_payment_payment_request"]?.id ?? void 0,
4534
+ obj["incoming_payment_uma_post_transaction_data"]?.map(
4535
+ (e) => PostTransactionDataFromJson(e)
4536
+ )
4537
+ );
4538
+ };
4539
+ var FRAGMENT12 = `
4540
+ fragment IncomingPaymentFragment on IncomingPayment {
4541
+ __typename
4542
+ incoming_payment_id: id
4543
+ incoming_payment_created_at: created_at
4544
+ incoming_payment_updated_at: updated_at
4545
+ incoming_payment_status: status
4546
+ incoming_payment_resolved_at: resolved_at
4547
+ incoming_payment_amount: amount {
4548
+ __typename
4549
+ currency_amount_original_value: original_value
4550
+ currency_amount_original_unit: original_unit
4551
+ currency_amount_preferred_currency_unit: preferred_currency_unit
4552
+ currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
4553
+ currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
4554
+ }
4555
+ incoming_payment_transaction_hash: transaction_hash
4556
+ incoming_payment_destination: destination {
4557
+ id
4558
+ }
4559
+ incoming_payment_payment_request: payment_request {
4560
+ id
4561
+ }
4562
+ incoming_payment_uma_post_transaction_data: uma_post_transaction_data {
4563
+ __typename
4564
+ post_transaction_data_utxo: utxo
4565
+ post_transaction_data_amount: amount {
4566
+ __typename
4567
+ currency_amount_original_value: original_value
4568
+ currency_amount_original_unit: original_unit
4569
+ currency_amount_preferred_currency_unit: preferred_currency_unit
4570
+ currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
4571
+ currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
4572
+ }
4573
+ }
4574
+ }`;
4575
+ var IncomingPayment_default = IncomingPayment;
4576
+
4577
+ // src/graphql/CreateTestModePayment.ts
4578
+ var CreateTestModePayment = `
4579
+ mutation CreateTestModePayment(
4580
+ $local_node_id: ID!
4581
+ $encoded_invoice: String!
4582
+ $amount_msats: Long
4583
+ ) {
4584
+ create_test_mode_payment(input: {
4585
+ local_node_id: $local_node_id
4586
+ encoded_invoice: $encoded_invoice
4587
+ amount_msats: $amount_msats
4588
+ }) {
4589
+ incoming_payment {
4590
+ ...IncomingPaymentFragment
4591
+ }
4592
+ }
4593
+ }
4594
+
4595
+ ${FRAGMENT12}
4596
+ `;
4597
+
4598
+ // src/graphql/CreateUmaInvoice.ts
4599
+ var CreateUmaInvoice = `
4600
+ mutation CreateUmaInvoice(
4601
+ $node_id: ID!
4602
+ $amount_msats: Long!
4603
+ $metadata_hash: String!
4604
+ $expiry_secs: Int = null
4605
+ ) {
4606
+ create_uma_invoice(input: {
4607
+ node_id: $node_id
4608
+ amount_msats: $amount_msats
4609
+ metadata_hash: $metadata_hash
4610
+ expiry_secs: $expiry_secs
4611
+ }) {
4612
+ invoice {
4613
+ ...InvoiceFragment
4614
+ }
4615
+ }
4616
+ }
4617
+ ${FRAGMENT10}
4618
+ `;
4619
+
4620
+ // src/graphql/DecodeInvoice.ts
4621
+ var DecodeInvoice = `
4622
+ query DecodeInvoice($encoded_payment_request: String!) {
4623
+ decoded_payment_request(encoded_payment_request: $encoded_payment_request) {
4624
+ __typename
4625
+ ... on InvoiceData {
4626
+ ...InvoiceDataFragment
4627
+ }
4628
+ }
4629
+ }
4630
+
4631
+ ${FRAGMENT9}
4632
+ `;
4633
+
4634
+ // src/graphql/DeleteApiToken.ts
4635
+ var DeleteApiToken = `
4636
+ mutation DeleteApiToken(
4637
+ $api_token_id: ID!
4638
+ ) {
4639
+ delete_api_token(input: {
4640
+ api_token_id: $api_token_id
4641
+ }) {
4642
+ __typename
4643
+ }
4644
+ }
4645
+ `;
4646
+
4647
+ // src/graphql/FundNode.ts
4648
+ var FundNode = `
4649
+ mutation FundNode(
4650
+ $node_id: ID!,
4651
+ $amountSats: Long
4652
+ ) {
4653
+ fund_node(input: { node_id: $node_id, amount_sats: $amountMsats }) {
4654
+ amount {
4655
+ ...CurrencyAmountFragment
4656
+ }
4657
+ }
4658
+ }
4659
+
4660
+ ${FRAGMENT}
4661
+ `;
4662
+
4663
+ // src/objects/LightningFeeEstimateOutput.ts
4664
+ var FRAGMENT13 = `
4665
+ fragment LightningFeeEstimateOutputFragment on LightningFeeEstimateOutput {
4666
+ __typename
4667
+ lightning_fee_estimate_output_fee_estimate: fee_estimate {
4668
+ __typename
4669
+ currency_amount_original_value: original_value
4670
+ currency_amount_original_unit: original_unit
4671
+ currency_amount_preferred_currency_unit: preferred_currency_unit
4672
+ currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
4673
+ currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
4674
+ }
4675
+ }`;
4676
+
4677
+ // src/graphql/LightningFeeEstimateForInvoice.ts
4678
+ var LightningFeeEstimateForInvoice = `
4679
+ query LightningFeeEstimateForInvoice(
4680
+ $node_id: ID!
4681
+ $encoded_payment_request: String!
4682
+ $amount_msats: Long
4683
+ ) {
4684
+ lightning_fee_estimate_for_invoice(input: {
4685
+ node_id: $node_id,
4686
+ encoded_payment_request: $encoded_payment_request,
4687
+ amount_msats: $amount_msats
4688
+ }) {
4689
+ ...LightningFeeEstimateOutputFragment
4690
+ }
4691
+ }
4692
+
4693
+ ${FRAGMENT13}
4694
+ `;
4695
+
4696
+ // src/graphql/LightningFeeEstimateForNode.ts
4697
+ var LightningFeeEstimateForNode = `
4698
+ query LightningFeeEstimateForNode(
4699
+ $node_id: ID!
4700
+ $destination_node_public_key: String!
4701
+ $amount_msats: Long!
4702
+ ) {
4703
+ lightning_fee_estimate_for_node(input: {
4704
+ node_id: $node_id,
4705
+ destination_node_public_key: $destination_node_public_key,
4706
+ amount_msats: $amount_msats
4707
+ }) {
4708
+ ...LightningFeeEstimateOutputFragment
4709
+ }
4710
+ }
4711
+
4712
+ ${FRAGMENT13}
4713
+ `;
4714
+
4715
+ // src/graphql/MultiNodeDashboard.ts
4716
+ var MultiNodeDashboard = `
4717
+ query MultiNodeDashboard(
4718
+ $network: BitcoinNetwork!,
4719
+ $nodeIds: [ID!]
4720
+ ) {
4721
+ current_account {
4722
+ id
4723
+ name
4724
+ dashboard_overview_nodes: nodes(
4725
+ bitcoin_networks: [$network]
4726
+ node_ids: $nodeIds
4727
+ ) {
4728
+ count
4729
+ entities {
4730
+ color
4731
+ display_name
4732
+ id
4733
+ addresses(first: 1) {
4734
+ entities {
4735
+ address
4736
+ type
4737
+ __typename
4738
+ }
4739
+ count
4740
+ __typename
4741
+ }
4742
+ public_key
4743
+ status
4744
+ local_balance {
4745
+ ...CurrencyAmountFragment
4746
+ }
4747
+ remote_balance {
4748
+ ...CurrencyAmountFragment
4749
+ }
4750
+ blockchain_balance {
4751
+ available_balance {
4752
+ ...CurrencyAmountFragment
4753
+ }
4754
+ total_balance {
4755
+ ...CurrencyAmountFragment
4756
+ }
4757
+ __typename
4758
+ }
4759
+ __typename
4760
+ }
4761
+ __typename
4762
+ }
4763
+ blockchain_balance(bitcoin_networks: [$network], node_ids: $nodeIds) {
4764
+ l1_balance: total_balance {
4765
+ ...CurrencyAmountFragment
4766
+ }
4767
+ required_reserve {
4768
+ ...CurrencyAmountFragment
4769
+ }
4770
+ available_balance {
4771
+ ...CurrencyAmountFragment
4772
+ }
4773
+ unconfirmed_balance {
4774
+ ...CurrencyAmountFragment
4775
+ }
4776
+ __typename
4777
+ }
4778
+ local_balance(bitcoin_networks: [$network], node_ids: $nodeIds) {
4779
+ ...CurrencyAmountFragment
4780
+ }
4781
+ remote_balance(bitcoin_networks: [$network], node_ids: $nodeIds) {
4782
+ ...CurrencyAmountFragment
4783
+ }
4784
+ }
4785
+ }
4786
+
4787
+ ${FRAGMENT}
4788
+ `;
4789
+
4336
4790
  // src/objects/OutgoingPayment.ts
4337
- var import_auto_bind8 = __toESM(require("auto-bind"), 1);
4791
+ var import_auto_bind9 = __toESM(require("auto-bind"), 1);
4338
4792
 
4339
4793
  // src/objects/OutgoingPaymentAttempt.ts
4340
- var import_auto_bind7 = __toESM(require("auto-bind"), 1);
4794
+ var import_auto_bind8 = __toESM(require("auto-bind"), 1);
4341
4795
 
4342
4796
  // src/objects/HtlcAttemptFailureCode.ts
4343
4797
  var HtlcAttemptFailureCode = /* @__PURE__ */ ((HtlcAttemptFailureCode2) => {
@@ -4398,7 +4852,7 @@ var HopFromJson = (obj) => {
4398
4852
  expiryBlockHeight: obj["hop_expiry_block_height"]
4399
4853
  };
4400
4854
  };
4401
- var FRAGMENT11 = `
4855
+ var FRAGMENT14 = `
4402
4856
  fragment HopFragment on Hop {
4403
4857
  __typename
4404
4858
  hop_id: id
@@ -4438,7 +4892,7 @@ query GetHop($id: ID!) {
4438
4892
  }
4439
4893
  }
4440
4894
 
4441
- ${FRAGMENT11}
4895
+ ${FRAGMENT14}
4442
4896
  `,
4443
4897
  variables: { id },
4444
4898
  constructObject: (data) => HopFromJson(data.entity)
@@ -4473,7 +4927,7 @@ var OutgoingPaymentAttempt = class {
4473
4927
  this.resolvedAt = resolvedAt;
4474
4928
  this.amount = amount;
4475
4929
  this.fees = fees;
4476
- (0, import_auto_bind7.default)(this);
4930
+ (0, import_auto_bind8.default)(this);
4477
4931
  }
4478
4932
  async getHops(client, first = void 0, after = void 0) {
4479
4933
  return await client.executeRawQuery({
@@ -4542,7 +4996,7 @@ query GetOutgoingPaymentAttempt($id: ID!) {
4542
4996
  }
4543
4997
  }
4544
4998
 
4545
- ${FRAGMENT12}
4999
+ ${FRAGMENT15}
4546
5000
  `,
4547
5001
  variables: { id },
4548
5002
  constructObject: (data) => OutgoingPaymentAttemptFromJson(data.entity)
@@ -4564,7 +5018,7 @@ var OutgoingPaymentAttemptFromJson = (obj) => {
4564
5018
  !!obj["outgoing_payment_attempt_fees"] ? CurrencyAmountFromJson(obj["outgoing_payment_attempt_fees"]) : void 0
4565
5019
  );
4566
5020
  };
4567
- var FRAGMENT12 = `
5021
+ var FRAGMENT15 = `
4568
5022
  fragment OutgoingPaymentAttemptFragment on OutgoingPaymentAttempt {
4569
5023
  __typename
4570
5024
  outgoing_payment_attempt_id: id
@@ -4649,14 +5103,6 @@ var PaymentRequestDataFromJson = (obj) => {
4649
5103
  );
4650
5104
  };
4651
5105
 
4652
- // src/objects/PostTransactionData.ts
4653
- var PostTransactionDataFromJson = (obj) => {
4654
- return {
4655
- utxo: obj["post_transaction_data_utxo"],
4656
- amount: CurrencyAmountFromJson(obj["post_transaction_data_amount"])
4657
- };
4658
- };
4659
-
4660
5106
  // src/objects/RichText.ts
4661
5107
  var RichTextFromJson = (obj) => {
4662
5108
  return {
@@ -4664,19 +5110,6 @@ var RichTextFromJson = (obj) => {
4664
5110
  };
4665
5111
  };
4666
5112
 
4667
- // src/objects/TransactionStatus.ts
4668
- var TransactionStatus = /* @__PURE__ */ ((TransactionStatus2) => {
4669
- TransactionStatus2["FUTURE_VALUE"] = "FUTURE_VALUE";
4670
- TransactionStatus2["SUCCESS"] = "SUCCESS";
4671
- TransactionStatus2["FAILED"] = "FAILED";
4672
- TransactionStatus2["PENDING"] = "PENDING";
4673
- TransactionStatus2["NOT_STARTED"] = "NOT_STARTED";
4674
- TransactionStatus2["EXPIRED"] = "EXPIRED";
4675
- TransactionStatus2["CANCELLED"] = "CANCELLED";
4676
- return TransactionStatus2;
4677
- })(TransactionStatus || {});
4678
- var TransactionStatus_default = TransactionStatus;
4679
-
4680
5113
  // src/objects/OutgoingPayment.ts
4681
5114
  var OutgoingPayment = class {
4682
5115
  constructor(id, createdAt, updatedAt, status, amount, originId, typename, resolvedAt, transactionHash, destinationId, fees, paymentRequestData, failureReason, failureMessage, umaPostTransactionData) {
@@ -4695,7 +5128,7 @@ var OutgoingPayment = class {
4695
5128
  this.failureReason = failureReason;
4696
5129
  this.failureMessage = failureMessage;
4697
5130
  this.umaPostTransactionData = umaPostTransactionData;
4698
- (0, import_auto_bind8.default)(this);
5131
+ (0, import_auto_bind9.default)(this);
4699
5132
  }
4700
5133
  async getAttempts(client, first = void 0, after = void 0) {
4701
5134
  return await client.executeRawQuery({
@@ -4765,7 +5198,7 @@ query GetOutgoingPayment($id: ID!) {
4765
5198
  }
4766
5199
  }
4767
5200
 
4768
- ${FRAGMENT13}
5201
+ ${FRAGMENT16}
4769
5202
  `,
4770
5203
  variables: { id },
4771
5204
  constructObject: (data) => OutgoingPaymentFromJson(data.entity)
@@ -4793,7 +5226,7 @@ var OutgoingPaymentFromJson = (obj) => {
4793
5226
  )
4794
5227
  );
4795
5228
  };
4796
- var FRAGMENT13 = `
5229
+ var FRAGMENT16 = `
4797
5230
  fragment OutgoingPaymentFragment on OutgoingPayment {
4798
5231
  __typename
4799
5232
  outgoing_payment_id: id
@@ -5076,226 +5509,13 @@ fragment OutgoingPaymentFragment on OutgoingPayment {
5076
5509
  __typename
5077
5510
  currency_amount_original_value: original_value
5078
5511
  currency_amount_original_unit: original_unit
5079
- currency_amount_preferred_currency_unit: preferred_currency_unit
5080
- currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
5081
- currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
5082
- }
5083
- }
5084
- }`;
5085
- var OutgoingPayment_default = OutgoingPayment;
5086
-
5087
- // src/graphql/CreateTestModePayment.ts
5088
- var CreateTestModePayment = `
5089
- mutation CreateTestModePayment(
5090
- $local_node_id: ID!
5091
- $encoded_invoice: String!
5092
- $amount_msats: Long
5093
- ) {
5094
- create_test_mode_payment(input: {
5095
- local_node_id: $local_node_id
5096
- encoded_invoice: $encoded_invoice
5097
- amount_msats: $amount_msats
5098
- }) {
5099
- payment {
5100
- ...OutgoingPaymentFragment
5101
- }
5102
- }
5103
- }
5104
-
5105
- ${FRAGMENT13}
5106
- `;
5107
-
5108
- // src/graphql/CreateUmaInvoice.ts
5109
- var CreateUmaInvoice = `
5110
- mutation CreateUmaInvoice(
5111
- $node_id: ID!
5112
- $amount_msats: Long!
5113
- $metadata_hash: String!
5114
- $expiry_secs: Int = null
5115
- ) {
5116
- create_uma_invoice(input: {
5117
- node_id: $node_id
5118
- amount_msats: $amount_msats
5119
- metadata_hash: $metadata_hash
5120
- expiry_secs: $expiry_secs
5121
- }) {
5122
- invoice {
5123
- ...InvoiceFragment
5124
- }
5125
- }
5126
- }
5127
- ${FRAGMENT10}
5128
- `;
5129
-
5130
- // src/graphql/DecodeInvoice.ts
5131
- var DecodeInvoice = `
5132
- query DecodeInvoice($encoded_payment_request: String!) {
5133
- decoded_payment_request(encoded_payment_request: $encoded_payment_request) {
5134
- __typename
5135
- ... on InvoiceData {
5136
- ...InvoiceDataFragment
5137
- }
5138
- }
5139
- }
5140
-
5141
- ${FRAGMENT9}
5142
- `;
5143
-
5144
- // src/graphql/DeleteApiToken.ts
5145
- var DeleteApiToken = `
5146
- mutation DeleteApiToken(
5147
- $api_token_id: ID!
5148
- ) {
5149
- delete_api_token(input: {
5150
- api_token_id: $api_token_id
5151
- }) {
5152
- __typename
5153
- }
5154
- }
5155
- `;
5156
-
5157
- // src/graphql/FundNode.ts
5158
- var FundNode = `
5159
- mutation FundNode(
5160
- $node_id: ID!,
5161
- $amountSats: Long
5162
- ) {
5163
- fund_node(input: { node_id: $node_id, amount_sats: $amountMsats }) {
5164
- amount {
5165
- ...CurrencyAmountFragment
5166
- }
5167
- }
5168
- }
5169
-
5170
- ${FRAGMENT}
5171
- `;
5172
-
5173
- // src/objects/LightningFeeEstimateOutput.ts
5174
- var FRAGMENT14 = `
5175
- fragment LightningFeeEstimateOutputFragment on LightningFeeEstimateOutput {
5176
- __typename
5177
- lightning_fee_estimate_output_fee_estimate: fee_estimate {
5178
- __typename
5179
- currency_amount_original_value: original_value
5180
- currency_amount_original_unit: original_unit
5181
- currency_amount_preferred_currency_unit: preferred_currency_unit
5182
- currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
5183
- currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
5184
- }
5185
- }`;
5186
-
5187
- // src/graphql/LightningFeeEstimateForInvoice.ts
5188
- var LightningFeeEstimateForInvoice = `
5189
- query LightningFeeEstimateForInvoice(
5190
- $node_id: ID!
5191
- $encoded_payment_request: String!
5192
- $amount_msats: Long
5193
- ) {
5194
- lightning_fee_estimate_for_invoice(input: {
5195
- node_id: $node_id,
5196
- encoded_payment_request: $encoded_payment_request,
5197
- amount_msats: $amount_msats
5198
- }) {
5199
- ...LightningFeeEstimateOutputFragment
5200
- }
5201
- }
5202
-
5203
- ${FRAGMENT14}
5204
- `;
5205
-
5206
- // src/graphql/LightningFeeEstimateForNode.ts
5207
- var LightningFeeEstimateForNode = `
5208
- query LightningFeeEstimateForNode(
5209
- $node_id: ID!
5210
- $destination_node_public_key: String!
5211
- $amount_msats: Long!
5212
- ) {
5213
- lightning_fee_estimate_for_node(input: {
5214
- node_id: $node_id,
5215
- destination_node_public_key: $destination_node_public_key,
5216
- amount_msats: $amount_msats
5217
- }) {
5218
- ...LightningFeeEstimateOutputFragment
5219
- }
5220
- }
5221
-
5222
- ${FRAGMENT14}
5223
- `;
5224
-
5225
- // src/graphql/MultiNodeDashboard.ts
5226
- var MultiNodeDashboard = `
5227
- query MultiNodeDashboard(
5228
- $network: BitcoinNetwork!,
5229
- $nodeIds: [ID!]
5230
- ) {
5231
- current_account {
5232
- id
5233
- name
5234
- dashboard_overview_nodes: nodes(
5235
- bitcoin_networks: [$network]
5236
- node_ids: $nodeIds
5237
- ) {
5238
- count
5239
- entities {
5240
- color
5241
- display_name
5242
- id
5243
- addresses(first: 1) {
5244
- entities {
5245
- address
5246
- type
5247
- __typename
5248
- }
5249
- count
5250
- __typename
5251
- }
5252
- public_key
5253
- status
5254
- local_balance {
5255
- ...CurrencyAmountFragment
5256
- }
5257
- remote_balance {
5258
- ...CurrencyAmountFragment
5259
- }
5260
- blockchain_balance {
5261
- available_balance {
5262
- ...CurrencyAmountFragment
5263
- }
5264
- total_balance {
5265
- ...CurrencyAmountFragment
5266
- }
5267
- __typename
5268
- }
5269
- __typename
5270
- }
5271
- __typename
5272
- }
5273
- blockchain_balance(bitcoin_networks: [$network], node_ids: $nodeIds) {
5274
- l1_balance: total_balance {
5275
- ...CurrencyAmountFragment
5276
- }
5277
- required_reserve {
5278
- ...CurrencyAmountFragment
5279
- }
5280
- available_balance {
5281
- ...CurrencyAmountFragment
5282
- }
5283
- unconfirmed_balance {
5284
- ...CurrencyAmountFragment
5512
+ currency_amount_preferred_currency_unit: preferred_currency_unit
5513
+ currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
5514
+ currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
5285
5515
  }
5286
- __typename
5287
- }
5288
- local_balance(bitcoin_networks: [$network], node_ids: $nodeIds) {
5289
- ...CurrencyAmountFragment
5290
- }
5291
- remote_balance(bitcoin_networks: [$network], node_ids: $nodeIds) {
5292
- ...CurrencyAmountFragment
5293
- }
5294
5516
  }
5295
- }
5296
-
5297
- ${FRAGMENT}
5298
- `;
5517
+ }`;
5518
+ var OutgoingPayment_default = OutgoingPayment;
5299
5519
 
5300
5520
  // src/graphql/PayInvoice.ts
5301
5521
  var PayInvoice = `
@@ -5321,7 +5541,7 @@ var PayInvoice = `
5321
5541
  }
5322
5542
  }
5323
5543
 
5324
- ${FRAGMENT13}
5544
+ ${FRAGMENT16}
5325
5545
  `;
5326
5546
 
5327
5547
  // src/graphql/PayUmaInvoice.ts
@@ -5348,11 +5568,11 @@ var PayUmaInvoice = `
5348
5568
  }
5349
5569
  }
5350
5570
 
5351
- ${FRAGMENT13}
5571
+ ${FRAGMENT16}
5352
5572
  `;
5353
5573
 
5354
5574
  // src/objects/WithdrawalRequest.ts
5355
- var import_auto_bind9 = __toESM(require("auto-bind"), 1);
5575
+ var import_auto_bind10 = __toESM(require("auto-bind"), 1);
5356
5576
 
5357
5577
  // src/objects/WithdrawalMode.ts
5358
5578
  var WithdrawalMode = /* @__PURE__ */ ((WithdrawalMode2) => {
@@ -5392,7 +5612,7 @@ var ChannelClosingTransactionFromJson = (obj) => {
5392
5612
  channelId: obj["channel_closing_transaction_channel"]?.id ?? void 0
5393
5613
  };
5394
5614
  };
5395
- var FRAGMENT15 = `
5615
+ var FRAGMENT17 = `
5396
5616
  fragment ChannelClosingTransactionFragment on ChannelClosingTransaction {
5397
5617
  __typename
5398
5618
  channel_closing_transaction_id: id
@@ -5436,7 +5656,7 @@ query GetChannelClosingTransaction($id: ID!) {
5436
5656
  }
5437
5657
  }
5438
5658
 
5439
- ${FRAGMENT15}
5659
+ ${FRAGMENT17}
5440
5660
  `,
5441
5661
  variables: { id },
5442
5662
  constructObject: (data) => ChannelClosingTransactionFromJson(data.entity)
@@ -5473,7 +5693,7 @@ var ChannelOpeningTransactionFromJson = (obj) => {
5473
5693
  channelId: obj["channel_opening_transaction_channel"]?.id ?? void 0
5474
5694
  };
5475
5695
  };
5476
- var FRAGMENT16 = `
5696
+ var FRAGMENT18 = `
5477
5697
  fragment ChannelOpeningTransactionFragment on ChannelOpeningTransaction {
5478
5698
  __typename
5479
5699
  channel_opening_transaction_id: id
@@ -5517,7 +5737,7 @@ query GetChannelOpeningTransaction($id: ID!) {
5517
5737
  }
5518
5738
  }
5519
5739
 
5520
- ${FRAGMENT16}
5740
+ ${FRAGMENT18}
5521
5741
  `,
5522
5742
  variables: { id },
5523
5743
  constructObject: (data) => ChannelOpeningTransactionFromJson(data.entity)
@@ -5549,7 +5769,7 @@ var WithdrawalRequest = class {
5549
5769
  this.estimatedAmount = estimatedAmount;
5550
5770
  this.completedAt = completedAt;
5551
5771
  this.withdrawalId = withdrawalId;
5552
- (0, import_auto_bind9.default)(this);
5772
+ (0, import_auto_bind10.default)(this);
5553
5773
  }
5554
5774
  async getChannelClosingTransactions(client, first = void 0) {
5555
5775
  return await client.executeRawQuery({
@@ -5686,7 +5906,7 @@ query GetWithdrawalRequest($id: ID!) {
5686
5906
  }
5687
5907
  }
5688
5908
 
5689
- ${FRAGMENT17}
5909
+ ${FRAGMENT19}
5690
5910
  `,
5691
5911
  variables: { id },
5692
5912
  constructObject: (data) => WithdrawalRequestFromJson(data.entity)
@@ -5708,7 +5928,7 @@ var WithdrawalRequestFromJson = (obj) => {
5708
5928
  obj["withdrawal_request_withdrawal"]?.id ?? void 0
5709
5929
  );
5710
5930
  };
5711
- var FRAGMENT17 = `
5931
+ var FRAGMENT19 = `
5712
5932
  fragment WithdrawalRequestFragment on WithdrawalRequest {
5713
5933
  __typename
5714
5934
  withdrawal_request_id: id
@@ -5760,7 +5980,7 @@ var RequestWithdrawal = `
5760
5980
  }
5761
5981
  }
5762
5982
 
5763
- ${FRAGMENT17}
5983
+ ${FRAGMENT19}
5764
5984
  `;
5765
5985
 
5766
5986
  // src/graphql/SendPayment.ts
@@ -5787,232 +6007,12 @@ var SendPayment = `
5787
6007
  }
5788
6008
  }
5789
6009
 
5790
- ${FRAGMENT13}
6010
+ ${FRAGMENT16}
5791
6011
  `;
5792
6012
 
5793
6013
  // src/objects/Transaction.ts
5794
6014
  var import_core4 = require("@lightsparkdev/core");
5795
6015
 
5796
- // src/objects/IncomingPayment.ts
5797
- var import_auto_bind10 = __toESM(require("auto-bind"), 1);
5798
-
5799
- // src/objects/IncomingPaymentAttemptStatus.ts
5800
- var IncomingPaymentAttemptStatus = /* @__PURE__ */ ((IncomingPaymentAttemptStatus2) => {
5801
- IncomingPaymentAttemptStatus2["FUTURE_VALUE"] = "FUTURE_VALUE";
5802
- IncomingPaymentAttemptStatus2["ACCEPTED"] = "ACCEPTED";
5803
- IncomingPaymentAttemptStatus2["SETTLED"] = "SETTLED";
5804
- IncomingPaymentAttemptStatus2["CANCELED"] = "CANCELED";
5805
- IncomingPaymentAttemptStatus2["UNKNOWN"] = "UNKNOWN";
5806
- return IncomingPaymentAttemptStatus2;
5807
- })(IncomingPaymentAttemptStatus || {});
5808
- var IncomingPaymentAttemptStatus_default = IncomingPaymentAttemptStatus;
5809
-
5810
- // src/objects/IncomingPaymentAttempt.ts
5811
- var IncomingPaymentAttemptFromJson = (obj) => {
5812
- return {
5813
- id: obj["incoming_payment_attempt_id"],
5814
- createdAt: obj["incoming_payment_attempt_created_at"],
5815
- updatedAt: obj["incoming_payment_attempt_updated_at"],
5816
- status: IncomingPaymentAttemptStatus_default[obj["incoming_payment_attempt_status"]] ?? IncomingPaymentAttemptStatus_default.FUTURE_VALUE,
5817
- amount: CurrencyAmountFromJson(obj["incoming_payment_attempt_amount"]),
5818
- channelId: obj["incoming_payment_attempt_channel"].id,
5819
- typename: "IncomingPaymentAttempt",
5820
- resolvedAt: obj["incoming_payment_attempt_resolved_at"]
5821
- };
5822
- };
5823
- var FRAGMENT18 = `
5824
- fragment IncomingPaymentAttemptFragment on IncomingPaymentAttempt {
5825
- __typename
5826
- incoming_payment_attempt_id: id
5827
- incoming_payment_attempt_created_at: created_at
5828
- incoming_payment_attempt_updated_at: updated_at
5829
- incoming_payment_attempt_status: status
5830
- incoming_payment_attempt_resolved_at: resolved_at
5831
- incoming_payment_attempt_amount: amount {
5832
- __typename
5833
- currency_amount_original_value: original_value
5834
- currency_amount_original_unit: original_unit
5835
- currency_amount_preferred_currency_unit: preferred_currency_unit
5836
- currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
5837
- currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
5838
- }
5839
- incoming_payment_attempt_channel: channel {
5840
- id
5841
- }
5842
- }`;
5843
- var getIncomingPaymentAttemptQuery = (id) => {
5844
- return {
5845
- queryPayload: `
5846
- query GetIncomingPaymentAttempt($id: ID!) {
5847
- entity(id: $id) {
5848
- ... on IncomingPaymentAttempt {
5849
- ...IncomingPaymentAttemptFragment
5850
- }
5851
- }
5852
- }
5853
-
5854
- ${FRAGMENT18}
5855
- `,
5856
- variables: { id },
5857
- constructObject: (data) => IncomingPaymentAttemptFromJson(data.entity)
5858
- };
5859
- };
5860
-
5861
- // src/objects/IncomingPaymentToAttemptsConnection.ts
5862
- var IncomingPaymentToAttemptsConnectionFromJson = (obj) => {
5863
- return {
5864
- count: obj["incoming_payment_to_attempts_connection_count"],
5865
- pageInfo: PageInfoFromJson(
5866
- obj["incoming_payment_to_attempts_connection_page_info"]
5867
- ),
5868
- entities: obj["incoming_payment_to_attempts_connection_entities"].map(
5869
- (e) => IncomingPaymentAttemptFromJson(e)
5870
- ),
5871
- typename: "IncomingPaymentToAttemptsConnection"
5872
- };
5873
- };
5874
-
5875
- // src/objects/IncomingPayment.ts
5876
- var IncomingPayment = class {
5877
- constructor(id, createdAt, updatedAt, status, amount, destinationId, typename, resolvedAt, transactionHash, paymentRequestId, umaPostTransactionData) {
5878
- this.id = id;
5879
- this.createdAt = createdAt;
5880
- this.updatedAt = updatedAt;
5881
- this.status = status;
5882
- this.amount = amount;
5883
- this.destinationId = destinationId;
5884
- this.typename = typename;
5885
- this.resolvedAt = resolvedAt;
5886
- this.transactionHash = transactionHash;
5887
- this.paymentRequestId = paymentRequestId;
5888
- this.umaPostTransactionData = umaPostTransactionData;
5889
- (0, import_auto_bind10.default)(this);
5890
- }
5891
- async getAttempts(client, first = void 0, statuses = void 0, after = void 0) {
5892
- return await client.executeRawQuery({
5893
- queryPayload: `
5894
- query FetchIncomingPaymentToAttemptsConnection($entity_id: ID!, $first: Int, $statuses: [IncomingPaymentAttemptStatus!], $after: String) {
5895
- entity(id: $entity_id) {
5896
- ... on IncomingPayment {
5897
- attempts(, first: $first, statuses: $statuses, after: $after) {
5898
- __typename
5899
- incoming_payment_to_attempts_connection_count: count
5900
- incoming_payment_to_attempts_connection_page_info: page_info {
5901
- __typename
5902
- page_info_has_next_page: has_next_page
5903
- page_info_has_previous_page: has_previous_page
5904
- page_info_start_cursor: start_cursor
5905
- page_info_end_cursor: end_cursor
5906
- }
5907
- incoming_payment_to_attempts_connection_entities: entities {
5908
- __typename
5909
- incoming_payment_attempt_id: id
5910
- incoming_payment_attempt_created_at: created_at
5911
- incoming_payment_attempt_updated_at: updated_at
5912
- incoming_payment_attempt_status: status
5913
- incoming_payment_attempt_resolved_at: resolved_at
5914
- incoming_payment_attempt_amount: amount {
5915
- __typename
5916
- currency_amount_original_value: original_value
5917
- currency_amount_original_unit: original_unit
5918
- currency_amount_preferred_currency_unit: preferred_currency_unit
5919
- currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
5920
- currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
5921
- }
5922
- incoming_payment_attempt_channel: channel {
5923
- id
5924
- }
5925
- }
5926
- }
5927
- }
5928
- }
5929
- }
5930
- `,
5931
- variables: {
5932
- entity_id: this.id,
5933
- first,
5934
- statuses,
5935
- after
5936
- },
5937
- constructObject: (json) => {
5938
- const connection = json["entity"]["attempts"];
5939
- return IncomingPaymentToAttemptsConnectionFromJson(connection);
5940
- }
5941
- });
5942
- }
5943
- static getIncomingPaymentQuery(id) {
5944
- return {
5945
- queryPayload: `
5946
- query GetIncomingPayment($id: ID!) {
5947
- entity(id: $id) {
5948
- ... on IncomingPayment {
5949
- ...IncomingPaymentFragment
5950
- }
5951
- }
5952
- }
5953
-
5954
- ${FRAGMENT19}
5955
- `,
5956
- variables: { id },
5957
- constructObject: (data) => IncomingPaymentFromJson(data.entity)
5958
- };
5959
- }
5960
- };
5961
- var IncomingPaymentFromJson = (obj) => {
5962
- return new IncomingPayment(
5963
- obj["incoming_payment_id"],
5964
- obj["incoming_payment_created_at"],
5965
- obj["incoming_payment_updated_at"],
5966
- TransactionStatus_default[obj["incoming_payment_status"]] ?? TransactionStatus_default.FUTURE_VALUE,
5967
- CurrencyAmountFromJson(obj["incoming_payment_amount"]),
5968
- obj["incoming_payment_destination"].id,
5969
- "IncomingPayment",
5970
- obj["incoming_payment_resolved_at"],
5971
- obj["incoming_payment_transaction_hash"],
5972
- obj["incoming_payment_payment_request"]?.id ?? void 0,
5973
- obj["incoming_payment_uma_post_transaction_data"]?.map(
5974
- (e) => PostTransactionDataFromJson(e)
5975
- )
5976
- );
5977
- };
5978
- var FRAGMENT19 = `
5979
- fragment IncomingPaymentFragment on IncomingPayment {
5980
- __typename
5981
- incoming_payment_id: id
5982
- incoming_payment_created_at: created_at
5983
- incoming_payment_updated_at: updated_at
5984
- incoming_payment_status: status
5985
- incoming_payment_resolved_at: resolved_at
5986
- incoming_payment_amount: amount {
5987
- __typename
5988
- currency_amount_original_value: original_value
5989
- currency_amount_original_unit: original_unit
5990
- currency_amount_preferred_currency_unit: preferred_currency_unit
5991
- currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
5992
- currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
5993
- }
5994
- incoming_payment_transaction_hash: transaction_hash
5995
- incoming_payment_destination: destination {
5996
- id
5997
- }
5998
- incoming_payment_payment_request: payment_request {
5999
- id
6000
- }
6001
- incoming_payment_uma_post_transaction_data: uma_post_transaction_data {
6002
- __typename
6003
- post_transaction_data_utxo: utxo
6004
- post_transaction_data_amount: amount {
6005
- __typename
6006
- currency_amount_original_value: original_value
6007
- currency_amount_original_unit: original_unit
6008
- currency_amount_preferred_currency_unit: preferred_currency_unit
6009
- currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded
6010
- currency_amount_preferred_currency_value_approx: preferred_currency_value_approx
6011
- }
6012
- }
6013
- }`;
6014
- var IncomingPayment_default = IncomingPayment;
6015
-
6016
6016
  // src/objects/RoutingTransactionFailureReason.ts
6017
6017
  var RoutingTransactionFailureReason = /* @__PURE__ */ ((RoutingTransactionFailureReason2) => {
6018
6018
  RoutingTransactionFailureReason2["FUTURE_VALUE"] = "FUTURE_VALUE";
@@ -11156,8 +11156,8 @@ var LightsparkClient = class {
11156
11156
  amount_msats: amountMsats
11157
11157
  },
11158
11158
  constructObject: (responseJson) => {
11159
- return OutgoingPaymentFromJson(
11160
- responseJson.create_test_mode_payment?.payment
11159
+ return IncomingPaymentFromJson(
11160
+ responseJson.create_test_mode_payment?.incoming_payment
11161
11161
  );
11162
11162
  }
11163
11163
  });