@buildonspark/spark-sdk 0.2.10 → 0.2.12
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/CHANGELOG.md +17 -1
- package/dist/bare/chunk-P6AVV7VD.js +34 -0
- package/dist/bare/index.cjs +729 -166
- package/dist/bare/index.d.cts +62 -5
- package/dist/bare/index.d.ts +62 -5
- package/dist/bare/index.js +675 -173
- package/dist/bare/{wasm-OPXXYRN5.js → wasm-F5QFVBNZ.js} +26 -0
- package/dist/bare/{xhr-transport-6GYJAFWU.js → xhr-transport-EEEC7FYA.js} +2 -2
- package/dist/{chunk-A5M55UR3.js → chunk-5VWGOHED.js} +499 -8
- package/dist/{chunk-MWBK6QBF.js → chunk-NQMQVXR5.js} +1 -1
- package/dist/chunk-NX5KPN5F.js +34 -0
- package/dist/{chunk-JXLWOQK5.js → chunk-OEK3R57K.js} +196 -162
- package/dist/{chunk-76SYPHOC.js → chunk-TB7DG5CU.js} +2 -2
- package/dist/{chunk-6CMNEDBK.js → chunk-XXTWWW6L.js} +1 -1
- package/dist/{client-Dd3QnxQu.d.ts → client-D7KDa4Ih.d.ts} +1 -1
- package/dist/{client-B9CAWKWz.d.cts → client-DVuA5-7M.d.cts} +1 -1
- package/dist/debug.cjs +725 -163
- package/dist/debug.d.cts +8 -5
- package/dist/debug.d.ts +8 -5
- package/dist/debug.js +5 -4
- package/dist/graphql/objects/index.d.cts +3 -3
- package/dist/graphql/objects/index.d.ts +3 -3
- package/dist/index.cjs +810 -246
- package/dist/index.d.cts +6 -6
- package/dist/index.d.ts +6 -6
- package/dist/index.js +11 -5
- package/dist/index.node.cjs +810 -246
- package/dist/index.node.d.cts +6 -6
- package/dist/index.node.d.ts +6 -6
- package/dist/index.node.js +10 -4
- package/dist/{xchain-address-BPwpnmuY.d.ts → logging-ClNhGzus.d.ts} +18 -4
- package/dist/{xchain-address-CNQEwLjR.d.cts → logging-D3kvES69.d.cts} +18 -4
- package/dist/native/chunk-D3SZRO65.js +36 -0
- package/dist/native/index.cjs +808 -244
- package/dist/native/index.d.cts +62 -5
- package/dist/native/index.d.ts +62 -5
- package/dist/native/index.js +769 -268
- package/dist/native/{wasm-2KV6XFEP.js → wasm-3YAXKQ7F.js} +25 -0
- package/dist/native/{xhr-transport-WHMS3FGG.js → xhr-transport-TNCG4HTW.js} +2 -2
- package/dist/proto/spark.cjs +499 -8
- package/dist/proto/spark.d.cts +1 -1
- package/dist/proto/spark.d.ts +1 -1
- package/dist/proto/spark.js +17 -1
- package/dist/proto/spark_token.d.cts +1 -1
- package/dist/proto/spark_token.d.ts +1 -1
- package/dist/proto/spark_token.js +2 -2
- package/dist/{spark-CtGJPkx4.d.cts → spark-C7OG9mGJ.d.cts} +79 -2
- package/dist/{spark-CtGJPkx4.d.ts → spark-C7OG9mGJ.d.ts} +79 -2
- package/dist/{spark-wallet-yc2KhsVY.d.cts → spark-wallet-Dg5IRQe2.d.cts} +3 -5
- package/dist/{spark-wallet-Cp3yv6cK.d.ts → spark-wallet-DiHSU-pz.d.ts} +3 -5
- package/dist/{spark-wallet.node-D4IovOHu.d.ts → spark-wallet.node-BZrxwomN.d.ts} +1 -1
- package/dist/{spark-wallet.node-D0Qw5Wb4.d.cts → spark-wallet.node-DSWb18zh.d.cts} +1 -1
- package/dist/spark_bindings/wasm/index.cjs +51 -0
- package/dist/spark_bindings/wasm/index.js +25 -0
- package/dist/tests/test-utils.cjs +725 -155
- package/dist/tests/test-utils.d.cts +4 -4
- package/dist/tests/test-utils.d.ts +4 -4
- package/dist/tests/test-utils.js +6 -5
- package/dist/{token-transactions-CwhlOgIP.d.cts → token-transactions-B-WqFYpW.d.cts} +2 -2
- package/dist/{token-transactions-0nmR9mQO.d.ts → token-transactions-DovxHIxV.d.ts} +2 -2
- package/dist/types/index.cjs +492 -9
- package/dist/types/index.d.cts +2 -2
- package/dist/types/index.d.ts +2 -2
- package/dist/types/index.js +2 -2
- package/dist/{xhr-transport-RH6LDRXS.js → xhr-transport-IWJPYF7F.js} +2 -2
- package/package.json +1 -1
- package/src/proto/common.ts +1 -1
- package/src/proto/google/protobuf/descriptor.ts +4 -10
- package/src/proto/google/protobuf/duration.ts +1 -1
- package/src/proto/google/protobuf/empty.ts +1 -1
- package/src/proto/google/protobuf/timestamp.ts +1 -1
- package/src/proto/mock.ts +1 -1
- package/src/proto/spark.ts +593 -3
- package/src/proto/spark_authn.ts +1 -1
- package/src/proto/spark_token.ts +1 -1
- package/src/proto/validate/validate.ts +27 -79
- package/src/services/deposit.ts +60 -4
- package/src/services/lightning.ts +2 -2
- package/src/services/signing.ts +1 -1
- package/src/services/token-transactions.ts +2 -5
- package/src/services/transfer.ts +2 -2
- package/src/services/xhr-transport.ts +2 -2
- package/src/signer/signer.ts +2 -2
- package/src/spark-wallet/spark-wallet.ts +25 -33
- package/src/spark_bindings/wasm/index.ts +21 -0
- package/src/tests/address.test.ts +10 -10
- package/src/tests/bitcoin.test.ts +2 -2
- package/src/tests/integration/coop-exit.test.ts +1 -1
- package/src/tests/integration/lightning.test.ts +1 -1
- package/src/tests/integration/ssp/coop-exit-validation.test.ts +2 -2
- package/src/tests/integration/ssp/static_deposit.test.ts +122 -33
- package/src/tests/integration/swap.test.ts +1 -1
- package/src/tests/integration/transfer.test.ts +1 -5
- package/src/tests/integration/wallet.test.ts +7 -7
- package/src/tests/integration/watchtower.test.ts +3 -3
- package/src/tests/token-hashing.test.ts +3 -6
- package/src/tests/token-outputs.test.ts +3 -3
- package/src/tests/utils/test-faucet.ts +2 -2
- package/src/types/sdk-types.ts +1 -1
- package/src/utils/adaptor-signature.ts +12 -13
- package/src/utils/address.ts +10 -10
- package/src/utils/bitcoin.ts +7 -11
- package/src/utils/index.ts +1 -0
- package/src/utils/keys.ts +10 -10
- package/src/utils/logging.ts +40 -0
- package/src/utils/secret-sharing.ts +10 -12
- package/src/utils/token-transactions.ts +1 -2
- package/src/utils/transfer_package.ts +1 -1
- package/src/utils/unilateral-exit.ts +1 -1
|
@@ -2,10 +2,10 @@ import {
|
|
|
2
2
|
Network,
|
|
3
3
|
TransferStatus,
|
|
4
4
|
TransferType
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-5VWGOHED.js";
|
|
6
6
|
|
|
7
7
|
// src/types/sdk-types.ts
|
|
8
|
-
import { bytesToHex } from "@noble/curves/
|
|
8
|
+
import { bytesToHex } from "@noble/curves/utils";
|
|
9
9
|
function mapTreeNodeToWalletLeaf(proto) {
|
|
10
10
|
return {
|
|
11
11
|
id: proto.id,
|
|
@@ -2,7 +2,7 @@ import { Query } from '@lightsparkdev/core';
|
|
|
2
2
|
import { Transaction } from '@scure/btc-signer';
|
|
3
3
|
import { HDKey } from '@scure/bip32';
|
|
4
4
|
import { a as ISigningCommitment } from './types-B3hMoTYO.js';
|
|
5
|
-
import { S as SigningKeyshare, N as Network, g as TransferStatus, h as TransferType, b as TreeNode, i as TransferLeaf, a as Transfer$1 } from './spark-
|
|
5
|
+
import { S as SigningKeyshare, N as Network, g as TransferStatus, h as TransferType, b as TreeNode, i as TransferLeaf, a as Transfer$1 } from './spark-C7OG9mGJ.js';
|
|
6
6
|
|
|
7
7
|
type Polynomial = {
|
|
8
8
|
fieldModulus: bigint;
|
|
@@ -2,7 +2,7 @@ import { Query } from '@lightsparkdev/core';
|
|
|
2
2
|
import { Transaction } from '@scure/btc-signer';
|
|
3
3
|
import { HDKey } from '@scure/bip32';
|
|
4
4
|
import { a as ISigningCommitment } from './types-B3hMoTYO.cjs';
|
|
5
|
-
import { S as SigningKeyshare, N as Network, g as TransferStatus, h as TransferType, b as TreeNode, i as TransferLeaf, a as Transfer$1 } from './spark-
|
|
5
|
+
import { S as SigningKeyshare, N as Network, g as TransferStatus, h as TransferType, b as TreeNode, i as TransferLeaf, a as Transfer$1 } from './spark-C7OG9mGJ.cjs';
|
|
6
6
|
|
|
7
7
|
type Polynomial = {
|
|
8
8
|
fieldModulus: bigint;
|