@breeztech/breez-sdk-spark-react-native 0.7.5 → 0.7.7
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/cpp/generated/breez_sdk_spark.cpp +231 -234
- package/cpp/generated/breez_sdk_spark.hpp +23 -22
- package/lib/commonjs/generated/breez_sdk_spark.js +76 -53
- package/lib/commonjs/generated/breez_sdk_spark.js.map +1 -1
- package/lib/module/generated/breez_sdk_spark.js +75 -52
- package/lib/module/generated/breez_sdk_spark.js.map +1 -1
- package/lib/typescript/commonjs/src/generated/breez_sdk_spark-ffi.d.ts +35 -35
- package/lib/typescript/commonjs/src/generated/breez_sdk_spark-ffi.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/generated/breez_sdk_spark.d.ts +133 -87
- package/lib/typescript/commonjs/src/generated/breez_sdk_spark.d.ts.map +1 -1
- package/lib/typescript/module/src/generated/breez_sdk_spark-ffi.d.ts +35 -35
- package/lib/typescript/module/src/generated/breez_sdk_spark-ffi.d.ts.map +1 -1
- package/lib/typescript/module/src/generated/breez_sdk_spark.d.ts +133 -87
- package/lib/typescript/module/src/generated/breez_sdk_spark.d.ts.map +1 -1
- package/package.json +3 -3
- package/src/generated/breez_sdk_spark-ffi.ts +37 -37
- package/src/generated/breez_sdk_spark.ts +248 -202
|
@@ -1361,7 +1361,7 @@ export type ExternalSignFrostRequest = {
|
|
|
1361
1361
|
/**
|
|
1362
1362
|
* The private key source
|
|
1363
1363
|
*/
|
|
1364
|
-
privateKey:
|
|
1364
|
+
privateKey: ExternalSecretKeySource;
|
|
1365
1365
|
/**
|
|
1366
1366
|
* The verifying key (33 bytes compressed)
|
|
1367
1367
|
*/
|
|
@@ -4923,20 +4923,20 @@ export declare const DepositClaimError: Readonly<{
|
|
|
4923
4923
|
};
|
|
4924
4924
|
}>;
|
|
4925
4925
|
export type DepositClaimError = InstanceType<(typeof DepositClaimError)[keyof Omit<typeof DepositClaimError, 'instanceOf'>]>;
|
|
4926
|
-
export declare enum
|
|
4926
|
+
export declare enum ExternalSecretKeySource_Tags {
|
|
4927
4927
|
Derived = "Derived",
|
|
4928
4928
|
Encrypted = "Encrypted"
|
|
4929
4929
|
}
|
|
4930
4930
|
/**
|
|
4931
|
-
* FFI-safe representation of `spark_wallet::
|
|
4931
|
+
* FFI-safe representation of `spark_wallet::SecretKeySource`
|
|
4932
4932
|
*/
|
|
4933
|
-
export declare const
|
|
4934
|
-
instanceOf: (obj: any) => obj is
|
|
4933
|
+
export declare const ExternalSecretKeySource: Readonly<{
|
|
4934
|
+
instanceOf: (obj: any) => obj is ExternalSecretKeySource;
|
|
4935
4935
|
Derived: {
|
|
4936
4936
|
new (inner: {
|
|
4937
4937
|
nodeId: ExternalTreeNodeId;
|
|
4938
4938
|
}): {
|
|
4939
|
-
readonly tag:
|
|
4939
|
+
readonly tag: ExternalSecretKeySource_Tags.Derived;
|
|
4940
4940
|
readonly inner: Readonly<{
|
|
4941
4941
|
nodeId: ExternalTreeNodeId;
|
|
4942
4942
|
}>;
|
|
@@ -4944,12 +4944,12 @@ export declare const ExternalPrivateKeySource: Readonly<{
|
|
|
4944
4944
|
* @private
|
|
4945
4945
|
* This field is private and should not be used, use `tag` instead.
|
|
4946
4946
|
*/
|
|
4947
|
-
readonly [uniffiTypeNameSymbol]: "
|
|
4947
|
+
readonly [uniffiTypeNameSymbol]: "ExternalSecretKeySource";
|
|
4948
4948
|
};
|
|
4949
4949
|
"new"(inner: {
|
|
4950
4950
|
nodeId: ExternalTreeNodeId;
|
|
4951
4951
|
}): {
|
|
4952
|
-
readonly tag:
|
|
4952
|
+
readonly tag: ExternalSecretKeySource_Tags.Derived;
|
|
4953
4953
|
readonly inner: Readonly<{
|
|
4954
4954
|
nodeId: ExternalTreeNodeId;
|
|
4955
4955
|
}>;
|
|
@@ -4957,10 +4957,10 @@ export declare const ExternalPrivateKeySource: Readonly<{
|
|
|
4957
4957
|
* @private
|
|
4958
4958
|
* This field is private and should not be used, use `tag` instead.
|
|
4959
4959
|
*/
|
|
4960
|
-
readonly [uniffiTypeNameSymbol]: "
|
|
4960
|
+
readonly [uniffiTypeNameSymbol]: "ExternalSecretKeySource";
|
|
4961
4961
|
};
|
|
4962
4962
|
instanceOf(obj: any): obj is {
|
|
4963
|
-
readonly tag:
|
|
4963
|
+
readonly tag: ExternalSecretKeySource_Tags.Derived;
|
|
4964
4964
|
readonly inner: Readonly<{
|
|
4965
4965
|
nodeId: ExternalTreeNodeId;
|
|
4966
4966
|
}>;
|
|
@@ -4968,14 +4968,14 @@ export declare const ExternalPrivateKeySource: Readonly<{
|
|
|
4968
4968
|
* @private
|
|
4969
4969
|
* This field is private and should not be used, use `tag` instead.
|
|
4970
4970
|
*/
|
|
4971
|
-
readonly [uniffiTypeNameSymbol]: "
|
|
4971
|
+
readonly [uniffiTypeNameSymbol]: "ExternalSecretKeySource";
|
|
4972
4972
|
};
|
|
4973
4973
|
};
|
|
4974
4974
|
Encrypted: {
|
|
4975
4975
|
new (inner: {
|
|
4976
4976
|
key: ExternalEncryptedPrivateKey;
|
|
4977
4977
|
}): {
|
|
4978
|
-
readonly tag:
|
|
4978
|
+
readonly tag: ExternalSecretKeySource_Tags.Encrypted;
|
|
4979
4979
|
readonly inner: Readonly<{
|
|
4980
4980
|
key: ExternalEncryptedPrivateKey;
|
|
4981
4981
|
}>;
|
|
@@ -4983,12 +4983,12 @@ export declare const ExternalPrivateKeySource: Readonly<{
|
|
|
4983
4983
|
* @private
|
|
4984
4984
|
* This field is private and should not be used, use `tag` instead.
|
|
4985
4985
|
*/
|
|
4986
|
-
readonly [uniffiTypeNameSymbol]: "
|
|
4986
|
+
readonly [uniffiTypeNameSymbol]: "ExternalSecretKeySource";
|
|
4987
4987
|
};
|
|
4988
4988
|
"new"(inner: {
|
|
4989
4989
|
key: ExternalEncryptedPrivateKey;
|
|
4990
4990
|
}): {
|
|
4991
|
-
readonly tag:
|
|
4991
|
+
readonly tag: ExternalSecretKeySource_Tags.Encrypted;
|
|
4992
4992
|
readonly inner: Readonly<{
|
|
4993
4993
|
key: ExternalEncryptedPrivateKey;
|
|
4994
4994
|
}>;
|
|
@@ -4996,10 +4996,10 @@ export declare const ExternalPrivateKeySource: Readonly<{
|
|
|
4996
4996
|
* @private
|
|
4997
4997
|
* This field is private and should not be used, use `tag` instead.
|
|
4998
4998
|
*/
|
|
4999
|
-
readonly [uniffiTypeNameSymbol]: "
|
|
4999
|
+
readonly [uniffiTypeNameSymbol]: "ExternalSecretKeySource";
|
|
5000
5000
|
};
|
|
5001
5001
|
instanceOf(obj: any): obj is {
|
|
5002
|
-
readonly tag:
|
|
5002
|
+
readonly tag: ExternalSecretKeySource_Tags.Encrypted;
|
|
5003
5003
|
readonly inner: Readonly<{
|
|
5004
5004
|
key: ExternalEncryptedPrivateKey;
|
|
5005
5005
|
}>;
|
|
@@ -5007,14 +5007,14 @@ export declare const ExternalPrivateKeySource: Readonly<{
|
|
|
5007
5007
|
* @private
|
|
5008
5008
|
* This field is private and should not be used, use `tag` instead.
|
|
5009
5009
|
*/
|
|
5010
|
-
readonly [uniffiTypeNameSymbol]: "
|
|
5010
|
+
readonly [uniffiTypeNameSymbol]: "ExternalSecretKeySource";
|
|
5011
5011
|
};
|
|
5012
5012
|
};
|
|
5013
5013
|
}>;
|
|
5014
5014
|
/**
|
|
5015
|
-
* FFI-safe representation of `spark_wallet::
|
|
5015
|
+
* FFI-safe representation of `spark_wallet::SecretKeySource`
|
|
5016
5016
|
*/
|
|
5017
|
-
export type
|
|
5017
|
+
export type ExternalSecretKeySource = InstanceType<(typeof ExternalSecretKeySource)[keyof Omit<typeof ExternalSecretKeySource, 'instanceOf'>]>;
|
|
5018
5018
|
export declare enum ExternalSecretToSplit_Tags {
|
|
5019
5019
|
PrivateKey = "PrivateKey",
|
|
5020
5020
|
Preimage = "Preimage"
|
|
@@ -5026,11 +5026,11 @@ export declare const ExternalSecretToSplit: Readonly<{
|
|
|
5026
5026
|
instanceOf: (obj: any) => obj is ExternalSecretToSplit;
|
|
5027
5027
|
PrivateKey: {
|
|
5028
5028
|
new (inner: {
|
|
5029
|
-
source:
|
|
5029
|
+
source: ExternalSecretKeySource;
|
|
5030
5030
|
}): {
|
|
5031
5031
|
readonly tag: ExternalSecretToSplit_Tags.PrivateKey;
|
|
5032
5032
|
readonly inner: Readonly<{
|
|
5033
|
-
source:
|
|
5033
|
+
source: ExternalSecretKeySource;
|
|
5034
5034
|
}>;
|
|
5035
5035
|
/**
|
|
5036
5036
|
* @private
|
|
@@ -5039,11 +5039,11 @@ export declare const ExternalSecretToSplit: Readonly<{
|
|
|
5039
5039
|
readonly [uniffiTypeNameSymbol]: "ExternalSecretToSplit";
|
|
5040
5040
|
};
|
|
5041
5041
|
"new"(inner: {
|
|
5042
|
-
source:
|
|
5042
|
+
source: ExternalSecretKeySource;
|
|
5043
5043
|
}): {
|
|
5044
5044
|
readonly tag: ExternalSecretToSplit_Tags.PrivateKey;
|
|
5045
5045
|
readonly inner: Readonly<{
|
|
5046
|
-
source:
|
|
5046
|
+
source: ExternalSecretKeySource;
|
|
5047
5047
|
}>;
|
|
5048
5048
|
/**
|
|
5049
5049
|
* @private
|
|
@@ -5054,7 +5054,7 @@ export declare const ExternalSecretToSplit: Readonly<{
|
|
|
5054
5054
|
instanceOf(obj: any): obj is {
|
|
5055
5055
|
readonly tag: ExternalSecretToSplit_Tags.PrivateKey;
|
|
5056
5056
|
readonly inner: Readonly<{
|
|
5057
|
-
source:
|
|
5057
|
+
source: ExternalSecretKeySource;
|
|
5058
5058
|
}>;
|
|
5059
5059
|
/**
|
|
5060
5060
|
* @private
|
|
@@ -11503,6 +11503,8 @@ export declare class BreezSdk extends UniffiAbstractObject implements BreezSdkIn
|
|
|
11503
11503
|
export interface ExternalSigner {
|
|
11504
11504
|
/**
|
|
11505
11505
|
* Returns the identity public key as 33 bytes (compressed secp256k1 key).
|
|
11506
|
+
*
|
|
11507
|
+
* See also: [JavaScript `getIdentityPublicKey`](https://docs.spark.money/wallets/spark-signer#get-identity-public-key)
|
|
11506
11508
|
*/
|
|
11507
11509
|
identityPublicKey(): PublicKeyBytes;
|
|
11508
11510
|
/**
|
|
@@ -11513,6 +11515,8 @@ export interface ExternalSigner {
|
|
|
11513
11515
|
*
|
|
11514
11516
|
* # Returns
|
|
11515
11517
|
* The derived public key as 33 bytes, or a `SignerError`
|
|
11518
|
+
*
|
|
11519
|
+
* See also: [JavaScript `getPublicKeyFromDerivation`](https://docs.spark.money/wallets/spark-signer#get-public-key-from-derivation)
|
|
11516
11520
|
*/
|
|
11517
11521
|
derivePublicKey(path: string, asyncOpts_?: {
|
|
11518
11522
|
signal: AbortSignal;
|
|
@@ -11557,7 +11561,7 @@ export interface ExternalSigner {
|
|
|
11557
11561
|
* # Returns
|
|
11558
11562
|
* Encrypted data, or a `SignerError`
|
|
11559
11563
|
*/
|
|
11560
|
-
|
|
11564
|
+
encryptEcies(message: ArrayBuffer, path: string, asyncOpts_?: {
|
|
11561
11565
|
signal: AbortSignal;
|
|
11562
11566
|
}): Promise<ArrayBuffer>;
|
|
11563
11567
|
/**
|
|
@@ -11569,8 +11573,10 @@ export interface ExternalSigner {
|
|
|
11569
11573
|
*
|
|
11570
11574
|
* # Returns
|
|
11571
11575
|
* Decrypted data, or a `SignerError`
|
|
11576
|
+
*
|
|
11577
|
+
* See also: [JavaScript `decryptEcies`](https://docs.spark.money/wallets/spark-signer#decrypt-ecies)
|
|
11572
11578
|
*/
|
|
11573
|
-
|
|
11579
|
+
decryptEcies(message: ArrayBuffer, path: string, asyncOpts_?: {
|
|
11574
11580
|
signal: AbortSignal;
|
|
11575
11581
|
}): Promise<ArrayBuffer>;
|
|
11576
11582
|
/**
|
|
@@ -11595,6 +11601,8 @@ export interface ExternalSigner {
|
|
|
11595
11601
|
*
|
|
11596
11602
|
* # Returns
|
|
11597
11603
|
* 32-byte HMAC-SHA256, or a `SignerError`
|
|
11604
|
+
*
|
|
11605
|
+
* See also: [JavaScript `htlcHMAC`](https://docs.spark.money/wallets/spark-signer#generate-htlc-hmac)
|
|
11598
11606
|
*/
|
|
11599
11607
|
hmacSha256(message: ArrayBuffer, path: string, asyncOpts_?: {
|
|
11600
11608
|
signal: AbortSignal;
|
|
@@ -11604,8 +11612,10 @@ export interface ExternalSigner {
|
|
|
11604
11612
|
*
|
|
11605
11613
|
* # Returns
|
|
11606
11614
|
* Frost commitments with nonces, or a `SignerError`
|
|
11615
|
+
*
|
|
11616
|
+
* See also: [JavaScript `getRandomSigningCommitment`](https://docs.spark.money/wallets/spark-signer#get-random-signing-commitment)
|
|
11607
11617
|
*/
|
|
11608
|
-
|
|
11618
|
+
generateRandomSigningCommitment(asyncOpts_?: {
|
|
11609
11619
|
signal: AbortSignal;
|
|
11610
11620
|
}): Promise<ExternalFrostCommitments>;
|
|
11611
11621
|
/**
|
|
@@ -11621,36 +11631,38 @@ export interface ExternalSigner {
|
|
|
11621
11631
|
signal: AbortSignal;
|
|
11622
11632
|
}): Promise<PublicKeyBytes>;
|
|
11623
11633
|
/**
|
|
11624
|
-
* Generates a random
|
|
11634
|
+
* Generates a random secret key.
|
|
11625
11635
|
*
|
|
11626
11636
|
* # Returns
|
|
11627
|
-
* A randomly generated
|
|
11637
|
+
* A randomly generated secret key source, or an error string
|
|
11628
11638
|
*/
|
|
11629
11639
|
generateRandomKey(asyncOpts_?: {
|
|
11630
11640
|
signal: AbortSignal;
|
|
11631
|
-
}): Promise<
|
|
11641
|
+
}): Promise<ExternalSecretKeySource>;
|
|
11632
11642
|
/**
|
|
11633
|
-
* Gets
|
|
11643
|
+
* Gets an encrypted static deposit secret key by index.
|
|
11634
11644
|
*
|
|
11635
11645
|
* # Arguments
|
|
11636
11646
|
* * `index` - The index of the static deposit key
|
|
11637
11647
|
*
|
|
11638
11648
|
* # Returns
|
|
11639
|
-
* The
|
|
11649
|
+
* The encrypted secret key, or an error string
|
|
11640
11650
|
*/
|
|
11641
|
-
|
|
11651
|
+
staticDepositSecretKeyEncrypted(index: number, asyncOpts_?: {
|
|
11642
11652
|
signal: AbortSignal;
|
|
11643
|
-
}): Promise<
|
|
11653
|
+
}): Promise<ExternalSecretKeySource>;
|
|
11644
11654
|
/**
|
|
11645
|
-
* Gets a static deposit
|
|
11655
|
+
* Gets a static deposit secret key by index.
|
|
11646
11656
|
*
|
|
11647
11657
|
* # Arguments
|
|
11648
11658
|
* * `index` - The index of the static deposit key
|
|
11649
11659
|
*
|
|
11650
11660
|
* # Returns
|
|
11651
|
-
* The 32-byte
|
|
11661
|
+
* The 32-byte secret key, or an error string
|
|
11662
|
+
*
|
|
11663
|
+
* See also: [JavaScript `getStaticDepositSecretKey`](https://docs.spark.money/wallets/spark-signer#get-static-deposit-secret-key)
|
|
11652
11664
|
*/
|
|
11653
|
-
|
|
11665
|
+
staticDepositSecretKey(index: number, asyncOpts_?: {
|
|
11654
11666
|
signal: AbortSignal;
|
|
11655
11667
|
}): Promise<PrivateKeyBytes>;
|
|
11656
11668
|
/**
|
|
@@ -11661,23 +11673,28 @@ export interface ExternalSigner {
|
|
|
11661
11673
|
*
|
|
11662
11674
|
* # Returns
|
|
11663
11675
|
* The 33-byte public key, or an error string
|
|
11676
|
+
*
|
|
11677
|
+
* See also: [JavaScript `getStaticDepositSigningKey`](https://docs.spark.money/wallets/spark-signer#get-static-deposit-signing-key)
|
|
11664
11678
|
*/
|
|
11665
|
-
|
|
11679
|
+
staticDepositSigningKey(index: number, asyncOpts_?: {
|
|
11666
11680
|
signal: AbortSignal;
|
|
11667
11681
|
}): Promise<PublicKeyBytes>;
|
|
11668
11682
|
/**
|
|
11669
|
-
* Subtracts one
|
|
11683
|
+
* Subtracts one secret key from another.
|
|
11670
11684
|
*
|
|
11671
11685
|
* # Arguments
|
|
11672
|
-
* * `signing_key` - The first
|
|
11673
|
-
* * `new_signing_key` - The second
|
|
11686
|
+
* * `signing_key` - The first secret key source
|
|
11687
|
+
* * `new_signing_key` - The second secret key source to subtract
|
|
11674
11688
|
*
|
|
11675
11689
|
* # Returns
|
|
11676
|
-
* The resulting
|
|
11690
|
+
* The resulting secret key source, or an error string
|
|
11691
|
+
*
|
|
11692
|
+
* See also: [JavaScript `subtractSplitAndEncrypt`](https://docs.spark.money/wallets/spark-signer#subtract,-split,-and-encrypt)
|
|
11693
|
+
* (this method provides the subtraction step of that higher-level operation)
|
|
11677
11694
|
*/
|
|
11678
|
-
|
|
11695
|
+
subtractSecretKeys(signingKey: ExternalSecretKeySource, newSigningKey: ExternalSecretKeySource, asyncOpts_?: {
|
|
11679
11696
|
signal: AbortSignal;
|
|
11680
|
-
}): Promise<
|
|
11697
|
+
}): Promise<ExternalSecretKeySource>;
|
|
11681
11698
|
/**
|
|
11682
11699
|
* Splits a secret with proofs using Shamir's Secret Sharing.
|
|
11683
11700
|
*
|
|
@@ -11688,33 +11705,35 @@ export interface ExternalSigner {
|
|
|
11688
11705
|
*
|
|
11689
11706
|
* # Returns
|
|
11690
11707
|
* Vector of verifiable secret shares, or an error string
|
|
11708
|
+
*
|
|
11709
|
+
* See also: [JavaScript `splitSecretWithProofs`](https://docs.spark.money/wallets/spark-signer#split-secret-with-proofs)
|
|
11691
11710
|
*/
|
|
11692
|
-
|
|
11711
|
+
splitSecretWithProofs(secret: ExternalSecretToSplit, threshold: number, numShares: number, asyncOpts_?: {
|
|
11693
11712
|
signal: AbortSignal;
|
|
11694
11713
|
}): Promise<Array<ExternalVerifiableSecretShare>>;
|
|
11695
11714
|
/**
|
|
11696
|
-
* Encrypts a
|
|
11715
|
+
* Encrypts a secret key for a specific receiver's public key.
|
|
11697
11716
|
*
|
|
11698
11717
|
* # Arguments
|
|
11699
|
-
* * `
|
|
11718
|
+
* * `secret_key` - The encrypted secret key to re-encrypt
|
|
11700
11719
|
* * `receiver_public_key` - The receiver's 33-byte public key
|
|
11701
11720
|
*
|
|
11702
11721
|
* # Returns
|
|
11703
11722
|
* Encrypted data for the receiver, or an error string
|
|
11704
11723
|
*/
|
|
11705
|
-
|
|
11724
|
+
encryptSecretKeyForReceiver(secretKey: ExternalEncryptedPrivateKey, receiverPublicKey: PublicKeyBytes, asyncOpts_?: {
|
|
11706
11725
|
signal: AbortSignal;
|
|
11707
11726
|
}): Promise<ArrayBuffer>;
|
|
11708
11727
|
/**
|
|
11709
|
-
* Gets the public key from a
|
|
11728
|
+
* Gets the public key from a secret key source.
|
|
11710
11729
|
*
|
|
11711
11730
|
* # Arguments
|
|
11712
|
-
* * `
|
|
11731
|
+
* * `secret_key` - The secret key source
|
|
11713
11732
|
*
|
|
11714
11733
|
* # Returns
|
|
11715
11734
|
* The corresponding 33-byte public key, or an error string
|
|
11716
11735
|
*/
|
|
11717
|
-
|
|
11736
|
+
publicKeyFromSecretKeySource(secretKey: ExternalSecretKeySource, asyncOpts_?: {
|
|
11718
11737
|
signal: AbortSignal;
|
|
11719
11738
|
}): Promise<PublicKeyBytes>;
|
|
11720
11739
|
/**
|
|
@@ -11725,6 +11744,8 @@ export interface ExternalSigner {
|
|
|
11725
11744
|
*
|
|
11726
11745
|
* # Returns
|
|
11727
11746
|
* A signature share, or an error string
|
|
11747
|
+
*
|
|
11748
|
+
* See also: [JavaScript `signFrost`](https://docs.spark.money/wallets/spark-signer#frost-signing)
|
|
11728
11749
|
*/
|
|
11729
11750
|
signFrost(request: ExternalSignFrostRequest, asyncOpts_?: {
|
|
11730
11751
|
signal: AbortSignal;
|
|
@@ -11737,8 +11758,10 @@ export interface ExternalSigner {
|
|
|
11737
11758
|
*
|
|
11738
11759
|
* # Returns
|
|
11739
11760
|
* The aggregated Frost signature, or an error string
|
|
11761
|
+
*
|
|
11762
|
+
* See also: [JavaScript `aggregateFrost`](https://docs.spark.money/wallets/spark-signer#aggregate-frost-signatures)
|
|
11740
11763
|
*/
|
|
11741
|
-
|
|
11764
|
+
aggregateFrost(request: ExternalAggregateFrostRequest, asyncOpts_?: {
|
|
11742
11765
|
signal: AbortSignal;
|
|
11743
11766
|
}): Promise<ExternalFrostSignature>;
|
|
11744
11767
|
}
|
|
@@ -11762,6 +11785,8 @@ export declare class ExternalSignerImpl extends UniffiAbstractObject implements
|
|
|
11762
11785
|
private constructor();
|
|
11763
11786
|
/**
|
|
11764
11787
|
* Returns the identity public key as 33 bytes (compressed secp256k1 key).
|
|
11788
|
+
*
|
|
11789
|
+
* See also: [JavaScript `getIdentityPublicKey`](https://docs.spark.money/wallets/spark-signer#get-identity-public-key)
|
|
11765
11790
|
*/
|
|
11766
11791
|
identityPublicKey(): PublicKeyBytes;
|
|
11767
11792
|
/**
|
|
@@ -11772,6 +11797,8 @@ export declare class ExternalSignerImpl extends UniffiAbstractObject implements
|
|
|
11772
11797
|
*
|
|
11773
11798
|
* # Returns
|
|
11774
11799
|
* The derived public key as 33 bytes, or a `SignerError`
|
|
11800
|
+
*
|
|
11801
|
+
* See also: [JavaScript `getPublicKeyFromDerivation`](https://docs.spark.money/wallets/spark-signer#get-public-key-from-derivation)
|
|
11775
11802
|
*/
|
|
11776
11803
|
derivePublicKey(path: string, asyncOpts_?: {
|
|
11777
11804
|
signal: AbortSignal;
|
|
@@ -11816,7 +11843,7 @@ export declare class ExternalSignerImpl extends UniffiAbstractObject implements
|
|
|
11816
11843
|
* # Returns
|
|
11817
11844
|
* Encrypted data, or a `SignerError`
|
|
11818
11845
|
*/
|
|
11819
|
-
|
|
11846
|
+
encryptEcies(message: ArrayBuffer, path: string, asyncOpts_?: {
|
|
11820
11847
|
signal: AbortSignal;
|
|
11821
11848
|
}): Promise<ArrayBuffer>;
|
|
11822
11849
|
/**
|
|
@@ -11828,8 +11855,10 @@ export declare class ExternalSignerImpl extends UniffiAbstractObject implements
|
|
|
11828
11855
|
*
|
|
11829
11856
|
* # Returns
|
|
11830
11857
|
* Decrypted data, or a `SignerError`
|
|
11858
|
+
*
|
|
11859
|
+
* See also: [JavaScript `decryptEcies`](https://docs.spark.money/wallets/spark-signer#decrypt-ecies)
|
|
11831
11860
|
*/
|
|
11832
|
-
|
|
11861
|
+
decryptEcies(message: ArrayBuffer, path: string, asyncOpts_?: {
|
|
11833
11862
|
signal: AbortSignal;
|
|
11834
11863
|
}): Promise<ArrayBuffer>;
|
|
11835
11864
|
/**
|
|
@@ -11854,6 +11883,8 @@ export declare class ExternalSignerImpl extends UniffiAbstractObject implements
|
|
|
11854
11883
|
*
|
|
11855
11884
|
* # Returns
|
|
11856
11885
|
* 32-byte HMAC-SHA256, or a `SignerError`
|
|
11886
|
+
*
|
|
11887
|
+
* See also: [JavaScript `htlcHMAC`](https://docs.spark.money/wallets/spark-signer#generate-htlc-hmac)
|
|
11857
11888
|
*/
|
|
11858
11889
|
hmacSha256(message: ArrayBuffer, path: string, asyncOpts_?: {
|
|
11859
11890
|
signal: AbortSignal;
|
|
@@ -11863,8 +11894,10 @@ export declare class ExternalSignerImpl extends UniffiAbstractObject implements
|
|
|
11863
11894
|
*
|
|
11864
11895
|
* # Returns
|
|
11865
11896
|
* Frost commitments with nonces, or a `SignerError`
|
|
11897
|
+
*
|
|
11898
|
+
* See also: [JavaScript `getRandomSigningCommitment`](https://docs.spark.money/wallets/spark-signer#get-random-signing-commitment)
|
|
11866
11899
|
*/
|
|
11867
|
-
|
|
11900
|
+
generateRandomSigningCommitment(asyncOpts_?: {
|
|
11868
11901
|
signal: AbortSignal;
|
|
11869
11902
|
}): Promise<ExternalFrostCommitments>;
|
|
11870
11903
|
/**
|
|
@@ -11880,36 +11913,38 @@ export declare class ExternalSignerImpl extends UniffiAbstractObject implements
|
|
|
11880
11913
|
signal: AbortSignal;
|
|
11881
11914
|
}): Promise<PublicKeyBytes>;
|
|
11882
11915
|
/**
|
|
11883
|
-
* Generates a random
|
|
11916
|
+
* Generates a random secret key.
|
|
11884
11917
|
*
|
|
11885
11918
|
* # Returns
|
|
11886
|
-
* A randomly generated
|
|
11919
|
+
* A randomly generated secret key source, or an error string
|
|
11887
11920
|
*/
|
|
11888
11921
|
generateRandomKey(asyncOpts_?: {
|
|
11889
11922
|
signal: AbortSignal;
|
|
11890
|
-
}): Promise<
|
|
11923
|
+
}): Promise<ExternalSecretKeySource>;
|
|
11891
11924
|
/**
|
|
11892
|
-
* Gets
|
|
11925
|
+
* Gets an encrypted static deposit secret key by index.
|
|
11893
11926
|
*
|
|
11894
11927
|
* # Arguments
|
|
11895
11928
|
* * `index` - The index of the static deposit key
|
|
11896
11929
|
*
|
|
11897
11930
|
* # Returns
|
|
11898
|
-
* The
|
|
11931
|
+
* The encrypted secret key, or an error string
|
|
11899
11932
|
*/
|
|
11900
|
-
|
|
11933
|
+
staticDepositSecretKeyEncrypted(index: number, asyncOpts_?: {
|
|
11901
11934
|
signal: AbortSignal;
|
|
11902
|
-
}): Promise<
|
|
11935
|
+
}): Promise<ExternalSecretKeySource>;
|
|
11903
11936
|
/**
|
|
11904
|
-
* Gets a static deposit
|
|
11937
|
+
* Gets a static deposit secret key by index.
|
|
11905
11938
|
*
|
|
11906
11939
|
* # Arguments
|
|
11907
11940
|
* * `index` - The index of the static deposit key
|
|
11908
11941
|
*
|
|
11909
11942
|
* # Returns
|
|
11910
|
-
* The 32-byte
|
|
11943
|
+
* The 32-byte secret key, or an error string
|
|
11944
|
+
*
|
|
11945
|
+
* See also: [JavaScript `getStaticDepositSecretKey`](https://docs.spark.money/wallets/spark-signer#get-static-deposit-secret-key)
|
|
11911
11946
|
*/
|
|
11912
|
-
|
|
11947
|
+
staticDepositSecretKey(index: number, asyncOpts_?: {
|
|
11913
11948
|
signal: AbortSignal;
|
|
11914
11949
|
}): Promise<PrivateKeyBytes>;
|
|
11915
11950
|
/**
|
|
@@ -11920,23 +11955,28 @@ export declare class ExternalSignerImpl extends UniffiAbstractObject implements
|
|
|
11920
11955
|
*
|
|
11921
11956
|
* # Returns
|
|
11922
11957
|
* The 33-byte public key, or an error string
|
|
11958
|
+
*
|
|
11959
|
+
* See also: [JavaScript `getStaticDepositSigningKey`](https://docs.spark.money/wallets/spark-signer#get-static-deposit-signing-key)
|
|
11923
11960
|
*/
|
|
11924
|
-
|
|
11961
|
+
staticDepositSigningKey(index: number, asyncOpts_?: {
|
|
11925
11962
|
signal: AbortSignal;
|
|
11926
11963
|
}): Promise<PublicKeyBytes>;
|
|
11927
11964
|
/**
|
|
11928
|
-
* Subtracts one
|
|
11965
|
+
* Subtracts one secret key from another.
|
|
11929
11966
|
*
|
|
11930
11967
|
* # Arguments
|
|
11931
|
-
* * `signing_key` - The first
|
|
11932
|
-
* * `new_signing_key` - The second
|
|
11968
|
+
* * `signing_key` - The first secret key source
|
|
11969
|
+
* * `new_signing_key` - The second secret key source to subtract
|
|
11933
11970
|
*
|
|
11934
11971
|
* # Returns
|
|
11935
|
-
* The resulting
|
|
11972
|
+
* The resulting secret key source, or an error string
|
|
11973
|
+
*
|
|
11974
|
+
* See also: [JavaScript `subtractSplitAndEncrypt`](https://docs.spark.money/wallets/spark-signer#subtract,-split,-and-encrypt)
|
|
11975
|
+
* (this method provides the subtraction step of that higher-level operation)
|
|
11936
11976
|
*/
|
|
11937
|
-
|
|
11977
|
+
subtractSecretKeys(signingKey: ExternalSecretKeySource, newSigningKey: ExternalSecretKeySource, asyncOpts_?: {
|
|
11938
11978
|
signal: AbortSignal;
|
|
11939
|
-
}): Promise<
|
|
11979
|
+
}): Promise<ExternalSecretKeySource>;
|
|
11940
11980
|
/**
|
|
11941
11981
|
* Splits a secret with proofs using Shamir's Secret Sharing.
|
|
11942
11982
|
*
|
|
@@ -11947,33 +11987,35 @@ export declare class ExternalSignerImpl extends UniffiAbstractObject implements
|
|
|
11947
11987
|
*
|
|
11948
11988
|
* # Returns
|
|
11949
11989
|
* Vector of verifiable secret shares, or an error string
|
|
11990
|
+
*
|
|
11991
|
+
* See also: [JavaScript `splitSecretWithProofs`](https://docs.spark.money/wallets/spark-signer#split-secret-with-proofs)
|
|
11950
11992
|
*/
|
|
11951
|
-
|
|
11993
|
+
splitSecretWithProofs(secret: ExternalSecretToSplit, threshold: number, numShares: number, asyncOpts_?: {
|
|
11952
11994
|
signal: AbortSignal;
|
|
11953
11995
|
}): Promise<Array<ExternalVerifiableSecretShare>>;
|
|
11954
11996
|
/**
|
|
11955
|
-
* Encrypts a
|
|
11997
|
+
* Encrypts a secret key for a specific receiver's public key.
|
|
11956
11998
|
*
|
|
11957
11999
|
* # Arguments
|
|
11958
|
-
* * `
|
|
12000
|
+
* * `secret_key` - The encrypted secret key to re-encrypt
|
|
11959
12001
|
* * `receiver_public_key` - The receiver's 33-byte public key
|
|
11960
12002
|
*
|
|
11961
12003
|
* # Returns
|
|
11962
12004
|
* Encrypted data for the receiver, or an error string
|
|
11963
12005
|
*/
|
|
11964
|
-
|
|
12006
|
+
encryptSecretKeyForReceiver(secretKey: ExternalEncryptedPrivateKey, receiverPublicKey: PublicKeyBytes, asyncOpts_?: {
|
|
11965
12007
|
signal: AbortSignal;
|
|
11966
12008
|
}): Promise<ArrayBuffer>;
|
|
11967
12009
|
/**
|
|
11968
|
-
* Gets the public key from a
|
|
12010
|
+
* Gets the public key from a secret key source.
|
|
11969
12011
|
*
|
|
11970
12012
|
* # Arguments
|
|
11971
|
-
* * `
|
|
12013
|
+
* * `secret_key` - The secret key source
|
|
11972
12014
|
*
|
|
11973
12015
|
* # Returns
|
|
11974
12016
|
* The corresponding 33-byte public key, or an error string
|
|
11975
12017
|
*/
|
|
11976
|
-
|
|
12018
|
+
publicKeyFromSecretKeySource(secretKey: ExternalSecretKeySource, asyncOpts_?: {
|
|
11977
12019
|
signal: AbortSignal;
|
|
11978
12020
|
}): Promise<PublicKeyBytes>;
|
|
11979
12021
|
/**
|
|
@@ -11984,6 +12026,8 @@ export declare class ExternalSignerImpl extends UniffiAbstractObject implements
|
|
|
11984
12026
|
*
|
|
11985
12027
|
* # Returns
|
|
11986
12028
|
* A signature share, or an error string
|
|
12029
|
+
*
|
|
12030
|
+
* See also: [JavaScript `signFrost`](https://docs.spark.money/wallets/spark-signer#frost-signing)
|
|
11987
12031
|
*/
|
|
11988
12032
|
signFrost(request: ExternalSignFrostRequest, asyncOpts_?: {
|
|
11989
12033
|
signal: AbortSignal;
|
|
@@ -11996,8 +12040,10 @@ export declare class ExternalSignerImpl extends UniffiAbstractObject implements
|
|
|
11996
12040
|
*
|
|
11997
12041
|
* # Returns
|
|
11998
12042
|
* The aggregated Frost signature, or an error string
|
|
12043
|
+
*
|
|
12044
|
+
* See also: [JavaScript `aggregateFrost`](https://docs.spark.money/wallets/spark-signer#aggregate-frost-signatures)
|
|
11999
12045
|
*/
|
|
12000
|
-
|
|
12046
|
+
aggregateFrost(request: ExternalAggregateFrostRequest, asyncOpts_?: {
|
|
12001
12047
|
signal: AbortSignal;
|
|
12002
12048
|
}): Promise<ExternalFrostSignature>;
|
|
12003
12049
|
/**
|
|
@@ -13319,13 +13365,6 @@ declare const _default: Readonly<{
|
|
|
13319
13365
|
lift(value: UniffiByteArray): ExternalInputParser;
|
|
13320
13366
|
lower(value: ExternalInputParser): UniffiByteArray;
|
|
13321
13367
|
};
|
|
13322
|
-
FfiConverterTypeExternalPrivateKeySource: {
|
|
13323
|
-
read(from: RustBuffer): ExternalPrivateKeySource;
|
|
13324
|
-
write(value: ExternalPrivateKeySource, into: RustBuffer): void;
|
|
13325
|
-
allocationSize(value: ExternalPrivateKeySource): number;
|
|
13326
|
-
lift(value: UniffiByteArray): ExternalPrivateKeySource;
|
|
13327
|
-
lower(value: ExternalPrivateKeySource): UniffiByteArray;
|
|
13328
|
-
};
|
|
13329
13368
|
FfiConverterTypeExternalScalar: {
|
|
13330
13369
|
read(from: RustBuffer): ExternalScalar;
|
|
13331
13370
|
write(value: ExternalScalar, into: RustBuffer): void;
|
|
@@ -13333,6 +13372,13 @@ declare const _default: Readonly<{
|
|
|
13333
13372
|
lift(value: UniffiByteArray): ExternalScalar;
|
|
13334
13373
|
lower(value: ExternalScalar): UniffiByteArray;
|
|
13335
13374
|
};
|
|
13375
|
+
FfiConverterTypeExternalSecretKeySource: {
|
|
13376
|
+
read(from: RustBuffer): ExternalSecretKeySource;
|
|
13377
|
+
write(value: ExternalSecretKeySource, into: RustBuffer): void;
|
|
13378
|
+
allocationSize(value: ExternalSecretKeySource): number;
|
|
13379
|
+
lift(value: UniffiByteArray): ExternalSecretKeySource;
|
|
13380
|
+
lower(value: ExternalSecretKeySource): UniffiByteArray;
|
|
13381
|
+
};
|
|
13336
13382
|
FfiConverterTypeExternalSecretShare: {
|
|
13337
13383
|
read(from: RustBuffer): ExternalSecretShare;
|
|
13338
13384
|
write(value: ExternalSecretShare, into: RustBuffer): void;
|