@breeztech/breez-sdk-spark-react-native 0.6.2 → 0.6.4-dev1
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/README.md +32 -0
- package/app.plugin.js +2 -0
- package/lib/typescript/commonjs/src/generated/breez_sdk_spark.d.ts.map +1 -1
- package/lib/typescript/module/src/generated/breez_sdk_spark.d.ts.map +1 -1
- package/package.json +12 -3
- package/plugin/build/index.d.ts +10 -0
- package/plugin/build/index.js +19 -0
- package/plugin/build/tsconfig.tsbuildinfo +1 -0
- package/plugin/build/utils.d.ts +4 -0
- package/plugin/build/utils.js +4 -0
- package/plugin/build/withAndroid.d.ts +5 -0
- package/plugin/build/withAndroid.js +26 -0
- package/plugin/build/withBinaryArtifacts.d.ts +6 -0
- package/plugin/build/withBinaryArtifacts.js +108 -0
- package/plugin/build/withIOS.d.ts +6 -0
- package/plugin/build/withIOS.js +13 -0
- package/src/generated/breez_sdk_spark.ts +70 -70
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.withBreezSdkAndroid = void 0;
|
|
4
|
+
const config_plugins_1 = require("@expo/config-plugins");
|
|
5
|
+
/**
|
|
6
|
+
* Add required configurations to gradle.properties
|
|
7
|
+
*/
|
|
8
|
+
const withGradlePropertiesConfig = (config) => {
|
|
9
|
+
return (0, config_plugins_1.withGradleProperties)(config, (config) => {
|
|
10
|
+
config.modResults = config.modResults.filter((item) => item.type !== 'property' || item.key !== 'android.useAndroidX');
|
|
11
|
+
config.modResults.push({
|
|
12
|
+
type: 'property',
|
|
13
|
+
key: 'android.useAndroidX',
|
|
14
|
+
value: 'true',
|
|
15
|
+
});
|
|
16
|
+
return config;
|
|
17
|
+
});
|
|
18
|
+
};
|
|
19
|
+
/**
|
|
20
|
+
* Configure Android build settings for Breez SDK
|
|
21
|
+
*/
|
|
22
|
+
const withBreezSdkAndroid = (config) => {
|
|
23
|
+
config = withGradlePropertiesConfig(config);
|
|
24
|
+
return config;
|
|
25
|
+
};
|
|
26
|
+
exports.withBreezSdkAndroid = withBreezSdkAndroid;
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
+
var ownKeys = function(o) {
|
|
20
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
+
var ar = [];
|
|
22
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
+
return ar;
|
|
24
|
+
};
|
|
25
|
+
return ownKeys(o);
|
|
26
|
+
};
|
|
27
|
+
return function (mod) {
|
|
28
|
+
if (mod && mod.__esModule) return mod;
|
|
29
|
+
var result = {};
|
|
30
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
+
__setModuleDefault(result, mod);
|
|
32
|
+
return result;
|
|
33
|
+
};
|
|
34
|
+
})();
|
|
35
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
|
+
exports.withBinaryArtifacts = void 0;
|
|
37
|
+
const path = __importStar(require("path"));
|
|
38
|
+
const fs = __importStar(require("fs"));
|
|
39
|
+
const child_process_1 = require("child_process");
|
|
40
|
+
/**
|
|
41
|
+
* Downloads prebuilt binary artifacts for Android and iOS
|
|
42
|
+
* This runs during expo prebuild to ensure binaries are available
|
|
43
|
+
*/
|
|
44
|
+
const withBinaryArtifacts = (config) => {
|
|
45
|
+
return {
|
|
46
|
+
...config,
|
|
47
|
+
async prebuildAsync(config) {
|
|
48
|
+
try {
|
|
49
|
+
await downloadBinaryArtifacts();
|
|
50
|
+
}
|
|
51
|
+
catch (error) {
|
|
52
|
+
console.warn('Failed to download Breez SDK binary artifacts:', error);
|
|
53
|
+
console.warn('You may need to run the postinstall script manually or check your network connection.');
|
|
54
|
+
}
|
|
55
|
+
return config;
|
|
56
|
+
},
|
|
57
|
+
};
|
|
58
|
+
};
|
|
59
|
+
exports.withBinaryArtifacts = withBinaryArtifacts;
|
|
60
|
+
async function downloadBinaryArtifacts() {
|
|
61
|
+
const packageRoot = findPackageRoot();
|
|
62
|
+
if (!packageRoot) {
|
|
63
|
+
throw new Error('Could not find @breeztech/breez-sdk-spark-react-native package');
|
|
64
|
+
}
|
|
65
|
+
// Check if artifacts already exist
|
|
66
|
+
const androidLibsPath = path.join(packageRoot, 'android/src/main/jniLibs');
|
|
67
|
+
const iosFrameworkPath = path.join(packageRoot, 'build/RnBreezSdkSpark.xcframework');
|
|
68
|
+
if (fs.existsSync(androidLibsPath) && fs.existsSync(iosFrameworkPath)) {
|
|
69
|
+
return;
|
|
70
|
+
}
|
|
71
|
+
const packageJsonPath = path.join(packageRoot, 'package.json');
|
|
72
|
+
const packageJson = JSON.parse(fs.readFileSync(packageJsonPath, 'utf-8'));
|
|
73
|
+
const version = packageJson.version;
|
|
74
|
+
const repo = 'https://github.com/breez/breez-sdk-spark-react-native';
|
|
75
|
+
const androidUrl = `${repo}/releases/download/${version}/android-artifacts.zip`;
|
|
76
|
+
const iosUrl = `${repo}/releases/download/${version}/ios-artifacts.zip`;
|
|
77
|
+
// Download Android artifacts
|
|
78
|
+
try {
|
|
79
|
+
(0, child_process_1.execSync)(`curl -L "${androidUrl}" --output android-artifacts.zip && unzip -o android-artifacts.zip && rm -rf android-artifacts.zip`, { cwd: packageRoot, stdio: 'inherit' });
|
|
80
|
+
}
|
|
81
|
+
catch (error) {
|
|
82
|
+
console.error('Failed to download Android artifacts');
|
|
83
|
+
throw error;
|
|
84
|
+
}
|
|
85
|
+
// Download iOS artifacts
|
|
86
|
+
try {
|
|
87
|
+
(0, child_process_1.execSync)(`curl -L "${iosUrl}" --output ios-artifacts.zip && unzip -o ios-artifacts.zip && rm -rf ios-artifacts.zip`, { cwd: packageRoot, stdio: 'inherit' });
|
|
88
|
+
}
|
|
89
|
+
catch (error) {
|
|
90
|
+
console.error('Failed to download iOS artifacts');
|
|
91
|
+
throw error;
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
function findPackageRoot() {
|
|
95
|
+
let currentDir = __dirname;
|
|
96
|
+
// Walk up the directory tree to find the package root
|
|
97
|
+
while (currentDir !== path.dirname(currentDir)) {
|
|
98
|
+
const packageJsonPath = path.join(currentDir, 'package.json');
|
|
99
|
+
if (fs.existsSync(packageJsonPath)) {
|
|
100
|
+
const packageJson = JSON.parse(fs.readFileSync(packageJsonPath, 'utf-8'));
|
|
101
|
+
if (packageJson.name === '@breeztech/breez-sdk-spark-react-native') {
|
|
102
|
+
return currentDir;
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
currentDir = path.dirname(currentDir);
|
|
106
|
+
}
|
|
107
|
+
return null;
|
|
108
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.withBreezSdkIOS = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* Configure iOS build settings for Breez SDK
|
|
6
|
+
* The podspec already defines the minimum iOS version via min_ios_version_supported
|
|
7
|
+
*/
|
|
8
|
+
const withBreezSdkIOS = (config) => {
|
|
9
|
+
// Currently no additional iOS configuration needed
|
|
10
|
+
// The podspec handles minimum version and framework linking
|
|
11
|
+
return config;
|
|
12
|
+
};
|
|
13
|
+
exports.withBreezSdkIOS = withBreezSdkIOS;
|
|
@@ -14345,22 +14345,22 @@ export interface BitcoinChainService {
|
|
|
14345
14345
|
getAddressUtxos(
|
|
14346
14346
|
address: string,
|
|
14347
14347
|
asyncOpts_?: { signal: AbortSignal }
|
|
14348
|
-
) /*throws*/
|
|
14348
|
+
): /*throws*/ Promise<Array<Utxo>>;
|
|
14349
14349
|
getTransactionStatus(
|
|
14350
14350
|
txid: string,
|
|
14351
14351
|
asyncOpts_?: { signal: AbortSignal }
|
|
14352
|
-
) /*throws*/
|
|
14352
|
+
): /*throws*/ Promise<TxStatus>;
|
|
14353
14353
|
getTransactionHex(
|
|
14354
14354
|
txid: string,
|
|
14355
14355
|
asyncOpts_?: { signal: AbortSignal }
|
|
14356
|
-
) /*throws*/
|
|
14356
|
+
): /*throws*/ Promise<string>;
|
|
14357
14357
|
broadcastTransaction(
|
|
14358
14358
|
tx: string,
|
|
14359
14359
|
asyncOpts_?: { signal: AbortSignal }
|
|
14360
|
-
) /*throws*/
|
|
14360
|
+
): /*throws*/ Promise<void>;
|
|
14361
14361
|
recommendedFees(asyncOpts_?: {
|
|
14362
14362
|
signal: AbortSignal;
|
|
14363
|
-
}) /*throws*/
|
|
14363
|
+
}): /*throws*/ Promise<RecommendedFees>;
|
|
14364
14364
|
}
|
|
14365
14365
|
|
|
14366
14366
|
export class BitcoinChainServiceImpl
|
|
@@ -14921,7 +14921,7 @@ export interface BreezSdkInterface {
|
|
|
14921
14921
|
checkLightningAddressAvailable(
|
|
14922
14922
|
req: CheckLightningAddressRequest,
|
|
14923
14923
|
asyncOpts_?: { signal: AbortSignal }
|
|
14924
|
-
) /*throws*/
|
|
14924
|
+
): /*throws*/ Promise<boolean>;
|
|
14925
14925
|
/**
|
|
14926
14926
|
* Verifies a message signature against the provided public key. The message
|
|
14927
14927
|
* is SHA256 hashed before verification. The signature can be hex encoded
|
|
@@ -14930,18 +14930,18 @@ export interface BreezSdkInterface {
|
|
|
14930
14930
|
checkMessage(
|
|
14931
14931
|
request: CheckMessageRequest,
|
|
14932
14932
|
asyncOpts_?: { signal: AbortSignal }
|
|
14933
|
-
) /*throws*/
|
|
14933
|
+
): /*throws*/ Promise<CheckMessageResponse>;
|
|
14934
14934
|
claimDeposit(
|
|
14935
14935
|
request: ClaimDepositRequest,
|
|
14936
14936
|
asyncOpts_?: { signal: AbortSignal }
|
|
14937
|
-
) /*throws*/
|
|
14937
|
+
): /*throws*/ Promise<ClaimDepositResponse>;
|
|
14938
14938
|
claimHtlcPayment(
|
|
14939
14939
|
request: ClaimHtlcPaymentRequest,
|
|
14940
14940
|
asyncOpts_?: { signal: AbortSignal }
|
|
14941
|
-
) /*throws*/
|
|
14941
|
+
): /*throws*/ Promise<ClaimHtlcPaymentResponse>;
|
|
14942
14942
|
deleteLightningAddress(asyncOpts_?: {
|
|
14943
14943
|
signal: AbortSignal;
|
|
14944
|
-
}) /*throws*/
|
|
14944
|
+
}): /*throws*/ Promise<void>;
|
|
14945
14945
|
/**
|
|
14946
14946
|
* Stops the SDK's background tasks
|
|
14947
14947
|
*
|
|
@@ -14952,21 +14952,21 @@ export interface BreezSdkInterface {
|
|
|
14952
14952
|
*
|
|
14953
14953
|
* Result containing either success or an `SdkError` if the background task couldn't be stopped
|
|
14954
14954
|
*/
|
|
14955
|
-
disconnect(asyncOpts_?: { signal: AbortSignal }) /*throws*/
|
|
14955
|
+
disconnect(asyncOpts_?: { signal: AbortSignal }): /*throws*/ Promise<void>;
|
|
14956
14956
|
/**
|
|
14957
14957
|
* Returns the balance of the wallet in satoshis
|
|
14958
14958
|
*/
|
|
14959
14959
|
getInfo(
|
|
14960
14960
|
request: GetInfoRequest,
|
|
14961
14961
|
asyncOpts_?: { signal: AbortSignal }
|
|
14962
|
-
) /*throws*/
|
|
14962
|
+
): /*throws*/ Promise<GetInfoResponse>;
|
|
14963
14963
|
getLightningAddress(asyncOpts_?: {
|
|
14964
14964
|
signal: AbortSignal;
|
|
14965
|
-
}) /*throws*/
|
|
14965
|
+
}): /*throws*/ Promise<LightningAddressInfo | undefined>;
|
|
14966
14966
|
getPayment(
|
|
14967
14967
|
request: GetPaymentRequest,
|
|
14968
14968
|
asyncOpts_?: { signal: AbortSignal }
|
|
14969
|
-
) /*throws*/
|
|
14969
|
+
): /*throws*/ Promise<GetPaymentResponse>;
|
|
14970
14970
|
/**
|
|
14971
14971
|
* Returns an instance of the [`TokenIssuer`] for managing token issuance.
|
|
14972
14972
|
*/
|
|
@@ -14982,7 +14982,7 @@ export interface BreezSdkInterface {
|
|
|
14982
14982
|
getTokensMetadata(
|
|
14983
14983
|
request: GetTokensMetadataRequest,
|
|
14984
14984
|
asyncOpts_?: { signal: AbortSignal }
|
|
14985
|
-
) /*throws*/
|
|
14985
|
+
): /*throws*/ Promise<GetTokensMetadataResponse>;
|
|
14986
14986
|
/**
|
|
14987
14987
|
* Returns the user settings for the wallet.
|
|
14988
14988
|
*
|
|
@@ -14990,20 +14990,20 @@ export interface BreezSdkInterface {
|
|
|
14990
14990
|
*/
|
|
14991
14991
|
getUserSettings(asyncOpts_?: {
|
|
14992
14992
|
signal: AbortSignal;
|
|
14993
|
-
}) /*throws*/
|
|
14993
|
+
}): /*throws*/ Promise<UserSettings>;
|
|
14994
14994
|
/**
|
|
14995
14995
|
* List fiat currencies for which there is a known exchange rate,
|
|
14996
14996
|
* sorted by the canonical name of the currency.
|
|
14997
14997
|
*/
|
|
14998
14998
|
listFiatCurrencies(asyncOpts_?: {
|
|
14999
14999
|
signal: AbortSignal;
|
|
15000
|
-
}) /*throws*/
|
|
15000
|
+
}): /*throws*/ Promise<ListFiatCurrenciesResponse>;
|
|
15001
15001
|
/**
|
|
15002
15002
|
* List the latest rates of fiat currencies, sorted by name.
|
|
15003
15003
|
*/
|
|
15004
15004
|
listFiatRates(asyncOpts_?: {
|
|
15005
15005
|
signal: AbortSignal;
|
|
15006
|
-
}) /*throws*/
|
|
15006
|
+
}): /*throws*/ Promise<ListFiatRatesResponse>;
|
|
15007
15007
|
/**
|
|
15008
15008
|
* Lists payments from the storage with pagination
|
|
15009
15009
|
*
|
|
@@ -15023,15 +15023,15 @@ export interface BreezSdkInterface {
|
|
|
15023
15023
|
listPayments(
|
|
15024
15024
|
request: ListPaymentsRequest,
|
|
15025
15025
|
asyncOpts_?: { signal: AbortSignal }
|
|
15026
|
-
) /*throws*/
|
|
15026
|
+
): /*throws*/ Promise<ListPaymentsResponse>;
|
|
15027
15027
|
listUnclaimedDeposits(
|
|
15028
15028
|
request: ListUnclaimedDepositsRequest,
|
|
15029
15029
|
asyncOpts_?: { signal: AbortSignal }
|
|
15030
|
-
) /*throws*/
|
|
15030
|
+
): /*throws*/ Promise<ListUnclaimedDepositsResponse>;
|
|
15031
15031
|
lnurlPay(
|
|
15032
15032
|
request: LnurlPayRequest,
|
|
15033
15033
|
asyncOpts_?: { signal: AbortSignal }
|
|
15034
|
-
) /*throws*/
|
|
15034
|
+
): /*throws*/ Promise<LnurlPayResponse>;
|
|
15035
15035
|
/**
|
|
15036
15036
|
* Performs an LNURL withdraw operation for the amount of satoshis to
|
|
15037
15037
|
* withdraw and the LNURL withdraw request details. The LNURL withdraw request
|
|
@@ -15062,37 +15062,37 @@ export interface BreezSdkInterface {
|
|
|
15062
15062
|
lnurlWithdraw(
|
|
15063
15063
|
request: LnurlWithdrawRequest,
|
|
15064
15064
|
asyncOpts_?: { signal: AbortSignal }
|
|
15065
|
-
) /*throws*/
|
|
15065
|
+
): /*throws*/ Promise<LnurlWithdrawResponse>;
|
|
15066
15066
|
parse(
|
|
15067
15067
|
input: string,
|
|
15068
15068
|
asyncOpts_?: { signal: AbortSignal }
|
|
15069
|
-
) /*throws*/
|
|
15069
|
+
): /*throws*/ Promise<InputType>;
|
|
15070
15070
|
prepareLnurlPay(
|
|
15071
15071
|
request: PrepareLnurlPayRequest,
|
|
15072
15072
|
asyncOpts_?: { signal: AbortSignal }
|
|
15073
|
-
) /*throws*/
|
|
15073
|
+
): /*throws*/ Promise<PrepareLnurlPayResponse>;
|
|
15074
15074
|
prepareSendPayment(
|
|
15075
15075
|
request: PrepareSendPaymentRequest,
|
|
15076
15076
|
asyncOpts_?: { signal: AbortSignal }
|
|
15077
|
-
) /*throws*/
|
|
15077
|
+
): /*throws*/ Promise<PrepareSendPaymentResponse>;
|
|
15078
15078
|
receivePayment(
|
|
15079
15079
|
request: ReceivePaymentRequest,
|
|
15080
15080
|
asyncOpts_?: { signal: AbortSignal }
|
|
15081
|
-
) /*throws*/
|
|
15081
|
+
): /*throws*/ Promise<ReceivePaymentResponse>;
|
|
15082
15082
|
/**
|
|
15083
15083
|
* Get the recommended BTC fees based on the configured chain service.
|
|
15084
15084
|
*/
|
|
15085
15085
|
recommendedFees(asyncOpts_?: {
|
|
15086
15086
|
signal: AbortSignal;
|
|
15087
|
-
}) /*throws*/
|
|
15087
|
+
}): /*throws*/ Promise<RecommendedFees>;
|
|
15088
15088
|
refundDeposit(
|
|
15089
15089
|
request: RefundDepositRequest,
|
|
15090
15090
|
asyncOpts_?: { signal: AbortSignal }
|
|
15091
|
-
) /*throws*/
|
|
15091
|
+
): /*throws*/ Promise<RefundDepositResponse>;
|
|
15092
15092
|
registerLightningAddress(
|
|
15093
15093
|
request: RegisterLightningAddressRequest,
|
|
15094
15094
|
asyncOpts_?: { signal: AbortSignal }
|
|
15095
|
-
) /*throws*/
|
|
15095
|
+
): /*throws*/ Promise<LightningAddressInfo>;
|
|
15096
15096
|
/**
|
|
15097
15097
|
* Removes a previously registered event listener
|
|
15098
15098
|
*
|
|
@@ -15111,7 +15111,7 @@ export interface BreezSdkInterface {
|
|
|
15111
15111
|
sendPayment(
|
|
15112
15112
|
request: SendPaymentRequest,
|
|
15113
15113
|
asyncOpts_?: { signal: AbortSignal }
|
|
15114
|
-
) /*throws*/
|
|
15114
|
+
): /*throws*/ Promise<SendPaymentResponse>;
|
|
15115
15115
|
/**
|
|
15116
15116
|
* Signs a message with the wallet's identity key. The message is SHA256
|
|
15117
15117
|
* hashed before signing. The returned signature will be hex encoded in
|
|
@@ -15120,14 +15120,14 @@ export interface BreezSdkInterface {
|
|
|
15120
15120
|
signMessage(
|
|
15121
15121
|
request: SignMessageRequest,
|
|
15122
15122
|
asyncOpts_?: { signal: AbortSignal }
|
|
15123
|
-
) /*throws*/
|
|
15123
|
+
): /*throws*/ Promise<SignMessageResponse>;
|
|
15124
15124
|
/**
|
|
15125
15125
|
* Synchronizes the wallet with the Spark network
|
|
15126
15126
|
*/
|
|
15127
15127
|
syncWallet(
|
|
15128
15128
|
request: SyncWalletRequest,
|
|
15129
15129
|
asyncOpts_?: { signal: AbortSignal }
|
|
15130
|
-
) /*throws*/
|
|
15130
|
+
): /*throws*/ Promise<SyncWalletResponse>;
|
|
15131
15131
|
/**
|
|
15132
15132
|
* Updates the user settings for the wallet.
|
|
15133
15133
|
*
|
|
@@ -15136,7 +15136,7 @@ export interface BreezSdkInterface {
|
|
|
15136
15136
|
updateUserSettings(
|
|
15137
15137
|
request: UpdateUserSettingsRequest,
|
|
15138
15138
|
asyncOpts_?: { signal: AbortSignal }
|
|
15139
|
-
) /*throws*/
|
|
15139
|
+
): /*throws*/ Promise<void>;
|
|
15140
15140
|
}
|
|
15141
15141
|
|
|
15142
15142
|
/**
|
|
@@ -16525,13 +16525,13 @@ export interface FiatService {
|
|
|
16525
16525
|
*/
|
|
16526
16526
|
fetchFiatCurrencies(asyncOpts_?: {
|
|
16527
16527
|
signal: AbortSignal;
|
|
16528
|
-
}) /*throws*/
|
|
16528
|
+
}): /*throws*/ Promise<Array<FiatCurrency>>;
|
|
16529
16529
|
/**
|
|
16530
16530
|
* Get the live rates from the server.
|
|
16531
16531
|
*/
|
|
16532
16532
|
fetchFiatRates(asyncOpts_?: {
|
|
16533
16533
|
signal: AbortSignal;
|
|
16534
|
-
}) /*throws*/
|
|
16534
|
+
}): /*throws*/ Promise<Array<Rate>>;
|
|
16535
16535
|
}
|
|
16536
16536
|
|
|
16537
16537
|
/**
|
|
@@ -16834,7 +16834,7 @@ export interface PaymentObserver {
|
|
|
16834
16834
|
beforeSend(
|
|
16835
16835
|
payments: Array<ProvisionalPayment>,
|
|
16836
16836
|
asyncOpts_?: { signal: AbortSignal }
|
|
16837
|
-
) /*throws*/
|
|
16837
|
+
): /*throws*/ Promise<void>;
|
|
16838
16838
|
}
|
|
16839
16839
|
|
|
16840
16840
|
/**
|
|
@@ -17056,7 +17056,7 @@ export interface RestClient {
|
|
|
17056
17056
|
url: string,
|
|
17057
17057
|
headers: Map<string, string> | undefined,
|
|
17058
17058
|
asyncOpts_?: { signal: AbortSignal }
|
|
17059
|
-
) /*throws*/
|
|
17059
|
+
): /*throws*/ Promise<RestResponse>;
|
|
17060
17060
|
/**
|
|
17061
17061
|
* Makes a POST request, and logs on DEBUG.
|
|
17062
17062
|
* ### Arguments
|
|
@@ -17069,7 +17069,7 @@ export interface RestClient {
|
|
|
17069
17069
|
headers: Map<string, string> | undefined,
|
|
17070
17070
|
body: string | undefined,
|
|
17071
17071
|
asyncOpts_?: { signal: AbortSignal }
|
|
17072
|
-
) /*throws*/
|
|
17072
|
+
): /*throws*/ Promise<RestResponse>;
|
|
17073
17073
|
/**
|
|
17074
17074
|
* Makes a DELETE request, and logs on DEBUG.
|
|
17075
17075
|
* ### Arguments
|
|
@@ -17082,7 +17082,7 @@ export interface RestClient {
|
|
|
17082
17082
|
headers: Map<string, string> | undefined,
|
|
17083
17083
|
body: string | undefined,
|
|
17084
17084
|
asyncOpts_?: { signal: AbortSignal }
|
|
17085
|
-
) /*throws*/
|
|
17085
|
+
): /*throws*/ Promise<RestResponse>;
|
|
17086
17086
|
}
|
|
17087
17087
|
|
|
17088
17088
|
export class RestClientImpl extends UniffiAbstractObject implements RestClient {
|
|
@@ -17507,7 +17507,7 @@ export interface SdkBuilderInterface {
|
|
|
17507
17507
|
*/
|
|
17508
17508
|
build(asyncOpts_?: {
|
|
17509
17509
|
signal: AbortSignal;
|
|
17510
|
-
}) /*throws*/
|
|
17510
|
+
}): /*throws*/ Promise<BreezSdkInterface>;
|
|
17511
17511
|
/**
|
|
17512
17512
|
* Sets the chain service to be used by the SDK.
|
|
17513
17513
|
* Arguments:
|
|
@@ -18118,16 +18118,16 @@ export interface Storage {
|
|
|
18118
18118
|
deleteCachedItem(
|
|
18119
18119
|
key: string,
|
|
18120
18120
|
asyncOpts_?: { signal: AbortSignal }
|
|
18121
|
-
) /*throws*/
|
|
18121
|
+
): /*throws*/ Promise<void>;
|
|
18122
18122
|
getCachedItem(
|
|
18123
18123
|
key: string,
|
|
18124
18124
|
asyncOpts_?: { signal: AbortSignal }
|
|
18125
|
-
) /*throws*/
|
|
18125
|
+
): /*throws*/ Promise<string | undefined>;
|
|
18126
18126
|
setCachedItem(
|
|
18127
18127
|
key: string,
|
|
18128
18128
|
value: string,
|
|
18129
18129
|
asyncOpts_?: { signal: AbortSignal }
|
|
18130
|
-
) /*throws*/
|
|
18130
|
+
): /*throws*/ Promise<void>;
|
|
18131
18131
|
/**
|
|
18132
18132
|
* Lists payments with optional filters and pagination
|
|
18133
18133
|
*
|
|
@@ -18142,7 +18142,7 @@ export interface Storage {
|
|
|
18142
18142
|
listPayments(
|
|
18143
18143
|
request: ListPaymentsRequest,
|
|
18144
18144
|
asyncOpts_?: { signal: AbortSignal }
|
|
18145
|
-
) /*throws*/
|
|
18145
|
+
): /*throws*/ Promise<Array<Payment>>;
|
|
18146
18146
|
/**
|
|
18147
18147
|
* Inserts a payment into storage
|
|
18148
18148
|
*
|
|
@@ -18157,7 +18157,7 @@ export interface Storage {
|
|
|
18157
18157
|
insertPayment(
|
|
18158
18158
|
payment: Payment,
|
|
18159
18159
|
asyncOpts_?: { signal: AbortSignal }
|
|
18160
|
-
) /*throws*/
|
|
18160
|
+
): /*throws*/ Promise<void>;
|
|
18161
18161
|
/**
|
|
18162
18162
|
* Inserts payment metadata into storage
|
|
18163
18163
|
*
|
|
@@ -18174,7 +18174,7 @@ export interface Storage {
|
|
|
18174
18174
|
paymentId: string,
|
|
18175
18175
|
metadata: PaymentMetadata,
|
|
18176
18176
|
asyncOpts_?: { signal: AbortSignal }
|
|
18177
|
-
) /*throws*/
|
|
18177
|
+
): /*throws*/ Promise<void>;
|
|
18178
18178
|
/**
|
|
18179
18179
|
* Gets a payment by its ID
|
|
18180
18180
|
* # Arguments
|
|
@@ -18188,7 +18188,7 @@ export interface Storage {
|
|
|
18188
18188
|
getPaymentById(
|
|
18189
18189
|
id: string,
|
|
18190
18190
|
asyncOpts_?: { signal: AbortSignal }
|
|
18191
|
-
) /*throws*/
|
|
18191
|
+
): /*throws*/ Promise<Payment>;
|
|
18192
18192
|
/**
|
|
18193
18193
|
* Gets a payment by its invoice
|
|
18194
18194
|
* # Arguments
|
|
@@ -18201,7 +18201,7 @@ export interface Storage {
|
|
|
18201
18201
|
getPaymentByInvoice(
|
|
18202
18202
|
invoice: string,
|
|
18203
18203
|
asyncOpts_?: { signal: AbortSignal }
|
|
18204
|
-
) /*throws*/
|
|
18204
|
+
): /*throws*/ Promise<Payment | undefined>;
|
|
18205
18205
|
/**
|
|
18206
18206
|
* Add a deposit to storage
|
|
18207
18207
|
* # Arguments
|
|
@@ -18219,7 +18219,7 @@ export interface Storage {
|
|
|
18219
18219
|
vout: /*u32*/ number,
|
|
18220
18220
|
amountSats: /*u64*/ bigint,
|
|
18221
18221
|
asyncOpts_?: { signal: AbortSignal }
|
|
18222
|
-
) /*throws*/
|
|
18222
|
+
): /*throws*/ Promise<void>;
|
|
18223
18223
|
/**
|
|
18224
18224
|
* Removes an unclaimed deposit from storage
|
|
18225
18225
|
* # Arguments
|
|
@@ -18235,7 +18235,7 @@ export interface Storage {
|
|
|
18235
18235
|
txid: string,
|
|
18236
18236
|
vout: /*u32*/ number,
|
|
18237
18237
|
asyncOpts_?: { signal: AbortSignal }
|
|
18238
|
-
) /*throws*/
|
|
18238
|
+
): /*throws*/ Promise<void>;
|
|
18239
18239
|
/**
|
|
18240
18240
|
* Lists all unclaimed deposits from storage
|
|
18241
18241
|
* # Returns
|
|
@@ -18244,7 +18244,7 @@ export interface Storage {
|
|
|
18244
18244
|
*/
|
|
18245
18245
|
listDeposits(asyncOpts_?: {
|
|
18246
18246
|
signal: AbortSignal;
|
|
18247
|
-
}) /*throws*/
|
|
18247
|
+
}): /*throws*/ Promise<Array<DepositInfo>>;
|
|
18248
18248
|
/**
|
|
18249
18249
|
* Updates or inserts unclaimed deposit details
|
|
18250
18250
|
* # Arguments
|
|
@@ -18262,11 +18262,11 @@ export interface Storage {
|
|
|
18262
18262
|
vout: /*u32*/ number,
|
|
18263
18263
|
payload: UpdateDepositPayload,
|
|
18264
18264
|
asyncOpts_?: { signal: AbortSignal }
|
|
18265
|
-
) /*throws*/
|
|
18265
|
+
): /*throws*/ Promise<void>;
|
|
18266
18266
|
setLnurlMetadata(
|
|
18267
18267
|
metadata: Array<SetLnurlMetadataItem>,
|
|
18268
18268
|
asyncOpts_?: { signal: AbortSignal }
|
|
18269
|
-
) /*throws*/
|
|
18269
|
+
): /*throws*/ Promise<void>;
|
|
18270
18270
|
}
|
|
18271
18271
|
|
|
18272
18272
|
/**
|
|
@@ -19561,62 +19561,62 @@ export interface SyncStorage {
|
|
|
19561
19561
|
addOutgoingChange(
|
|
19562
19562
|
record: UnversionedRecordChange,
|
|
19563
19563
|
asyncOpts_?: { signal: AbortSignal }
|
|
19564
|
-
) /*throws*/
|
|
19564
|
+
): /*throws*/ Promise</*u64*/ bigint>;
|
|
19565
19565
|
completeOutgoingSync(
|
|
19566
19566
|
record: Record,
|
|
19567
19567
|
asyncOpts_?: { signal: AbortSignal }
|
|
19568
|
-
) /*throws*/
|
|
19568
|
+
): /*throws*/ Promise<void>;
|
|
19569
19569
|
getPendingOutgoingChanges(
|
|
19570
19570
|
limit: /*u32*/ number,
|
|
19571
19571
|
asyncOpts_?: { signal: AbortSignal }
|
|
19572
|
-
) /*throws*/
|
|
19572
|
+
): /*throws*/ Promise<Array<OutgoingChange>>;
|
|
19573
19573
|
/**
|
|
19574
19574
|
* Get the revision number of the last synchronized record
|
|
19575
19575
|
*/
|
|
19576
19576
|
getLastRevision(asyncOpts_?: {
|
|
19577
19577
|
signal: AbortSignal;
|
|
19578
|
-
}) /*throws*/
|
|
19578
|
+
}): /*throws*/ Promise</*u64*/ bigint>;
|
|
19579
19579
|
/**
|
|
19580
19580
|
* Insert incoming records from remote sync
|
|
19581
19581
|
*/
|
|
19582
19582
|
insertIncomingRecords(
|
|
19583
19583
|
records: Array<Record>,
|
|
19584
19584
|
asyncOpts_?: { signal: AbortSignal }
|
|
19585
|
-
) /*throws*/
|
|
19585
|
+
): /*throws*/ Promise<void>;
|
|
19586
19586
|
/**
|
|
19587
19587
|
* Delete an incoming record after it has been processed
|
|
19588
19588
|
*/
|
|
19589
19589
|
deleteIncomingRecord(
|
|
19590
19590
|
record: Record,
|
|
19591
19591
|
asyncOpts_?: { signal: AbortSignal }
|
|
19592
|
-
) /*throws*/
|
|
19592
|
+
): /*throws*/ Promise<void>;
|
|
19593
19593
|
/**
|
|
19594
19594
|
* Update revision numbers of pending outgoing records to be higher than the given revision
|
|
19595
19595
|
*/
|
|
19596
19596
|
rebasePendingOutgoingRecords(
|
|
19597
19597
|
revision: /*u64*/ bigint,
|
|
19598
19598
|
asyncOpts_?: { signal: AbortSignal }
|
|
19599
|
-
) /*throws*/
|
|
19599
|
+
): /*throws*/ Promise<void>;
|
|
19600
19600
|
/**
|
|
19601
19601
|
* Get incoming records that need to be processed, up to the specified limit
|
|
19602
19602
|
*/
|
|
19603
19603
|
getIncomingRecords(
|
|
19604
19604
|
limit: /*u32*/ number,
|
|
19605
19605
|
asyncOpts_?: { signal: AbortSignal }
|
|
19606
|
-
) /*throws*/
|
|
19606
|
+
): /*throws*/ Promise<Array<IncomingChange>>;
|
|
19607
19607
|
/**
|
|
19608
19608
|
* Get the latest outgoing record if any exists
|
|
19609
19609
|
*/
|
|
19610
19610
|
getLatestOutgoingChange(asyncOpts_?: {
|
|
19611
19611
|
signal: AbortSignal;
|
|
19612
|
-
}) /*throws*/
|
|
19612
|
+
}): /*throws*/ Promise<OutgoingChange | undefined>;
|
|
19613
19613
|
/**
|
|
19614
19614
|
* Update the sync state record from an incoming record
|
|
19615
19615
|
*/
|
|
19616
19616
|
updateRecordFromIncoming(
|
|
19617
19617
|
record: Record,
|
|
19618
19618
|
asyncOpts_?: { signal: AbortSignal }
|
|
19619
|
-
) /*throws*/
|
|
19619
|
+
): /*throws*/ Promise<void>;
|
|
19620
19620
|
}
|
|
19621
19621
|
|
|
19622
19622
|
export class SyncStorageImpl
|
|
@@ -20584,7 +20584,7 @@ export interface TokenIssuerInterface {
|
|
|
20584
20584
|
burnIssuerToken(
|
|
20585
20585
|
request: BurnIssuerTokenRequest,
|
|
20586
20586
|
asyncOpts_?: { signal: AbortSignal }
|
|
20587
|
-
) /*throws*/
|
|
20587
|
+
): /*throws*/ Promise<Payment>;
|
|
20588
20588
|
/**
|
|
20589
20589
|
* Creates a new issuer token
|
|
20590
20590
|
*
|
|
@@ -20601,7 +20601,7 @@ export interface TokenIssuerInterface {
|
|
|
20601
20601
|
createIssuerToken(
|
|
20602
20602
|
request: CreateIssuerTokenRequest,
|
|
20603
20603
|
asyncOpts_?: { signal: AbortSignal }
|
|
20604
|
-
) /*throws*/
|
|
20604
|
+
): /*throws*/ Promise<TokenMetadata>;
|
|
20605
20605
|
/**
|
|
20606
20606
|
* Freezes tokens held at the specified address
|
|
20607
20607
|
*
|
|
@@ -20618,7 +20618,7 @@ export interface TokenIssuerInterface {
|
|
|
20618
20618
|
freezeIssuerToken(
|
|
20619
20619
|
request: FreezeIssuerTokenRequest,
|
|
20620
20620
|
asyncOpts_?: { signal: AbortSignal }
|
|
20621
|
-
) /*throws*/
|
|
20621
|
+
): /*throws*/ Promise<FreezeIssuerTokenResponse>;
|
|
20622
20622
|
/**
|
|
20623
20623
|
* Gets the issuer token balance
|
|
20624
20624
|
*
|
|
@@ -20630,7 +20630,7 @@ export interface TokenIssuerInterface {
|
|
|
20630
20630
|
*/
|
|
20631
20631
|
getIssuerTokenBalance(asyncOpts_?: {
|
|
20632
20632
|
signal: AbortSignal;
|
|
20633
|
-
}) /*throws*/
|
|
20633
|
+
}): /*throws*/ Promise<TokenBalance>;
|
|
20634
20634
|
/**
|
|
20635
20635
|
* Gets the issuer token metadata
|
|
20636
20636
|
*
|
|
@@ -20642,7 +20642,7 @@ export interface TokenIssuerInterface {
|
|
|
20642
20642
|
*/
|
|
20643
20643
|
getIssuerTokenMetadata(asyncOpts_?: {
|
|
20644
20644
|
signal: AbortSignal;
|
|
20645
|
-
}) /*throws*/
|
|
20645
|
+
}): /*throws*/ Promise<TokenMetadata>;
|
|
20646
20646
|
/**
|
|
20647
20647
|
* Mints supply for the issuer token
|
|
20648
20648
|
*
|
|
@@ -20659,7 +20659,7 @@ export interface TokenIssuerInterface {
|
|
|
20659
20659
|
mintIssuerToken(
|
|
20660
20660
|
request: MintIssuerTokenRequest,
|
|
20661
20661
|
asyncOpts_?: { signal: AbortSignal }
|
|
20662
|
-
) /*throws*/
|
|
20662
|
+
): /*throws*/ Promise<Payment>;
|
|
20663
20663
|
/**
|
|
20664
20664
|
* Unfreezes tokens held at the specified address
|
|
20665
20665
|
*
|
|
@@ -20676,7 +20676,7 @@ export interface TokenIssuerInterface {
|
|
|
20676
20676
|
unfreezeIssuerToken(
|
|
20677
20677
|
request: UnfreezeIssuerTokenRequest,
|
|
20678
20678
|
asyncOpts_?: { signal: AbortSignal }
|
|
20679
|
-
) /*throws*/
|
|
20679
|
+
): /*throws*/ Promise<UnfreezeIssuerTokenResponse>;
|
|
20680
20680
|
}
|
|
20681
20681
|
|
|
20682
20682
|
export class TokenIssuer
|