4 * @param {string} word_start
5 * @returns {(string)[]}
7 export function getWordsAutocomplete(word_start: string): (string)[];
8 export function setPanicHook(): void;
10 * @param {WasmPsbt} psbt
11 * @param {WasmAccount} account
12 * @returns {Promise<WasmTransactionDetailsData>}
14 export function createTransactionFromPsbt(psbt: WasmPsbt, account: WasmAccount): Promise<WasmTransactionDetailsData>;
18 export function getDefaultStopGap(): number;
19 export enum WasmChangeSpendPolicy {
24 export enum WasmCoinSelection {
30 export enum WasmKeychainKind {
32 * External keychain, used for deriving recipient addresses.
36 * Internal keychain, used for deriving change addresses.
40 export enum WasmLanguage {
42 SimplifiedChinese = 1,
43 TraditionalChinese = 2,
51 export enum WasmNetwork {
57 * Bitcoin's testnet network.
61 * Bitcoin's signet network.
65 * Bitcoin's regtest network.
69 export enum WasmPaymentLinkKind {
75 export enum WasmScriptType {
81 export enum WasmSortOrder {
85 export enum WasmWalletTransactionFlag {
89 export enum WasmWordCount {
96 export type WasmInviteNotificationType = "Newcomer" | "EmailIntegration" | "Unsupported";
98 export interface WasmPagination {
103 export interface WasmApiWalletBitcoinAddressLookup {
104 BitcoinAddress: string | null;
105 BitcoinAddressSignature: string | null;
108 export interface WasmApiWalletBitcoinAddress {
111 WalletAccountID: string;
114 BitcoinAddress: string | null;
115 BitcoinAddressSignature: string | null;
116 BitcoinAddressIndex: number | null;
119 export interface WasmApiBitcoinAddressCreationPayload {
120 BitcoinAddress: string;
121 BitcoinAddressSignature: string;
122 BitcoinAddressIndex: number;
125 export interface WasmApiWalletBitcoinAddressLookup {
126 BitcoinAddress: string | null;
127 BitcoinAddressSignature: string | null;
130 export interface WasmApiExchangeRate {
132 BitcoinUnit: WasmBitcoinUnit;
133 FiatCurrency: WasmFiatCurrencySymbol;
135 ExchangeRateTime: string;
136 ExchangeRate: number;
140 export interface WasmApiFiatCurrency {
143 Symbol: WasmFiatCurrencySymbol;
148 export type WasmTimeframe = "OneDay" | "OneWeek" | "OneMonth" | "Unsupported";
150 export interface WasmDataPoint {
151 ExchangeRate: number;
156 export interface WasmPriceGraph {
157 FiatCurrency: WasmFiatCurrencySymbol;
158 BitcoinUnit: WasmBitcoinUnit;
159 GraphData: WasmDataPoint[];
162 export type WasmUserReceiveNotificationEmailTypes = "NotificationToInviter" | "EmailIntegration" | "TransactionalBvE" | "Unsupported";
164 export type WasmFiatCurrencySymbol = "ALL" | "DZD" | "ARS" | "AMD" | "AUD" | "AZN" | "BHD" | "BDT" | "BYN" | "BMD" | "BOB" | "BAM" | "BRL" | "BGN" | "KHR" | "CAD" | "CLP" | "CNY" | "COP" | "CRC" | "HRK" | "CUP" | "CZK" | "DKK" | "DOP" | "EGP" | "EUR" | "GEL" | "GHS" | "GTQ" | "HNL" | "HKD" | "HUF" | "ISK" | "INR" | "IDR" | "IRR" | "IQD" | "ILS" | "JMD" | "JPY" | "JOD" | "KZT" | "KES" | "KWD" | "KGS" | "LBP" | "MKD" | "MYR" | "MUR" | "MXN" | "MDL" | "MNT" | "MAD" | "MMK" | "NAD" | "NPR" | "TWD" | "NZD" | "NIO" | "NGN" | "NOK" | "OMR" | "PKR" | "PAB" | "PEN" | "PHP" | "PLN" | "GBP" | "QAR" | "RON" | "RUB" | "SAR" | "RSD" | "SGD" | "ZAR" | "KRW" | "SSP" | "VES" | "LKR" | "SEK" | "CHF" | "THB" | "TTD" | "TND" | "TRY" | "UGX" | "UAH" | "AED" | "USD" | "UYU" | "UZS" | "VND";
166 export interface WasmUserSettings {
167 AcceptTermsAndConditions: number | null;
168 BitcoinUnit: WasmBitcoinUnit;
169 FiatCurrency: WasmFiatCurrencySymbol;
170 HideEmptyUsedAddresses: number;
171 TwoFactorAmountThreshold: number | null;
172 ReceiveInviterNotification: number | null;
173 ReceiveEmailIntegrationNotification: number | null;
174 ReceiveTransactionNotification: number | null;
175 WalletCreated: number | null;
178 export interface WasmApiWallet {
184 HasPassphrase: number;
186 Mnemonic: string | null;
187 Fingerprint: string | null;
188 PublicKey: string | null;
189 MigrationRequired: number | null;
190 Legacy: number | null;
193 export interface WasmApiWalletKey {
197 WalletKeySignature: string;
200 export interface WasmApiWalletSettings {
202 HideAccounts: number;
203 InvoiceDefaultDescription: string | null;
204 InvoiceExpirationTime: number;
205 MaxChannelOpeningFee: number;
206 ShowWalletRecovery: boolean | null;
209 export interface WasmApiEmailAddress {
214 export interface WasmApiWalletAccount {
216 FiatCurrency: WasmFiatCurrencySymbol;
218 DerivationPath: string;
220 LastUsedIndex: number;
224 Addresses: WasmApiEmailAddress[];
227 export type WasmTransactionType = "NotSend" | "ProtonToProtonSend" | "ProtonToProtonReceive" | "ExternalSend" | "ExternalReceive" | "Unsupported";
229 export interface WasmApiWalletTransaction {
231 Type: WasmTransactionType | null;
233 WalletAccountID: string | null;
234 Label: string | null;
235 TransactionID: string;
236 TransactionTime: string;
237 IsSuspicious: number;
239 ExchangeRate: WasmApiExchangeRate | null;
240 HashedTransactionID: string | null;
241 Subject: string | null;
243 ToList: string | null;
244 Sender: string | null;
247 export interface WasmCreateWalletTransactionPayload {
250 label: string | null;
251 exchange_rate_id: string | null;
252 transaction_time: string | null;
255 export interface WasmMigratedWallet {
259 WalletKeySignature: string;
264 export interface WasmMigratedWalletAccount {
269 export interface WasmMigratedWalletTransaction {
271 WalletAccountID: string;
272 HashedTransactionID: string | null;
273 Label: string | null;
276 export type WasmBitcoinUnit = "BTC" | "MBTC" | "SATS";
278 export interface WasmBalance {
280 trusted_pending: number;
281 untrusted_pending: number;
285 export interface WasmAddressInfo {
288 keychain: WasmKeychainKind;
291 export type WasmGatewayProvider = "Banxa" | "Ramp" | "MoonPay" | "Azteco" | "Unsupported";
293 export interface WasmApiCountry {
295 FiatCurrency: string;
299 export interface WasmCountries {
300 data: WasmApiCountry[];
303 export interface WasmApiSimpleFiatCurrency {
306 MinimumAmount: string | null;
309 export interface WasmFiatCurrencies {
310 data: WasmApiSimpleFiatCurrency[];
313 export type WasmPaymentMethod = "ApplePay" | "BankTransfer" | "Card" | "GooglePay" | "InstantPayment" | "Paypal" | "Unsupported";
315 export interface WasmPaymentMethods {
316 data: WasmPaymentMethod[];
319 export interface WasmQuote {
320 BitcoinAmount: string;
322 FiatCurrencySymbol: string;
324 PaymentGatewayFee: string;
325 PaymentMethod: WasmPaymentMethod;
326 PurchaseAmount: string | null;
327 PaymentProcessingFee: string | null;
328 OrderID: string | null;
331 export interface WasmQuotes {
335 export interface WasmAddressDetails {
338 transactions: WasmTransactionDetails[];
339 balance: WasmBalance;
342 export interface WasmTxOut {
344 script_pubkey: WasmScript;
346 address: string | null;
349 export interface WasmTransactionDetails {
355 time: WasmTransactionTime;
356 inputs: WasmDetailledTxIn[];
357 outputs: WasmTxOut[];
358 account_derivation_path: string;
361 export interface WasmTransactionTime {
363 confirmation_time: number | null;
364 last_seen: number | null;
367 export type WasmExchangeRateOrTransactionTimeEnum = "ExchangeRate" | "TransactionTime";
369 export interface WasmExchangeRateOrTransactionTime {
370 key: WasmExchangeRateOrTransactionTimeEnum;
374 export interface WasmTransactionData {
375 label: string | null;
376 exchange_rate_or_transaction_time: WasmExchangeRateOrTransactionTime;
379 export interface WasmBroadcastMessage {
381 key_packets: Record<string, string>;
384 export interface WasmEmailIntegrationData {
385 address_id: string | null;
387 message: WasmBroadcastMessage | null;
388 recipients: Record<string, string> | null;
389 is_anonymous: number | null;
392 export class WasmAccount {
395 * @param {WasmWallet} wallet
396 * @param {WasmScriptType} script_type
397 * @param {WasmDerivationPath} derivation_path
399 constructor(wallet: WasmWallet, script_type: WasmScriptType, derivation_path: WasmDerivationPath);
401 * @param {number} from
402 * @param {number | undefined} [to]
403 * @returns {Promise<void>}
405 markReceiveAddressesUsedTo(from: number, to?: number): Promise<void>;
407 * @returns {Promise<WasmAddressInfo>}
409 getNextReceiveAddress(): Promise<WasmAddressInfo>;
411 * @param {number} index
412 * @returns {Promise<WasmAddressInfo>}
414 peekReceiveAddress(index: number): Promise<WasmAddressInfo>;
416 * @param {WasmAddress} address
417 * @returns {Promise<boolean>}
419 owns(address: WasmAddress): Promise<boolean>;
421 * @returns {Promise<WasmBalanceWrapper>}
423 getBalance(): Promise<WasmBalanceWrapper>;
427 getDerivationPath(): string;
429 * @returns {Promise<WasmUtxoArray>}
431 getUtxos(): Promise<WasmUtxoArray>;
433 * @param {WasmNetwork} network
434 * @param {string} address_str
435 * @param {WasmBlockchainClient} client
436 * @param {boolean | undefined} [force_sync]
437 * @returns {Promise<WasmAddressDetailsData | undefined>}
439 getAddress(network: WasmNetwork, address_str: string, client: WasmBlockchainClient, force_sync?: boolean): Promise<WasmAddressDetailsData | undefined>;
441 * @param {WasmPagination} pagination
442 * @param {WasmBlockchainClient} client
443 * @param {WasmKeychainKind} keychain
444 * @param {boolean | undefined} [force_sync]
445 * @returns {Promise<WasmAddressDetailsArray>}
447 getAddresses(pagination: WasmPagination, client: WasmBlockchainClient, keychain: WasmKeychainKind, force_sync?: boolean): Promise<WasmAddressDetailsArray>;
449 * @param {WasmPagination} pagination
450 * @param {WasmSortOrder | undefined} [sort]
451 * @returns {Promise<WasmTransactionDetailsArray>}
453 getTransactions(pagination: WasmPagination, sort?: WasmSortOrder): Promise<WasmTransactionDetailsArray>;
455 * @param {string} txid
456 * @returns {Promise<WasmTransactionDetailsData>}
458 getTransaction(txid: string): Promise<WasmTransactionDetailsData>;
460 * @returns {Promise<boolean>}
462 hasSyncData(): Promise<boolean>;
464 * @param {WasmPsbt} psbt
465 * @returns {Promise<void>}
467 insertUnconfirmedTransaction(psbt: WasmPsbt): Promise<void>;
469 * @param {WasmNetwork} network
470 * @param {string} txid
471 * @param {bigint} fees
472 * @returns {Promise<WasmPsbt>}
474 bumpTransactionsFees(network: WasmNetwork, txid: string, fees: bigint): Promise<WasmPsbt>;
476 * @returns {Promise<void>}
478 clearStore(): Promise<void>;
480 export class WasmAddress {
483 * @param {string} str
484 * @param {WasmNetwork} network
486 constructor(str: string, network: WasmNetwork);
488 * @param {WasmScript} value
489 * @param {WasmNetwork} network
490 * @returns {WasmAddress}
492 static fromScript(value: WasmScript, network: WasmNetwork): WasmAddress;
498 * @returns {WasmScript}
500 intoScript(): WasmScript;
502 export class WasmAddressDetailsArray {
504 0: (WasmAddressDetailsData)[];
506 export class WasmAddressDetailsData {
508 Data: WasmAddressDetails;
510 export class WasmAddressInfo {
517 * Child index of this address
523 keychain: WasmKeychainKind;
525 export class WasmApiBitcoinAddressCreationPayloadData {
527 Data: WasmApiBitcoinAddressCreationPayload;
529 export class WasmApiBitcoinAddressesCreationPayload {
533 * @param {WasmApiBitcoinAddressCreationPayload} create_payload
535 push(create_payload: WasmApiBitcoinAddressCreationPayload): void;
536 0: (WasmApiBitcoinAddressCreationPayloadData)[];
538 export class WasmApiClients {
540 bitcoin_address: WasmBitcoinAddressClient;
541 email_integration: WasmEmailIntegrationClient;
542 exchange_rate: WasmExchangeRateClient;
543 invite: WasmInviteClient;
544 network: WasmNetworkClient;
545 payment_gateway: WasmPaymentGatewayClient;
546 price_graph: WasmPriceGraphClient;
547 settings: WasmSettingsClient;
548 wallet: WasmWalletClient;
550 export class WasmApiExchangeRateData {
552 Data: WasmApiExchangeRate;
554 export class WasmApiFiatCurrencies {
556 0: (WasmApiFiatCurrencyData)[];
558 export class WasmApiFiatCurrencyData {
560 Data: WasmApiFiatCurrency;
562 export class WasmApiWalletAccountAddresses {
564 0: (WasmWalletAccountAddressData)[];
566 export class WasmApiWalletAccounts {
568 0: (WasmWalletAccountData)[];
570 export class WasmApiWalletBitcoinAddressData {
572 Data: WasmApiWalletBitcoinAddress;
574 export class WasmApiWalletBitcoinAddressLookupData {
576 Data: WasmApiWalletBitcoinAddressLookup;
578 export class WasmApiWalletBitcoinAddresses {
580 0: (WasmApiWalletBitcoinAddressData)[];
582 export class WasmApiWalletData {
585 * @param {WasmApiWallet} wallet
586 * @param {WasmApiWalletKey} key
587 * @param {WasmApiWalletSettings} settings
588 * @returns {WasmApiWalletData}
590 static from_parts(wallet: WasmApiWallet, key: WasmApiWalletKey, settings: WasmApiWalletSettings): WasmApiWalletData;
591 Wallet: WasmApiWallet;
592 WalletKey: WasmApiWalletKey;
593 WalletSettings: WasmApiWalletSettings;
595 export class WasmApiWalletTransactionData {
597 Data: WasmApiWalletTransaction;
599 export class WasmApiWalletTransactions {
601 0: (WasmApiWalletTransactionData)[];
603 export class WasmApiWalletsData {
605 0: (WasmApiWalletData)[];
607 export class WasmAuthData {
614 export class WasmBalanceWrapper {
618 export class WasmBitcoinAddressClient {
621 * @param {string} wallet_id
622 * @param {string} wallet_account_id
623 * @param {number | undefined} [only_without_bitcoin_addresses]
624 * @returns {Promise<WasmApiWalletBitcoinAddresses>}
626 getBitcoinAddresses(wallet_id: string, wallet_account_id: string, only_without_bitcoin_addresses?: number): Promise<WasmApiWalletBitcoinAddresses>;
628 * @param {string} wallet_id
629 * @param {string} wallet_account_id
630 * @returns {Promise<bigint>}
632 getBitcoinAddressHighestIndex(wallet_id: string, wallet_account_id: string): Promise<bigint>;
634 * @param {string} wallet_id
635 * @param {string} wallet_account_id
636 * @param {WasmApiBitcoinAddressesCreationPayload} bitcoin_addresses
637 * @returns {Promise<WasmApiWalletBitcoinAddresses>}
639 addBitcoinAddresses(wallet_id: string, wallet_account_id: string, bitcoin_addresses: WasmApiBitcoinAddressesCreationPayload): Promise<WasmApiWalletBitcoinAddresses>;
641 * @param {string} wallet_id
642 * @param {string} wallet_account_id
643 * @param {string} wallet_account_bitcoin_address_id
644 * @param {WasmApiBitcoinAddressCreationPayload} bitcoin_address
645 * @returns {Promise<WasmApiWalletBitcoinAddressData>}
647 updateBitcoinAddress(wallet_id: string, wallet_account_id: string, wallet_account_bitcoin_address_id: string, bitcoin_address: WasmApiBitcoinAddressCreationPayload): Promise<WasmApiWalletBitcoinAddressData>;
649 export class WasmBlockchainClient {
652 * Generates a Mnemonic with a random entropy based on the given word
654 * @param {WasmProtonWalletApiClient} proton_api_client
656 constructor(proton_api_client: WasmProtonWalletApiClient);
658 * @returns {Promise<Map<string, number>>}
660 getFeesEstimation(): Promise<Map<string, number>>;
662 * @returns {Promise<WasmMinimumFees>}
664 getMininumFees(): Promise<WasmMinimumFees>;
666 * @param {WasmAccount} account
667 * @param {number | undefined} [stop_gap]
668 * @returns {Promise<void>}
670 fullSync(account: WasmAccount, stop_gap?: number): Promise<void>;
672 * @param {WasmAccount} account
673 * @returns {Promise<void>}
675 partialSync(account: WasmAccount): Promise<void>;
677 * @param {WasmAccount} account
678 * @returns {Promise<boolean>}
680 shouldSync(account: WasmAccount): Promise<boolean>;
682 * @param {WasmPsbt} psbt
683 * @param {string} wallet_id
684 * @param {string} wallet_account_id
685 * @param {WasmTransactionData} transaction_data
686 * @param {WasmEmailIntegrationData | undefined} [email_integration]
687 * @returns {Promise<string>}
689 broadcastPsbt(psbt: WasmPsbt, wallet_id: string, wallet_account_id: string, transaction_data: WasmTransactionData, email_integration?: WasmEmailIntegrationData): Promise<string>;
691 export class WasmCountriesAndProviderTupple {
693 0: WasmGatewayProvider;
696 export class WasmCountriesByProvider {
698 data: (WasmCountriesAndProviderTupple)[];
700 export class WasmDerivationPath {
703 * @param {string} path
705 constructor(path: string);
707 * @param {WasmScriptType} script_type
708 * @param {WasmNetwork} network
709 * @param {number} account_index
710 * @returns {WasmDerivationPath}
712 static fromParts(script_type: WasmScriptType, network: WasmNetwork, account_index: number): WasmDerivationPath;
714 * @param {string} str
715 * @returns {WasmDerivationPath}
717 static fromString(str: string): WasmDerivationPath;
723 export class WasmDetailledTxIn {
725 previous_output?: WasmTxOut;
726 script_sig: WasmScript;
727 sequence: WasmSequence;
729 export class WasmDiscoveredAccount {
733 2: WasmDerivationPath;
735 export class WasmDiscoveredAccounts {
737 data: (WasmDiscoveredAccount)[];
739 export class WasmEmailIntegrationClient {
742 * @param {string} email
743 * @returns {Promise<WasmApiWalletBitcoinAddressLookupData>}
745 lookupBitcoinAddress(email: string): Promise<WasmApiWalletBitcoinAddressLookupData>;
747 * @param {string} email
748 * @returns {Promise<void>}
750 createBitcoinAddressesRequest(email: string): Promise<void>;
752 export class WasmExchangeRateClient {
755 * @param {WasmFiatCurrencySymbol} fiat
756 * @param {bigint | undefined} [time]
757 * @returns {Promise<WasmApiExchangeRateData>}
759 getExchangeRate(fiat: WasmFiatCurrencySymbol, time?: bigint): Promise<WasmApiExchangeRateData>;
761 * @returns {Promise<WasmApiFiatCurrencies>}
763 getAllFiatCurrencies(): Promise<WasmApiFiatCurrencies>;
765 export class WasmFiatCurrenciesAndProviderTupple {
767 0: WasmGatewayProvider;
768 1: WasmFiatCurrencies;
770 export class WasmFiatCurrenciesByProvider {
772 data: (WasmFiatCurrenciesAndProviderTupple)[];
774 export class WasmInviteClient {
777 * @param {string} invitee_email
778 * @param {string} inviter_address_id
779 * @returns {Promise<void>}
781 sendNewcomerInvite(invitee_email: string, inviter_address_id: string): Promise<void>;
783 * @param {string} invitee_email
784 * @param {WasmInviteNotificationType} invite_notification_type
785 * @param {string} inviter_address_id
786 * @returns {Promise<number>}
788 checkInviteStatus(invitee_email: string, invite_notification_type: WasmInviteNotificationType, inviter_address_id: string): Promise<number>;
790 * @param {string} invitee_email
791 * @param {string} inviter_address_id
792 * @returns {Promise<void>}
794 sendEmailIntegrationInvite(invitee_email: string, inviter_address_id: string): Promise<void>;
796 * @returns {Promise<WasmRemainingMonthlyInvitations>}
798 getRemainingMonthlyInvitation(): Promise<WasmRemainingMonthlyInvitations>;
800 export class WasmLockTime {
803 * @param {number} height
804 * @returns {WasmLockTime}
806 static fromHeight(height: number): WasmLockTime;
808 * @param {number} seconds
809 * @returns {WasmLockTime}
811 static fromSeconds(seconds: number): WasmLockTime;
815 isBlockHeight(): boolean;
819 isBlockTime(): boolean;
823 toConsensusU32(): number;
825 export class WasmMigratedWalletAccountData {
827 Data: WasmMigratedWalletAccount;
829 export class WasmMigratedWalletAccounts {
833 * @param {WasmMigratedWalletAccount} account_data
835 push(account_data: WasmMigratedWalletAccount): void;
836 0: (WasmMigratedWalletAccountData)[];
838 export class WasmMigratedWalletTransactionData {
840 Data: WasmMigratedWalletTransaction;
842 export class WasmMigratedWalletTransactions {
846 * @param {WasmMigratedWalletTransaction} account_data
848 push(account_data: WasmMigratedWalletTransaction): void;
849 0: (WasmMigratedWalletTransactionData)[];
851 export class WasmMinimumFees {
853 MinimumBroadcastFee: number;
854 MinimumIncrementalFee: number;
856 export class WasmMnemonic {
859 * Generates a Mnemonic with a random entropy based on the given word
861 * @param {WasmWordCount} word_count
863 constructor(word_count: WasmWordCount);
865 * Parse a Mnemonic with the given string.
866 * @param {string} mnemonic
867 * @returns {WasmMnemonic}
869 static fromString(mnemonic: string): WasmMnemonic;
871 * Returns the Mnemonic as a string.
876 * @returns {(string)[]}
878 asWords(): (string)[];
880 export class WasmNetworkClient {
883 * @returns {Promise<WasmNetwork>}
885 getNetwork(): Promise<WasmNetwork>;
887 export class WasmOnchainPaymentLink {
895 * Serialised Outpoint under the form <txid>:<index>
897 export class WasmOutPoint {
900 * @param {string} str
901 * @returns {WasmOutPoint}
903 static fromString(str: string): WasmOutPoint;
906 export class WasmPaymentGatewayClient {
909 * @returns {Promise<WasmCountriesByProvider>}
911 getCountries(): Promise<WasmCountriesByProvider>;
913 * @returns {Promise<WasmFiatCurrenciesByProvider>}
915 getFiatCurrencies(): Promise<WasmFiatCurrenciesByProvider>;
917 * @param {string} fiat_currency
918 * @returns {Promise<WasmPaymentMethodsByProvider>}
920 getPaymentMethods(fiat_currency: string): Promise<WasmPaymentMethodsByProvider>;
922 * @param {number} amount
923 * @param {string} fiat_currency
924 * @param {WasmPaymentMethod | undefined} [payment_method]
925 * @param {WasmGatewayProvider | undefined} [provider]
926 * @returns {Promise<WasmQuotesByProvider>}
928 getQuotes(amount: number, fiat_currency: string, payment_method?: WasmPaymentMethod, provider?: WasmGatewayProvider): Promise<WasmQuotesByProvider>;
930 * @param {string} amount
931 * @param {string} btc_address
932 * @param {string} fiat_currency
933 * @param {WasmPaymentMethod} payment_method
934 * @param {WasmGatewayProvider} provider
935 * @param {string} order_id
936 * @returns {Promise<string>}
938 createOnRampCheckout(amount: string, btc_address: string, fiat_currency: string, payment_method: WasmPaymentMethod, provider: WasmGatewayProvider, order_id: string): Promise<string>;
940 * @param {string} url
941 * @param {WasmGatewayProvider} provider
942 * @returns {Promise<string>}
944 signUrl(url: string, provider: WasmGatewayProvider): Promise<string>;
946 * @param {WasmGatewayProvider} provider
947 * @returns {Promise<string>}
949 getPublicApiKey(provider: WasmGatewayProvider): Promise<string>;
951 * @param {number} amount
952 * @param {string} address
953 * @param {string} fiat_currency
954 * @param {WasmPaymentMethod} payment_method
955 * @param {WasmGatewayProvider} provider
958 getCheckoutIframeSrc(amount: number, address: string, fiat_currency: string, payment_method: WasmPaymentMethod, provider: WasmGatewayProvider): string;
960 export class WasmPaymentLink {
971 * @param {string} str
972 * @param {WasmNetwork} network
973 * @returns {WasmPaymentLink}
975 static tryParse(str: string, network: WasmNetwork): WasmPaymentLink;
977 * @returns {WasmPaymentLinkKind}
979 getKind(): WasmPaymentLinkKind;
981 * @returns {WasmOnchainPaymentLink}
983 assumeOnchain(): WasmOnchainPaymentLink;
985 export class WasmPaymentMethodsAndProviderTupple {
987 0: WasmGatewayProvider;
988 1: WasmPaymentMethods;
990 export class WasmPaymentMethodsByProvider {
992 data: (WasmPaymentMethodsAndProviderTupple)[];
994 export class WasmPriceGraphClient {
997 * @param {WasmFiatCurrencySymbol} fiat_currency
998 * @param {WasmTimeframe} timeframe
999 * @returns {Promise<WasmWrappedPriceGraph>}
1001 getGraphData(fiat_currency: WasmFiatCurrencySymbol, timeframe: WasmTimeframe): Promise<WasmWrappedPriceGraph>;
1003 export class WasmProtonWalletApiClient {
1006 * @param {string} app_version
1007 * @param {string} user_agent
1008 * @param {string | undefined} [uid_str]
1009 * @param {string | undefined} [origin]
1010 * @param {string | undefined} [url_prefix]
1012 constructor(app_version: string, user_agent: string, uid_str?: string, origin?: string, url_prefix?: string);
1014 * @returns {WasmApiClients}
1016 clients(): WasmApiClients;
1018 export class WasmPsbt {
1021 * @param {WasmAccount} wasm_account
1022 * @param {WasmNetwork} network
1023 * @returns {Promise<WasmPsbt>}
1025 sign(wasm_account: WasmAccount, network: WasmNetwork): Promise<WasmPsbt>;
1029 computeTxVbytes(): bigint;
1030 recipients: (WasmPsbtRecipient)[];
1033 export class WasmPsbtAndTxBuilder {
1038 export class WasmPsbtRecipient {
1043 export class WasmQuotesAndProviderTupple {
1045 0: WasmGatewayProvider;
1048 export class WasmQuotesByProvider {
1050 data: (WasmQuotesAndProviderTupple)[];
1052 export class WasmRecipient {
1058 export class WasmRemainingMonthlyInvitations {
1063 export class WasmScript {
1066 * @param {WasmNetwork} network
1067 * @returns {WasmAddress}
1069 toAddress(network: WasmNetwork): WasmAddress;
1072 export class WasmSequence {
1076 export class WasmSettingsClient {
1079 * @returns {Promise<WasmUserSettingsData>}
1081 getUserSettings(): Promise<WasmUserSettingsData>;
1083 * @param {WasmBitcoinUnit} symbol
1084 * @returns {Promise<WasmUserSettingsData>}
1086 setBitcoinUnit(symbol: WasmBitcoinUnit): Promise<WasmUserSettingsData>;
1088 * @param {WasmFiatCurrencySymbol} symbol
1089 * @returns {Promise<WasmUserSettingsData>}
1091 setFiatCurrency(symbol: WasmFiatCurrencySymbol): Promise<WasmUserSettingsData>;
1093 * @param {bigint} amount
1094 * @returns {Promise<WasmUserSettingsData>}
1096 setTwoFaThreshold(amount: bigint): Promise<WasmUserSettingsData>;
1098 * @param {boolean} hide_empty_used_addresses
1099 * @returns {Promise<WasmUserSettingsData>}
1101 setHideEmptyUsedAddresses(hide_empty_used_addresses: boolean): Promise<WasmUserSettingsData>;
1103 * @param {WasmUserReceiveNotificationEmailTypes} email_type
1104 * @param {boolean} is_enable
1105 * @returns {Promise<WasmUserSettingsData>}
1107 setReceiveNotificationEmail(email_type: WasmUserReceiveNotificationEmailTypes, is_enable: boolean): Promise<WasmUserSettingsData>;
1109 * @returns {Promise<WasmUserSettingsData>}
1111 acceptTermsAndConditions(): Promise<WasmUserSettingsData>;
1113 * @returns {Promise<number>}
1115 getUserWalletEligibility(): Promise<number>;
1117 export class WasmTransaction {
1120 * @param {WasmPsbt} value
1121 * @returns {WasmTransaction}
1123 static fromPsbt(value: WasmPsbt): WasmTransaction;
1125 export class WasmTransactionDetailsArray {
1127 0: (WasmTransactionDetailsData)[];
1129 export class WasmTransactionDetailsData {
1131 Data: WasmTransactionDetails;
1133 export class WasmTxBuilder {
1137 * @param {WasmAccount} account
1138 * @returns {WasmTxBuilder}
1140 setAccount(account: WasmAccount): WasmTxBuilder;
1142 * @returns {Promise<WasmTxBuilder>}
1144 constrainRecipientAmounts(): Promise<WasmTxBuilder>;
1146 * @returns {WasmTxBuilder}
1148 clearRecipients(): WasmTxBuilder;
1150 * @param {string | undefined} [address_str]
1151 * @param {bigint | undefined} [amount]
1152 * @returns {WasmTxBuilder}
1154 addRecipient(address_str?: string, amount?: bigint): WasmTxBuilder;
1156 * @param {number} index
1157 * @returns {WasmTxBuilder}
1159 removeRecipient(index: number): WasmTxBuilder;
1161 * @param {number} index
1162 * @param {string | undefined} [address_str]
1163 * @param {bigint | undefined} [amount]
1164 * @returns {WasmTxBuilder}
1166 updateRecipient(index: number, address_str?: string, amount?: bigint): WasmTxBuilder;
1168 * @param {number} index
1169 * @returns {Promise<WasmTxBuilder>}
1171 updateRecipientAmountToMax(index: number): Promise<WasmTxBuilder>;
1173 * @returns {(WasmRecipient)[]}
1175 getRecipients(): (WasmRecipient)[];
1180 * @param {WasmOutPoint} outpoint
1181 * @returns {WasmTxBuilder}
1183 addUtxoToSpend(outpoint: WasmOutPoint): WasmTxBuilder;
1185 * @param {WasmOutPoint} outpoint
1186 * @returns {WasmTxBuilder}
1188 removeUtxoToSpend(outpoint: WasmOutPoint): WasmTxBuilder;
1190 * @returns {WasmTxBuilder}
1192 clearUtxosToSpend(): WasmTxBuilder;
1194 * @returns {(WasmOutPoint)[]}
1196 getUtxosToSpend(): (WasmOutPoint)[];
1199 * * Coin selection enforcement
1201 * @param {WasmCoinSelection} coin_selection
1202 * @returns {WasmTxBuilder}
1204 setCoinSelection(coin_selection: WasmCoinSelection): WasmTxBuilder;
1206 * @returns {WasmCoinSelection}
1208 getCoinSelection(): WasmCoinSelection;
1213 * @returns {WasmTxBuilder}
1215 enableRbf(): WasmTxBuilder;
1217 * @returns {WasmTxBuilder}
1219 disableRbf(): WasmTxBuilder;
1221 * @returns {boolean}
1223 getRbfEnabled(): boolean;
1228 * @param {WasmChangeSpendPolicy} change_policy
1229 * @returns {WasmTxBuilder}
1231 setChangePolicy(change_policy: WasmChangeSpendPolicy): WasmTxBuilder;
1233 * @returns {WasmChangeSpendPolicy}
1235 getChangePolicy(): WasmChangeSpendPolicy;
1240 * @param {bigint} sat_per_vb
1241 * @returns {WasmTxBuilder}
1243 setFeeRate(sat_per_vb: bigint): WasmTxBuilder;
1245 * @returns {bigint | undefined}
1247 getFeeRate(): bigint | undefined;
1252 * @param {WasmLockTime} locktime
1253 * @returns {WasmTxBuilder}
1255 addLocktime(locktime: WasmLockTime): WasmTxBuilder;
1257 * @returns {WasmTxBuilder}
1259 removeLocktime(): WasmTxBuilder;
1261 * @returns {WasmLockTime | undefined}
1263 getLocktime(): WasmLockTime | undefined;
1268 * @param {WasmNetwork} network
1269 * @returns {Promise<WasmPsbt>}
1271 createPsbt(network: WasmNetwork): Promise<WasmPsbt>;
1273 * @param {WasmNetwork} network
1274 * @param {boolean | undefined} [allow_dust]
1275 * @returns {Promise<WasmPsbt>}
1277 createDraftPsbt(network: WasmNetwork, allow_dust?: boolean): Promise<WasmPsbt>;
1279 export class WasmTxOut {
1283 script_pubkey: WasmScript;
1286 export class WasmUserSettingsData {
1288 0: WasmUserSettings;
1290 export class WasmUtxo {
1293 keychain: WasmKeychainKind;
1294 outpoint: WasmOutPoint;
1295 script_pubkey: WasmScript;
1298 export class WasmUtxoArray {
1302 export class WasmWallet {
1305 * @param {WasmNetwork} network
1306 * @param {string} bip39_mnemonic
1307 * @param {string | undefined} [bip38_passphrase]
1309 constructor(network: WasmNetwork, bip39_mnemonic: string, bip38_passphrase?: string);
1311 * @param {number} script_type
1312 * @param {string} derivation_path
1313 * @returns {WasmAccount}
1315 addAccount(script_type: number, derivation_path: string): WasmAccount;
1317 * @param {WasmProtonWalletApiClient} api_client
1318 * @returns {Promise<WasmDiscoveredAccounts>}
1320 discoverAccounts(api_client: WasmProtonWalletApiClient): Promise<WasmDiscoveredAccounts>;
1322 * @param {string} derivation_path
1323 * @returns {WasmAccount | undefined}
1325 getAccount(derivation_path: string): WasmAccount | undefined;
1327 * @returns {Promise<WasmBalanceWrapper>}
1329 getBalance(): Promise<WasmBalanceWrapper>;
1331 * @param {WasmPagination | undefined} [pagination]
1332 * @param {WasmSortOrder | undefined} [sort]
1333 * @returns {Promise<WasmTransactionDetailsArray>}
1335 getTransactions(pagination?: WasmPagination, sort?: WasmSortOrder): Promise<WasmTransactionDetailsArray>;
1337 * @param {WasmDerivationPath} account_key
1338 * @param {string} txid
1339 * @returns {Promise<WasmTransactionDetailsData>}
1341 getTransaction(account_key: WasmDerivationPath, txid: string): Promise<WasmTransactionDetailsData>;
1345 getFingerprint(): string;
1348 export class WasmWalletAccountAddressData {
1350 Data: WasmApiEmailAddress;
1352 export class WasmWalletAccountData {
1354 Data: WasmApiWalletAccount;
1356 export class WasmWalletClient {
1359 * @returns {Promise<WasmApiWalletsData>}
1361 getWallets(): Promise<WasmApiWalletsData>;
1363 * @param {string} name
1364 * @param {boolean} is_imported
1365 * @param {number} wallet_type
1366 * @param {boolean} has_passphrase
1367 * @param {string} user_key_id
1368 * @param {string} wallet_key
1369 * @param {string} wallet_key_signature
1370 * @param {string | undefined} [mnemonic]
1371 * @param {string | undefined} [fingerprint]
1372 * @param {string | undefined} [public_key]
1373 * @param {boolean | undefined} [is_auto_created]
1374 * @returns {Promise<WasmApiWalletData>}
1376 createWallet(name: string, is_imported: boolean, wallet_type: number, has_passphrase: boolean, user_key_id: string, wallet_key: string, wallet_key_signature: string, mnemonic?: string, fingerprint?: string, public_key?: string, is_auto_created?: boolean): Promise<WasmApiWalletData>;
1378 * @param {string} wallet_id
1379 * @param {WasmMigratedWallet} migrated_wallet
1380 * @param {WasmMigratedWalletAccounts} migrated_wallet_accounts
1381 * @param {WasmMigratedWalletTransactions} migrated_wallet_transactions
1382 * @returns {Promise<void>}
1384 migrate(wallet_id: string, migrated_wallet: WasmMigratedWallet, migrated_wallet_accounts: WasmMigratedWalletAccounts, migrated_wallet_transactions: WasmMigratedWalletTransactions): Promise<void>;
1386 * @param {string} wallet_id
1387 * @param {string} name
1388 * @returns {Promise<void>}
1390 updateWalletName(wallet_id: string, name: string): Promise<void>;
1392 * @param {string} wallet_id
1393 * @returns {Promise<void>}
1395 disableShowWalletRecovery(wallet_id: string): Promise<void>;
1397 * @param {string} wallet_id
1398 * @returns {Promise<void>}
1400 deleteWallet(wallet_id: string): Promise<void>;
1402 * @param {string} wallet_id
1403 * @returns {Promise<WasmApiWalletAccounts>}
1405 getWalletAccounts(wallet_id: string): Promise<WasmApiWalletAccounts>;
1407 * @param {string} wallet_id
1408 * @param {string} wallet_account_id
1409 * @returns {Promise<WasmApiWalletAccountAddresses>}
1411 getWalletAccountAddresses(wallet_id: string, wallet_account_id: string): Promise<WasmApiWalletAccountAddresses>;
1413 * @param {string} wallet_id
1414 * @param {WasmDerivationPath} derivation_path
1415 * @param {string} label
1416 * @param {WasmScriptType} script_type
1417 * @returns {Promise<WasmWalletAccountData>}
1419 createWalletAccount(wallet_id: string, derivation_path: WasmDerivationPath, label: string, script_type: WasmScriptType): Promise<WasmWalletAccountData>;
1421 * @param {string} wallet_id
1422 * @param {string} wallet_account_id
1423 * @param {WasmFiatCurrencySymbol} symbol
1424 * @returns {Promise<WasmWalletAccountData>}
1426 updateWalletAccountFiatCurrency(wallet_id: string, wallet_account_id: string, symbol: WasmFiatCurrencySymbol): Promise<WasmWalletAccountData>;
1428 * @param {string} wallet_id
1429 * @param {string} wallet_account_id
1430 * @param {string} label
1431 * @returns {Promise<WasmWalletAccountData>}
1433 updateWalletAccountLabel(wallet_id: string, wallet_account_id: string, label: string): Promise<WasmWalletAccountData>;
1435 * @param {string} wallet_id
1436 * @param {(string)[]} wallet_account_ids
1437 * @returns {Promise<WasmApiWalletAccounts>}
1439 updateWalletAccountsOrder(wallet_id: string, wallet_account_ids: (string)[]): Promise<WasmApiWalletAccounts>;
1441 * @param {string} wallet_id
1442 * @param {string} wallet_account_id
1443 * @param {number} last_used_index
1444 * @returns {Promise<WasmWalletAccountData>}
1446 updateWalletAccountLastUsedIndex(wallet_id: string, wallet_account_id: string, last_used_index: number): Promise<WasmWalletAccountData>;
1448 * @param {string} wallet_id
1449 * @param {string} wallet_account_id
1450 * @param {string} email_address_id
1451 * @returns {Promise<WasmWalletAccountData>}
1453 addEmailAddress(wallet_id: string, wallet_account_id: string, email_address_id: string): Promise<WasmWalletAccountData>;
1455 * @param {string} wallet_id
1456 * @param {string} wallet_account_id
1457 * @param {string} email_address_id
1458 * @returns {Promise<WasmWalletAccountData>}
1460 removeEmailAddress(wallet_id: string, wallet_account_id: string, email_address_id: string): Promise<WasmWalletAccountData>;
1462 * @param {string} wallet_id
1463 * @param {string} wallet_account_id
1464 * @returns {Promise<void>}
1466 deleteWalletAccount(wallet_id: string, wallet_account_id: string): Promise<void>;
1468 * @param {string} wallet_id
1469 * @param {string | undefined} [wallet_account_id]
1470 * @param {(string)[] | undefined} [hashed_txids]
1471 * @returns {Promise<WasmApiWalletTransactions>}
1473 getWalletTransactions(wallet_id: string, wallet_account_id?: string, hashed_txids?: (string)[]): Promise<WasmApiWalletTransactions>;
1475 * @param {string} wallet_id
1476 * @param {string | undefined} [wallet_account_id]
1477 * @returns {Promise<WasmApiWalletTransactions>}
1479 getWalletTransactionsToHash(wallet_id: string, wallet_account_id?: string): Promise<WasmApiWalletTransactions>;
1481 * @param {string} wallet_id
1482 * @param {string} wallet_account_id
1483 * @param {WasmCreateWalletTransactionPayload} payload
1484 * @returns {Promise<WasmApiWalletTransactionData>}
1486 createWalletTransaction(wallet_id: string, wallet_account_id: string, payload: WasmCreateWalletTransactionPayload): Promise<WasmApiWalletTransactionData>;
1488 * @param {string} wallet_id
1489 * @param {string} wallet_account_id
1490 * @param {string} wallet_transaction_id
1491 * @param {string} label
1492 * @returns {Promise<WasmApiWalletTransactionData>}
1494 updateWalletTransactionLabel(wallet_id: string, wallet_account_id: string, wallet_transaction_id: string, label: string): Promise<WasmApiWalletTransactionData>;
1496 * @param {string} wallet_id
1497 * @param {string} wallet_account_id
1498 * @param {string} wallet_transaction_id
1499 * @param {string} hash_txid
1500 * @returns {Promise<WasmApiWalletTransactionData>}
1502 updateWalletTransactionHashedTxId(wallet_id: string, wallet_account_id: string, wallet_transaction_id: string, hash_txid: string): Promise<WasmApiWalletTransactionData>;
1504 * @param {string} wallet_id
1505 * @param {string} wallet_account_id
1506 * @param {string} wallet_transaction_id
1507 * @param {string} sender
1508 * @returns {Promise<WasmApiWalletTransactionData>}
1510 updateExternalWalletTransactionSender(wallet_id: string, wallet_account_id: string, wallet_transaction_id: string, sender: string): Promise<WasmApiWalletTransactionData>;
1512 * @param {string} wallet_id
1513 * @param {string} wallet_account_id
1514 * @param {string} wallet_transaction_id
1515 * @param {WasmWalletTransactionFlag} flag
1516 * @returns {Promise<WasmApiWalletTransactionData>}
1518 setWalletTransactionFlag(wallet_id: string, wallet_account_id: string, wallet_transaction_id: string, flag: WasmWalletTransactionFlag): Promise<WasmApiWalletTransactionData>;
1520 * @param {string} wallet_id
1521 * @param {string} wallet_account_id
1522 * @param {string} wallet_transaction_id
1523 * @param {WasmWalletTransactionFlag} flag
1524 * @returns {Promise<WasmApiWalletTransactionData>}
1526 deleteWalletTransactionFlag(wallet_id: string, wallet_account_id: string, wallet_transaction_id: string, flag: WasmWalletTransactionFlag): Promise<WasmApiWalletTransactionData>;
1528 * @param {string} wallet_id
1529 * @param {string} wallet_account_id
1530 * @param {string} wallet_transaction_id
1531 * @returns {Promise<void>}
1533 deleteWalletTransaction(wallet_id: string, wallet_account_id: string, wallet_transaction_id: string): Promise<void>;
1535 export class WasmWrappedPriceGraph {
1537 data: WasmPriceGraph;