// This file was autogenerated by some hot garbage in the
// `uniffi-bindgen-react-native` crate. Trust me, you don't want to mess with
// it!
#include "breez_sdk_spark.hpp"

#include "UniffiJsiTypes.h"
#include <iostream>
#include <map>
#include <stdexcept>
#include <thread>
#include <utility>

namespace react = facebook::react;
namespace jsi = facebook::jsi;

// Calling into Rust.
extern "C" {
typedef void (*UniffiRustFutureContinuationCallback)(uint64_t data,
                                                     int8_t poll_result);
typedef void (*UniffiForeignFutureFree)(uint64_t handle);
typedef void (*UniffiCallbackInterfaceFree)(uint64_t handle);
typedef struct UniffiForeignFuture {
  uint64_t handle;
  UniffiForeignFutureFree free;
} UniffiForeignFuture;
typedef struct UniffiForeignFutureStructU8 {
  uint8_t return_value;
  RustCallStatus call_status;
} UniffiForeignFutureStructU8;
typedef void (*UniffiForeignFutureCompleteU8)(
    uint64_t callback_data, UniffiForeignFutureStructU8 result);
typedef struct UniffiForeignFutureStructI8 {
  int8_t return_value;
  RustCallStatus call_status;
} UniffiForeignFutureStructI8;
typedef void (*UniffiForeignFutureCompleteI8)(
    uint64_t callback_data, UniffiForeignFutureStructI8 result);
typedef struct UniffiForeignFutureStructU16 {
  uint16_t return_value;
  RustCallStatus call_status;
} UniffiForeignFutureStructU16;
typedef void (*UniffiForeignFutureCompleteU16)(
    uint64_t callback_data, UniffiForeignFutureStructU16 result);
typedef struct UniffiForeignFutureStructI16 {
  int16_t return_value;
  RustCallStatus call_status;
} UniffiForeignFutureStructI16;
typedef void (*UniffiForeignFutureCompleteI16)(
    uint64_t callback_data, UniffiForeignFutureStructI16 result);
typedef struct UniffiForeignFutureStructU32 {
  uint32_t return_value;
  RustCallStatus call_status;
} UniffiForeignFutureStructU32;
typedef void (*UniffiForeignFutureCompleteU32)(
    uint64_t callback_data, UniffiForeignFutureStructU32 result);
typedef struct UniffiForeignFutureStructI32 {
  int32_t return_value;
  RustCallStatus call_status;
} UniffiForeignFutureStructI32;
typedef void (*UniffiForeignFutureCompleteI32)(
    uint64_t callback_data, UniffiForeignFutureStructI32 result);
typedef struct UniffiForeignFutureStructU64 {
  uint64_t return_value;
  RustCallStatus call_status;
} UniffiForeignFutureStructU64;
typedef void (*UniffiForeignFutureCompleteU64)(
    uint64_t callback_data, UniffiForeignFutureStructU64 result);
typedef struct UniffiForeignFutureStructI64 {
  int64_t return_value;
  RustCallStatus call_status;
} UniffiForeignFutureStructI64;
typedef void (*UniffiForeignFutureCompleteI64)(
    uint64_t callback_data, UniffiForeignFutureStructI64 result);
typedef struct UniffiForeignFutureStructF32 {
  float return_value;
  RustCallStatus call_status;
} UniffiForeignFutureStructF32;
typedef void (*UniffiForeignFutureCompleteF32)(
    uint64_t callback_data, UniffiForeignFutureStructF32 result);
typedef struct UniffiForeignFutureStructF64 {
  double return_value;
  RustCallStatus call_status;
} UniffiForeignFutureStructF64;
typedef void (*UniffiForeignFutureCompleteF64)(
    uint64_t callback_data, UniffiForeignFutureStructF64 result);
typedef struct UniffiForeignFutureStructPointer {
  void *return_value;
  RustCallStatus call_status;
} UniffiForeignFutureStructPointer;
typedef void (*UniffiForeignFutureCompletePointer)(
    uint64_t callback_data, UniffiForeignFutureStructPointer result);
typedef struct UniffiForeignFutureStructRustBuffer {
  RustBuffer return_value;
  RustCallStatus call_status;
} UniffiForeignFutureStructRustBuffer;
typedef void (*UniffiForeignFutureCompleteRustBuffer)(
    uint64_t callback_data, UniffiForeignFutureStructRustBuffer result);
typedef struct UniffiForeignFutureStructVoid {
  RustCallStatus call_status;
} UniffiForeignFutureStructVoid;
typedef void (*UniffiForeignFutureCompleteVoid)(
    uint64_t callback_data, UniffiForeignFutureStructVoid result);
typedef void (*UniffiCallbackInterfaceEventListenerMethod0)(
    uint64_t uniffi_handle, RustBuffer event,
    UniffiForeignFutureCompleteVoid uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceLoggerMethod0)(
    uint64_t uniffi_handle, RustBuffer l, void *uniffi_out_return,
    RustCallStatus *rust_call_status);
typedef void (*UniffiCallbackInterfaceBitcoinChainServiceMethod0)(
    uint64_t uniffi_handle, RustBuffer address,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceBitcoinChainServiceMethod1)(
    uint64_t uniffi_handle, RustBuffer address,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceBitcoinChainServiceMethod2)(
    uint64_t uniffi_handle, RustBuffer txid,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceBitcoinChainServiceMethod3)(
    uint64_t uniffi_handle,
    UniffiForeignFutureCompleteU32 uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceBitcoinChainServiceMethod4)(
    uint64_t uniffi_handle, RustBuffer txid,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceBitcoinChainServiceMethod5)(
    uint64_t uniffi_handle, RustBuffer txid, uint32_t vout,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceBitcoinChainServiceMethod6)(
    uint64_t uniffi_handle, RustBuffer tx,
    UniffiForeignFutureCompleteVoid uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceBitcoinChainServiceMethod7)(
    uint64_t uniffi_handle,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceCpfpSignerMethod0)(
    uint64_t uniffi_handle, RustBuffer psbt_bytes,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalBreezSignerMethod0)(
    uint64_t uniffi_handle, RustBuffer path,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalBreezSignerMethod1)(
    uint64_t uniffi_handle, RustBuffer message, RustBuffer path,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalBreezSignerMethod2)(
    uint64_t uniffi_handle, RustBuffer message, RustBuffer path,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalBreezSignerMethod3)(
    uint64_t uniffi_handle, RustBuffer message, RustBuffer path,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalBreezSignerMethod4)(
    uint64_t uniffi_handle, RustBuffer message, RustBuffer path,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalBreezSignerMethod5)(
    uint64_t uniffi_handle, RustBuffer hash, RustBuffer path,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalBreezSignerMethod6)(
    uint64_t uniffi_handle, RustBuffer message, RustBuffer path,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalSigningSignerMethod0)(
    uint64_t uniffi_handle, RustBuffer path,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalSigningSignerMethod1)(
    uint64_t uniffi_handle, RustBuffer message, RustBuffer path,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalSigningSignerMethod2)(
    uint64_t uniffi_handle, RustBuffer message, RustBuffer path,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalSigningSignerMethod3)(
    uint64_t uniffi_handle, RustBuffer hash, RustBuffer path,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalSparkSignerMethod0)(
    uint64_t uniffi_handle,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalSparkSignerMethod1)(
    uint64_t uniffi_handle, RustBuffer leaf_id,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalSparkSignerMethod2)(
    uint64_t uniffi_handle, int8_t *uniffi_out_return,
    RustCallStatus *rust_call_status);
typedef void (*UniffiCallbackInterfaceExternalSparkSignerMethod3)(
    uint64_t uniffi_handle, uint32_t index,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalSparkSignerMethod4)(
    uint64_t uniffi_handle, RustBuffer challenge,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalSparkSignerMethod5)(
    uint64_t uniffi_handle, RustBuffer message,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalSparkSignerMethod6)(
    uint64_t uniffi_handle, RustBuffer leaf_id, RustBuffer sighash,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalSparkSignerMethod7)(
    uint64_t uniffi_handle, RustBuffer jobs,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalSparkSignerMethod8)(
    uint64_t uniffi_handle, RustBuffer request,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalSparkSignerMethod9)(
    uint64_t uniffi_handle, RustBuffer request,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalSparkSignerMethod10)(
    uint64_t uniffi_handle, RustBuffer request,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalSparkSignerMethod11)(
    uint64_t uniffi_handle, RustBuffer request,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalSparkSignerMethod12)(
    uint64_t uniffi_handle, RustBuffer request,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalSparkSignerMethod13)(
    uint64_t uniffi_handle, RustBuffer request,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalSparkSignerMethod14)(
    uint64_t uniffi_handle, RustBuffer request,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalSparkSignerMethod15)(
    uint64_t uniffi_handle, RustBuffer request,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceExternalSparkSignerMethod16)(
    uint64_t uniffi_handle, RustBuffer request,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceFiatServiceMethod0)(
    uint64_t uniffi_handle,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceFiatServiceMethod1)(
    uint64_t uniffi_handle,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfacePaymentObserverMethod0)(
    uint64_t uniffi_handle, RustBuffer payments,
    UniffiForeignFutureCompleteVoid uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfacePaymentObserverMethod1)(
    uint64_t uniffi_handle, RustBuffer updates,
    UniffiForeignFutureCompleteVoid uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfacePrfProviderMethod0)(
    uint64_t uniffi_handle, RustBuffer request,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfacePrfProviderMethod1)(
    uint64_t uniffi_handle,
    UniffiForeignFutureCompleteI8 uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfacePrfProviderMethod2)(
    uint64_t uniffi_handle, RustBuffer exclude_credentials, RustBuffer salts,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfacePrfProviderMethod3)(
    uint64_t uniffi_handle,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceRestClientMethod0)(
    uint64_t uniffi_handle, RustBuffer url, RustBuffer headers,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceRestClientMethod1)(
    uint64_t uniffi_handle, RustBuffer url, RustBuffer headers, RustBuffer body,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceRestClientMethod2)(
    uint64_t uniffi_handle, RustBuffer url, RustBuffer headers, RustBuffer body,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceSessionStoreMethod0)(
    uint64_t uniffi_handle, RustBuffer service_identity_key,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceSessionStoreMethod1)(
    uint64_t uniffi_handle, RustBuffer service_identity_key, RustBuffer session,
    UniffiForeignFutureCompleteVoid uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod0)(
    uint64_t uniffi_handle, RustBuffer key,
    UniffiForeignFutureCompleteVoid uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod1)(
    uint64_t uniffi_handle, RustBuffer key,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod2)(
    uint64_t uniffi_handle, RustBuffer key, RustBuffer value,
    UniffiForeignFutureCompleteVoid uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod3)(
    uint64_t uniffi_handle, RustBuffer request,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod4)(
    uint64_t uniffi_handle, RustBuffer payment,
    UniffiForeignFutureCompleteI8 uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod5)(
    uint64_t uniffi_handle, RustBuffer payment_id, RustBuffer metadata,
    UniffiForeignFutureCompleteVoid uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod6)(
    uint64_t uniffi_handle, RustBuffer id,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod7)(
    uint64_t uniffi_handle, RustBuffer invoice,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod8)(
    uint64_t uniffi_handle, RustBuffer parent_payment_ids,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod9)(
    uint64_t uniffi_handle, RustBuffer txid, uint32_t vout,
    uint64_t amount_sats, int8_t is_mature,
    UniffiForeignFutureCompleteVoid uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod10)(
    uint64_t uniffi_handle, RustBuffer txid, uint32_t vout,
    UniffiForeignFutureCompleteVoid uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod11)(
    uint64_t uniffi_handle,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod12)(
    uint64_t uniffi_handle, RustBuffer txid, uint32_t vout, RustBuffer payload,
    UniffiForeignFutureCompleteVoid uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod13)(
    uint64_t uniffi_handle, RustBuffer metadata,
    UniffiForeignFutureCompleteVoid uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod14)(
    uint64_t uniffi_handle, RustBuffer request,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod15)(
    uint64_t uniffi_handle, RustBuffer id,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod16)(
    uint64_t uniffi_handle, RustBuffer contact,
    UniffiForeignFutureCompleteVoid uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod17)(
    uint64_t uniffi_handle, RustBuffer id,
    UniffiForeignFutureCompleteVoid uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod18)(
    uint64_t uniffi_handle, RustBuffer swap,
    UniffiForeignFutureCompleteVoid uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod19)(
    uint64_t uniffi_handle, RustBuffer provider, RustBuffer id,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod20)(
    uint64_t uniffi_handle, RustBuffer provider,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod21)(
    uint64_t uniffi_handle, RustBuffer record,
    UniffiForeignFutureCompleteU64 uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod22)(
    uint64_t uniffi_handle, RustBuffer record, uint64_t local_revision,
    UniffiForeignFutureCompleteVoid uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod23)(
    uint64_t uniffi_handle, uint32_t limit,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod24)(
    uint64_t uniffi_handle,
    UniffiForeignFutureCompleteU64 uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod25)(
    uint64_t uniffi_handle, RustBuffer records,
    UniffiForeignFutureCompleteVoid uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod26)(
    uint64_t uniffi_handle, RustBuffer record,
    UniffiForeignFutureCompleteVoid uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod27)(
    uint64_t uniffi_handle, uint32_t limit,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod28)(
    uint64_t uniffi_handle,
    UniffiForeignFutureCompleteRustBuffer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageMethod29)(
    uint64_t uniffi_handle, RustBuffer record,
    UniffiForeignFutureCompleteVoid uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef void (*UniffiCallbackInterfaceStorageBackendMethod0)(
    uint64_t uniffi_handle, RustBuffer network, RustBuffer identity,
    UniffiForeignFutureCompletePointer uniffi_future_callback,
    uint64_t uniffi_callback_data, UniffiForeignFuture *uniffi_out_return);
typedef struct UniffiVTableCallbackInterfaceEventListener {
  UniffiCallbackInterfaceEventListenerMethod0 on_event;
  UniffiCallbackInterfaceFree uniffi_free;
} UniffiVTableCallbackInterfaceEventListener;
typedef struct UniffiVTableCallbackInterfaceLogger {
  UniffiCallbackInterfaceLoggerMethod0 log;
  UniffiCallbackInterfaceFree uniffi_free;
} UniffiVTableCallbackInterfaceLogger;
typedef struct UniffiVTableCallbackInterfaceBitcoinChainService {
  UniffiCallbackInterfaceBitcoinChainServiceMethod0 get_address_utxos;
  UniffiCallbackInterfaceBitcoinChainServiceMethod1 get_address_txos;
  UniffiCallbackInterfaceBitcoinChainServiceMethod2 get_transaction_status;
  UniffiCallbackInterfaceBitcoinChainServiceMethod3 tip_height;
  UniffiCallbackInterfaceBitcoinChainServiceMethod4 get_transaction_hex;
  UniffiCallbackInterfaceBitcoinChainServiceMethod5 get_outspend;
  UniffiCallbackInterfaceBitcoinChainServiceMethod6 broadcast_transaction;
  UniffiCallbackInterfaceBitcoinChainServiceMethod7 recommended_fees;
  UniffiCallbackInterfaceFree uniffi_free;
} UniffiVTableCallbackInterfaceBitcoinChainService;
typedef struct UniffiVTableCallbackInterfaceCpfpSigner {
  UniffiCallbackInterfaceCpfpSignerMethod0 sign_psbt;
  UniffiCallbackInterfaceFree uniffi_free;
} UniffiVTableCallbackInterfaceCpfpSigner;
typedef struct UniffiVTableCallbackInterfaceExternalBreezSigner {
  UniffiCallbackInterfaceExternalBreezSignerMethod0 derive_public_key;
  UniffiCallbackInterfaceExternalBreezSignerMethod1 sign_ecdsa;
  UniffiCallbackInterfaceExternalBreezSignerMethod2 sign_ecdsa_recoverable;
  UniffiCallbackInterfaceExternalBreezSignerMethod3 encrypt_ecies;
  UniffiCallbackInterfaceExternalBreezSignerMethod4 decrypt_ecies;
  UniffiCallbackInterfaceExternalBreezSignerMethod5 sign_hash_schnorr;
  UniffiCallbackInterfaceExternalBreezSignerMethod6 hmac_sha256;
  UniffiCallbackInterfaceFree uniffi_free;
} UniffiVTableCallbackInterfaceExternalBreezSigner;
typedef struct UniffiVTableCallbackInterfaceExternalSigningSigner {
  UniffiCallbackInterfaceExternalSigningSignerMethod0 derive_public_key;
  UniffiCallbackInterfaceExternalSigningSignerMethod1 sign_ecdsa;
  UniffiCallbackInterfaceExternalSigningSignerMethod2 sign_ecdsa_recoverable;
  UniffiCallbackInterfaceExternalSigningSignerMethod3 sign_hash_schnorr;
  UniffiCallbackInterfaceFree uniffi_free;
} UniffiVTableCallbackInterfaceExternalSigningSigner;
typedef struct UniffiVTableCallbackInterfaceExternalSparkSigner {
  UniffiCallbackInterfaceExternalSparkSignerMethod0 get_identity_public_key;
  UniffiCallbackInterfaceExternalSparkSignerMethod1 get_public_key_for_leaf;
  UniffiCallbackInterfaceExternalSparkSignerMethod2 is_remote;
  UniffiCallbackInterfaceExternalSparkSignerMethod3
      get_static_deposit_public_key;
  UniffiCallbackInterfaceExternalSparkSignerMethod4
      sign_authentication_challenge;
  UniffiCallbackInterfaceExternalSparkSignerMethod5 sign_message;
  UniffiCallbackInterfaceExternalSparkSignerMethod6 sign_leaf_refund_spend;
  UniffiCallbackInterfaceExternalSparkSignerMethod7 sign_frost;
  UniffiCallbackInterfaceExternalSparkSignerMethod8 prepare_transfer;
  UniffiCallbackInterfaceExternalSparkSignerMethod9 prepare_claim;
  UniffiCallbackInterfaceExternalSparkSignerMethod10 prepare_lightning_receive;
  UniffiCallbackInterfaceExternalSparkSignerMethod11 prepare_static_deposit;
  UniffiCallbackInterfaceExternalSparkSignerMethod12
      start_static_deposit_refund;
  UniffiCallbackInterfaceExternalSparkSignerMethod13 sign_static_deposit_refund;
  UniffiCallbackInterfaceExternalSparkSignerMethod14 sign_spark_invoice;
  UniffiCallbackInterfaceExternalSparkSignerMethod15 prepare_token_transaction;
  UniffiCallbackInterfaceExternalSparkSignerMethod16
      prepare_static_deposit_claim;
  UniffiCallbackInterfaceFree uniffi_free;
} UniffiVTableCallbackInterfaceExternalSparkSigner;
typedef struct UniffiVTableCallbackInterfaceFiatService {
  UniffiCallbackInterfaceFiatServiceMethod0 fetch_fiat_currencies;
  UniffiCallbackInterfaceFiatServiceMethod1 fetch_fiat_rates;
  UniffiCallbackInterfaceFree uniffi_free;
} UniffiVTableCallbackInterfaceFiatService;
typedef struct UniffiVTableCallbackInterfacePaymentObserver {
  UniffiCallbackInterfacePaymentObserverMethod0 before_send;
  UniffiCallbackInterfacePaymentObserverMethod1 after_send;
  UniffiCallbackInterfaceFree uniffi_free;
} UniffiVTableCallbackInterfacePaymentObserver;
typedef struct UniffiVTableCallbackInterfacePrfProvider {
  UniffiCallbackInterfacePrfProviderMethod0 derive_seeds;
  UniffiCallbackInterfacePrfProviderMethod1 is_supported;
  UniffiCallbackInterfacePrfProviderMethod2 create_passkey;
  UniffiCallbackInterfacePrfProviderMethod3 check_domain_association;
  UniffiCallbackInterfaceFree uniffi_free;
} UniffiVTableCallbackInterfacePrfProvider;
typedef struct UniffiVTableCallbackInterfaceRestClient {
  UniffiCallbackInterfaceRestClientMethod0 get_request;
  UniffiCallbackInterfaceRestClientMethod1 post_request;
  UniffiCallbackInterfaceRestClientMethod2 delete_request;
  UniffiCallbackInterfaceFree uniffi_free;
} UniffiVTableCallbackInterfaceRestClient;
typedef struct UniffiVTableCallbackInterfaceSessionStore {
  UniffiCallbackInterfaceSessionStoreMethod0 get_session;
  UniffiCallbackInterfaceSessionStoreMethod1 set_session;
  UniffiCallbackInterfaceFree uniffi_free;
} UniffiVTableCallbackInterfaceSessionStore;
typedef struct UniffiVTableCallbackInterfaceStorage {
  UniffiCallbackInterfaceStorageMethod0 delete_cached_item;
  UniffiCallbackInterfaceStorageMethod1 get_cached_item;
  UniffiCallbackInterfaceStorageMethod2 set_cached_item;
  UniffiCallbackInterfaceStorageMethod3 list_payments;
  UniffiCallbackInterfaceStorageMethod4 apply_payment_update;
  UniffiCallbackInterfaceStorageMethod5 insert_payment_metadata;
  UniffiCallbackInterfaceStorageMethod6 get_payment_by_id;
  UniffiCallbackInterfaceStorageMethod7 get_payment_by_invoice;
  UniffiCallbackInterfaceStorageMethod8 get_payments_by_parent_ids;
  UniffiCallbackInterfaceStorageMethod9 add_deposit;
  UniffiCallbackInterfaceStorageMethod10 delete_deposit;
  UniffiCallbackInterfaceStorageMethod11 list_deposits;
  UniffiCallbackInterfaceStorageMethod12 update_deposit;
  UniffiCallbackInterfaceStorageMethod13 set_lnurl_metadata;
  UniffiCallbackInterfaceStorageMethod14 list_contacts;
  UniffiCallbackInterfaceStorageMethod15 get_contact;
  UniffiCallbackInterfaceStorageMethod16 insert_contact;
  UniffiCallbackInterfaceStorageMethod17 delete_contact;
  UniffiCallbackInterfaceStorageMethod18 set_cross_chain_swap;
  UniffiCallbackInterfaceStorageMethod19 get_cross_chain_swap;
  UniffiCallbackInterfaceStorageMethod20 list_active_cross_chain_swaps;
  UniffiCallbackInterfaceStorageMethod21 add_outgoing_change;
  UniffiCallbackInterfaceStorageMethod22 complete_outgoing_sync;
  UniffiCallbackInterfaceStorageMethod23 get_pending_outgoing_changes;
  UniffiCallbackInterfaceStorageMethod24 get_last_revision;
  UniffiCallbackInterfaceStorageMethod25 insert_incoming_records;
  UniffiCallbackInterfaceStorageMethod26 delete_incoming_record;
  UniffiCallbackInterfaceStorageMethod27 get_incoming_records;
  UniffiCallbackInterfaceStorageMethod28 get_latest_outgoing_change;
  UniffiCallbackInterfaceStorageMethod29 update_record_from_incoming;
  UniffiCallbackInterfaceFree uniffi_free;
} UniffiVTableCallbackInterfaceStorage;
typedef struct UniffiVTableCallbackInterfaceStorageBackend {
  UniffiCallbackInterfaceStorageBackendMethod0 create_stores;
  UniffiCallbackInterfaceFree uniffi_free;
} UniffiVTableCallbackInterfaceStorageBackend;
void *uniffi_breez_sdk_spark_fn_clone_bitcoinchainservice(
    void *ptr, RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_free_bitcoinchainservice(
    void *ptr, RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_init_callback_vtable_bitcoinchainservice(
    UniffiVTableCallbackInterfaceBitcoinChainService *vtable);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_get_address_utxos(
    void *ptr, RustBuffer address);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_get_address_txos(
    void *ptr, RustBuffer address);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_get_transaction_status(
    void *ptr, RustBuffer txid);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_tip_height(void *ptr);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_get_transaction_hex(
    void *ptr, RustBuffer txid);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_get_outspend(
    void *ptr, RustBuffer txid, uint32_t vout);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_broadcast_transaction(
    void *ptr, RustBuffer tx);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_recommended_fees(
    void *ptr);
void *uniffi_breez_sdk_spark_fn_clone_breezsdk(void *ptr,
                                               RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_free_breezsdk(void *ptr,
                                             RustCallStatus *uniffi_out_err);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_add_contact(void *ptr,
                                                      RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_add_event_listener(void *ptr,
                                                             uint64_t listener);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_authorize_lightning_address_transfer(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_build_unsigned_batch_package(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_build_unsigned_lnurl_pay_package(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_build_unsigned_transfer_package(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_buy_bitcoin(void *ptr,
                                                      RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_check_lightning_address_available(
    void *ptr, RustBuffer req);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_check_message(void *ptr,
                                                        RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_check_unilateral_exit(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_claim_deposit(void *ptr,
                                                        RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_claim_htlc_payment(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_claim_lightning_address_transfer(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_delete_contact(void *ptr,
                                                         RustBuffer id);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_delete_lightning_address(void *ptr);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_disconnect(void *ptr);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_export_unilateral_exit_state(
    void *ptr);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_fetch_claim_deposit_quote(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_fetch_conversion_limits(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_get_cross_chain_routes(
    void *ptr, RustBuffer filter);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_get_info(void *ptr,
                                                   RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_get_lightning_address(void *ptr);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_get_payment(void *ptr,
                                                      RustBuffer request);
void *uniffi_breez_sdk_spark_fn_method_breezsdk_get_token_issuer(
    void *ptr, RustCallStatus *uniffi_out_err);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_get_tokens_metadata(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_get_user_settings(void *ptr);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_import_unilateral_exit_state(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_list_contacts(void *ptr,
                                                        RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_list_fiat_currencies(void *ptr);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_list_fiat_rates(void *ptr);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_list_payments(void *ptr,
                                                        RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_list_unclaimed_deposits(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_list_webhooks(void *ptr);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_lnurl_auth(void *ptr,
                                                     RustBuffer request_data);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_lnurl_pay(void *ptr,
                                                    RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_lnurl_withdraw(void *ptr,
                                                         RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_optimize_leaves(void *ptr,
                                                          RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_parse(void *ptr, RustBuffer input);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_prepare_lnurl_pay(void *ptr,
                                                            RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_prepare_payment_link(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_prepare_send_batch(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_prepare_send_payment(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_prepare_unilateral_exit(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_publish_signed_lnurl_pay_package(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_publish_signed_transfer_package(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_receive_payment(void *ptr,
                                                          RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_recommended_fees(void *ptr);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_refund_deposit(void *ptr,
                                                         RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_refund_pending_conversions(void *ptr);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_register_lightning_address(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_register_webhook(void *ptr,
                                                           RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_remove_event_listener(void *ptr,
                                                                RustBuffer id);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_send_batch(void *ptr,
                                                     RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_send_payment(void *ptr,
                                                       RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_sign_message(void *ptr,
                                                       RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_sync_wallet(void *ptr,
                                                      RustBuffer request);
/*handle*/ uint64_t uniffi_breez_sdk_spark_fn_method_breezsdk_unilateral_exit(
    void *ptr, RustBuffer request, void *signer);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_unregister_webhook(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_update_contact(void *ptr,
                                                         RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_breezsdk_update_user_settings(
    void *ptr, RustBuffer request);
void *
uniffi_breez_sdk_spark_fn_clone_cpfpsigner(void *ptr,
                                           RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_free_cpfpsigner(void *ptr,
                                               RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_init_callback_vtable_cpfpsigner(
    UniffiVTableCallbackInterfaceCpfpSigner *vtable);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_cpfpsigner_sign_psbt(void *ptr,
                                                      RustBuffer psbt_bytes);
void *uniffi_breez_sdk_spark_fn_clone_externalbreezsigner(
    void *ptr, RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_free_externalbreezsigner(
    void *ptr, RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_init_callback_vtable_externalbreezsigner(
    UniffiVTableCallbackInterfaceExternalBreezSigner *vtable);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalbreezsigner_derive_public_key(
    void *ptr, RustBuffer path);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalbreezsigner_sign_ecdsa(
    void *ptr, RustBuffer message, RustBuffer path);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalbreezsigner_sign_ecdsa_recoverable(
    void *ptr, RustBuffer message, RustBuffer path);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalbreezsigner_encrypt_ecies(
    void *ptr, RustBuffer message, RustBuffer path);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalbreezsigner_decrypt_ecies(
    void *ptr, RustBuffer message, RustBuffer path);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalbreezsigner_sign_hash_schnorr(
    void *ptr, RustBuffer hash, RustBuffer path);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalbreezsigner_hmac_sha256(
    void *ptr, RustBuffer message, RustBuffer path);
void *uniffi_breez_sdk_spark_fn_clone_externalsigningsigner(
    void *ptr, RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_free_externalsigningsigner(
    void *ptr, RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_init_callback_vtable_externalsigningsigner(
    UniffiVTableCallbackInterfaceExternalSigningSigner *vtable);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalsigningsigner_derive_public_key(
    void *ptr, RustBuffer path);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalsigningsigner_sign_ecdsa(
    void *ptr, RustBuffer message, RustBuffer path);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalsigningsigner_sign_ecdsa_recoverable(
    void *ptr, RustBuffer message, RustBuffer path);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalsigningsigner_sign_hash_schnorr(
    void *ptr, RustBuffer hash, RustBuffer path);
void *uniffi_breez_sdk_spark_fn_clone_externalsparksigner(
    void *ptr, RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_free_externalsparksigner(
    void *ptr, RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_init_callback_vtable_externalsparksigner(
    UniffiVTableCallbackInterfaceExternalSparkSigner *vtable);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalsparksigner_get_identity_public_key(
    void *ptr);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalsparksigner_get_public_key_for_leaf(
    void *ptr, RustBuffer leaf_id);
int8_t uniffi_breez_sdk_spark_fn_method_externalsparksigner_is_remote(
    void *ptr, RustCallStatus *uniffi_out_err);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalsparksigner_get_static_deposit_public_key(
    void *ptr, uint32_t index);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_authentication_challenge(
    void *ptr, RustBuffer challenge);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_message(
    void *ptr, RustBuffer message);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_leaf_refund_spend(
    void *ptr, RustBuffer leaf_id, RustBuffer sighash);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_frost(
    void *ptr, RustBuffer jobs);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_transfer(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_claim(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_lightning_receive(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_static_deposit(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalsparksigner_start_static_deposit_refund(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_static_deposit_refund(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_spark_invoice(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_token_transaction(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_static_deposit_claim(
    void *ptr, RustBuffer request);
void *
uniffi_breez_sdk_spark_fn_clone_fiatservice(void *ptr,
                                            RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_free_fiatservice(void *ptr,
                                                RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_init_callback_vtable_fiatservice(
    UniffiVTableCallbackInterfaceFiatService *vtable);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_fiatservice_fetch_fiat_currencies(void *ptr);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_fiatservice_fetch_fiat_rates(void *ptr);
void *
uniffi_breez_sdk_spark_fn_clone_passkeyclient(void *ptr,
                                              RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_free_passkeyclient(
    void *ptr, RustCallStatus *uniffi_out_err);
void *uniffi_breez_sdk_spark_fn_constructor_passkeyclient_new(
    void *prf_provider, RustBuffer breez_api_key, RustBuffer config,
    RustCallStatus *uniffi_out_err);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_passkeyclient_check_availability(void *ptr);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_passkeyclient_connect_with_passkey(
    void *ptr, RustBuffer request);
void *uniffi_breez_sdk_spark_fn_method_passkeyclient_labels(
    void *ptr, RustCallStatus *uniffi_out_err);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_passkeyclient_register(void *ptr,
                                                        RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_passkeyclient_sign_in(void *ptr,
                                                       RustBuffer request);
void *
uniffi_breez_sdk_spark_fn_clone_passkeylabels(void *ptr,
                                              RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_free_passkeylabels(
    void *ptr, RustCallStatus *uniffi_out_err);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_passkeylabels_list(void *ptr);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_passkeylabels_store(void *ptr,
                                                     RustBuffer label);
void *
uniffi_breez_sdk_spark_fn_clone_paymentobserver(void *ptr,
                                                RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_free_paymentobserver(
    void *ptr, RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_init_callback_vtable_paymentobserver(
    UniffiVTableCallbackInterfacePaymentObserver *vtable);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_paymentobserver_before_send(
    void *ptr, RustBuffer payments);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_paymentobserver_after_send(void *ptr,
                                                            RustBuffer updates);
void *
uniffi_breez_sdk_spark_fn_clone_prfprovider(void *ptr,
                                            RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_free_prfprovider(void *ptr,
                                                RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_init_callback_vtable_prfprovider(
    UniffiVTableCallbackInterfacePrfProvider *vtable);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_prfprovider_derive_seeds(void *ptr,
                                                          RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_prfprovider_is_supported(void *ptr);
/*handle*/ uint64_t uniffi_breez_sdk_spark_fn_method_prfprovider_create_passkey(
    void *ptr, RustBuffer exclude_credentials, RustBuffer salts);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_prfprovider_check_domain_association(
    void *ptr);
void *
uniffi_breez_sdk_spark_fn_clone_resolvedstores(void *ptr,
                                               RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_free_resolvedstores(
    void *ptr, RustCallStatus *uniffi_out_err);
void *
uniffi_breez_sdk_spark_fn_clone_restclient(void *ptr,
                                           RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_free_restclient(void *ptr,
                                               RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_init_callback_vtable_restclient(
    UniffiVTableCallbackInterfaceRestClient *vtable);
/*handle*/ uint64_t uniffi_breez_sdk_spark_fn_method_restclient_get_request(
    void *ptr, RustBuffer url, RustBuffer headers);
/*handle*/ uint64_t uniffi_breez_sdk_spark_fn_method_restclient_post_request(
    void *ptr, RustBuffer url, RustBuffer headers, RustBuffer body);
/*handle*/ uint64_t uniffi_breez_sdk_spark_fn_method_restclient_delete_request(
    void *ptr, RustBuffer url, RustBuffer headers, RustBuffer body);
void *
uniffi_breez_sdk_spark_fn_clone_sdkbuilder(void *ptr,
                                           RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_free_sdkbuilder(void *ptr,
                                               RustCallStatus *uniffi_out_err);
void *uniffi_breez_sdk_spark_fn_constructor_sdkbuilder_new(
    RustBuffer config, RustBuffer seed, RustCallStatus *uniffi_out_err);
void *uniffi_breez_sdk_spark_fn_constructor_sdkbuilder_new_with_signer(
    RustBuffer config, void *breez_signer, void *spark_signer,
    RustCallStatus *uniffi_out_err);
void *
uniffi_breez_sdk_spark_fn_constructor_sdkbuilder_new_with_signing_only_signer(
    RustBuffer config, void *breez_signer, void *spark_signer,
    RustCallStatus *uniffi_out_err);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_sdkbuilder_build(void *ptr);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_account_number(
    void *ptr, uint32_t account_number);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_chain_service(
    void *ptr, void *chain_service);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_default_storage(
    void *ptr, RustBuffer storage_dir);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_fiat_service(
    void *ptr, void *fiat_service);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_lnurl_client(
    void *ptr, void *lnurl_client);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_payment_observer(
    void *ptr, void *payment_observer);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_rest_chain_service(
    void *ptr, RustBuffer url, RustBuffer api_type, RustBuffer credentials);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_session_store(
    void *ptr, void *session_store);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_shared_context(void *ptr,
                                                                void *context);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_storage(void *ptr,
                                                         void *storage);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_storage_backend(void *ptr,
                                                                 void *storage);
void *
uniffi_breez_sdk_spark_fn_clone_sdkcontext(void *ptr,
                                           RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_free_sdkcontext(void *ptr,
                                               RustCallStatus *uniffi_out_err);
void *
uniffi_breez_sdk_spark_fn_clone_sessionstore(void *ptr,
                                             RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_free_sessionstore(
    void *ptr, RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_init_callback_vtable_sessionstore(
    UniffiVTableCallbackInterfaceSessionStore *vtable);
/*handle*/ uint64_t uniffi_breez_sdk_spark_fn_method_sessionstore_get_session(
    void *ptr, RustBuffer service_identity_key);
/*handle*/ uint64_t uniffi_breez_sdk_spark_fn_method_sessionstore_set_session(
    void *ptr, RustBuffer service_identity_key, RustBuffer session);
void *uniffi_breez_sdk_spark_fn_clone_storage(void *ptr,
                                              RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_free_storage(void *ptr,
                                            RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_init_callback_vtable_storage(
    UniffiVTableCallbackInterfaceStorage *vtable);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_storage_delete_cached_item(void *ptr,
                                                            RustBuffer key);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_storage_get_cached_item(void *ptr,
                                                         RustBuffer key);
/*handle*/ uint64_t uniffi_breez_sdk_spark_fn_method_storage_set_cached_item(
    void *ptr, RustBuffer key, RustBuffer value);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_storage_list_payments(void *ptr,
                                                       RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_storage_apply_payment_update(
    void *ptr, RustBuffer payment);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_storage_insert_payment_metadata(
    void *ptr, RustBuffer payment_id, RustBuffer metadata);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_storage_get_payment_by_id(void *ptr,
                                                           RustBuffer id);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_storage_get_payment_by_invoice(
    void *ptr, RustBuffer invoice);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_storage_get_payments_by_parent_ids(
    void *ptr, RustBuffer parent_payment_ids);
/*handle*/ uint64_t uniffi_breez_sdk_spark_fn_method_storage_add_deposit(
    void *ptr, RustBuffer txid, uint32_t vout, uint64_t amount_sats,
    int8_t is_mature);
/*handle*/ uint64_t uniffi_breez_sdk_spark_fn_method_storage_delete_deposit(
    void *ptr, RustBuffer txid, uint32_t vout);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_storage_list_deposits(void *ptr);
/*handle*/ uint64_t uniffi_breez_sdk_spark_fn_method_storage_update_deposit(
    void *ptr, RustBuffer txid, uint32_t vout, RustBuffer payload);
/*handle*/ uint64_t uniffi_breez_sdk_spark_fn_method_storage_set_lnurl_metadata(
    void *ptr, RustBuffer metadata);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_storage_list_contacts(void *ptr,
                                                       RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_storage_get_contact(void *ptr, RustBuffer id);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_storage_insert_contact(void *ptr,
                                                        RustBuffer contact);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_storage_delete_contact(void *ptr,
                                                        RustBuffer id);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_storage_set_cross_chain_swap(void *ptr,
                                                              RustBuffer swap);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_storage_get_cross_chain_swap(
    void *ptr, RustBuffer provider, RustBuffer id);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_storage_list_active_cross_chain_swaps(
    void *ptr, RustBuffer provider);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_storage_add_outgoing_change(void *ptr,
                                                             RustBuffer record);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_storage_complete_outgoing_sync(
    void *ptr, RustBuffer record, uint64_t local_revision);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_storage_get_pending_outgoing_changes(
    void *ptr, uint32_t limit);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_storage_get_last_revision(void *ptr);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_storage_insert_incoming_records(
    void *ptr, RustBuffer records);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_storage_delete_incoming_record(
    void *ptr, RustBuffer record);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_storage_get_incoming_records(void *ptr,
                                                              uint32_t limit);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_storage_get_latest_outgoing_change(void *ptr);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_storage_update_record_from_incoming(
    void *ptr, RustBuffer record);
void *
uniffi_breez_sdk_spark_fn_clone_storagebackend(void *ptr,
                                               RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_free_storagebackend(
    void *ptr, RustCallStatus *uniffi_out_err);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_storagebackend_create_stores(
    void *ptr, RustBuffer network, RustBuffer identity);
void *
uniffi_breez_sdk_spark_fn_clone_tokenissuer(void *ptr,
                                            RustCallStatus *uniffi_out_err);
void uniffi_breez_sdk_spark_fn_free_tokenissuer(void *ptr,
                                                RustCallStatus *uniffi_out_err);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_tokenissuer_burn_issuer_token(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_tokenissuer_create_issuer_token(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_tokenissuer_freeze_issuer_token(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_tokenissuer_get_issuer_token_balance(
    void *ptr);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_tokenissuer_get_issuer_token_metadata(
    void *ptr);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_tokenissuer_mint_issuer_token(
    void *ptr, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_method_tokenissuer_unfreeze_issuer_token(
    void *ptr, RustBuffer request);
void uniffi_breez_sdk_spark_fn_init_callback_vtable_eventlistener(
    UniffiVTableCallbackInterfaceEventListener *vtable);
void uniffi_breez_sdk_spark_fn_init_callback_vtable_logger(
    UniffiVTableCallbackInterfaceLogger *vtable);
/*handle*/ uint64_t uniffi_breez_sdk_spark_fn_func_connect(RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_func_connect_with_signer(RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_func_connect_with_signing_only_signer(
    RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_func_create_turnkey_signer(RustBuffer config);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_func_create_turnkey_signing_only_signer(
    RustBuffer config);
void *
uniffi_breez_sdk_spark_fn_func_custom_storage(void *storage,
                                              RustCallStatus *uniffi_out_err);
RustBuffer
uniffi_breez_sdk_spark_fn_func_default_config(RustBuffer network,
                                              RustCallStatus *uniffi_out_err);
RustBuffer uniffi_breez_sdk_spark_fn_func_default_external_signers(
    RustBuffer mnemonic, RustBuffer passphrase, RustBuffer network,
    RustBuffer account_number, RustCallStatus *uniffi_out_err);
RustBuffer uniffi_breez_sdk_spark_fn_func_default_server_config(
    RustBuffer network, RustCallStatus *uniffi_out_err);
/*handle*/ uint64_t uniffi_breez_sdk_spark_fn_func_default_session_store(
    void *backend, RustBuffer network, RustBuffer identity);
void *
uniffi_breez_sdk_spark_fn_func_default_storage(RustBuffer storage_dir,
                                               RustCallStatus *uniffi_out_err);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_func_get_spark_status(RustBuffer request);
void uniffi_breez_sdk_spark_fn_func_init_logging(
    RustBuffer log_dir, RustBuffer app_logger, RustBuffer log_filter,
    RustCallStatus *uniffi_out_err);
/*handle*/ uint64_t uniffi_breez_sdk_spark_fn_func_new_rest_chain_service(
    RustBuffer url, RustBuffer network, RustBuffer api_type,
    RustBuffer credentials, RustBuffer request);
/*handle*/ uint64_t
uniffi_breez_sdk_spark_fn_func_new_shared_sdk_context(RustBuffer config);
void *uniffi_breez_sdk_spark_fn_func_single_key_cpfp_signer(
    RustBuffer secret_key_bytes, RustCallStatus *uniffi_out_err);
RustBuffer ffi_breez_sdk_spark_rustbuffer_alloc(uint64_t size,
                                                RustCallStatus *uniffi_out_err);
RustBuffer
ffi_breez_sdk_spark_rustbuffer_from_bytes(ForeignBytes bytes,
                                          RustCallStatus *uniffi_out_err);
void ffi_breez_sdk_spark_rustbuffer_free(RustBuffer buf,
                                         RustCallStatus *uniffi_out_err);
RustBuffer
ffi_breez_sdk_spark_rustbuffer_reserve(RustBuffer buf, uint64_t additional,
                                       RustCallStatus *uniffi_out_err);
void ffi_breez_sdk_spark_rust_future_poll_u8(
    /*handle*/ uint64_t handle, UniffiRustFutureContinuationCallback callback,
    /*handle*/ uint64_t callback_data);
void ffi_breez_sdk_spark_rust_future_cancel_u8(
    /*handle*/ uint64_t handle);
void ffi_breez_sdk_spark_rust_future_free_u8(
    /*handle*/ uint64_t handle);
uint8_t ffi_breez_sdk_spark_rust_future_complete_u8(
    /*handle*/ uint64_t handle, RustCallStatus *uniffi_out_err);
void ffi_breez_sdk_spark_rust_future_poll_i8(
    /*handle*/ uint64_t handle, UniffiRustFutureContinuationCallback callback,
    /*handle*/ uint64_t callback_data);
void ffi_breez_sdk_spark_rust_future_cancel_i8(
    /*handle*/ uint64_t handle);
void ffi_breez_sdk_spark_rust_future_free_i8(
    /*handle*/ uint64_t handle);
int8_t ffi_breez_sdk_spark_rust_future_complete_i8(
    /*handle*/ uint64_t handle, RustCallStatus *uniffi_out_err);
void ffi_breez_sdk_spark_rust_future_poll_u16(
    /*handle*/ uint64_t handle, UniffiRustFutureContinuationCallback callback,
    /*handle*/ uint64_t callback_data);
void ffi_breez_sdk_spark_rust_future_cancel_u16(
    /*handle*/ uint64_t handle);
void ffi_breez_sdk_spark_rust_future_free_u16(
    /*handle*/ uint64_t handle);
uint16_t ffi_breez_sdk_spark_rust_future_complete_u16(
    /*handle*/ uint64_t handle, RustCallStatus *uniffi_out_err);
void ffi_breez_sdk_spark_rust_future_poll_i16(
    /*handle*/ uint64_t handle, UniffiRustFutureContinuationCallback callback,
    /*handle*/ uint64_t callback_data);
void ffi_breez_sdk_spark_rust_future_cancel_i16(
    /*handle*/ uint64_t handle);
void ffi_breez_sdk_spark_rust_future_free_i16(
    /*handle*/ uint64_t handle);
int16_t ffi_breez_sdk_spark_rust_future_complete_i16(
    /*handle*/ uint64_t handle, RustCallStatus *uniffi_out_err);
void ffi_breez_sdk_spark_rust_future_poll_u32(
    /*handle*/ uint64_t handle, UniffiRustFutureContinuationCallback callback,
    /*handle*/ uint64_t callback_data);
void ffi_breez_sdk_spark_rust_future_cancel_u32(
    /*handle*/ uint64_t handle);
void ffi_breez_sdk_spark_rust_future_free_u32(
    /*handle*/ uint64_t handle);
uint32_t ffi_breez_sdk_spark_rust_future_complete_u32(
    /*handle*/ uint64_t handle, RustCallStatus *uniffi_out_err);
void ffi_breez_sdk_spark_rust_future_poll_i32(
    /*handle*/ uint64_t handle, UniffiRustFutureContinuationCallback callback,
    /*handle*/ uint64_t callback_data);
void ffi_breez_sdk_spark_rust_future_cancel_i32(
    /*handle*/ uint64_t handle);
void ffi_breez_sdk_spark_rust_future_free_i32(
    /*handle*/ uint64_t handle);
int32_t ffi_breez_sdk_spark_rust_future_complete_i32(
    /*handle*/ uint64_t handle, RustCallStatus *uniffi_out_err);
void ffi_breez_sdk_spark_rust_future_poll_u64(
    /*handle*/ uint64_t handle, UniffiRustFutureContinuationCallback callback,
    /*handle*/ uint64_t callback_data);
void ffi_breez_sdk_spark_rust_future_cancel_u64(
    /*handle*/ uint64_t handle);
void ffi_breez_sdk_spark_rust_future_free_u64(
    /*handle*/ uint64_t handle);
uint64_t ffi_breez_sdk_spark_rust_future_complete_u64(
    /*handle*/ uint64_t handle, RustCallStatus *uniffi_out_err);
void ffi_breez_sdk_spark_rust_future_poll_i64(
    /*handle*/ uint64_t handle, UniffiRustFutureContinuationCallback callback,
    /*handle*/ uint64_t callback_data);
void ffi_breez_sdk_spark_rust_future_cancel_i64(
    /*handle*/ uint64_t handle);
void ffi_breez_sdk_spark_rust_future_free_i64(
    /*handle*/ uint64_t handle);
int64_t ffi_breez_sdk_spark_rust_future_complete_i64(
    /*handle*/ uint64_t handle, RustCallStatus *uniffi_out_err);
void ffi_breez_sdk_spark_rust_future_poll_f32(
    /*handle*/ uint64_t handle, UniffiRustFutureContinuationCallback callback,
    /*handle*/ uint64_t callback_data);
void ffi_breez_sdk_spark_rust_future_cancel_f32(
    /*handle*/ uint64_t handle);
void ffi_breez_sdk_spark_rust_future_free_f32(
    /*handle*/ uint64_t handle);
float ffi_breez_sdk_spark_rust_future_complete_f32(
    /*handle*/ uint64_t handle, RustCallStatus *uniffi_out_err);
void ffi_breez_sdk_spark_rust_future_poll_f64(
    /*handle*/ uint64_t handle, UniffiRustFutureContinuationCallback callback,
    /*handle*/ uint64_t callback_data);
void ffi_breez_sdk_spark_rust_future_cancel_f64(
    /*handle*/ uint64_t handle);
void ffi_breez_sdk_spark_rust_future_free_f64(
    /*handle*/ uint64_t handle);
double ffi_breez_sdk_spark_rust_future_complete_f64(
    /*handle*/ uint64_t handle, RustCallStatus *uniffi_out_err);
void ffi_breez_sdk_spark_rust_future_poll_pointer(
    /*handle*/ uint64_t handle, UniffiRustFutureContinuationCallback callback,
    /*handle*/ uint64_t callback_data);
void ffi_breez_sdk_spark_rust_future_cancel_pointer(
    /*handle*/ uint64_t handle);
void ffi_breez_sdk_spark_rust_future_free_pointer(
    /*handle*/ uint64_t handle);
void *ffi_breez_sdk_spark_rust_future_complete_pointer(
    /*handle*/ uint64_t handle, RustCallStatus *uniffi_out_err);
void ffi_breez_sdk_spark_rust_future_poll_rust_buffer(
    /*handle*/ uint64_t handle, UniffiRustFutureContinuationCallback callback,
    /*handle*/ uint64_t callback_data);
void ffi_breez_sdk_spark_rust_future_cancel_rust_buffer(
    /*handle*/ uint64_t handle);
void ffi_breez_sdk_spark_rust_future_free_rust_buffer(
    /*handle*/ uint64_t handle);
RustBuffer ffi_breez_sdk_spark_rust_future_complete_rust_buffer(
    /*handle*/ uint64_t handle, RustCallStatus *uniffi_out_err);
void ffi_breez_sdk_spark_rust_future_poll_void(
    /*handle*/ uint64_t handle, UniffiRustFutureContinuationCallback callback,
    /*handle*/ uint64_t callback_data);
void ffi_breez_sdk_spark_rust_future_cancel_void(
    /*handle*/ uint64_t handle);
void ffi_breez_sdk_spark_rust_future_free_void(
    /*handle*/ uint64_t handle);
void ffi_breez_sdk_spark_rust_future_complete_void(
    /*handle*/ uint64_t handle, RustCallStatus *uniffi_out_err);
uint16_t uniffi_breez_sdk_spark_checksum_func_connect();
uint16_t uniffi_breez_sdk_spark_checksum_func_connect_with_signer();
uint16_t
uniffi_breez_sdk_spark_checksum_func_connect_with_signing_only_signer();
uint16_t uniffi_breez_sdk_spark_checksum_func_create_turnkey_signer();
uint16_t
uniffi_breez_sdk_spark_checksum_func_create_turnkey_signing_only_signer();
uint16_t uniffi_breez_sdk_spark_checksum_func_custom_storage();
uint16_t uniffi_breez_sdk_spark_checksum_func_default_config();
uint16_t uniffi_breez_sdk_spark_checksum_func_default_external_signers();
uint16_t uniffi_breez_sdk_spark_checksum_func_default_server_config();
uint16_t uniffi_breez_sdk_spark_checksum_func_default_session_store();
uint16_t uniffi_breez_sdk_spark_checksum_func_default_storage();
uint16_t uniffi_breez_sdk_spark_checksum_func_get_spark_status();
uint16_t uniffi_breez_sdk_spark_checksum_func_init_logging();
uint16_t uniffi_breez_sdk_spark_checksum_func_new_rest_chain_service();
uint16_t uniffi_breez_sdk_spark_checksum_func_new_shared_sdk_context();
uint16_t uniffi_breez_sdk_spark_checksum_func_single_key_cpfp_signer();
uint16_t
uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_get_address_utxos();
uint16_t
uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_get_address_txos();
uint16_t
uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_get_transaction_status();
uint16_t
uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_tip_height();
uint16_t
uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_get_transaction_hex();
uint16_t
uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_get_outspend();
uint16_t
uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_broadcast_transaction();
uint16_t
uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_recommended_fees();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_add_contact();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_add_event_listener();
uint16_t
uniffi_breez_sdk_spark_checksum_method_breezsdk_authorize_lightning_address_transfer();
uint16_t
uniffi_breez_sdk_spark_checksum_method_breezsdk_build_unsigned_batch_package();
uint16_t
uniffi_breez_sdk_spark_checksum_method_breezsdk_build_unsigned_lnurl_pay_package();
uint16_t
uniffi_breez_sdk_spark_checksum_method_breezsdk_build_unsigned_transfer_package();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_buy_bitcoin();
uint16_t
uniffi_breez_sdk_spark_checksum_method_breezsdk_check_lightning_address_available();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_check_message();
uint16_t
uniffi_breez_sdk_spark_checksum_method_breezsdk_check_unilateral_exit();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_claim_deposit();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_claim_htlc_payment();
uint16_t
uniffi_breez_sdk_spark_checksum_method_breezsdk_claim_lightning_address_transfer();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_delete_contact();
uint16_t
uniffi_breez_sdk_spark_checksum_method_breezsdk_delete_lightning_address();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_disconnect();
uint16_t
uniffi_breez_sdk_spark_checksum_method_breezsdk_export_unilateral_exit_state();
uint16_t
uniffi_breez_sdk_spark_checksum_method_breezsdk_fetch_claim_deposit_quote();
uint16_t
uniffi_breez_sdk_spark_checksum_method_breezsdk_fetch_conversion_limits();
uint16_t
uniffi_breez_sdk_spark_checksum_method_breezsdk_get_cross_chain_routes();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_get_info();
uint16_t
uniffi_breez_sdk_spark_checksum_method_breezsdk_get_lightning_address();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_get_payment();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_get_token_issuer();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_get_tokens_metadata();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_get_user_settings();
uint16_t
uniffi_breez_sdk_spark_checksum_method_breezsdk_import_unilateral_exit_state();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_list_contacts();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_list_fiat_currencies();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_list_fiat_rates();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_list_payments();
uint16_t
uniffi_breez_sdk_spark_checksum_method_breezsdk_list_unclaimed_deposits();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_list_webhooks();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_lnurl_auth();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_lnurl_pay();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_lnurl_withdraw();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_optimize_leaves();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_parse();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_prepare_lnurl_pay();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_prepare_payment_link();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_prepare_send_batch();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_prepare_send_payment();
uint16_t
uniffi_breez_sdk_spark_checksum_method_breezsdk_prepare_unilateral_exit();
uint16_t
uniffi_breez_sdk_spark_checksum_method_breezsdk_publish_signed_lnurl_pay_package();
uint16_t
uniffi_breez_sdk_spark_checksum_method_breezsdk_publish_signed_transfer_package();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_receive_payment();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_recommended_fees();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_refund_deposit();
uint16_t
uniffi_breez_sdk_spark_checksum_method_breezsdk_refund_pending_conversions();
uint16_t
uniffi_breez_sdk_spark_checksum_method_breezsdk_register_lightning_address();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_register_webhook();
uint16_t
uniffi_breez_sdk_spark_checksum_method_breezsdk_remove_event_listener();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_send_batch();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_send_payment();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_sign_message();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_sync_wallet();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_unilateral_exit();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_unregister_webhook();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_update_contact();
uint16_t uniffi_breez_sdk_spark_checksum_method_breezsdk_update_user_settings();
uint16_t uniffi_breez_sdk_spark_checksum_method_cpfpsigner_sign_psbt();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_derive_public_key();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_sign_ecdsa();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_sign_ecdsa_recoverable();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_encrypt_ecies();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_decrypt_ecies();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_sign_hash_schnorr();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_hmac_sha256();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalsigningsigner_derive_public_key();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalsigningsigner_sign_ecdsa();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalsigningsigner_sign_ecdsa_recoverable();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalsigningsigner_sign_hash_schnorr();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalsparksigner_get_identity_public_key();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalsparksigner_get_public_key_for_leaf();
uint16_t uniffi_breez_sdk_spark_checksum_method_externalsparksigner_is_remote();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalsparksigner_get_static_deposit_public_key();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_authentication_challenge();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_message();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_leaf_refund_spend();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_frost();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalsparksigner_prepare_transfer();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalsparksigner_prepare_claim();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalsparksigner_prepare_lightning_receive();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalsparksigner_prepare_static_deposit();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalsparksigner_start_static_deposit_refund();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_static_deposit_refund();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_spark_invoice();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalsparksigner_prepare_token_transaction();
uint16_t
uniffi_breez_sdk_spark_checksum_method_externalsparksigner_prepare_static_deposit_claim();
uint16_t
uniffi_breez_sdk_spark_checksum_method_fiatservice_fetch_fiat_currencies();
uint16_t uniffi_breez_sdk_spark_checksum_method_fiatservice_fetch_fiat_rates();
uint16_t
uniffi_breez_sdk_spark_checksum_method_passkeyclient_check_availability();
uint16_t
uniffi_breez_sdk_spark_checksum_method_passkeyclient_connect_with_passkey();
uint16_t uniffi_breez_sdk_spark_checksum_method_passkeyclient_labels();
uint16_t uniffi_breez_sdk_spark_checksum_method_passkeyclient_register();
uint16_t uniffi_breez_sdk_spark_checksum_method_passkeyclient_sign_in();
uint16_t uniffi_breez_sdk_spark_checksum_method_passkeylabels_list();
uint16_t uniffi_breez_sdk_spark_checksum_method_passkeylabels_store();
uint16_t uniffi_breez_sdk_spark_checksum_method_paymentobserver_before_send();
uint16_t uniffi_breez_sdk_spark_checksum_method_paymentobserver_after_send();
uint16_t uniffi_breez_sdk_spark_checksum_method_prfprovider_derive_seeds();
uint16_t uniffi_breez_sdk_spark_checksum_method_prfprovider_is_supported();
uint16_t uniffi_breez_sdk_spark_checksum_method_prfprovider_create_passkey();
uint16_t
uniffi_breez_sdk_spark_checksum_method_prfprovider_check_domain_association();
uint16_t uniffi_breez_sdk_spark_checksum_method_restclient_get_request();
uint16_t uniffi_breez_sdk_spark_checksum_method_restclient_post_request();
uint16_t uniffi_breez_sdk_spark_checksum_method_restclient_delete_request();
uint16_t uniffi_breez_sdk_spark_checksum_method_sdkbuilder_build();
uint16_t
uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_account_number();
uint16_t uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_chain_service();
uint16_t
uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_default_storage();
uint16_t uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_fiat_service();
uint16_t uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_lnurl_client();
uint16_t
uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_payment_observer();
uint16_t
uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_rest_chain_service();
uint16_t uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_session_store();
uint16_t
uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_shared_context();
uint16_t uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_storage();
uint16_t
uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_storage_backend();
uint16_t uniffi_breez_sdk_spark_checksum_method_sessionstore_get_session();
uint16_t uniffi_breez_sdk_spark_checksum_method_sessionstore_set_session();
uint16_t uniffi_breez_sdk_spark_checksum_method_storage_delete_cached_item();
uint16_t uniffi_breez_sdk_spark_checksum_method_storage_get_cached_item();
uint16_t uniffi_breez_sdk_spark_checksum_method_storage_set_cached_item();
uint16_t uniffi_breez_sdk_spark_checksum_method_storage_list_payments();
uint16_t uniffi_breez_sdk_spark_checksum_method_storage_apply_payment_update();
uint16_t
uniffi_breez_sdk_spark_checksum_method_storage_insert_payment_metadata();
uint16_t uniffi_breez_sdk_spark_checksum_method_storage_get_payment_by_id();
uint16_t
uniffi_breez_sdk_spark_checksum_method_storage_get_payment_by_invoice();
uint16_t
uniffi_breez_sdk_spark_checksum_method_storage_get_payments_by_parent_ids();
uint16_t uniffi_breez_sdk_spark_checksum_method_storage_add_deposit();
uint16_t uniffi_breez_sdk_spark_checksum_method_storage_delete_deposit();
uint16_t uniffi_breez_sdk_spark_checksum_method_storage_list_deposits();
uint16_t uniffi_breez_sdk_spark_checksum_method_storage_update_deposit();
uint16_t uniffi_breez_sdk_spark_checksum_method_storage_set_lnurl_metadata();
uint16_t uniffi_breez_sdk_spark_checksum_method_storage_list_contacts();
uint16_t uniffi_breez_sdk_spark_checksum_method_storage_get_contact();
uint16_t uniffi_breez_sdk_spark_checksum_method_storage_insert_contact();
uint16_t uniffi_breez_sdk_spark_checksum_method_storage_delete_contact();
uint16_t uniffi_breez_sdk_spark_checksum_method_storage_set_cross_chain_swap();
uint16_t uniffi_breez_sdk_spark_checksum_method_storage_get_cross_chain_swap();
uint16_t
uniffi_breez_sdk_spark_checksum_method_storage_list_active_cross_chain_swaps();
uint16_t uniffi_breez_sdk_spark_checksum_method_storage_add_outgoing_change();
uint16_t
uniffi_breez_sdk_spark_checksum_method_storage_complete_outgoing_sync();
uint16_t
uniffi_breez_sdk_spark_checksum_method_storage_get_pending_outgoing_changes();
uint16_t uniffi_breez_sdk_spark_checksum_method_storage_get_last_revision();
uint16_t
uniffi_breez_sdk_spark_checksum_method_storage_insert_incoming_records();
uint16_t
uniffi_breez_sdk_spark_checksum_method_storage_delete_incoming_record();
uint16_t uniffi_breez_sdk_spark_checksum_method_storage_get_incoming_records();
uint16_t
uniffi_breez_sdk_spark_checksum_method_storage_get_latest_outgoing_change();
uint16_t
uniffi_breez_sdk_spark_checksum_method_storage_update_record_from_incoming();
uint16_t uniffi_breez_sdk_spark_checksum_method_storagebackend_create_stores();
uint16_t uniffi_breez_sdk_spark_checksum_method_tokenissuer_burn_issuer_token();
uint16_t
uniffi_breez_sdk_spark_checksum_method_tokenissuer_create_issuer_token();
uint16_t
uniffi_breez_sdk_spark_checksum_method_tokenissuer_freeze_issuer_token();
uint16_t
uniffi_breez_sdk_spark_checksum_method_tokenissuer_get_issuer_token_balance();
uint16_t
uniffi_breez_sdk_spark_checksum_method_tokenissuer_get_issuer_token_metadata();
uint16_t uniffi_breez_sdk_spark_checksum_method_tokenissuer_mint_issuer_token();
uint16_t
uniffi_breez_sdk_spark_checksum_method_tokenissuer_unfreeze_issuer_token();
uint16_t uniffi_breez_sdk_spark_checksum_constructor_passkeyclient_new();
uint16_t uniffi_breez_sdk_spark_checksum_constructor_sdkbuilder_new();
uint16_t
uniffi_breez_sdk_spark_checksum_constructor_sdkbuilder_new_with_signer();
uint16_t
uniffi_breez_sdk_spark_checksum_constructor_sdkbuilder_new_with_signing_only_signer();
uint16_t uniffi_breez_sdk_spark_checksum_method_eventlistener_on_event();
uint16_t uniffi_breez_sdk_spark_checksum_method_logger_log();
uint32_t ffi_breez_sdk_spark_uniffi_contract_version();
}

namespace uniffi::breez_sdk_spark {
template <typename T> struct Bridging;

using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <typename T> struct Bridging<ReferenceHolder<T>> {
  static jsi::Value jsNew(jsi::Runtime &rt) {
    auto holder = jsi::Object(rt);
    return holder;
  }
  static T fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
                  const jsi::Value &value) {
    auto obj = value.asObject(rt);
    if (obj.hasProperty(rt, "pointee")) {
      auto pointee = obj.getProperty(rt, "pointee");
      return uniffi::breez_sdk_spark::Bridging<T>::fromJs(rt, callInvoker,
                                                          pointee);
    }
    throw jsi::JSError(rt,
                       "Expected ReferenceHolder to have a pointee property. "
                       "This is likely a bug in uniffi-bindgen-react-native");
  }
};
} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<RustBuffer> {
  static RustBuffer rustbuffer_alloc(int32_t size) {
    RustCallStatus status = {UNIFFI_CALL_STATUS_OK};
    return ffi_breez_sdk_spark_rustbuffer_alloc(size, &status);
  }

  static void rustbuffer_free(RustBuffer buf) {
    RustCallStatus status = {UNIFFI_CALL_STATUS_OK};
    ffi_breez_sdk_spark_rustbuffer_free(buf, &status);
  }

  static RustBuffer rustbuffer_from_bytes(ForeignBytes bytes) {
    RustCallStatus status = {UNIFFI_CALL_STATUS_OK};
    return ffi_breez_sdk_spark_rustbuffer_from_bytes(bytes, &status);
  }

  static RustBuffer fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker>,
                           const jsi::Value &value) {
    try {
      auto buffer =
          uniffi_jsi::Bridging<jsi::ArrayBuffer>::value_to_arraybuffer(rt,
                                                                       value);
      auto bytes = ForeignBytes{
          .len = static_cast<int32_t>(buffer.length(rt)),
          .data = buffer.data(rt),
      };

      // This buffer is constructed from foreign bytes. Rust scaffolding copies
      // the bytes, to make the RustBuffer.
      auto buf = rustbuffer_from_bytes(bytes);
      // Once it leaves this function, the buffer is immediately passed back
      // into Rust, where it's used to deserialize into the Rust versions of the
      // arguments. At that point, the copy is destroyed.
      return buf;
    } catch (const std::logic_error &e) {
      throw jsi::JSError(rt, e.what());
    }
  }

  static jsi::Value toJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker>,
                         RustBuffer buf) {
    // We need to make a copy of the bytes from Rust's memory space into
    // Javascripts memory space. We need to do this because the two languages
    // manages memory very differently: a garbage collector needs to track all
    // the memory at runtime, Rust is doing it all closer to compile time.
    uint8_t *bytes = new uint8_t[buf.len];
    std::memcpy(bytes, buf.data, buf.len);

    // Construct an ArrayBuffer with copy of the bytes from the RustBuffer.
    auto payload = std::make_shared<uniffi_jsi::CMutableBuffer>(
        uniffi_jsi::CMutableBuffer((uint8_t *)bytes, buf.len));
    auto arrayBuffer = jsi::ArrayBuffer(rt, payload);

    // Once we have a Javascript version, we no longer need the Rust version, so
    // we can call into Rust to tell it it's okay to free that memory.
    rustbuffer_free(buf);

    // Finally, return the ArrayBuffer.
    return uniffi_jsi::Bridging<jsi::ArrayBuffer>::arraybuffer_to_value(
        rt, arrayBuffer);
    ;
  }
};

} // namespace uniffi::breez_sdk_spark

namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<RustCallStatus> {
  static jsi::Value jsSuccess(jsi::Runtime &rt) {
    auto statusObject = jsi::Object(rt);
    statusObject.setProperty(rt, "code", jsi::Value(rt, UNIFFI_CALL_STATUS_OK));
    return statusObject;
  }
  static RustCallStatus rustSuccess(jsi::Runtime &rt) {
    return {UNIFFI_CALL_STATUS_OK};
  }
  static void copyIntoJs(jsi::Runtime &rt,
                         std::shared_ptr<CallInvoker> callInvoker,
                         const RustCallStatus status,
                         const jsi::Value &jsStatus) {
    auto statusObject = jsStatus.asObject(rt);
    if (status.error_buf.data != nullptr) {
      auto rbuf = Bridging<RustBuffer>::toJs(rt, callInvoker, status.error_buf);
      statusObject.setProperty(rt, "errorBuf", rbuf);
    }
    if (status.code != UNIFFI_CALL_STATUS_OK) {
      auto code =
          uniffi_jsi::Bridging<uint8_t>::toJs(rt, callInvoker, status.code);
      statusObject.setProperty(rt, "code", code);
    }
  }

  static RustCallStatus fromJs(jsi::Runtime &rt,
                               std::shared_ptr<CallInvoker> invoker,
                               const jsi::Value &jsStatus) {
    RustCallStatus status;
    auto statusObject = jsStatus.asObject(rt);
    if (statusObject.hasProperty(rt, "errorBuf")) {
      auto rbuf = statusObject.getProperty(rt, "errorBuf");
      status.error_buf = Bridging<RustBuffer>::fromJs(rt, invoker, rbuf);
    }
    if (statusObject.hasProperty(rt, "code")) {
      auto code = statusObject.getProperty(rt, "code");
      status.code = uniffi_jsi::Bridging<uint8_t>::fromJs(rt, invoker, code);
    }
    return status;
  }

  static void copyFromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> invoker,
                         const jsi::Value &jsStatus, RustCallStatus *status) {
    auto statusObject = jsStatus.asObject(rt);
    if (statusObject.hasProperty(rt, "errorBuf")) {
      auto rbuf = statusObject.getProperty(rt, "errorBuf");
      status->error_buf = Bridging<RustBuffer>::fromJs(rt, invoker, rbuf);
    }
    if (statusObject.hasProperty(rt, "code")) {
      auto code = statusObject.getProperty(rt, "code");
      status->code = uniffi_jsi::Bridging<uint8_t>::fromJs(rt, invoker, code);
    }
  }
};

} // namespace uniffi::breez_sdk_spark
// In other uniffi bindings, it is assumed that the foreign language holds on
// to the vtable, which the Rust just gets a pointer to.
// Here, we need to hold on to them, but also be able to clear them at just the
// right time so we can support hot-reloading.
namespace uniffi::breez_sdk_spark::registry {
template <typename T> class VTableHolder {
public:
  T vtable;
  VTableHolder(T v) : vtable(v) {}
};

// Mutex to bind the storage and setting of vtable together.
// We declare it here, but the lock is taken by callers of the putTable
// method who are also sending a pointer to Rust.
static std::mutex vtableMutex;

// Registry to hold all vtables so they persist even when JS objects are GC'd.
// The only reason this exists is to prevent a dangling pointer in the
// Rust machinery: i.e. we don't need to access or write to this registry
// after startup.
// Registry to hold all vtables so they persist even when JS objects are GC'd.
// Maps string identifiers to vtable holders using type erasure
static std::unordered_map<std::string, std::shared_ptr<void>> vtableRegistry;

// Add a vtable to the registry with an identifier
template <typename T>
static T *putTable(std::string_view identifier, T vtable) {
  auto holder = std::make_shared<VTableHolder<T>>(vtable);
  // Store the raw pointer to the vtable before type erasure
  T *rawPtr = &(holder->vtable);
  // Store the holder using type erasure with the string identifier
  vtableRegistry[std::string(identifier)] = std::shared_ptr<void>(holder);
  return rawPtr;
}

// Clear the registry.
//
// Conceptually, this is called after teardown of the module (i.e. after
// teardown of the jsi::Runtime). However, because Rust is dropping callbacks
// because the Runtime is being torn down, we must keep the registry intact
// until after the runtime goes away.
//
// Therefore, in practice we should call this when the next runtime is
// being stood up.
static void clearRegistry() {
  std::lock_guard<std::mutex> lock(vtableMutex);
  vtableRegistry.clear();
}
} // namespace uniffi::breez_sdk_spark::registry

// This calls into Rust.
// Implementation of callback function calling from Rust to JS
// RustFutureContinuationCallback

// Callback function:
// uniffi::breez_sdk_spark::cb::rustfuturecontinuationcallback::UniffiRustFutureContinuationCallback
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::rustfuturecontinuationcallback {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, int8_t)> rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue, uint64_t rs_data,
                 int8_t rs_pollResult) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_data = uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_data);
  auto js_pollResult =
      uniffi_jsi::Bridging<int8_t>::toJs(rt, callInvoker, rs_pollResult);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_data, js_pollResult);

  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiRustFutureContinuationCallback: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_data, int8_t rs_pollResult) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_data, rs_pollResult);
}

static UniffiRustFutureContinuationCallback
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::rustfuturecontinuationcallback
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](uint64_t rs_data,
                                               int8_t rs_pollResult) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_data,
         rs_pollResult](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_data, rs_pollResult);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.

    callInvoker->invokeNonBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::rustfuturecontinuationcallback
  // Implementation of callback function calling from JS to Rust
  // ForeignFutureFree, passed from Rust to JS as part of async callbacks.
namespace uniffi::breez_sdk_spark {
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureFree> {
  static jsi::Value toJs(jsi::Runtime &rt,
                         std::shared_ptr<CallInvoker> callInvoker,
                         UniffiForeignFutureFree rsCallback) {
    return jsi::Function::createFromHostFunction(
        rt, jsi::PropNameID::forAscii(rt, "--ForeignFutureFree"), 1,
        [rsCallback, callInvoker](jsi::Runtime &rt, const jsi::Value &thisValue,
                                  const jsi::Value *arguments,
                                  size_t count) -> jsi::Value {
          return intoRust(rt, callInvoker, thisValue, arguments, count,
                          rsCallback);
        });
  }

  static jsi::Value intoRust(jsi::Runtime &rt,
                             std::shared_ptr<CallInvoker> callInvoker,
                             const jsi::Value &thisValue,
                             const jsi::Value *args, size_t count,
                             UniffiForeignFutureFree func) {
    // Convert the arguments into the Rust, with Bridging<T>::fromJs,
    // then call the rs_callback with those arguments.
    func(uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]));

    return jsi::Value::undefined();
  }
};
} // namespace uniffi::breez_sdk_spark
  // Implementation of free callback function CallbackInterfaceFree

// Callback function:
// uniffi::breez_sdk_spark::st::foreignfuture::foreignfuture::free::UniffiCallbackInterfaceFree
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::st::foreignfuture::foreignfuture::free {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t)> rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_handle) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_handle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_handle);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_handle);

  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceFree: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_handle) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_handle);
}

static UniffiCallbackInterfaceFree
makeCallbackFunction( // uniffi::breez_sdk_spark::st::foreignfuture::foreignfuture::free
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](uint64_t rs_handle) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_handle](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_handle);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.

    callInvoker->invokeNonBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::st::foreignfuture::foreignfuture::free

// Callback function:
// uniffi::breez_sdk_spark::st::vtablecallbackinterfaceeventlistener::vtablecallbackinterfaceeventlistener::free::UniffiCallbackInterfaceFree
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::st::vtablecallbackinterfaceeventlistener::
    vtablecallbackinterfaceeventlistener::free {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t)> rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_handle) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_handle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_handle);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_handle);

  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceFree: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_handle) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_handle);
}

static UniffiCallbackInterfaceFree
makeCallbackFunction( // uniffi::breez_sdk_spark::st::vtablecallbackinterfaceeventlistener::vtablecallbackinterfaceeventlistener::free
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](uint64_t rs_handle) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_handle](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_handle);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.

    callInvoker->invokeNonBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::st::vtablecallbackinterfaceeventlistener::vtablecallbackinterfaceeventlistener::free

// Callback function:
// uniffi::breez_sdk_spark::st::vtablecallbackinterfacelogger::vtablecallbackinterfacelogger::free::UniffiCallbackInterfaceFree
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::st::vtablecallbackinterfacelogger::
    vtablecallbackinterfacelogger::free {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t)> rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_handle) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_handle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_handle);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_handle);

  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceFree: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_handle) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_handle);
}

static UniffiCallbackInterfaceFree
makeCallbackFunction( // uniffi::breez_sdk_spark::st::vtablecallbackinterfacelogger::vtablecallbackinterfacelogger::free
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](uint64_t rs_handle) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_handle](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_handle);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.

    callInvoker->invokeNonBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::st::vtablecallbackinterfacelogger::vtablecallbackinterfacelogger::free

// Callback function:
// uniffi::breez_sdk_spark::st::vtablecallbackinterfacebitcoinchainservice::vtablecallbackinterfacebitcoinchainservice::free::UniffiCallbackInterfaceFree
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::st::
    vtablecallbackinterfacebitcoinchainservice::
        vtablecallbackinterfacebitcoinchainservice::free {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t)> rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_handle) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_handle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_handle);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_handle);

  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceFree: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_handle) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_handle);
}

static UniffiCallbackInterfaceFree
makeCallbackFunction( // uniffi::breez_sdk_spark::st::vtablecallbackinterfacebitcoinchainservice::vtablecallbackinterfacebitcoinchainservice::free
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](uint64_t rs_handle) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_handle](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_handle);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.

    callInvoker->invokeNonBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::st::vtablecallbackinterfacebitcoinchainservice::vtablecallbackinterfacebitcoinchainservice::free

// Callback function:
// uniffi::breez_sdk_spark::st::vtablecallbackinterfacecpfpsigner::vtablecallbackinterfacecpfpsigner::free::UniffiCallbackInterfaceFree
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::st::vtablecallbackinterfacecpfpsigner::
    vtablecallbackinterfacecpfpsigner::free {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t)> rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_handle) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_handle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_handle);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_handle);

  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceFree: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_handle) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_handle);
}

static UniffiCallbackInterfaceFree
makeCallbackFunction( // uniffi::breez_sdk_spark::st::vtablecallbackinterfacecpfpsigner::vtablecallbackinterfacecpfpsigner::free
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](uint64_t rs_handle) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_handle](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_handle);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.

    callInvoker->invokeNonBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::st::vtablecallbackinterfacecpfpsigner::vtablecallbackinterfacecpfpsigner::free

// Callback function:
// uniffi::breez_sdk_spark::st::vtablecallbackinterfaceexternalbreezsigner::vtablecallbackinterfaceexternalbreezsigner::free::UniffiCallbackInterfaceFree
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::st::
    vtablecallbackinterfaceexternalbreezsigner::
        vtablecallbackinterfaceexternalbreezsigner::free {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t)> rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_handle) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_handle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_handle);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_handle);

  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceFree: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_handle) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_handle);
}

static UniffiCallbackInterfaceFree
makeCallbackFunction( // uniffi::breez_sdk_spark::st::vtablecallbackinterfaceexternalbreezsigner::vtablecallbackinterfaceexternalbreezsigner::free
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](uint64_t rs_handle) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_handle](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_handle);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.

    callInvoker->invokeNonBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::st::vtablecallbackinterfaceexternalbreezsigner::vtablecallbackinterfaceexternalbreezsigner::free

// Callback function:
// uniffi::breez_sdk_spark::st::vtablecallbackinterfaceexternalsigningsigner::vtablecallbackinterfaceexternalsigningsigner::free::UniffiCallbackInterfaceFree
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::st::
    vtablecallbackinterfaceexternalsigningsigner::
        vtablecallbackinterfaceexternalsigningsigner::free {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t)> rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_handle) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_handle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_handle);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_handle);

  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceFree: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_handle) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_handle);
}

static UniffiCallbackInterfaceFree
makeCallbackFunction( // uniffi::breez_sdk_spark::st::vtablecallbackinterfaceexternalsigningsigner::vtablecallbackinterfaceexternalsigningsigner::free
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](uint64_t rs_handle) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_handle](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_handle);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.

    callInvoker->invokeNonBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::st::vtablecallbackinterfaceexternalsigningsigner::vtablecallbackinterfaceexternalsigningsigner::free

// Callback function:
// uniffi::breez_sdk_spark::st::vtablecallbackinterfaceexternalsparksigner::vtablecallbackinterfaceexternalsparksigner::free::UniffiCallbackInterfaceFree
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::st::
    vtablecallbackinterfaceexternalsparksigner::
        vtablecallbackinterfaceexternalsparksigner::free {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t)> rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_handle) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_handle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_handle);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_handle);

  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceFree: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_handle) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_handle);
}

static UniffiCallbackInterfaceFree
makeCallbackFunction( // uniffi::breez_sdk_spark::st::vtablecallbackinterfaceexternalsparksigner::vtablecallbackinterfaceexternalsparksigner::free
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](uint64_t rs_handle) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_handle](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_handle);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.

    callInvoker->invokeNonBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::st::vtablecallbackinterfaceexternalsparksigner::vtablecallbackinterfaceexternalsparksigner::free

// Callback function:
// uniffi::breez_sdk_spark::st::vtablecallbackinterfacefiatservice::vtablecallbackinterfacefiatservice::free::UniffiCallbackInterfaceFree
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::st::vtablecallbackinterfacefiatservice::
    vtablecallbackinterfacefiatservice::free {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t)> rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_handle) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_handle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_handle);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_handle);

  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceFree: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_handle) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_handle);
}

static UniffiCallbackInterfaceFree
makeCallbackFunction( // uniffi::breez_sdk_spark::st::vtablecallbackinterfacefiatservice::vtablecallbackinterfacefiatservice::free
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](uint64_t rs_handle) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_handle](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_handle);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.

    callInvoker->invokeNonBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::st::vtablecallbackinterfacefiatservice::vtablecallbackinterfacefiatservice::free

// Callback function:
// uniffi::breez_sdk_spark::st::vtablecallbackinterfacepaymentobserver::vtablecallbackinterfacepaymentobserver::free::UniffiCallbackInterfaceFree
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::st::vtablecallbackinterfacepaymentobserver::
    vtablecallbackinterfacepaymentobserver::free {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t)> rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_handle) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_handle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_handle);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_handle);

  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceFree: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_handle) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_handle);
}

static UniffiCallbackInterfaceFree
makeCallbackFunction( // uniffi::breez_sdk_spark::st::vtablecallbackinterfacepaymentobserver::vtablecallbackinterfacepaymentobserver::free
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](uint64_t rs_handle) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_handle](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_handle);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.

    callInvoker->invokeNonBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::st::vtablecallbackinterfacepaymentobserver::vtablecallbackinterfacepaymentobserver::free

// Callback function:
// uniffi::breez_sdk_spark::st::vtablecallbackinterfaceprfprovider::vtablecallbackinterfaceprfprovider::free::UniffiCallbackInterfaceFree
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::st::vtablecallbackinterfaceprfprovider::
    vtablecallbackinterfaceprfprovider::free {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t)> rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_handle) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_handle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_handle);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_handle);

  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceFree: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_handle) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_handle);
}

static UniffiCallbackInterfaceFree
makeCallbackFunction( // uniffi::breez_sdk_spark::st::vtablecallbackinterfaceprfprovider::vtablecallbackinterfaceprfprovider::free
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](uint64_t rs_handle) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_handle](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_handle);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.

    callInvoker->invokeNonBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::st::vtablecallbackinterfaceprfprovider::vtablecallbackinterfaceprfprovider::free

// Callback function:
// uniffi::breez_sdk_spark::st::vtablecallbackinterfacerestclient::vtablecallbackinterfacerestclient::free::UniffiCallbackInterfaceFree
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::st::vtablecallbackinterfacerestclient::
    vtablecallbackinterfacerestclient::free {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t)> rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_handle) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_handle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_handle);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_handle);

  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceFree: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_handle) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_handle);
}

static UniffiCallbackInterfaceFree
makeCallbackFunction( // uniffi::breez_sdk_spark::st::vtablecallbackinterfacerestclient::vtablecallbackinterfacerestclient::free
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](uint64_t rs_handle) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_handle](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_handle);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.

    callInvoker->invokeNonBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::st::vtablecallbackinterfacerestclient::vtablecallbackinterfacerestclient::free

// Callback function:
// uniffi::breez_sdk_spark::st::vtablecallbackinterfacesessionstore::vtablecallbackinterfacesessionstore::free::UniffiCallbackInterfaceFree
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::st::vtablecallbackinterfacesessionstore::
    vtablecallbackinterfacesessionstore::free {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t)> rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_handle) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_handle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_handle);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_handle);

  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceFree: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_handle) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_handle);
}

static UniffiCallbackInterfaceFree
makeCallbackFunction( // uniffi::breez_sdk_spark::st::vtablecallbackinterfacesessionstore::vtablecallbackinterfacesessionstore::free
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](uint64_t rs_handle) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_handle](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_handle);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.

    callInvoker->invokeNonBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::st::vtablecallbackinterfacesessionstore::vtablecallbackinterfacesessionstore::free

// Callback function:
// uniffi::breez_sdk_spark::st::vtablecallbackinterfacestorage::vtablecallbackinterfacestorage::free::UniffiCallbackInterfaceFree
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::st::vtablecallbackinterfacestorage::
    vtablecallbackinterfacestorage::free {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t)> rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_handle) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_handle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_handle);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_handle);

  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceFree: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_handle) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_handle);
}

static UniffiCallbackInterfaceFree
makeCallbackFunction( // uniffi::breez_sdk_spark::st::vtablecallbackinterfacestorage::vtablecallbackinterfacestorage::free
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](uint64_t rs_handle) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_handle](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_handle);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.

    callInvoker->invokeNonBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::st::vtablecallbackinterfacestorage::vtablecallbackinterfacestorage::free

// Callback function:
// uniffi::breez_sdk_spark::st::vtablecallbackinterfacestoragebackend::vtablecallbackinterfacestoragebackend::free::UniffiCallbackInterfaceFree
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::st::vtablecallbackinterfacestoragebackend::
    vtablecallbackinterfacestoragebackend::free {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t)> rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_handle) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_handle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_handle);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_handle);

  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceFree: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_handle) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_handle);
}

static UniffiCallbackInterfaceFree
makeCallbackFunction( // uniffi::breez_sdk_spark::st::vtablecallbackinterfacestoragebackend::vtablecallbackinterfacestoragebackend::free
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](uint64_t rs_handle) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_handle](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_handle);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.

    callInvoker->invokeNonBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::st::vtablecallbackinterfacestoragebackend::vtablecallbackinterfacestoragebackend::free
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFuture> {
  static UniffiForeignFuture fromJs(jsi::Runtime &rt,
                                    std::shared_ptr<CallInvoker> callInvoker,
                                    const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(rt, "Expected an object for UniffiForeignFuture");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiForeignFuture rsObject;

    // Create the vtable from the js callbacks.
    rsObject.handle = uniffi_jsi::Bridging<uint64_t>::fromJs(
        rt, callInvoker, jsObject.getProperty(rt, "handle"));
    rsObject.free = uniffi::breez_sdk_spark::st::foreignfuture::foreignfuture::
        free::makeCallbackFunction(rt, callInvoker,
                                   jsObject.getProperty(rt, "free"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureStructU8> {
  static UniffiForeignFutureStructU8
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(rt,
                         "Expected an object for UniffiForeignFutureStructU8");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiForeignFutureStructU8 rsObject;

    // Create the vtable from the js callbacks.
    rsObject.return_value = uniffi_jsi::Bridging<uint8_t>::fromJs(
        rt, callInvoker, jsObject.getProperty(rt, "returnValue"));
    rsObject.call_status =
        uniffi::breez_sdk_spark::Bridging<RustCallStatus>::fromJs(
            rt, callInvoker, jsObject.getProperty(rt, "callStatus"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
  // Implementation of callback function calling from JS to Rust
  // ForeignFutureCompleteU8, passed from Rust to JS as part of async callbacks.
namespace uniffi::breez_sdk_spark {
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureCompleteU8> {
  static jsi::Value toJs(jsi::Runtime &rt,
                         std::shared_ptr<CallInvoker> callInvoker,
                         UniffiForeignFutureCompleteU8 rsCallback) {
    return jsi::Function::createFromHostFunction(
        rt, jsi::PropNameID::forAscii(rt, "--ForeignFutureCompleteU8"), 2,
        [rsCallback, callInvoker](jsi::Runtime &rt, const jsi::Value &thisValue,
                                  const jsi::Value *arguments,
                                  size_t count) -> jsi::Value {
          return intoRust(rt, callInvoker, thisValue, arguments, count,
                          rsCallback);
        });
  }

  static jsi::Value intoRust(jsi::Runtime &rt,
                             std::shared_ptr<CallInvoker> callInvoker,
                             const jsi::Value &thisValue,
                             const jsi::Value *args, size_t count,
                             UniffiForeignFutureCompleteU8 func) {
    // Convert the arguments into the Rust, with Bridging<T>::fromJs,
    // then call the rs_callback with those arguments.
    func(uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]),
         uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureStructU8>::fromJs(
             rt, callInvoker, args[1]));

    return jsi::Value::undefined();
  }
};
} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureStructI8> {
  static UniffiForeignFutureStructI8
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(rt,
                         "Expected an object for UniffiForeignFutureStructI8");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiForeignFutureStructI8 rsObject;

    // Create the vtable from the js callbacks.
    rsObject.return_value = uniffi_jsi::Bridging<int8_t>::fromJs(
        rt, callInvoker, jsObject.getProperty(rt, "returnValue"));
    rsObject.call_status =
        uniffi::breez_sdk_spark::Bridging<RustCallStatus>::fromJs(
            rt, callInvoker, jsObject.getProperty(rt, "callStatus"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
  // Implementation of callback function calling from JS to Rust
  // ForeignFutureCompleteI8, passed from Rust to JS as part of async callbacks.
namespace uniffi::breez_sdk_spark {
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureCompleteI8> {
  static jsi::Value toJs(jsi::Runtime &rt,
                         std::shared_ptr<CallInvoker> callInvoker,
                         UniffiForeignFutureCompleteI8 rsCallback) {
    return jsi::Function::createFromHostFunction(
        rt, jsi::PropNameID::forAscii(rt, "--ForeignFutureCompleteI8"), 2,
        [rsCallback, callInvoker](jsi::Runtime &rt, const jsi::Value &thisValue,
                                  const jsi::Value *arguments,
                                  size_t count) -> jsi::Value {
          return intoRust(rt, callInvoker, thisValue, arguments, count,
                          rsCallback);
        });
  }

  static jsi::Value intoRust(jsi::Runtime &rt,
                             std::shared_ptr<CallInvoker> callInvoker,
                             const jsi::Value &thisValue,
                             const jsi::Value *args, size_t count,
                             UniffiForeignFutureCompleteI8 func) {
    // Convert the arguments into the Rust, with Bridging<T>::fromJs,
    // then call the rs_callback with those arguments.
    func(uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]),
         uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureStructI8>::fromJs(
             rt, callInvoker, args[1]));

    return jsi::Value::undefined();
  }
};
} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureStructU16> {
  static UniffiForeignFutureStructU16
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(rt,
                         "Expected an object for UniffiForeignFutureStructU16");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiForeignFutureStructU16 rsObject;

    // Create the vtable from the js callbacks.
    rsObject.return_value = uniffi_jsi::Bridging<uint16_t>::fromJs(
        rt, callInvoker, jsObject.getProperty(rt, "returnValue"));
    rsObject.call_status =
        uniffi::breez_sdk_spark::Bridging<RustCallStatus>::fromJs(
            rt, callInvoker, jsObject.getProperty(rt, "callStatus"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
  // Implementation of callback function calling from JS to Rust
  // ForeignFutureCompleteU16, passed from Rust to JS as part of async
  // callbacks.
namespace uniffi::breez_sdk_spark {
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureCompleteU16> {
  static jsi::Value toJs(jsi::Runtime &rt,
                         std::shared_ptr<CallInvoker> callInvoker,
                         UniffiForeignFutureCompleteU16 rsCallback) {
    return jsi::Function::createFromHostFunction(
        rt, jsi::PropNameID::forAscii(rt, "--ForeignFutureCompleteU16"), 2,
        [rsCallback, callInvoker](jsi::Runtime &rt, const jsi::Value &thisValue,
                                  const jsi::Value *arguments,
                                  size_t count) -> jsi::Value {
          return intoRust(rt, callInvoker, thisValue, arguments, count,
                          rsCallback);
        });
  }

  static jsi::Value intoRust(jsi::Runtime &rt,
                             std::shared_ptr<CallInvoker> callInvoker,
                             const jsi::Value &thisValue,
                             const jsi::Value *args, size_t count,
                             UniffiForeignFutureCompleteU16 func) {
    // Convert the arguments into the Rust, with Bridging<T>::fromJs,
    // then call the rs_callback with those arguments.
    func(
        uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]),
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureStructU16>::fromJs(
            rt, callInvoker, args[1]));

    return jsi::Value::undefined();
  }
};
} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureStructI16> {
  static UniffiForeignFutureStructI16
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(rt,
                         "Expected an object for UniffiForeignFutureStructI16");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiForeignFutureStructI16 rsObject;

    // Create the vtable from the js callbacks.
    rsObject.return_value = uniffi_jsi::Bridging<int16_t>::fromJs(
        rt, callInvoker, jsObject.getProperty(rt, "returnValue"));
    rsObject.call_status =
        uniffi::breez_sdk_spark::Bridging<RustCallStatus>::fromJs(
            rt, callInvoker, jsObject.getProperty(rt, "callStatus"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
  // Implementation of callback function calling from JS to Rust
  // ForeignFutureCompleteI16, passed from Rust to JS as part of async
  // callbacks.
namespace uniffi::breez_sdk_spark {
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureCompleteI16> {
  static jsi::Value toJs(jsi::Runtime &rt,
                         std::shared_ptr<CallInvoker> callInvoker,
                         UniffiForeignFutureCompleteI16 rsCallback) {
    return jsi::Function::createFromHostFunction(
        rt, jsi::PropNameID::forAscii(rt, "--ForeignFutureCompleteI16"), 2,
        [rsCallback, callInvoker](jsi::Runtime &rt, const jsi::Value &thisValue,
                                  const jsi::Value *arguments,
                                  size_t count) -> jsi::Value {
          return intoRust(rt, callInvoker, thisValue, arguments, count,
                          rsCallback);
        });
  }

  static jsi::Value intoRust(jsi::Runtime &rt,
                             std::shared_ptr<CallInvoker> callInvoker,
                             const jsi::Value &thisValue,
                             const jsi::Value *args, size_t count,
                             UniffiForeignFutureCompleteI16 func) {
    // Convert the arguments into the Rust, with Bridging<T>::fromJs,
    // then call the rs_callback with those arguments.
    func(
        uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]),
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureStructI16>::fromJs(
            rt, callInvoker, args[1]));

    return jsi::Value::undefined();
  }
};
} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureStructU32> {
  static UniffiForeignFutureStructU32
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(rt,
                         "Expected an object for UniffiForeignFutureStructU32");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiForeignFutureStructU32 rsObject;

    // Create the vtable from the js callbacks.
    rsObject.return_value = uniffi_jsi::Bridging<uint32_t>::fromJs(
        rt, callInvoker, jsObject.getProperty(rt, "returnValue"));
    rsObject.call_status =
        uniffi::breez_sdk_spark::Bridging<RustCallStatus>::fromJs(
            rt, callInvoker, jsObject.getProperty(rt, "callStatus"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
  // Implementation of callback function calling from JS to Rust
  // ForeignFutureCompleteU32, passed from Rust to JS as part of async
  // callbacks.
namespace uniffi::breez_sdk_spark {
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureCompleteU32> {
  static jsi::Value toJs(jsi::Runtime &rt,
                         std::shared_ptr<CallInvoker> callInvoker,
                         UniffiForeignFutureCompleteU32 rsCallback) {
    return jsi::Function::createFromHostFunction(
        rt, jsi::PropNameID::forAscii(rt, "--ForeignFutureCompleteU32"), 2,
        [rsCallback, callInvoker](jsi::Runtime &rt, const jsi::Value &thisValue,
                                  const jsi::Value *arguments,
                                  size_t count) -> jsi::Value {
          return intoRust(rt, callInvoker, thisValue, arguments, count,
                          rsCallback);
        });
  }

  static jsi::Value intoRust(jsi::Runtime &rt,
                             std::shared_ptr<CallInvoker> callInvoker,
                             const jsi::Value &thisValue,
                             const jsi::Value *args, size_t count,
                             UniffiForeignFutureCompleteU32 func) {
    // Convert the arguments into the Rust, with Bridging<T>::fromJs,
    // then call the rs_callback with those arguments.
    func(
        uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]),
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureStructU32>::fromJs(
            rt, callInvoker, args[1]));

    return jsi::Value::undefined();
  }
};
} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureStructI32> {
  static UniffiForeignFutureStructI32
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(rt,
                         "Expected an object for UniffiForeignFutureStructI32");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiForeignFutureStructI32 rsObject;

    // Create the vtable from the js callbacks.
    rsObject.return_value = uniffi_jsi::Bridging<int32_t>::fromJs(
        rt, callInvoker, jsObject.getProperty(rt, "returnValue"));
    rsObject.call_status =
        uniffi::breez_sdk_spark::Bridging<RustCallStatus>::fromJs(
            rt, callInvoker, jsObject.getProperty(rt, "callStatus"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
  // Implementation of callback function calling from JS to Rust
  // ForeignFutureCompleteI32, passed from Rust to JS as part of async
  // callbacks.
namespace uniffi::breez_sdk_spark {
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureCompleteI32> {
  static jsi::Value toJs(jsi::Runtime &rt,
                         std::shared_ptr<CallInvoker> callInvoker,
                         UniffiForeignFutureCompleteI32 rsCallback) {
    return jsi::Function::createFromHostFunction(
        rt, jsi::PropNameID::forAscii(rt, "--ForeignFutureCompleteI32"), 2,
        [rsCallback, callInvoker](jsi::Runtime &rt, const jsi::Value &thisValue,
                                  const jsi::Value *arguments,
                                  size_t count) -> jsi::Value {
          return intoRust(rt, callInvoker, thisValue, arguments, count,
                          rsCallback);
        });
  }

  static jsi::Value intoRust(jsi::Runtime &rt,
                             std::shared_ptr<CallInvoker> callInvoker,
                             const jsi::Value &thisValue,
                             const jsi::Value *args, size_t count,
                             UniffiForeignFutureCompleteI32 func) {
    // Convert the arguments into the Rust, with Bridging<T>::fromJs,
    // then call the rs_callback with those arguments.
    func(
        uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]),
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureStructI32>::fromJs(
            rt, callInvoker, args[1]));

    return jsi::Value::undefined();
  }
};
} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureStructU64> {
  static UniffiForeignFutureStructU64
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(rt,
                         "Expected an object for UniffiForeignFutureStructU64");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiForeignFutureStructU64 rsObject;

    // Create the vtable from the js callbacks.
    rsObject.return_value = uniffi_jsi::Bridging<uint64_t>::fromJs(
        rt, callInvoker, jsObject.getProperty(rt, "returnValue"));
    rsObject.call_status =
        uniffi::breez_sdk_spark::Bridging<RustCallStatus>::fromJs(
            rt, callInvoker, jsObject.getProperty(rt, "callStatus"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
  // Implementation of callback function calling from JS to Rust
  // ForeignFutureCompleteU64, passed from Rust to JS as part of async
  // callbacks.
namespace uniffi::breez_sdk_spark {
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureCompleteU64> {
  static jsi::Value toJs(jsi::Runtime &rt,
                         std::shared_ptr<CallInvoker> callInvoker,
                         UniffiForeignFutureCompleteU64 rsCallback) {
    return jsi::Function::createFromHostFunction(
        rt, jsi::PropNameID::forAscii(rt, "--ForeignFutureCompleteU64"), 2,
        [rsCallback, callInvoker](jsi::Runtime &rt, const jsi::Value &thisValue,
                                  const jsi::Value *arguments,
                                  size_t count) -> jsi::Value {
          return intoRust(rt, callInvoker, thisValue, arguments, count,
                          rsCallback);
        });
  }

  static jsi::Value intoRust(jsi::Runtime &rt,
                             std::shared_ptr<CallInvoker> callInvoker,
                             const jsi::Value &thisValue,
                             const jsi::Value *args, size_t count,
                             UniffiForeignFutureCompleteU64 func) {
    // Convert the arguments into the Rust, with Bridging<T>::fromJs,
    // then call the rs_callback with those arguments.
    func(
        uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]),
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureStructU64>::fromJs(
            rt, callInvoker, args[1]));

    return jsi::Value::undefined();
  }
};
} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureStructI64> {
  static UniffiForeignFutureStructI64
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(rt,
                         "Expected an object for UniffiForeignFutureStructI64");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiForeignFutureStructI64 rsObject;

    // Create the vtable from the js callbacks.
    rsObject.return_value = uniffi_jsi::Bridging<int64_t>::fromJs(
        rt, callInvoker, jsObject.getProperty(rt, "returnValue"));
    rsObject.call_status =
        uniffi::breez_sdk_spark::Bridging<RustCallStatus>::fromJs(
            rt, callInvoker, jsObject.getProperty(rt, "callStatus"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
  // Implementation of callback function calling from JS to Rust
  // ForeignFutureCompleteI64, passed from Rust to JS as part of async
  // callbacks.
namespace uniffi::breez_sdk_spark {
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureCompleteI64> {
  static jsi::Value toJs(jsi::Runtime &rt,
                         std::shared_ptr<CallInvoker> callInvoker,
                         UniffiForeignFutureCompleteI64 rsCallback) {
    return jsi::Function::createFromHostFunction(
        rt, jsi::PropNameID::forAscii(rt, "--ForeignFutureCompleteI64"), 2,
        [rsCallback, callInvoker](jsi::Runtime &rt, const jsi::Value &thisValue,
                                  const jsi::Value *arguments,
                                  size_t count) -> jsi::Value {
          return intoRust(rt, callInvoker, thisValue, arguments, count,
                          rsCallback);
        });
  }

  static jsi::Value intoRust(jsi::Runtime &rt,
                             std::shared_ptr<CallInvoker> callInvoker,
                             const jsi::Value &thisValue,
                             const jsi::Value *args, size_t count,
                             UniffiForeignFutureCompleteI64 func) {
    // Convert the arguments into the Rust, with Bridging<T>::fromJs,
    // then call the rs_callback with those arguments.
    func(
        uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]),
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureStructI64>::fromJs(
            rt, callInvoker, args[1]));

    return jsi::Value::undefined();
  }
};
} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureStructF32> {
  static UniffiForeignFutureStructF32
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(rt,
                         "Expected an object for UniffiForeignFutureStructF32");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiForeignFutureStructF32 rsObject;

    // Create the vtable from the js callbacks.
    rsObject.return_value = uniffi_jsi::Bridging<float>::fromJs(
        rt, callInvoker, jsObject.getProperty(rt, "returnValue"));
    rsObject.call_status =
        uniffi::breez_sdk_spark::Bridging<RustCallStatus>::fromJs(
            rt, callInvoker, jsObject.getProperty(rt, "callStatus"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
  // Implementation of callback function calling from JS to Rust
  // ForeignFutureCompleteF32, passed from Rust to JS as part of async
  // callbacks.
namespace uniffi::breez_sdk_spark {
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureCompleteF32> {
  static jsi::Value toJs(jsi::Runtime &rt,
                         std::shared_ptr<CallInvoker> callInvoker,
                         UniffiForeignFutureCompleteF32 rsCallback) {
    return jsi::Function::createFromHostFunction(
        rt, jsi::PropNameID::forAscii(rt, "--ForeignFutureCompleteF32"), 2,
        [rsCallback, callInvoker](jsi::Runtime &rt, const jsi::Value &thisValue,
                                  const jsi::Value *arguments,
                                  size_t count) -> jsi::Value {
          return intoRust(rt, callInvoker, thisValue, arguments, count,
                          rsCallback);
        });
  }

  static jsi::Value intoRust(jsi::Runtime &rt,
                             std::shared_ptr<CallInvoker> callInvoker,
                             const jsi::Value &thisValue,
                             const jsi::Value *args, size_t count,
                             UniffiForeignFutureCompleteF32 func) {
    // Convert the arguments into the Rust, with Bridging<T>::fromJs,
    // then call the rs_callback with those arguments.
    func(
        uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]),
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureStructF32>::fromJs(
            rt, callInvoker, args[1]));

    return jsi::Value::undefined();
  }
};
} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureStructF64> {
  static UniffiForeignFutureStructF64
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(rt,
                         "Expected an object for UniffiForeignFutureStructF64");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiForeignFutureStructF64 rsObject;

    // Create the vtable from the js callbacks.
    rsObject.return_value = uniffi_jsi::Bridging<double>::fromJs(
        rt, callInvoker, jsObject.getProperty(rt, "returnValue"));
    rsObject.call_status =
        uniffi::breez_sdk_spark::Bridging<RustCallStatus>::fromJs(
            rt, callInvoker, jsObject.getProperty(rt, "callStatus"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
  // Implementation of callback function calling from JS to Rust
  // ForeignFutureCompleteF64, passed from Rust to JS as part of async
  // callbacks.
namespace uniffi::breez_sdk_spark {
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureCompleteF64> {
  static jsi::Value toJs(jsi::Runtime &rt,
                         std::shared_ptr<CallInvoker> callInvoker,
                         UniffiForeignFutureCompleteF64 rsCallback) {
    return jsi::Function::createFromHostFunction(
        rt, jsi::PropNameID::forAscii(rt, "--ForeignFutureCompleteF64"), 2,
        [rsCallback, callInvoker](jsi::Runtime &rt, const jsi::Value &thisValue,
                                  const jsi::Value *arguments,
                                  size_t count) -> jsi::Value {
          return intoRust(rt, callInvoker, thisValue, arguments, count,
                          rsCallback);
        });
  }

  static jsi::Value intoRust(jsi::Runtime &rt,
                             std::shared_ptr<CallInvoker> callInvoker,
                             const jsi::Value &thisValue,
                             const jsi::Value *args, size_t count,
                             UniffiForeignFutureCompleteF64 func) {
    // Convert the arguments into the Rust, with Bridging<T>::fromJs,
    // then call the rs_callback with those arguments.
    func(
        uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]),
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureStructF64>::fromJs(
            rt, callInvoker, args[1]));

    return jsi::Value::undefined();
  }
};
} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureStructPointer> {
  static UniffiForeignFutureStructPointer
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(
          rt, "Expected an object for UniffiForeignFutureStructPointer");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiForeignFutureStructPointer rsObject;

    // Create the vtable from the js callbacks.
    rsObject.return_value = uniffi_jsi::Bridging<void *>::fromJs(
        rt, callInvoker, jsObject.getProperty(rt, "returnValue"));
    rsObject.call_status =
        uniffi::breez_sdk_spark::Bridging<RustCallStatus>::fromJs(
            rt, callInvoker, jsObject.getProperty(rt, "callStatus"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
  // Implementation of callback function calling from JS to Rust
  // ForeignFutureCompletePointer, passed from Rust to JS as part of async
  // callbacks.
namespace uniffi::breez_sdk_spark {
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureCompletePointer> {
  static jsi::Value toJs(jsi::Runtime &rt,
                         std::shared_ptr<CallInvoker> callInvoker,
                         UniffiForeignFutureCompletePointer rsCallback) {
    return jsi::Function::createFromHostFunction(
        rt, jsi::PropNameID::forAscii(rt, "--ForeignFutureCompletePointer"), 2,
        [rsCallback, callInvoker](jsi::Runtime &rt, const jsi::Value &thisValue,
                                  const jsi::Value *arguments,
                                  size_t count) -> jsi::Value {
          return intoRust(rt, callInvoker, thisValue, arguments, count,
                          rsCallback);
        });
  }

  static jsi::Value intoRust(jsi::Runtime &rt,
                             std::shared_ptr<CallInvoker> callInvoker,
                             const jsi::Value &thisValue,
                             const jsi::Value *args, size_t count,
                             UniffiForeignFutureCompletePointer func) {
    // Convert the arguments into the Rust, with Bridging<T>::fromJs,
    // then call the rs_callback with those arguments.
    func(uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]),
         uniffi::breez_sdk_spark::Bridging<
             UniffiForeignFutureStructPointer>::fromJs(rt, callInvoker,
                                                       args[1]));

    return jsi::Value::undefined();
  }
};
} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureStructRustBuffer> {
  static UniffiForeignFutureStructRustBuffer
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(
          rt, "Expected an object for UniffiForeignFutureStructRustBuffer");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiForeignFutureStructRustBuffer rsObject;

    // Create the vtable from the js callbacks.
    rsObject.return_value =
        uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(
            rt, callInvoker, jsObject.getProperty(rt, "returnValue"));
    rsObject.call_status =
        uniffi::breez_sdk_spark::Bridging<RustCallStatus>::fromJs(
            rt, callInvoker, jsObject.getProperty(rt, "callStatus"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
  // Implementation of callback function calling from JS to Rust
  // ForeignFutureCompleteRustBuffer, passed from Rust to JS as part of async
  // callbacks.
namespace uniffi::breez_sdk_spark {
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureCompleteRustBuffer> {
  static jsi::Value toJs(jsi::Runtime &rt,
                         std::shared_ptr<CallInvoker> callInvoker,
                         UniffiForeignFutureCompleteRustBuffer rsCallback) {
    return jsi::Function::createFromHostFunction(
        rt, jsi::PropNameID::forAscii(rt, "--ForeignFutureCompleteRustBuffer"),
        2,
        [rsCallback, callInvoker](jsi::Runtime &rt, const jsi::Value &thisValue,
                                  const jsi::Value *arguments,
                                  size_t count) -> jsi::Value {
          return intoRust(rt, callInvoker, thisValue, arguments, count,
                          rsCallback);
        });
  }

  static jsi::Value intoRust(jsi::Runtime &rt,
                             std::shared_ptr<CallInvoker> callInvoker,
                             const jsi::Value &thisValue,
                             const jsi::Value *args, size_t count,
                             UniffiForeignFutureCompleteRustBuffer func) {
    // Convert the arguments into the Rust, with Bridging<T>::fromJs,
    // then call the rs_callback with those arguments.
    func(uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]),
         uniffi::breez_sdk_spark::Bridging<
             UniffiForeignFutureStructRustBuffer>::fromJs(rt, callInvoker,
                                                          args[1]));

    return jsi::Value::undefined();
  }
};
} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureStructVoid> {
  static UniffiForeignFutureStructVoid
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(
          rt, "Expected an object for UniffiForeignFutureStructVoid");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiForeignFutureStructVoid rsObject;

    // Create the vtable from the js callbacks.
    rsObject.call_status =
        uniffi::breez_sdk_spark::Bridging<RustCallStatus>::fromJs(
            rt, callInvoker, jsObject.getProperty(rt, "callStatus"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
  // Implementation of callback function calling from JS to Rust
  // ForeignFutureCompleteVoid, passed from Rust to JS as part of async
  // callbacks.
namespace uniffi::breez_sdk_spark {
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiForeignFutureCompleteVoid> {
  static jsi::Value toJs(jsi::Runtime &rt,
                         std::shared_ptr<CallInvoker> callInvoker,
                         UniffiForeignFutureCompleteVoid rsCallback) {
    return jsi::Function::createFromHostFunction(
        rt, jsi::PropNameID::forAscii(rt, "--ForeignFutureCompleteVoid"), 2,
        [rsCallback, callInvoker](jsi::Runtime &rt, const jsi::Value &thisValue,
                                  const jsi::Value *arguments,
                                  size_t count) -> jsi::Value {
          return intoRust(rt, callInvoker, thisValue, arguments, count,
                          rsCallback);
        });
  }

  static jsi::Value intoRust(jsi::Runtime &rt,
                             std::shared_ptr<CallInvoker> callInvoker,
                             const jsi::Value &thisValue,
                             const jsi::Value *args, size_t count,
                             UniffiForeignFutureCompleteVoid func) {
    // Convert the arguments into the Rust, with Bridging<T>::fromJs,
    // then call the rs_callback with those arguments.
    func(uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]),
         uniffi::breez_sdk_spark::Bridging<
             UniffiForeignFutureStructVoid>::fromJs(rt, callInvoker, args[1]));

    return jsi::Value::undefined();
  }
};
} // namespace uniffi::breez_sdk_spark
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceEventListenerMethod0

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceeventlistenermethod0::UniffiCallbackInterfaceEventListenerMethod0
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfaceeventlistenermethod0 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, UniffiForeignFutureCompleteVoid,
                          uint64_t, UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_event,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_event = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_event);
  auto js_uniffiFutureCallback =
      uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureCompleteVoid>::toJs(
          rt, callInvoker, rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_event,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout
        << "Error in callback UniffiCallbackInterfaceEventListenerMethod0: "
        << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle, RustBuffer rs_event,
                     UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                     uint64_t rs_uniffiCallbackData,
                     UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_event, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceEventListenerMethod0
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceeventlistenermethod0
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_event,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_event,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_event,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceeventlistenermethod0
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceLoggerMethod0

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceloggermethod0::UniffiCallbackInterfaceLoggerMethod0
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfaceloggermethod0 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, void *, RustCallStatus *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_l,
                 void *rs_uniffiOutReturn, RustCallStatus *uniffi_call_status) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_l = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_l);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_l);

    // Now copy the result back from JS into the RustCallStatus object.
    uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyFromJs(
        rt, callInvoker, uniffiResult, uniffi_call_status);

    if (uniffi_call_status->code != UNIFFI_CALL_STATUS_OK) {
      // The JS callback finished abnormally, so we cannot retrieve the return
      // value.
      return;
    }

  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceLoggerMethod0: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle, RustBuffer rs_l,
                     void *rs_uniffiOutReturn,
                     RustCallStatus *uniffi_call_status) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_l, rs_uniffiOutReturn, uniffi_call_status);
}

static UniffiCallbackInterfaceLoggerMethod0
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceloggermethod0
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_l,
                 void *rs_uniffiOutReturn, RustCallStatus *uniffi_call_status) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_l, rs_uniffiOutReturn,
         uniffi_call_status](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_l,
               rs_uniffiOutReturn, uniffi_call_status);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfaceloggermethod0
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceBitcoinChainServiceMethod0

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod0::UniffiCallbackInterfaceBitcoinChainServiceMethod0
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfacebitcoinchainservicemethod0 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_address,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_address = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_address);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_address,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceBitcoinChainServiceMethod0: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_address,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_address, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceBitcoinChainServiceMethod0
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod0
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_address,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_address,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_address,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod0
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceBitcoinChainServiceMethod1

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod1::UniffiCallbackInterfaceBitcoinChainServiceMethod1
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfacebitcoinchainservicemethod1 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_address,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_address = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_address);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_address,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceBitcoinChainServiceMethod1: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_address,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_address, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceBitcoinChainServiceMethod1
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod1
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_address,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_address,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_address,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod1
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceBitcoinChainServiceMethod2

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod2::UniffiCallbackInterfaceBitcoinChainServiceMethod2
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfacebitcoinchainservicemethod2 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_txid,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_txid = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_txid);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_txid,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceBitcoinChainServiceMethod2: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_txid,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_txid, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceBitcoinChainServiceMethod2
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod2
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_txid,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_txid,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_txid,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod2
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceBitcoinChainServiceMethod3

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod3::UniffiCallbackInterfaceBitcoinChainServiceMethod3
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfacebitcoinchainservicemethod3 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, UniffiForeignFutureCompleteU32, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle,
                 UniffiForeignFutureCompleteU32 rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_uniffiFutureCallback =
      uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureCompleteU32>::toJs(
          rt, callInvoker, rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_uniffiFutureCallback,
                                js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceBitcoinChainServiceMethod3: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle,
                     UniffiForeignFutureCompleteU32 rs_uniffiFutureCallback,
                     uint64_t rs_uniffiCallbackData,
                     UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_uniffiFutureCallback, rs_uniffiCallbackData,
           rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceBitcoinChainServiceMethod3
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod3
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle,
                 UniffiForeignFutureCompleteU32 rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_uniffiFutureCallback,
         rs_uniffiCallbackData, rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod3
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceBitcoinChainServiceMethod4

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod4::UniffiCallbackInterfaceBitcoinChainServiceMethod4
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfacebitcoinchainservicemethod4 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_txid,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_txid = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_txid);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_txid,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceBitcoinChainServiceMethod4: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_txid,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_txid, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceBitcoinChainServiceMethod4
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod4
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_txid,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_txid,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_txid,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod4
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceBitcoinChainServiceMethod5

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod5::UniffiCallbackInterfaceBitcoinChainServiceMethod5
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfacebitcoinchainservicemethod5 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, uint32_t,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_txid, uint32_t rs_vout,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_txid = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_txid);
  auto js_vout = uniffi_jsi::Bridging<uint32_t>::toJs(rt, callInvoker, rs_vout);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_txid, js_vout,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceBitcoinChainServiceMethod5: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_txid, uint32_t rs_vout,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_txid, rs_vout, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceBitcoinChainServiceMethod5
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod5
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_txid, uint32_t rs_vout,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_txid, rs_vout,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_txid,
               rs_vout, rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod5
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceBitcoinChainServiceMethod6

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod6::UniffiCallbackInterfaceBitcoinChainServiceMethod6
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfacebitcoinchainservicemethod6 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, UniffiForeignFutureCompleteVoid,
                          uint64_t, UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_tx,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_tx = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_tx);
  auto js_uniffiFutureCallback =
      uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureCompleteVoid>::toJs(
          rt, callInvoker, rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_tx,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceBitcoinChainServiceMethod6: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle, RustBuffer rs_tx,
                     UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                     uint64_t rs_uniffiCallbackData,
                     UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_tx, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceBitcoinChainServiceMethod6
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod6
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_tx,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_tx,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_tx,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod6
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceBitcoinChainServiceMethod7

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod7::UniffiCallbackInterfaceBitcoinChainServiceMethod7
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfacebitcoinchainservicemethod7 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, UniffiForeignFutureCompleteRustBuffer,
                          uint64_t, UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_uniffiFutureCallback,
                                js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceBitcoinChainServiceMethod7: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_uniffiFutureCallback, rs_uniffiCallbackData,
           rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceBitcoinChainServiceMethod7
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod7
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_uniffiFutureCallback,
         rs_uniffiCallbackData, rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod7
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceCpfpSignerMethod0

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacecpfpsignermethod0::UniffiCallbackInterfaceCpfpSignerMethod0
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacecpfpsignermethod0 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_psbtBytes,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_psbtBytes = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_psbtBytes);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_psbtBytes,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceCpfpSignerMethod0: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_psbtBytes,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_psbtBytes, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceCpfpSignerMethod0
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacecpfpsignermethod0
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_psbtBytes,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_psbtBytes,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_psbtBytes,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacecpfpsignermethod0
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalBreezSignerMethod0

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod0::UniffiCallbackInterfaceExternalBreezSignerMethod0
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalbreezsignermethod0 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_path,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_path = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_path);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_path,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalBreezSignerMethod0: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_path,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_path, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalBreezSignerMethod0
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod0
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_path,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_path,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_path,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod0
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalBreezSignerMethod1

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod1::UniffiCallbackInterfaceExternalBreezSignerMethod1
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalbreezsignermethod1 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_message,
                 RustBuffer rs_path,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_message = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_message);
  auto js_path = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_path);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_message, js_path,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalBreezSignerMethod1: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_message, RustBuffer rs_path,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_message, rs_path, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalBreezSignerMethod1
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod1
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_message,
                 RustBuffer rs_path,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_message, rs_path,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_message,
               rs_path, rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod1
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalBreezSignerMethod2

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod2::UniffiCallbackInterfaceExternalBreezSignerMethod2
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalbreezsignermethod2 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_message,
                 RustBuffer rs_path,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_message = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_message);
  auto js_path = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_path);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_message, js_path,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalBreezSignerMethod2: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_message, RustBuffer rs_path,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_message, rs_path, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalBreezSignerMethod2
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod2
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_message,
                 RustBuffer rs_path,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_message, rs_path,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_message,
               rs_path, rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod2
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalBreezSignerMethod3

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod3::UniffiCallbackInterfaceExternalBreezSignerMethod3
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalbreezsignermethod3 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_message,
                 RustBuffer rs_path,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_message = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_message);
  auto js_path = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_path);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_message, js_path,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalBreezSignerMethod3: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_message, RustBuffer rs_path,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_message, rs_path, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalBreezSignerMethod3
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod3
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_message,
                 RustBuffer rs_path,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_message, rs_path,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_message,
               rs_path, rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod3
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalBreezSignerMethod4

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod4::UniffiCallbackInterfaceExternalBreezSignerMethod4
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalbreezsignermethod4 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_message,
                 RustBuffer rs_path,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_message = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_message);
  auto js_path = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_path);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_message, js_path,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalBreezSignerMethod4: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_message, RustBuffer rs_path,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_message, rs_path, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalBreezSignerMethod4
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod4
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_message,
                 RustBuffer rs_path,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_message, rs_path,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_message,
               rs_path, rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod4
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalBreezSignerMethod5

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod5::UniffiCallbackInterfaceExternalBreezSignerMethod5
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalbreezsignermethod5 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_hash,
                 RustBuffer rs_path,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_hash = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_hash);
  auto js_path = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_path);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_hash, js_path,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalBreezSignerMethod5: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_hash, RustBuffer rs_path,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_hash, rs_path, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalBreezSignerMethod5
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod5
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_hash,
                 RustBuffer rs_path,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_hash, rs_path,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_hash,
               rs_path, rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod5
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalBreezSignerMethod6

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod6::UniffiCallbackInterfaceExternalBreezSignerMethod6
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalbreezsignermethod6 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_message,
                 RustBuffer rs_path,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_message = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_message);
  auto js_path = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_path);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_message, js_path,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalBreezSignerMethod6: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_message, RustBuffer rs_path,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_message, rs_path, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalBreezSignerMethod6
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod6
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_message,
                 RustBuffer rs_path,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_message, rs_path,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_message,
               rs_path, rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod6
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalSigningSignerMethod0

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsigningsignermethod0::UniffiCallbackInterfaceExternalSigningSignerMethod0
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalsigningsignermethod0 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_path,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_path = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_path);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_path,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalSigningSignerMethod0: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_path,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_path, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalSigningSignerMethod0
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsigningsignermethod0
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_path,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_path,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_path,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsigningsignermethod0
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalSigningSignerMethod1

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsigningsignermethod1::UniffiCallbackInterfaceExternalSigningSignerMethod1
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalsigningsignermethod1 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_message,
                 RustBuffer rs_path,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_message = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_message);
  auto js_path = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_path);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_message, js_path,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalSigningSignerMethod1: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_message, RustBuffer rs_path,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_message, rs_path, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalSigningSignerMethod1
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsigningsignermethod1
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_message,
                 RustBuffer rs_path,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_message, rs_path,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_message,
               rs_path, rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsigningsignermethod1
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalSigningSignerMethod2

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsigningsignermethod2::UniffiCallbackInterfaceExternalSigningSignerMethod2
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalsigningsignermethod2 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_message,
                 RustBuffer rs_path,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_message = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_message);
  auto js_path = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_path);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_message, js_path,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalSigningSignerMethod2: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_message, RustBuffer rs_path,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_message, rs_path, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalSigningSignerMethod2
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsigningsignermethod2
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_message,
                 RustBuffer rs_path,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_message, rs_path,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_message,
               rs_path, rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsigningsignermethod2
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalSigningSignerMethod3

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsigningsignermethod3::UniffiCallbackInterfaceExternalSigningSignerMethod3
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalsigningsignermethod3 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_hash,
                 RustBuffer rs_path,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_hash = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_hash);
  auto js_path = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_path);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_hash, js_path,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalSigningSignerMethod3: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_hash, RustBuffer rs_path,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_hash, rs_path, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalSigningSignerMethod3
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsigningsignermethod3
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_hash,
                 RustBuffer rs_path,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_hash, rs_path,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_hash,
               rs_path, rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsigningsignermethod3
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalSparkSignerMethod0

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod0::UniffiCallbackInterfaceExternalSparkSignerMethod0
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalsparksignermethod0 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, UniffiForeignFutureCompleteRustBuffer,
                          uint64_t, UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_uniffiFutureCallback,
                                js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalSparkSignerMethod0: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_uniffiFutureCallback, rs_uniffiCallbackData,
           rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalSparkSignerMethod0
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod0
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_uniffiFutureCallback,
         rs_uniffiCallbackData, rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod0
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalSparkSignerMethod1

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod1::UniffiCallbackInterfaceExternalSparkSignerMethod1
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalsparksignermethod1 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_leafId,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_leafId = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_leafId);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_leafId,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalSparkSignerMethod1: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_leafId,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_leafId, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalSparkSignerMethod1
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod1
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_leafId,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_leafId,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_leafId,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod1
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalSparkSignerMethod2

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod2::UniffiCallbackInterfaceExternalSparkSignerMethod2
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalsparksignermethod2 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, int8_t *, RustCallStatus *)> rsLambda =
    nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, int8_t *rs_uniffiOutReturn,
                 RustCallStatus *uniffi_call_status) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle);

    // Now copy the result back from JS into the RustCallStatus object.
    uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyFromJs(
        rt, callInvoker, uniffiResult, uniffi_call_status);

    if (uniffi_call_status->code != UNIFFI_CALL_STATUS_OK) {
      // The JS callback finished abnormally, so we cannot retrieve the return
      // value.
      return;
    }

    // return type is MutReference(Int8)
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn = uniffi_jsi::Bridging<ReferenceHolder<int8_t>>::fromJs(
        rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalSparkSignerMethod2: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle, int8_t *rs_uniffiOutReturn,
                     RustCallStatus *uniffi_call_status) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_uniffiOutReturn, uniffi_call_status);
}

static UniffiCallbackInterfaceExternalSparkSignerMethod2
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod2
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, int8_t *rs_uniffiOutReturn,
                 RustCallStatus *uniffi_call_status) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_uniffiOutReturn,
         uniffi_call_status](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle,
               rs_uniffiOutReturn, uniffi_call_status);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod2
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalSparkSignerMethod3

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod3::UniffiCallbackInterfaceExternalSparkSignerMethod3
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalsparksignermethod3 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, uint32_t,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, uint32_t rs_index,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_index =
      uniffi_jsi::Bridging<uint32_t>::toJs(rt, callInvoker, rs_index);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_index,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalSparkSignerMethod3: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, uint32_t rs_index,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_index, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalSparkSignerMethod3
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod3
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, uint32_t rs_index,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_index,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_index,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod3
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalSparkSignerMethod4

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod4::UniffiCallbackInterfaceExternalSparkSignerMethod4
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalsparksignermethod4 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_challenge,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_challenge = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_challenge);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_challenge,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalSparkSignerMethod4: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_challenge,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_challenge, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalSparkSignerMethod4
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod4
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_challenge,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_challenge,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_challenge,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod4
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalSparkSignerMethod5

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod5::UniffiCallbackInterfaceExternalSparkSignerMethod5
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalsparksignermethod5 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_message,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_message = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_message);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_message,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalSparkSignerMethod5: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_message,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_message, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalSparkSignerMethod5
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod5
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_message,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_message,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_message,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod5
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalSparkSignerMethod6

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod6::UniffiCallbackInterfaceExternalSparkSignerMethod6
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalsparksignermethod6 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_leafId,
                 RustBuffer rs_sighash,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_leafId = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_leafId);
  auto js_sighash = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_sighash);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_leafId, js_sighash,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalSparkSignerMethod6: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_leafId, RustBuffer rs_sighash,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_leafId, rs_sighash, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalSparkSignerMethod6
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod6
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_leafId,
                 RustBuffer rs_sighash,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_leafId, rs_sighash,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_leafId,
               rs_sighash, rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod6
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalSparkSignerMethod7

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod7::UniffiCallbackInterfaceExternalSparkSignerMethod7
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalsparksignermethod7 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_jobs,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_jobs = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_jobs);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_jobs,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalSparkSignerMethod7: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_jobs,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_jobs, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalSparkSignerMethod7
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod7
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_jobs,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_jobs,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_jobs,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod7
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalSparkSignerMethod8

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod8::UniffiCallbackInterfaceExternalSparkSignerMethod8
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalsparksignermethod8 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_request,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_request = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_request);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_request,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalSparkSignerMethod8: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_request,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_request, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalSparkSignerMethod8
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod8
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_request,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_request,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_request,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod8
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalSparkSignerMethod9

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod9::UniffiCallbackInterfaceExternalSparkSignerMethod9
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalsparksignermethod9 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_request,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_request = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_request);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_request,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalSparkSignerMethod9: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_request,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_request, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalSparkSignerMethod9
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod9
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_request,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_request,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_request,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod9
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalSparkSignerMethod10

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod10::UniffiCallbackInterfaceExternalSparkSignerMethod10
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalsparksignermethod10 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_request,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_request = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_request);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_request,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalSparkSignerMethod10: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_request,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_request, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalSparkSignerMethod10
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod10
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_request,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_request,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_request,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod10
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalSparkSignerMethod11

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod11::UniffiCallbackInterfaceExternalSparkSignerMethod11
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalsparksignermethod11 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_request,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_request = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_request);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_request,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalSparkSignerMethod11: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_request,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_request, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalSparkSignerMethod11
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod11
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_request,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_request,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_request,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod11
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalSparkSignerMethod12

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod12::UniffiCallbackInterfaceExternalSparkSignerMethod12
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalsparksignermethod12 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_request,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_request = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_request);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_request,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalSparkSignerMethod12: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_request,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_request, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalSparkSignerMethod12
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod12
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_request,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_request,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_request,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod12
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalSparkSignerMethod13

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod13::UniffiCallbackInterfaceExternalSparkSignerMethod13
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalsparksignermethod13 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_request,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_request = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_request);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_request,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalSparkSignerMethod13: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_request,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_request, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalSparkSignerMethod13
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod13
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_request,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_request,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_request,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod13
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalSparkSignerMethod14

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod14::UniffiCallbackInterfaceExternalSparkSignerMethod14
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalsparksignermethod14 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_request,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_request = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_request);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_request,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalSparkSignerMethod14: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_request,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_request, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalSparkSignerMethod14
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod14
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_request,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_request,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_request,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod14
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalSparkSignerMethod15

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod15::UniffiCallbackInterfaceExternalSparkSignerMethod15
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalsparksignermethod15 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_request,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_request = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_request);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_request,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalSparkSignerMethod15: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_request,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_request, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalSparkSignerMethod15
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod15
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_request,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_request,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_request,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod15
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceExternalSparkSignerMethod16

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod16::UniffiCallbackInterfaceExternalSparkSignerMethod16
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::
    callbackinterfaceexternalsparksignermethod16 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_request,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_request = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_request);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_request,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback "
                 "UniffiCallbackInterfaceExternalSparkSignerMethod16: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_request,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_request, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceExternalSparkSignerMethod16
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod16
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_request,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_request,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_request,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod16
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceFiatServiceMethod0

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacefiatservicemethod0::UniffiCallbackInterfaceFiatServiceMethod0
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacefiatservicemethod0 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, UniffiForeignFutureCompleteRustBuffer,
                          uint64_t, UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_uniffiFutureCallback,
                                js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceFiatServiceMethod0: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_uniffiFutureCallback, rs_uniffiCallbackData,
           rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceFiatServiceMethod0
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacefiatservicemethod0
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_uniffiFutureCallback,
         rs_uniffiCallbackData, rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacefiatservicemethod0
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceFiatServiceMethod1

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacefiatservicemethod1::UniffiCallbackInterfaceFiatServiceMethod1
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacefiatservicemethod1 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, UniffiForeignFutureCompleteRustBuffer,
                          uint64_t, UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_uniffiFutureCallback,
                                js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceFiatServiceMethod1: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_uniffiFutureCallback, rs_uniffiCallbackData,
           rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceFiatServiceMethod1
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacefiatservicemethod1
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_uniffiFutureCallback,
         rs_uniffiCallbackData, rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacefiatservicemethod1
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfacePaymentObserverMethod0

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacepaymentobservermethod0::UniffiCallbackInterfacePaymentObserverMethod0
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacepaymentobservermethod0 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, UniffiForeignFutureCompleteVoid,
                          uint64_t, UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_payments,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_payments = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_payments);
  auto js_uniffiFutureCallback =
      uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureCompleteVoid>::toJs(
          rt, callInvoker, rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_payments,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout
        << "Error in callback UniffiCallbackInterfacePaymentObserverMethod0: "
        << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle, RustBuffer rs_payments,
                     UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                     uint64_t rs_uniffiCallbackData,
                     UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_payments, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfacePaymentObserverMethod0
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacepaymentobservermethod0
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_payments,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_payments,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_payments,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfacepaymentobservermethod0
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfacePaymentObserverMethod1

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacepaymentobservermethod1::UniffiCallbackInterfacePaymentObserverMethod1
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacepaymentobservermethod1 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, UniffiForeignFutureCompleteVoid,
                          uint64_t, UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_updates,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_updates = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_updates);
  auto js_uniffiFutureCallback =
      uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureCompleteVoid>::toJs(
          rt, callInvoker, rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_updates,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout
        << "Error in callback UniffiCallbackInterfacePaymentObserverMethod1: "
        << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle, RustBuffer rs_updates,
                     UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                     uint64_t rs_uniffiCallbackData,
                     UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_updates, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfacePaymentObserverMethod1
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacepaymentobservermethod1
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_updates,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_updates,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_updates,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfacepaymentobservermethod1
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfacePrfProviderMethod0

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceprfprovidermethod0::UniffiCallbackInterfacePrfProviderMethod0
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfaceprfprovidermethod0 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_request,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_request = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_request);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_request,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfacePrfProviderMethod0: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_request,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_request, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfacePrfProviderMethod0
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceprfprovidermethod0
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_request,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_request,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_request,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfaceprfprovidermethod0
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfacePrfProviderMethod1

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceprfprovidermethod1::UniffiCallbackInterfacePrfProviderMethod1
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfaceprfprovidermethod1 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, UniffiForeignFutureCompleteI8, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle,
                 UniffiForeignFutureCompleteI8 rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_uniffiFutureCallback =
      uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureCompleteI8>::toJs(
          rt, callInvoker, rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_uniffiFutureCallback,
                                js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfacePrfProviderMethod1: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle,
                     UniffiForeignFutureCompleteI8 rs_uniffiFutureCallback,
                     uint64_t rs_uniffiCallbackData,
                     UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_uniffiFutureCallback, rs_uniffiCallbackData,
           rs_uniffiOutReturn);
}

static UniffiCallbackInterfacePrfProviderMethod1
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceprfprovidermethod1
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle,
                 UniffiForeignFutureCompleteI8 rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_uniffiFutureCallback,
         rs_uniffiCallbackData, rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfaceprfprovidermethod1
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfacePrfProviderMethod2

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceprfprovidermethod2::UniffiCallbackInterfacePrfProviderMethod2
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfaceprfprovidermethod2 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_excludeCredentials,
                 RustBuffer rs_salts,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_excludeCredentials =
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
          rt, callInvoker, rs_excludeCredentials);
  auto js_salts = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_salts);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult =
        cb.call(rt, js_uniffiHandle, js_excludeCredentials, js_salts,
                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfacePrfProviderMethod2: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_excludeCredentials,
         RustBuffer rs_salts,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_excludeCredentials, rs_salts,
           rs_uniffiFutureCallback, rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfacePrfProviderMethod2
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceprfprovidermethod2
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_excludeCredentials,
                 RustBuffer rs_salts,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_excludeCredentials,
         rs_salts, rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle,
               rs_excludeCredentials, rs_salts, rs_uniffiFutureCallback,
               rs_uniffiCallbackData, rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfaceprfprovidermethod2
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfacePrfProviderMethod3

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfaceprfprovidermethod3::UniffiCallbackInterfacePrfProviderMethod3
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfaceprfprovidermethod3 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, UniffiForeignFutureCompleteRustBuffer,
                          uint64_t, UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_uniffiFutureCallback,
                                js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfacePrfProviderMethod3: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_uniffiFutureCallback, rs_uniffiCallbackData,
           rs_uniffiOutReturn);
}

static UniffiCallbackInterfacePrfProviderMethod3
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfaceprfprovidermethod3
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_uniffiFutureCallback,
         rs_uniffiCallbackData, rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfaceprfprovidermethod3
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceRestClientMethod0

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacerestclientmethod0::UniffiCallbackInterfaceRestClientMethod0
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacerestclientmethod0 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_url,
                 RustBuffer rs_headers,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_url = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_url);
  auto js_headers = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_headers);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_url, js_headers,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceRestClientMethod0: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_url, RustBuffer rs_headers,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_url, rs_headers, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceRestClientMethod0
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacerestclientmethod0
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_url,
                 RustBuffer rs_headers,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_url, rs_headers,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_url,
               rs_headers, rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacerestclientmethod0
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceRestClientMethod1

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacerestclientmethod1::UniffiCallbackInterfaceRestClientMethod1
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacerestclientmethod1 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, RustBuffer, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_url,
                 RustBuffer rs_headers, RustBuffer rs_body,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_url = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_url);
  auto js_headers = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_headers);
  auto js_body = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_body);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult =
        cb.call(rt, js_uniffiHandle, js_url, js_headers, js_body,
                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceRestClientMethod1: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_url, RustBuffer rs_headers,
         RustBuffer rs_body,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_url, rs_headers, rs_body,
           rs_uniffiFutureCallback, rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceRestClientMethod1
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacerestclientmethod1
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_url,
                 RustBuffer rs_headers, RustBuffer rs_body,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_url, rs_headers,
         rs_body, rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_url,
               rs_headers, rs_body, rs_uniffiFutureCallback,
               rs_uniffiCallbackData, rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacerestclientmethod1
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceRestClientMethod2

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacerestclientmethod2::UniffiCallbackInterfaceRestClientMethod2
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacerestclientmethod2 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, RustBuffer, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_url,
                 RustBuffer rs_headers, RustBuffer rs_body,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_url = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_url);
  auto js_headers = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_headers);
  auto js_body = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_body);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult =
        cb.call(rt, js_uniffiHandle, js_url, js_headers, js_body,
                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceRestClientMethod2: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_url, RustBuffer rs_headers,
         RustBuffer rs_body,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_url, rs_headers, rs_body,
           rs_uniffiFutureCallback, rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceRestClientMethod2
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacerestclientmethod2
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_url,
                 RustBuffer rs_headers, RustBuffer rs_body,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_url, rs_headers,
         rs_body, rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_url,
               rs_headers, rs_body, rs_uniffiFutureCallback,
               rs_uniffiCallbackData, rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacerestclientmethod2
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceSessionStoreMethod0

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacesessionstoremethod0::UniffiCallbackInterfaceSessionStoreMethod0
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacesessionstoremethod0 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_serviceIdentityKey,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_serviceIdentityKey =
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
          rt, callInvoker, rs_serviceIdentityKey);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_serviceIdentityKey,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout
        << "Error in callback UniffiCallbackInterfaceSessionStoreMethod0: "
        << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_serviceIdentityKey,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_serviceIdentityKey, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceSessionStoreMethod0
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacesessionstoremethod0
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_serviceIdentityKey,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_serviceIdentityKey,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle,
               rs_serviceIdentityKey, rs_uniffiFutureCallback,
               rs_uniffiCallbackData, rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacesessionstoremethod0
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceSessionStoreMethod1

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacesessionstoremethod1::UniffiCallbackInterfaceSessionStoreMethod1
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacesessionstoremethod1 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, RustBuffer,
                          UniffiForeignFutureCompleteVoid, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_serviceIdentityKey,
                 RustBuffer rs_session,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_serviceIdentityKey =
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
          rt, callInvoker, rs_serviceIdentityKey);
  auto js_session = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_session);
  auto js_uniffiFutureCallback =
      uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureCompleteVoid>::toJs(
          rt, callInvoker, rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult =
        cb.call(rt, js_uniffiHandle, js_serviceIdentityKey, js_session,
                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout
        << "Error in callback UniffiCallbackInterfaceSessionStoreMethod1: "
        << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle, RustBuffer rs_serviceIdentityKey,
                     RustBuffer rs_session,
                     UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                     uint64_t rs_uniffiCallbackData,
                     UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_serviceIdentityKey, rs_session,
           rs_uniffiFutureCallback, rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceSessionStoreMethod1
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacesessionstoremethod1
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_serviceIdentityKey,
                 RustBuffer rs_session,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_serviceIdentityKey,
         rs_session, rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle,
               rs_serviceIdentityKey, rs_session, rs_uniffiFutureCallback,
               rs_uniffiCallbackData, rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacesessionstoremethod1
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod0

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod0::UniffiCallbackInterfaceStorageMethod0
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod0 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, UniffiForeignFutureCompleteVoid,
                          uint64_t, UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_key,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_key = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_key);
  auto js_uniffiFutureCallback =
      uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureCompleteVoid>::toJs(
          rt, callInvoker, rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_key,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod0: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle, RustBuffer rs_key,
                     UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                     uint64_t rs_uniffiCallbackData,
                     UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_key, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod0
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod0
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_key,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_key,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_key,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod0
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod1

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod1::UniffiCallbackInterfaceStorageMethod1
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod1 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_key,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_key = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_key);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_key,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod1: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_key,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_key, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod1
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod1
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_key,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_key,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_key,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod1
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod2

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod2::UniffiCallbackInterfaceStorageMethod2
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod2 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, RustBuffer,
                          UniffiForeignFutureCompleteVoid, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_key,
                 RustBuffer rs_value,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_key = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_key);
  auto js_value = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_value);
  auto js_uniffiFutureCallback =
      uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureCompleteVoid>::toJs(
          rt, callInvoker, rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_key, js_value,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod2: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle, RustBuffer rs_key,
                     RustBuffer rs_value,
                     UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                     uint64_t rs_uniffiCallbackData,
                     UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_key, rs_value, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod2
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod2
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_key,
                 RustBuffer rs_value,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_key, rs_value,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_key,
               rs_value, rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod2
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod3

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod3::UniffiCallbackInterfaceStorageMethod3
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod3 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_request,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_request = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_request);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_request,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod3: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_request,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_request, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod3
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod3
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_request,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_request,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_request,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod3
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod4

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod4::UniffiCallbackInterfaceStorageMethod4
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod4 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, UniffiForeignFutureCompleteI8,
                          uint64_t, UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_payment,
                 UniffiForeignFutureCompleteI8 rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_payment = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_payment);
  auto js_uniffiFutureCallback =
      uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureCompleteI8>::toJs(
          rt, callInvoker, rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_payment,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod4: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle, RustBuffer rs_payment,
                     UniffiForeignFutureCompleteI8 rs_uniffiFutureCallback,
                     uint64_t rs_uniffiCallbackData,
                     UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_payment, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod4
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod4
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_payment,
                 UniffiForeignFutureCompleteI8 rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_payment,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_payment,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod4
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod5

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod5::UniffiCallbackInterfaceStorageMethod5
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod5 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, RustBuffer,
                          UniffiForeignFutureCompleteVoid, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_paymentId,
                 RustBuffer rs_metadata,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_paymentId = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_paymentId);
  auto js_metadata = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_metadata);
  auto js_uniffiFutureCallback =
      uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureCompleteVoid>::toJs(
          rt, callInvoker, rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_paymentId, js_metadata,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod5: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle, RustBuffer rs_paymentId,
                     RustBuffer rs_metadata,
                     UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                     uint64_t rs_uniffiCallbackData,
                     UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_paymentId, rs_metadata, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod5
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod5
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_paymentId,
                 RustBuffer rs_metadata,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_paymentId, rs_metadata,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_paymentId,
               rs_metadata, rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod5
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod6

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod6::UniffiCallbackInterfaceStorageMethod6
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod6 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_id,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_id = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_id);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_id,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod6: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_id,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_id, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod6
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod6
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_id,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_id,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_id,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod6
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod7

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod7::UniffiCallbackInterfaceStorageMethod7
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod7 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_invoice,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_invoice = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_invoice);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_invoice,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod7: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_invoice,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_invoice, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod7
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod7
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_invoice,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_invoice,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_invoice,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod7
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod8

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod8::UniffiCallbackInterfaceStorageMethod8
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod8 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_parentPaymentIds,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_parentPaymentIds =
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(rt, callInvoker,
                                                          rs_parentPaymentIds);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_parentPaymentIds,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod8: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_parentPaymentIds,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_parentPaymentIds, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod8
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod8
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_parentPaymentIds,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_parentPaymentIds,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle,
               rs_parentPaymentIds, rs_uniffiFutureCallback,
               rs_uniffiCallbackData, rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod8
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod9

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod9::UniffiCallbackInterfaceStorageMethod9
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod9 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, uint32_t, uint64_t, int8_t,
                          UniffiForeignFutureCompleteVoid, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_txid, uint32_t rs_vout,
                 uint64_t rs_amountSats, int8_t rs_isMature,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_txid = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_txid);
  auto js_vout = uniffi_jsi::Bridging<uint32_t>::toJs(rt, callInvoker, rs_vout);
  auto js_amountSats =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_amountSats);
  auto js_isMature =
      uniffi_jsi::Bridging<int8_t>::toJs(rt, callInvoker, rs_isMature);
  auto js_uniffiFutureCallback =
      uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureCompleteVoid>::toJs(
          rt, callInvoker, rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult =
        cb.call(rt, js_uniffiHandle, js_txid, js_vout, js_amountSats,
                js_isMature, js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod9: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle, RustBuffer rs_txid,
                     uint32_t rs_vout, uint64_t rs_amountSats,
                     int8_t rs_isMature,
                     UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                     uint64_t rs_uniffiCallbackData,
                     UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_txid, rs_vout, rs_amountSats, rs_isMature,
           rs_uniffiFutureCallback, rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod9
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod9
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_txid, uint32_t rs_vout,
                 uint64_t rs_amountSats, int8_t rs_isMature,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_txid, rs_vout,
         rs_amountSats, rs_isMature, rs_uniffiFutureCallback,
         rs_uniffiCallbackData, rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_txid,
               rs_vout, rs_amountSats, rs_isMature, rs_uniffiFutureCallback,
               rs_uniffiCallbackData, rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod9
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod10

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod10::UniffiCallbackInterfaceStorageMethod10
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod10 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, uint32_t,
                          UniffiForeignFutureCompleteVoid, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_txid, uint32_t rs_vout,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_txid = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_txid);
  auto js_vout = uniffi_jsi::Bridging<uint32_t>::toJs(rt, callInvoker, rs_vout);
  auto js_uniffiFutureCallback =
      uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureCompleteVoid>::toJs(
          rt, callInvoker, rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_txid, js_vout,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod10: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle, RustBuffer rs_txid,
                     uint32_t rs_vout,
                     UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                     uint64_t rs_uniffiCallbackData,
                     UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_txid, rs_vout, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod10
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod10
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_txid, uint32_t rs_vout,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_txid, rs_vout,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_txid,
               rs_vout, rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod10
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod11

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod11::UniffiCallbackInterfaceStorageMethod11
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod11 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, UniffiForeignFutureCompleteRustBuffer,
                          uint64_t, UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_uniffiFutureCallback,
                                js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod11: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_uniffiFutureCallback, rs_uniffiCallbackData,
           rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod11
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod11
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_uniffiFutureCallback,
         rs_uniffiCallbackData, rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod11
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod12

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod12::UniffiCallbackInterfaceStorageMethod12
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod12 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, uint32_t, RustBuffer,
                          UniffiForeignFutureCompleteVoid, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_txid, uint32_t rs_vout,
                 RustBuffer rs_payload,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_txid = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_txid);
  auto js_vout = uniffi_jsi::Bridging<uint32_t>::toJs(rt, callInvoker, rs_vout);
  auto js_payload = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_payload);
  auto js_uniffiFutureCallback =
      uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureCompleteVoid>::toJs(
          rt, callInvoker, rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult =
        cb.call(rt, js_uniffiHandle, js_txid, js_vout, js_payload,
                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod12: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle, RustBuffer rs_txid,
                     uint32_t rs_vout, RustBuffer rs_payload,
                     UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                     uint64_t rs_uniffiCallbackData,
                     UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_txid, rs_vout, rs_payload,
           rs_uniffiFutureCallback, rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod12
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod12
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_txid, uint32_t rs_vout,
                 RustBuffer rs_payload,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_txid, rs_vout,
         rs_payload, rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_txid,
               rs_vout, rs_payload, rs_uniffiFutureCallback,
               rs_uniffiCallbackData, rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod12
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod13

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod13::UniffiCallbackInterfaceStorageMethod13
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod13 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, UniffiForeignFutureCompleteVoid,
                          uint64_t, UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_metadata,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_metadata = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_metadata);
  auto js_uniffiFutureCallback =
      uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureCompleteVoid>::toJs(
          rt, callInvoker, rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_metadata,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod13: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle, RustBuffer rs_metadata,
                     UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                     uint64_t rs_uniffiCallbackData,
                     UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_metadata, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod13
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod13
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_metadata,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_metadata,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_metadata,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod13
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod14

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod14::UniffiCallbackInterfaceStorageMethod14
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod14 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_request,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_request = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_request);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_request,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod14: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_request,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_request, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod14
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod14
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_request,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_request,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_request,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod14
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod15

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod15::UniffiCallbackInterfaceStorageMethod15
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod15 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_id,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_id = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_id);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_id,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod15: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_id,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_id, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod15
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod15
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_id,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_id,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_id,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod15
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod16

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod16::UniffiCallbackInterfaceStorageMethod16
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod16 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, UniffiForeignFutureCompleteVoid,
                          uint64_t, UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_contact,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_contact = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_contact);
  auto js_uniffiFutureCallback =
      uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureCompleteVoid>::toJs(
          rt, callInvoker, rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_contact,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod16: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle, RustBuffer rs_contact,
                     UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                     uint64_t rs_uniffiCallbackData,
                     UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_contact, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod16
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod16
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_contact,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_contact,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_contact,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod16
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod17

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod17::UniffiCallbackInterfaceStorageMethod17
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod17 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, UniffiForeignFutureCompleteVoid,
                          uint64_t, UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_id,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_id = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_id);
  auto js_uniffiFutureCallback =
      uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureCompleteVoid>::toJs(
          rt, callInvoker, rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_id,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod17: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle, RustBuffer rs_id,
                     UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                     uint64_t rs_uniffiCallbackData,
                     UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_id, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod17
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod17
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_id,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_id,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_id,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod17
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod18

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod18::UniffiCallbackInterfaceStorageMethod18
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod18 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, UniffiForeignFutureCompleteVoid,
                          uint64_t, UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_swap,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_swap = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_swap);
  auto js_uniffiFutureCallback =
      uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureCompleteVoid>::toJs(
          rt, callInvoker, rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_swap,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod18: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle, RustBuffer rs_swap,
                     UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                     uint64_t rs_uniffiCallbackData,
                     UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_swap, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod18
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod18
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_swap,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_swap,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_swap,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod18
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod19

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod19::UniffiCallbackInterfaceStorageMethod19
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod19 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_provider,
                 RustBuffer rs_id,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_provider = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_provider);
  auto js_id = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_id);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_provider, js_id,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod19: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_provider, RustBuffer rs_id,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_provider, rs_id, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod19
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod19
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_provider,
                 RustBuffer rs_id,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_provider, rs_id,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_provider,
               rs_id, rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod19
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod20

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod20::UniffiCallbackInterfaceStorageMethod20
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod20 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_provider,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_provider = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_provider);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_provider,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod20: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, RustBuffer rs_provider,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_provider, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod20
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod20
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_provider,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_provider,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_provider,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod20
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod21

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod21::UniffiCallbackInterfaceStorageMethod21
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod21 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, UniffiForeignFutureCompleteU64,
                          uint64_t, UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_record,
                 UniffiForeignFutureCompleteU64 rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_record = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_record);
  auto js_uniffiFutureCallback =
      uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureCompleteU64>::toJs(
          rt, callInvoker, rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_record,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod21: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle, RustBuffer rs_record,
                     UniffiForeignFutureCompleteU64 rs_uniffiFutureCallback,
                     uint64_t rs_uniffiCallbackData,
                     UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_record, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod21
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod21
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_record,
                 UniffiForeignFutureCompleteU64 rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_record,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_record,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod21
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod22

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod22::UniffiCallbackInterfaceStorageMethod22
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod22 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, uint64_t,
                          UniffiForeignFutureCompleteVoid, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_record,
                 uint64_t rs_localRevision,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_record = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_record);
  auto js_localRevision =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_localRevision);
  auto js_uniffiFutureCallback =
      uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureCompleteVoid>::toJs(
          rt, callInvoker, rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult =
        cb.call(rt, js_uniffiHandle, js_record, js_localRevision,
                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod22: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle, RustBuffer rs_record,
                     uint64_t rs_localRevision,
                     UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                     uint64_t rs_uniffiCallbackData,
                     UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_record, rs_localRevision,
           rs_uniffiFutureCallback, rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod22
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod22
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_record,
                 uint64_t rs_localRevision,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_record,
         rs_localRevision, rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_record,
               rs_localRevision, rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod22
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod23

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod23::UniffiCallbackInterfaceStorageMethod23
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod23 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, uint32_t,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, uint32_t rs_limit,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_limit =
      uniffi_jsi::Bridging<uint32_t>::toJs(rt, callInvoker, rs_limit);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_limit,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod23: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, uint32_t rs_limit,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_limit, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod23
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod23
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, uint32_t rs_limit,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_limit,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_limit,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod23
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod24

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod24::UniffiCallbackInterfaceStorageMethod24
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod24 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, UniffiForeignFutureCompleteU64, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle,
                 UniffiForeignFutureCompleteU64 rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_uniffiFutureCallback =
      uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureCompleteU64>::toJs(
          rt, callInvoker, rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_uniffiFutureCallback,
                                js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod24: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle,
                     UniffiForeignFutureCompleteU64 rs_uniffiFutureCallback,
                     uint64_t rs_uniffiCallbackData,
                     UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_uniffiFutureCallback, rs_uniffiCallbackData,
           rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod24
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod24
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle,
                 UniffiForeignFutureCompleteU64 rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_uniffiFutureCallback,
         rs_uniffiCallbackData, rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod24
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod25

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod25::UniffiCallbackInterfaceStorageMethod25
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod25 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, UniffiForeignFutureCompleteVoid,
                          uint64_t, UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_records,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_records = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_records);
  auto js_uniffiFutureCallback =
      uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureCompleteVoid>::toJs(
          rt, callInvoker, rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_records,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod25: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle, RustBuffer rs_records,
                     UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                     uint64_t rs_uniffiCallbackData,
                     UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_records, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod25
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod25
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_records,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_records,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_records,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod25
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod26

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod26::UniffiCallbackInterfaceStorageMethod26
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod26 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, UniffiForeignFutureCompleteVoid,
                          uint64_t, UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_record,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_record = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_record);
  auto js_uniffiFutureCallback =
      uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureCompleteVoid>::toJs(
          rt, callInvoker, rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_record,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod26: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle, RustBuffer rs_record,
                     UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                     uint64_t rs_uniffiCallbackData,
                     UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_record, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod26
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod26
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_record,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_record,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_record,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod26
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod27

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod27::UniffiCallbackInterfaceStorageMethod27
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod27 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, uint32_t,
                          UniffiForeignFutureCompleteRustBuffer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, uint32_t rs_limit,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_limit =
      uniffi_jsi::Bridging<uint32_t>::toJs(rt, callInvoker, rs_limit);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_limit,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod27: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle, uint32_t rs_limit,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_limit, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod27
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod27
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, uint32_t rs_limit,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_limit,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_limit,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod27
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod28

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod28::UniffiCallbackInterfaceStorageMethod28
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod28 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, UniffiForeignFutureCompleteRustBuffer,
                          uint64_t, UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompleteRustBuffer>::toJs(rt, callInvoker,
                                                   rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_uniffiFutureCallback,
                                js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod28: "
              << error.what() << std::endl;
    throw error;
  }
}

static void
callback(uint64_t rs_uniffiHandle,
         UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
         uint64_t rs_uniffiCallbackData,
         UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_uniffiFutureCallback, rs_uniffiCallbackData,
           rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod28
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod28
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle,
                 UniffiForeignFutureCompleteRustBuffer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_uniffiFutureCallback,
         rs_uniffiCallbackData, rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod28
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageMethod29

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod29::UniffiCallbackInterfaceStorageMethod29
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod29 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, UniffiForeignFutureCompleteVoid,
                          uint64_t, UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_record,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_record = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_record);
  auto js_uniffiFutureCallback =
      uniffi::breez_sdk_spark::Bridging<UniffiForeignFutureCompleteVoid>::toJs(
          rt, callInvoker, rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_record,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout << "Error in callback UniffiCallbackInterfaceStorageMethod29: "
              << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle, RustBuffer rs_record,
                     UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                     uint64_t rs_uniffiCallbackData,
                     UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_record, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageMethod29
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod29
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_record,
                 UniffiForeignFutureCompleteVoid rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_record,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_record,
               rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod29
  // Implementation of callback function calling from Rust to JS
  // CallbackInterfaceStorageBackendMethod0

// Callback function:
// uniffi::breez_sdk_spark::cb::callbackinterfacestoragebackendmethod0::UniffiCallbackInterfaceStorageBackendMethod0
//
// We have the following constraints:
// - we need to pass a function pointer to Rust.
// - we need a jsi::Runtime and jsi::Function to call into JS.
// - function pointers can't store state, so we can't use a lamda.
//
// For this, we store a lambda as a global, as `rsLambda`. The `callback`
// function calls the lambda, which itself calls the `body` which then calls
// into JS.
//
// We then give the `callback` function pointer to Rust which will call the
// lambda sometime in the future.
namespace uniffi::breez_sdk_spark::cb::callbackinterfacestoragebackendmethod0 {
using namespace facebook;

// We need to store a lambda in a global so we can call it from
// a function pointer. The function pointer is passed to Rust.
static std::function<void(uint64_t, RustBuffer, RustBuffer,
                          UniffiForeignFutureCompletePointer, uint64_t,
                          UniffiForeignFuture *)>
    rsLambda = nullptr;

// This is the main body of the callback. It's called from the lambda,
// which itself is called from the callback function which is passed to Rust.
static void body(jsi::Runtime &rt,
                 std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
                 std::shared_ptr<jsi::Value> callbackValue,
                 uint64_t rs_uniffiHandle, RustBuffer rs_network,
                 RustBuffer rs_identity,
                 UniffiForeignFutureCompletePointer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {

  // Convert the arguments from Rust, into jsi::Values.
  // We'll use the Bridging class to do this…
  auto js_uniffiHandle =
      uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, rs_uniffiHandle);
  auto js_network = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_network);
  auto js_identity = uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(
      rt, callInvoker, rs_identity);
  auto js_uniffiFutureCallback = uniffi::breez_sdk_spark::Bridging<
      UniffiForeignFutureCompletePointer>::toJs(rt, callInvoker,
                                                rs_uniffiFutureCallback);
  auto js_uniffiCallbackData = uniffi_jsi::Bridging<uint64_t>::toJs(
      rt, callInvoker, rs_uniffiCallbackData);

  // Now we are ready to call the callback.
  // We are already on the JS thread, because this `body` function was
  // invoked from the CallInvoker.
  try {
    // Getting the callback function
    auto cb = callbackValue->asObject(rt).asFunction(rt);
    auto uniffiResult = cb.call(rt, js_uniffiHandle, js_network, js_identity,
                                js_uniffiFutureCallback, js_uniffiCallbackData);

    // return type is MutReference(Struct("ForeignFuture"))
    // Finally, we need to copy the return value back into the Rust pointer.
    *rs_uniffiOutReturn =
        uniffi::breez_sdk_spark::Bridging<UniffiForeignFuture>::fromJs(
            rt, callInvoker, uniffiResult);
  } catch (const jsi::JSError &error) {
    std::cout
        << "Error in callback UniffiCallbackInterfaceStorageBackendMethod0: "
        << error.what() << std::endl;
    throw error;
  }
}

static void callback(uint64_t rs_uniffiHandle, RustBuffer rs_network,
                     RustBuffer rs_identity,
                     UniffiForeignFutureCompletePointer rs_uniffiFutureCallback,
                     uint64_t rs_uniffiCallbackData,
                     UniffiForeignFuture *rs_uniffiOutReturn) {
  // If the runtime has shutdown, then there is no point in trying to
  // call into Javascript. BUT how do we tell if the runtime has shutdown?
  //
  // Answer: the module destructor calls into callback `cleanup` method,
  // which nulls out the rsLamda.
  //
  // If rsLamda is null, then there is no runtime to call into.
  if (rsLambda == nullptr) {
    // This only occurs when destructors are calling into Rust free/drop,
    // which causes the JS callback to be dropped.
    return;
  }

  // The runtime, the actual callback jsi::funtion, and the callInvoker
  // are all in the lambda.
  rsLambda(rs_uniffiHandle, rs_network, rs_identity, rs_uniffiFutureCallback,
           rs_uniffiCallbackData, rs_uniffiOutReturn);
}

static UniffiCallbackInterfaceStorageBackendMethod0
makeCallbackFunction( // uniffi::breez_sdk_spark::cb::callbackinterfacestoragebackendmethod0
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> callInvoker,
    const jsi::Value &value) {
  if (rsLambda != nullptr) {
    // `makeCallbackFunction` is called in two circumstances:
    //
    // 1. at startup, when initializing callback interface vtables.
    // 2. when polling futures. This happens at least once per future that is
    //    exposed to Javascript. We know that this is always the same function,
    //    `uniffiFutureContinuationCallback` in `async-rust-calls.ts`.
    //
    // We can therefore return the callback function without making anything
    // new if we've been initialized already.
    return callback;
  }
  auto callbackFunction = value.asObject(rt).asFunction(rt);
  auto callbackValue = std::make_shared<jsi::Value>(rt, callbackFunction);
  rsLambda = [&rt, callInvoker, callbackValue](
                 uint64_t rs_uniffiHandle, RustBuffer rs_network,
                 RustBuffer rs_identity,
                 UniffiForeignFutureCompletePointer rs_uniffiFutureCallback,
                 uint64_t rs_uniffiCallbackData,
                 UniffiForeignFuture *rs_uniffiOutReturn) {
    // We immediately make a lambda which will do the work of transforming the
    // arguments into JSI values and calling the callback.
    uniffi_runtime::UniffiCallFunc jsLambda =
        [callInvoker, callbackValue, rs_uniffiHandle, rs_network, rs_identity,
         rs_uniffiFutureCallback, rs_uniffiCallbackData,
         rs_uniffiOutReturn](jsi::Runtime &rt) mutable {
          body(rt, callInvoker, callbackValue, rs_uniffiHandle, rs_network,
               rs_identity, rs_uniffiFutureCallback, rs_uniffiCallbackData,
               rs_uniffiOutReturn);
        };
    // We'll then call that lambda from the callInvoker which will
    // look after calling it on the correct thread.
    callInvoker->invokeBlocking(rt, jsLambda);
  };
  return callback;
}

// This method is called from the destructor of NativeBreezSdkSpark, which only
// happens when the jsi::Runtime is being destroyed.
static void cleanup() {
  // The lambda holds a reference to the the Runtime, so when this is nulled
  // out, then the pointer will no longer be left dangling.
  rsLambda = nullptr;
}
} // namespace
  // uniffi::breez_sdk_spark::cb::callbackinterfacestoragebackendmethod0
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiVTableCallbackInterfaceEventListener> {
  static UniffiVTableCallbackInterfaceEventListener
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(
          rt,
          "Expected an object for UniffiVTableCallbackInterfaceEventListener");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiVTableCallbackInterfaceEventListener rsObject;

    // Create the vtable from the js callbacks.
    rsObject.on_event = uniffi::breez_sdk_spark::cb::
        callbackinterfaceeventlistenermethod0::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "onEvent"));
    rsObject.uniffi_free =
        uniffi::breez_sdk_spark::st::vtablecallbackinterfaceeventlistener::
            vtablecallbackinterfaceeventlistener::free::makeCallbackFunction(
                rt, callInvoker, jsObject.getProperty(rt, "uniffiFree"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiVTableCallbackInterfaceLogger> {
  static UniffiVTableCallbackInterfaceLogger
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(
          rt, "Expected an object for UniffiVTableCallbackInterfaceLogger");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiVTableCallbackInterfaceLogger rsObject;

    // Create the vtable from the js callbacks.
    rsObject.log = uniffi::breez_sdk_spark::cb::callbackinterfaceloggermethod0::
        makeCallbackFunction(rt, callInvoker, jsObject.getProperty(rt, "log"));
    rsObject.uniffi_free =
        uniffi::breez_sdk_spark::st::vtablecallbackinterfacelogger::
            vtablecallbackinterfacelogger::free::makeCallbackFunction(
                rt, callInvoker, jsObject.getProperty(rt, "uniffiFree"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiVTableCallbackInterfaceBitcoinChainService> {
  static UniffiVTableCallbackInterfaceBitcoinChainService
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(rt,
                         "Expected an object for "
                         "UniffiVTableCallbackInterfaceBitcoinChainService");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiVTableCallbackInterfaceBitcoinChainService rsObject;

    // Create the vtable from the js callbacks.
    rsObject.get_address_utxos = uniffi::breez_sdk_spark::cb::
        callbackinterfacebitcoinchainservicemethod0::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "getAddressUtxos"));
    rsObject.get_address_txos = uniffi::breez_sdk_spark::cb::
        callbackinterfacebitcoinchainservicemethod1::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "getAddressTxos"));
    rsObject.get_transaction_status = uniffi::breez_sdk_spark::cb::
        callbackinterfacebitcoinchainservicemethod2::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "getTransactionStatus"));
    rsObject.tip_height = uniffi::breez_sdk_spark::cb::
        callbackinterfacebitcoinchainservicemethod3::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "tipHeight"));
    rsObject.get_transaction_hex = uniffi::breez_sdk_spark::cb::
        callbackinterfacebitcoinchainservicemethod4::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "getTransactionHex"));
    rsObject.get_outspend = uniffi::breez_sdk_spark::cb::
        callbackinterfacebitcoinchainservicemethod5::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "getOutspend"));
    rsObject.broadcast_transaction = uniffi::breez_sdk_spark::cb::
        callbackinterfacebitcoinchainservicemethod6::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "broadcastTransaction"));
    rsObject.recommended_fees = uniffi::breez_sdk_spark::cb::
        callbackinterfacebitcoinchainservicemethod7::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "recommendedFees"));
    rsObject.uniffi_free = uniffi::breez_sdk_spark::st::
        vtablecallbackinterfacebitcoinchainservice::
            vtablecallbackinterfacebitcoinchainservice::free::
                makeCallbackFunction(rt, callInvoker,
                                     jsObject.getProperty(rt, "uniffiFree"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiVTableCallbackInterfaceCpfpSigner> {
  static UniffiVTableCallbackInterfaceCpfpSigner
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(
          rt, "Expected an object for UniffiVTableCallbackInterfaceCpfpSigner");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiVTableCallbackInterfaceCpfpSigner rsObject;

    // Create the vtable from the js callbacks.
    rsObject.sign_psbt = uniffi::breez_sdk_spark::cb::
        callbackinterfacecpfpsignermethod0::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "signPsbt"));
    rsObject.uniffi_free =
        uniffi::breez_sdk_spark::st::vtablecallbackinterfacecpfpsigner::
            vtablecallbackinterfacecpfpsigner::free::makeCallbackFunction(
                rt, callInvoker, jsObject.getProperty(rt, "uniffiFree"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiVTableCallbackInterfaceExternalBreezSigner> {
  static UniffiVTableCallbackInterfaceExternalBreezSigner
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(rt,
                         "Expected an object for "
                         "UniffiVTableCallbackInterfaceExternalBreezSigner");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiVTableCallbackInterfaceExternalBreezSigner rsObject;

    // Create the vtable from the js callbacks.
    rsObject.derive_public_key = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalbreezsignermethod0::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "derivePublicKey"));
    rsObject.sign_ecdsa = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalbreezsignermethod1::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "signEcdsa"));
    rsObject.sign_ecdsa_recoverable = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalbreezsignermethod2::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "signEcdsaRecoverable"));
    rsObject.encrypt_ecies = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalbreezsignermethod3::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "encryptEcies"));
    rsObject.decrypt_ecies = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalbreezsignermethod4::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "decryptEcies"));
    rsObject.sign_hash_schnorr = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalbreezsignermethod5::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "signHashSchnorr"));
    rsObject.hmac_sha256 = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalbreezsignermethod6::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "hmacSha256"));
    rsObject.uniffi_free = uniffi::breez_sdk_spark::st::
        vtablecallbackinterfaceexternalbreezsigner::
            vtablecallbackinterfaceexternalbreezsigner::free::
                makeCallbackFunction(rt, callInvoker,
                                     jsObject.getProperty(rt, "uniffiFree"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <>
struct Bridging<UniffiVTableCallbackInterfaceExternalSigningSigner> {
  static UniffiVTableCallbackInterfaceExternalSigningSigner
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(rt,
                         "Expected an object for "
                         "UniffiVTableCallbackInterfaceExternalSigningSigner");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiVTableCallbackInterfaceExternalSigningSigner rsObject;

    // Create the vtable from the js callbacks.
    rsObject.derive_public_key = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalsigningsignermethod0::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "derivePublicKey"));
    rsObject.sign_ecdsa = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalsigningsignermethod1::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "signEcdsa"));
    rsObject.sign_ecdsa_recoverable = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalsigningsignermethod2::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "signEcdsaRecoverable"));
    rsObject.sign_hash_schnorr = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalsigningsignermethod3::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "signHashSchnorr"));
    rsObject.uniffi_free = uniffi::breez_sdk_spark::st::
        vtablecallbackinterfaceexternalsigningsigner::
            vtablecallbackinterfaceexternalsigningsigner::free::
                makeCallbackFunction(rt, callInvoker,
                                     jsObject.getProperty(rt, "uniffiFree"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiVTableCallbackInterfaceExternalSparkSigner> {
  static UniffiVTableCallbackInterfaceExternalSparkSigner
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(rt,
                         "Expected an object for "
                         "UniffiVTableCallbackInterfaceExternalSparkSigner");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiVTableCallbackInterfaceExternalSparkSigner rsObject;

    // Create the vtable from the js callbacks.
    rsObject.get_identity_public_key = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalsparksignermethod0::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "getIdentityPublicKey"));
    rsObject.get_public_key_for_leaf = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalsparksignermethod1::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "getPublicKeyForLeaf"));
    rsObject.is_remote = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalsparksignermethod2::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "isRemote"));
    rsObject.get_static_deposit_public_key = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalsparksignermethod3::makeCallbackFunction(
            rt, callInvoker,
            jsObject.getProperty(rt, "getStaticDepositPublicKey"));
    rsObject.sign_authentication_challenge = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalsparksignermethod4::makeCallbackFunction(
            rt, callInvoker,
            jsObject.getProperty(rt, "signAuthenticationChallenge"));
    rsObject.sign_message = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalsparksignermethod5::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "signMessage"));
    rsObject.sign_leaf_refund_spend = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalsparksignermethod6::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "signLeafRefundSpend"));
    rsObject.sign_frost = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalsparksignermethod7::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "signFrost"));
    rsObject.prepare_transfer = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalsparksignermethod8::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "prepareTransfer"));
    rsObject.prepare_claim = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalsparksignermethod9::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "prepareClaim"));
    rsObject.prepare_lightning_receive = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalsparksignermethod10::makeCallbackFunction(
            rt, callInvoker,
            jsObject.getProperty(rt, "prepareLightningReceive"));
    rsObject.prepare_static_deposit = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalsparksignermethod11::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "prepareStaticDeposit"));
    rsObject.start_static_deposit_refund = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalsparksignermethod12::makeCallbackFunction(
            rt, callInvoker,
            jsObject.getProperty(rt, "startStaticDepositRefund"));
    rsObject.sign_static_deposit_refund = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalsparksignermethod13::makeCallbackFunction(
            rt, callInvoker,
            jsObject.getProperty(rt, "signStaticDepositRefund"));
    rsObject.sign_spark_invoice = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalsparksignermethod14::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "signSparkInvoice"));
    rsObject.prepare_token_transaction = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalsparksignermethod15::makeCallbackFunction(
            rt, callInvoker,
            jsObject.getProperty(rt, "prepareTokenTransaction"));
    rsObject.prepare_static_deposit_claim = uniffi::breez_sdk_spark::cb::
        callbackinterfaceexternalsparksignermethod16::makeCallbackFunction(
            rt, callInvoker,
            jsObject.getProperty(rt, "prepareStaticDepositClaim"));
    rsObject.uniffi_free = uniffi::breez_sdk_spark::st::
        vtablecallbackinterfaceexternalsparksigner::
            vtablecallbackinterfaceexternalsparksigner::free::
                makeCallbackFunction(rt, callInvoker,
                                     jsObject.getProperty(rt, "uniffiFree"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiVTableCallbackInterfaceFiatService> {
  static UniffiVTableCallbackInterfaceFiatService
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(
          rt,
          "Expected an object for UniffiVTableCallbackInterfaceFiatService");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiVTableCallbackInterfaceFiatService rsObject;

    // Create the vtable from the js callbacks.
    rsObject.fetch_fiat_currencies = uniffi::breez_sdk_spark::cb::
        callbackinterfacefiatservicemethod0::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "fetchFiatCurrencies"));
    rsObject.fetch_fiat_rates = uniffi::breez_sdk_spark::cb::
        callbackinterfacefiatservicemethod1::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "fetchFiatRates"));
    rsObject.uniffi_free =
        uniffi::breez_sdk_spark::st::vtablecallbackinterfacefiatservice::
            vtablecallbackinterfacefiatservice::free::makeCallbackFunction(
                rt, callInvoker, jsObject.getProperty(rt, "uniffiFree"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiVTableCallbackInterfacePaymentObserver> {
  static UniffiVTableCallbackInterfacePaymentObserver
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(rt, "Expected an object for "
                             "UniffiVTableCallbackInterfacePaymentObserver");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiVTableCallbackInterfacePaymentObserver rsObject;

    // Create the vtable from the js callbacks.
    rsObject.before_send = uniffi::breez_sdk_spark::cb::
        callbackinterfacepaymentobservermethod0::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "beforeSend"));
    rsObject.after_send = uniffi::breez_sdk_spark::cb::
        callbackinterfacepaymentobservermethod1::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "afterSend"));
    rsObject.uniffi_free =
        uniffi::breez_sdk_spark::st::vtablecallbackinterfacepaymentobserver::
            vtablecallbackinterfacepaymentobserver::free::makeCallbackFunction(
                rt, callInvoker, jsObject.getProperty(rt, "uniffiFree"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiVTableCallbackInterfacePrfProvider> {
  static UniffiVTableCallbackInterfacePrfProvider
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(
          rt,
          "Expected an object for UniffiVTableCallbackInterfacePrfProvider");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiVTableCallbackInterfacePrfProvider rsObject;

    // Create the vtable from the js callbacks.
    rsObject.derive_seeds = uniffi::breez_sdk_spark::cb::
        callbackinterfaceprfprovidermethod0::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "deriveSeeds"));
    rsObject.is_supported = uniffi::breez_sdk_spark::cb::
        callbackinterfaceprfprovidermethod1::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "isSupported"));
    rsObject.create_passkey = uniffi::breez_sdk_spark::cb::
        callbackinterfaceprfprovidermethod2::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "createPasskey"));
    rsObject.check_domain_association = uniffi::breez_sdk_spark::cb::
        callbackinterfaceprfprovidermethod3::makeCallbackFunction(
            rt, callInvoker,
            jsObject.getProperty(rt, "checkDomainAssociation"));
    rsObject.uniffi_free =
        uniffi::breez_sdk_spark::st::vtablecallbackinterfaceprfprovider::
            vtablecallbackinterfaceprfprovider::free::makeCallbackFunction(
                rt, callInvoker, jsObject.getProperty(rt, "uniffiFree"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiVTableCallbackInterfaceRestClient> {
  static UniffiVTableCallbackInterfaceRestClient
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(
          rt, "Expected an object for UniffiVTableCallbackInterfaceRestClient");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiVTableCallbackInterfaceRestClient rsObject;

    // Create the vtable from the js callbacks.
    rsObject.get_request = uniffi::breez_sdk_spark::cb::
        callbackinterfacerestclientmethod0::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "getRequest"));
    rsObject.post_request = uniffi::breez_sdk_spark::cb::
        callbackinterfacerestclientmethod1::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "postRequest"));
    rsObject.delete_request = uniffi::breez_sdk_spark::cb::
        callbackinterfacerestclientmethod2::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "deleteRequest"));
    rsObject.uniffi_free =
        uniffi::breez_sdk_spark::st::vtablecallbackinterfacerestclient::
            vtablecallbackinterfacerestclient::free::makeCallbackFunction(
                rt, callInvoker, jsObject.getProperty(rt, "uniffiFree"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiVTableCallbackInterfaceSessionStore> {
  static UniffiVTableCallbackInterfaceSessionStore
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(
          rt,
          "Expected an object for UniffiVTableCallbackInterfaceSessionStore");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiVTableCallbackInterfaceSessionStore rsObject;

    // Create the vtable from the js callbacks.
    rsObject.get_session = uniffi::breez_sdk_spark::cb::
        callbackinterfacesessionstoremethod0::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "getSession"));
    rsObject.set_session = uniffi::breez_sdk_spark::cb::
        callbackinterfacesessionstoremethod1::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "setSession"));
    rsObject.uniffi_free =
        uniffi::breez_sdk_spark::st::vtablecallbackinterfacesessionstore::
            vtablecallbackinterfacesessionstore::free::makeCallbackFunction(
                rt, callInvoker, jsObject.getProperty(rt, "uniffiFree"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiVTableCallbackInterfaceStorage> {
  static UniffiVTableCallbackInterfaceStorage
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(
          rt, "Expected an object for UniffiVTableCallbackInterfaceStorage");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiVTableCallbackInterfaceStorage rsObject;

    // Create the vtable from the js callbacks.
    rsObject.delete_cached_item = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod0::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "deleteCachedItem"));
    rsObject.get_cached_item = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod1::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "getCachedItem"));
    rsObject.set_cached_item = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod2::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "setCachedItem"));
    rsObject.list_payments = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod3::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "listPayments"));
    rsObject.apply_payment_update = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod4::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "applyPaymentUpdate"));
    rsObject.insert_payment_metadata = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod5::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "insertPaymentMetadata"));
    rsObject.get_payment_by_id = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod6::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "getPaymentById"));
    rsObject.get_payment_by_invoice = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod7::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "getPaymentByInvoice"));
    rsObject.get_payments_by_parent_ids = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod8::makeCallbackFunction(
            rt, callInvoker,
            jsObject.getProperty(rt, "getPaymentsByParentIds"));
    rsObject.add_deposit = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod9::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "addDeposit"));
    rsObject.delete_deposit = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod10::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "deleteDeposit"));
    rsObject.list_deposits = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod11::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "listDeposits"));
    rsObject.update_deposit = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod12::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "updateDeposit"));
    rsObject.set_lnurl_metadata = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod13::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "setLnurlMetadata"));
    rsObject.list_contacts = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod14::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "listContacts"));
    rsObject.get_contact = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod15::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "getContact"));
    rsObject.insert_contact = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod16::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "insertContact"));
    rsObject.delete_contact = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod17::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "deleteContact"));
    rsObject.set_cross_chain_swap = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod18::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "setCrossChainSwap"));
    rsObject.get_cross_chain_swap = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod19::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "getCrossChainSwap"));
    rsObject.list_active_cross_chain_swaps = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod20::makeCallbackFunction(
            rt, callInvoker,
            jsObject.getProperty(rt, "listActiveCrossChainSwaps"));
    rsObject.add_outgoing_change = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod21::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "addOutgoingChange"));
    rsObject.complete_outgoing_sync = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod22::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "completeOutgoingSync"));
    rsObject.get_pending_outgoing_changes = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod23::makeCallbackFunction(
            rt, callInvoker,
            jsObject.getProperty(rt, "getPendingOutgoingChanges"));
    rsObject.get_last_revision = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod24::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "getLastRevision"));
    rsObject.insert_incoming_records = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod25::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "insertIncomingRecords"));
    rsObject.delete_incoming_record = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod26::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "deleteIncomingRecord"));
    rsObject.get_incoming_records = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod27::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "getIncomingRecords"));
    rsObject.get_latest_outgoing_change = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod28::makeCallbackFunction(
            rt, callInvoker,
            jsObject.getProperty(rt, "getLatestOutgoingChange"));
    rsObject.update_record_from_incoming = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragemethod29::makeCallbackFunction(
            rt, callInvoker,
            jsObject.getProperty(rt, "updateRecordFromIncoming"));
    rsObject.uniffi_free =
        uniffi::breez_sdk_spark::st::vtablecallbackinterfacestorage::
            vtablecallbackinterfacestorage::free::makeCallbackFunction(
                rt, callInvoker, jsObject.getProperty(rt, "uniffiFree"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark
namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiVTableCallbackInterfaceStorageBackend> {
  static UniffiVTableCallbackInterfaceStorageBackend
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &jsValue) {
    // Check if the input is an object
    if (!jsValue.isObject()) {
      throw jsi::JSError(
          rt,
          "Expected an object for UniffiVTableCallbackInterfaceStorageBackend");
    }

    // Get the object from the jsi::Value
    auto jsObject = jsValue.getObject(rt);

    // Create the vtable struct
    UniffiVTableCallbackInterfaceStorageBackend rsObject;

    // Create the vtable from the js callbacks.
    rsObject.create_stores = uniffi::breez_sdk_spark::cb::
        callbackinterfacestoragebackendmethod0::makeCallbackFunction(
            rt, callInvoker, jsObject.getProperty(rt, "createStores"));
    rsObject.uniffi_free =
        uniffi::breez_sdk_spark::st::vtablecallbackinterfacestoragebackend::
            vtablecallbackinterfacestoragebackend::free::makeCallbackFunction(
                rt, callInvoker, jsObject.getProperty(rt, "uniffiFree"));

    return rsObject;
  }
};

} // namespace uniffi::breez_sdk_spark

namespace uniffi::breez_sdk_spark {
using namespace facebook;
using CallInvoker = uniffi_runtime::UniffiCallInvoker;

template <> struct Bridging<UniffiRustFutureContinuationCallback> {
  static UniffiRustFutureContinuationCallback
  fromJs(jsi::Runtime &rt, std::shared_ptr<CallInvoker> callInvoker,
         const jsi::Value &value) {
    try {
      return uniffi::breez_sdk_spark::cb::rustfuturecontinuationcallback::
          makeCallbackFunction(rt, callInvoker, value);
    } catch (const std::logic_error &e) {
      throw jsi::JSError(rt, e.what());
    }
  }
};

} // namespace uniffi::breez_sdk_spark

NativeBreezSdkSpark::NativeBreezSdkSpark(
    jsi::Runtime &rt,
    std::shared_ptr<uniffi_runtime::UniffiCallInvoker> invoker)
    : callInvoker(invoker), props() {
  // Map from Javascript names to the cpp names
  props["ubrn_uniffi_internal_fn_func_ffi__string_to_byte_length"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_internal_fn_func_ffi__string_to_byte_length"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_internal_fn_func_ffi__string_to_byte_length(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_internal_fn_func_ffi__string_to_arraybuffer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_internal_fn_func_ffi__string_to_arraybuffer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_internal_fn_func_ffi__string_to_arraybuffer(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_internal_fn_func_ffi__arraybuffer_to_string"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_internal_fn_func_ffi__arraybuffer_to_string"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_internal_fn_func_ffi__arraybuffer_to_string(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_clone_bitcoinchainservice"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_clone_bitcoinchainservice"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_clone_bitcoinchainservice(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_free_bitcoinchainservice"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_free_bitcoinchainservice"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_free_bitcoinchainservice(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_init_callback_vtable_"
        "bitcoinchainservice"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_init_"
                                    "callback_vtable_bitcoinchainservice"),
      1,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_init_callback_vtable_bitcoinchainservice(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_get_address_"
        "utxos"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "bitcoinchainservice_get_address_utxos"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_get_address_utxos(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_get_address_"
        "txos"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "bitcoinchainservice_get_address_txos"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_get_address_txos(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_get_"
        "transaction_status"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                "bitcoinchainservice_get_transaction_status"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_get_transaction_status(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_tip_"
        "height"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "bitcoinchainservice_tip_height"),
      1,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_tip_height(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_get_"
        "transaction_hex"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "bitcoinchainservice_get_transaction_hex"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_get_transaction_hex(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_get_"
        "outspend"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "bitcoinchainservice_get_outspend"),
      3,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_get_outspend(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_broadcast_"
        "transaction"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                "bitcoinchainservice_broadcast_transaction"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_broadcast_transaction(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_recommended_"
        "fees"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "bitcoinchainservice_recommended_fees"),
      1,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_recommended_fees(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_clone_breezsdk"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_clone_breezsdk"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_clone_breezsdk(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_free_breezsdk"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_free_breezsdk"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_free_breezsdk(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_add_contact"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_add_contact"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_add_contact(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_add_event_listener"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "breezsdk_add_event_listener"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_add_event_listener(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_authorize_lightning_"
        "address_transfer"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(
          rt, "ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_authorize_"
              "lightning_address_transfer"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_authorize_lightning_address_transfer(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_build_unsigned_batch_"
        "package"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "breezsdk_build_unsigned_batch_package"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_build_unsigned_batch_package(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_build_unsigned_lnurl_"
        "pay_package"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                "breezsdk_build_unsigned_lnurl_pay_package"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_build_unsigned_lnurl_pay_package(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_build_unsigned_"
        "transfer_package"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "breezsdk_build_unsigned_transfer_package"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_build_unsigned_transfer_package(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_buy_bitcoin"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_buy_bitcoin"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_buy_bitcoin(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_check_lightning_"
        "address_available"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                "breezsdk_check_lightning_address_available"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_check_lightning_address_available(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_check_message"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_check_message"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_check_message(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_check_unilateral_"
        "exit"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "breezsdk_check_unilateral_exit"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_check_unilateral_exit(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_claim_deposit"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_claim_deposit"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_claim_deposit(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_claim_htlc_payment"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "breezsdk_claim_htlc_payment"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_claim_htlc_payment(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_claim_lightning_"
        "address_transfer"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                "breezsdk_claim_lightning_address_transfer"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_claim_lightning_address_transfer(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_delete_contact"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_delete_contact"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_delete_contact(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_delete_lightning_"
        "address"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "breezsdk_delete_lightning_address"),
      1,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_delete_lightning_address(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_disconnect"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_disconnect"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_disconnect(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_export_unilateral_exit_"
        "state"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "breezsdk_export_unilateral_exit_state"),
      1,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_export_unilateral_exit_state(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_fetch_claim_deposit_"
        "quote"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "breezsdk_fetch_claim_deposit_quote"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_fetch_claim_deposit_quote(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_fetch_conversion_"
        "limits"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "breezsdk_fetch_conversion_limits"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_fetch_conversion_limits(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_get_cross_chain_"
        "routes"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "breezsdk_get_cross_chain_routes"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_get_cross_chain_routes(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_get_info"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_get_info"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_get_info(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_get_lightning_"
        "address"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "breezsdk_get_lightning_address"),
      1,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_get_lightning_address(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_get_payment"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_get_payment"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_get_payment(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_get_token_issuer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "breezsdk_get_token_issuer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_get_token_issuer(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_get_tokens_metadata"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "breezsdk_get_tokens_metadata"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_get_tokens_metadata(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_get_user_settings"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "breezsdk_get_user_settings"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_get_user_settings(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_import_unilateral_exit_"
        "state"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "breezsdk_import_unilateral_exit_state"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_import_unilateral_exit_state(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_list_contacts"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_list_contacts"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_list_contacts(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_list_fiat_currencies"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "breezsdk_list_fiat_currencies"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_list_fiat_currencies(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_list_fiat_rates"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_list_fiat_rates"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_list_fiat_rates(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_list_payments"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_list_payments"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_list_payments(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_list_unclaimed_"
        "deposits"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "breezsdk_list_unclaimed_deposits"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_list_unclaimed_deposits(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_list_webhooks"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_list_webhooks"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_list_webhooks(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_lnurl_auth"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_lnurl_auth"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_lnurl_auth(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_lnurl_pay"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_lnurl_pay"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_lnurl_pay(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_lnurl_withdraw"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_lnurl_withdraw"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_lnurl_withdraw(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_optimize_leaves"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_optimize_leaves"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_optimize_leaves(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_parse"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_parse"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_parse(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_prepare_lnurl_pay"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "breezsdk_prepare_lnurl_pay"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_prepare_lnurl_pay(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_prepare_payment_link"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "breezsdk_prepare_payment_link"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_prepare_payment_link(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_prepare_send_batch"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "breezsdk_prepare_send_batch"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_prepare_send_batch(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_prepare_send_payment"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "breezsdk_prepare_send_payment"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_prepare_send_payment(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_prepare_unilateral_"
        "exit"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "breezsdk_prepare_unilateral_exit"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_prepare_unilateral_exit(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_publish_signed_lnurl_"
        "pay_package"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                "breezsdk_publish_signed_lnurl_pay_package"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_publish_signed_lnurl_pay_package(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_publish_signed_"
        "transfer_package"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "breezsdk_publish_signed_transfer_package"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_publish_signed_transfer_package(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_receive_payment"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_receive_payment"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_receive_payment(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_recommended_fees"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "breezsdk_recommended_fees"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_recommended_fees(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_refund_deposit"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_refund_deposit"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_refund_deposit(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_refund_pending_"
        "conversions"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "breezsdk_refund_pending_conversions"),
      1,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_refund_pending_conversions(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_register_lightning_"
        "address"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "breezsdk_register_lightning_address"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_register_lightning_address(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_register_webhook"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "breezsdk_register_webhook"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_register_webhook(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_remove_event_"
        "listener"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "breezsdk_remove_event_listener"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_remove_event_listener(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_send_batch"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_send_batch"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_send_batch(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_send_payment"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_send_payment"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_send_payment(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_sign_message"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_sign_message"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_sign_message(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_sync_wallet"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_sync_wallet"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_sync_wallet(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_unilateral_exit"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_unilateral_exit"),
          3,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_unilateral_exit(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_unregister_webhook"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "breezsdk_unregister_webhook"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_unregister_webhook(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_update_contact"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_update_contact"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_update_contact(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_breezsdk_update_user_settings"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "breezsdk_update_user_settings"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_update_user_settings(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_clone_cpfpsigner"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_clone_cpfpsigner"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_clone_cpfpsigner(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_free_cpfpsigner"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_free_cpfpsigner"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_free_cpfpsigner(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_init_callback_vtable_cpfpsigner"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_init_callback_vtable_cpfpsigner"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_init_callback_vtable_cpfpsigner(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_cpfpsigner_sign_psbt"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_method_cpfpsigner_sign_psbt"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_cpfpsigner_sign_psbt(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_clone_externalbreezsigner"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_clone_externalbreezsigner"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_clone_externalbreezsigner(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_free_externalbreezsigner"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_free_externalbreezsigner"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_free_externalbreezsigner(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_init_callback_vtable_"
        "externalbreezsigner"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_init_"
                                    "callback_vtable_externalbreezsigner"),
      1,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_init_callback_vtable_externalbreezsigner(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalbreezsigner_derive_"
        "public_key"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "externalbreezsigner_derive_public_key"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalbreezsigner_derive_public_key(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalbreezsigner_sign_"
        "ecdsa"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "externalbreezsigner_sign_ecdsa"),
      3,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalbreezsigner_sign_ecdsa(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalbreezsigner_sign_ecdsa_"
        "recoverable"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                "externalbreezsigner_sign_ecdsa_recoverable"),
      3,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalbreezsigner_sign_ecdsa_recoverable(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalbreezsigner_encrypt_"
        "ecies"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "externalbreezsigner_encrypt_ecies"),
      3,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalbreezsigner_encrypt_ecies(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalbreezsigner_decrypt_"
        "ecies"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "externalbreezsigner_decrypt_ecies"),
      3,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalbreezsigner_decrypt_ecies(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalbreezsigner_sign_hash_"
        "schnorr"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "externalbreezsigner_sign_hash_schnorr"),
      3,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalbreezsigner_sign_hash_schnorr(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalbreezsigner_hmac_"
        "sha256"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "externalbreezsigner_hmac_sha256"),
      3,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalbreezsigner_hmac_sha256(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_clone_externalsigningsigner"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_clone_externalsigningsigner"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_clone_externalsigningsigner(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_free_externalsigningsigner"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_free_externalsigningsigner"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_free_externalsigningsigner(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_init_callback_vtable_"
        "externalsigningsigner"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_init_"
                                    "callback_vtable_externalsigningsigner"),
      1,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_init_callback_vtable_externalsigningsigner(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalsigningsigner_derive_"
        "public_key"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "externalsigningsigner_derive_public_key"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalsigningsigner_derive_public_key(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalsigningsigner_sign_"
        "ecdsa"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "externalsigningsigner_sign_ecdsa"),
      3,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalsigningsigner_sign_ecdsa(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalsigningsigner_sign_"
        "ecdsa_recoverable"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                "externalsigningsigner_sign_ecdsa_recoverable"),
      3,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalsigningsigner_sign_ecdsa_recoverable(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalsigningsigner_sign_hash_"
        "schnorr"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "externalsigningsigner_sign_hash_schnorr"),
      3,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalsigningsigner_sign_hash_schnorr(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_clone_externalsparksigner"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_clone_externalsparksigner"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_clone_externalsparksigner(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_free_externalsparksigner"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_free_externalsparksigner"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_free_externalsparksigner(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_init_callback_vtable_"
        "externalsparksigner"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_init_"
                                    "callback_vtable_externalsparksigner"),
      1,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_init_callback_vtable_externalsparksigner(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalsparksigner_get_"
        "identity_public_key"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                "externalsparksigner_get_identity_public_key"),
      1,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_get_identity_public_key(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalsparksigner_get_public_"
        "key_for_leaf"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                "externalsparksigner_get_public_key_for_leaf"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_get_public_key_for_leaf(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalsparksigner_is_remote"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "externalsparksigner_is_remote"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_is_remote(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalsparksigner_get_static_"
        "deposit_public_key"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(
          rt, "ubrn_uniffi_breez_sdk_spark_fn_method_externalsparksigner_get_"
              "static_deposit_public_key"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_get_static_deposit_public_key(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_"
        "authentication_challenge"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(
          rt, "ubrn_uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_"
              "authentication_challenge"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_authentication_challenge(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_"
        "message"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "externalsparksigner_sign_message"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_message(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_leaf_"
        "refund_spend"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                "externalsparksigner_sign_leaf_refund_spend"),
      3,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_leaf_refund_spend(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_"
        "frost"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "externalsparksigner_sign_frost"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_frost(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_"
        "transfer"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "externalsparksigner_prepare_transfer"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_transfer(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_"
        "claim"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "externalsparksigner_prepare_claim"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_claim(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_"
        "lightning_receive"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(
          rt, "ubrn_uniffi_breez_sdk_spark_fn_method_externalsparksigner_"
              "prepare_lightning_receive"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_lightning_receive(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_"
        "static_deposit"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                "externalsparksigner_prepare_static_deposit"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_static_deposit(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalsparksigner_start_"
        "static_deposit_refund"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(
          rt, "ubrn_uniffi_breez_sdk_spark_fn_method_externalsparksigner_start_"
              "static_deposit_refund"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_start_static_deposit_refund(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_static_"
        "deposit_refund"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(
          rt, "ubrn_uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_"
              "static_deposit_refund"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_static_deposit_refund(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_spark_"
        "invoice"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "externalsparksigner_sign_spark_invoice"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_spark_invoice(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_"
        "token_transaction"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(
          rt, "ubrn_uniffi_breez_sdk_spark_fn_method_externalsparksigner_"
              "prepare_token_transaction"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_token_transaction(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_"
        "static_deposit_claim"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(
          rt, "ubrn_uniffi_breez_sdk_spark_fn_method_externalsparksigner_"
              "prepare_static_deposit_claim"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_static_deposit_claim(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_clone_fiatservice"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_clone_fiatservice"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_clone_fiatservice(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_free_fiatservice"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_free_fiatservice"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_free_fiatservice(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_init_callback_vtable_fiatservice"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_init_"
                                        "callback_vtable_fiatservice"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_init_callback_vtable_fiatservice(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_fiatservice_fetch_fiat_"
        "currencies"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "fiatservice_fetch_fiat_currencies"),
      1,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_fiatservice_fetch_fiat_currencies(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_fiatservice_fetch_fiat_rates"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "fiatservice_fetch_fiat_rates"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_fiatservice_fetch_fiat_rates(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_clone_passkeyclient"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_clone_passkeyclient"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_clone_passkeyclient(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_free_passkeyclient"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_free_passkeyclient"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_free_passkeyclient(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_constructor_passkeyclient_new"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_constructor_passkeyclient_new"),
          3,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_constructor_passkeyclient_new(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_passkeyclient_check_"
        "availability"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "passkeyclient_check_availability"),
      1,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_passkeyclient_check_availability(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_passkeyclient_connect_with_"
        "passkey"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "passkeyclient_connect_with_passkey"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_passkeyclient_connect_with_passkey(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_passkeyclient_labels"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_method_passkeyclient_labels"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_passkeyclient_labels(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_passkeyclient_register"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_passkeyclient_register"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_passkeyclient_register(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_passkeyclient_sign_in"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_passkeyclient_sign_in"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_passkeyclient_sign_in(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_clone_passkeylabels"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_clone_passkeylabels"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_clone_passkeylabels(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_free_passkeylabels"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_free_passkeylabels"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_free_passkeylabels(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_passkeylabels_list"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_method_passkeylabels_list"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_passkeylabels_list(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_passkeylabels_store"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_method_passkeylabels_store"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_passkeylabels_store(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_clone_paymentobserver"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_clone_paymentobserver"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_clone_paymentobserver(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_free_paymentobserver"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_free_paymentobserver"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_free_paymentobserver(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_init_callback_vtable_paymentobserver"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_init_"
                                        "callback_vtable_paymentobserver"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_init_callback_vtable_paymentobserver(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_paymentobserver_before_send"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "paymentobserver_before_send"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_paymentobserver_before_send(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_paymentobserver_after_send"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "paymentobserver_after_send"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_paymentobserver_after_send(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_clone_prfprovider"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_clone_prfprovider"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_clone_prfprovider(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_free_prfprovider"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_free_prfprovider"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_free_prfprovider(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_init_callback_vtable_prfprovider"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_init_"
                                        "callback_vtable_prfprovider"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_init_callback_vtable_prfprovider(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_prfprovider_derive_seeds"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_prfprovider_derive_seeds"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_prfprovider_derive_seeds(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_prfprovider_is_supported"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_prfprovider_is_supported"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_prfprovider_is_supported(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_prfprovider_create_passkey"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "prfprovider_create_passkey"),
          3,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_prfprovider_create_passkey(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_prfprovider_check_domain_"
        "association"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "prfprovider_check_domain_association"),
      1,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_prfprovider_check_domain_association(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_clone_resolvedstores"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_clone_resolvedstores"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_clone_resolvedstores(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_free_resolvedstores"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_free_resolvedstores"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_free_resolvedstores(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_clone_restclient"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_clone_restclient"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_clone_restclient(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_free_restclient"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_free_restclient"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_free_restclient(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_init_callback_vtable_restclient"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_init_callback_vtable_restclient"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_init_callback_vtable_restclient(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_restclient_get_request"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_restclient_get_request"),
          3,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_restclient_get_request(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_restclient_post_request"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_restclient_post_request"),
          4,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_restclient_post_request(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_restclient_delete_request"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "restclient_delete_request"),
          4,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_restclient_delete_request(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_clone_sdkbuilder"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_clone_sdkbuilder"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_clone_sdkbuilder(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_free_sdkbuilder"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_free_sdkbuilder"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_free_sdkbuilder(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_constructor_sdkbuilder_new"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_constructor_sdkbuilder_new"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_constructor_sdkbuilder_new(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_constructor_sdkbuilder_new_with_"
        "signer"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_"
                                    "constructor_sdkbuilder_new_with_signer"),
      3,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_constructor_sdkbuilder_new_with_signer(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_constructor_sdkbuilder_new_with_"
        "signing_only_signer"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_fn_constructor_"
                                "sdkbuilder_new_with_signing_only_signer"),
      3,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_constructor_sdkbuilder_new_with_signing_only_signer(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_sdkbuilder_build"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_method_sdkbuilder_build"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_method_sdkbuilder_build(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_account_"
        "number"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "sdkbuilder_with_account_number"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_account_number(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_chain_service"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "sdkbuilder_with_chain_service"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_chain_service(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_default_"
        "storage"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "sdkbuilder_with_default_storage"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_default_storage(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_fiat_service"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "sdkbuilder_with_fiat_service"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_fiat_service(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_lnurl_client"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "sdkbuilder_with_lnurl_client"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_lnurl_client(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_payment_"
        "observer"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "sdkbuilder_with_payment_observer"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_payment_observer(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_rest_chain_"
        "service"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "sdkbuilder_with_rest_chain_service"),
      4,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_rest_chain_service(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_session_store"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "sdkbuilder_with_session_store"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_session_store(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_shared_"
        "context"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "sdkbuilder_with_shared_context"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_shared_context(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_storage"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_storage"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_storage(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_storage_"
        "backend"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "sdkbuilder_with_storage_backend"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_storage_backend(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_clone_sdkcontext"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_clone_sdkcontext"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_clone_sdkcontext(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_free_sdkcontext"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_free_sdkcontext"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_free_sdkcontext(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_clone_sessionstore"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_clone_sessionstore"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_clone_sessionstore(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_free_sessionstore"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_free_sessionstore"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_free_sessionstore(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_init_callback_vtable_sessionstore"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_init_"
                                        "callback_vtable_sessionstore"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_init_callback_vtable_sessionstore(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_sessionstore_get_session"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_sessionstore_get_session"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_sessionstore_get_session(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_sessionstore_set_session"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_sessionstore_set_session"),
          3,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_sessionstore_set_session(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_clone_storage"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_clone_storage"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_clone_storage(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_free_storage"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_free_storage"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_free_storage(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_init_callback_vtable_storage"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_init_callback_vtable_storage"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_init_callback_vtable_storage(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_delete_cached_item"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "storage_delete_cached_item"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_storage_delete_cached_item(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_get_cached_item"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_storage_get_cached_item"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_storage_get_cached_item(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_set_cached_item"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_storage_set_cached_item"),
          3,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_storage_set_cached_item(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_list_payments"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_storage_list_payments"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_storage_list_payments(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_apply_payment_update"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "storage_apply_payment_update"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_storage_apply_payment_update(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_insert_payment_"
        "metadata"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "storage_insert_payment_metadata"),
      3,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_storage_insert_payment_metadata(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_get_payment_by_id"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "storage_get_payment_by_id"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_storage_get_payment_by_id(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_get_payment_by_"
        "invoice"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "storage_get_payment_by_invoice"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_storage_get_payment_by_invoice(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_get_payments_by_parent_"
        "ids"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "storage_get_payments_by_parent_ids"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_storage_get_payments_by_parent_ids(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_add_deposit"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_method_storage_add_deposit"),
          5,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_storage_add_deposit(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_delete_deposit"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_storage_delete_deposit"),
          3,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_storage_delete_deposit(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_list_deposits"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_storage_list_deposits"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_storage_list_deposits(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_update_deposit"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_storage_update_deposit"),
          4,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_storage_update_deposit(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_set_lnurl_metadata"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "storage_set_lnurl_metadata"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_storage_set_lnurl_metadata(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_list_contacts"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_storage_list_contacts"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_storage_list_contacts(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_get_contact"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_method_storage_get_contact"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_storage_get_contact(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_insert_contact"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_storage_insert_contact"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_storage_insert_contact(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_delete_contact"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_method_storage_delete_contact"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_storage_delete_contact(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_set_cross_chain_swap"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "storage_set_cross_chain_swap"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_storage_set_cross_chain_swap(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_get_cross_chain_swap"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "storage_get_cross_chain_swap"),
          3,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_storage_get_cross_chain_swap(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_list_active_cross_chain_"
        "swaps"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "storage_list_active_cross_chain_swaps"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_storage_list_active_cross_chain_swaps(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_add_outgoing_change"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "storage_add_outgoing_change"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_storage_add_outgoing_change(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_complete_outgoing_"
        "sync"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "storage_complete_outgoing_sync"),
      3,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_storage_complete_outgoing_sync(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_get_pending_outgoing_"
        "changes"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "storage_get_pending_outgoing_changes"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_storage_get_pending_outgoing_changes(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_get_last_revision"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "storage_get_last_revision"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_storage_get_last_revision(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_insert_incoming_"
        "records"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "storage_insert_incoming_records"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_storage_insert_incoming_records(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_delete_incoming_"
        "record"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "storage_delete_incoming_record"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_storage_delete_incoming_record(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_get_incoming_records"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "storage_get_incoming_records"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_storage_get_incoming_records(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_get_latest_outgoing_"
        "change"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "storage_get_latest_outgoing_change"),
      1,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_storage_get_latest_outgoing_change(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storage_update_record_from_"
        "incoming"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "storage_update_record_from_incoming"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_storage_update_record_from_incoming(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_clone_storagebackend"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_clone_storagebackend"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_clone_storagebackend(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_free_storagebackend"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_free_storagebackend"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_free_storagebackend(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_storagebackend_create_stores"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "storagebackend_create_stores"),
          3,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_storagebackend_create_stores(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_clone_tokenissuer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_clone_tokenissuer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_clone_tokenissuer(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_free_tokenissuer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_free_tokenissuer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_free_tokenissuer(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_tokenissuer_burn_issuer_token"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "tokenissuer_burn_issuer_token"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_tokenissuer_burn_issuer_token(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_tokenissuer_create_issuer_"
        "token"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "tokenissuer_create_issuer_token"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_tokenissuer_create_issuer_token(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_tokenissuer_freeze_issuer_"
        "token"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "tokenissuer_freeze_issuer_token"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_tokenissuer_freeze_issuer_token(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_tokenissuer_get_issuer_token_"
        "balance"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "tokenissuer_get_issuer_token_balance"),
      1,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_tokenissuer_get_issuer_token_balance(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_tokenissuer_get_issuer_token_"
        "metadata"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "tokenissuer_get_issuer_token_metadata"),
      1,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_tokenissuer_get_issuer_token_metadata(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_tokenissuer_mint_issuer_token"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                        "tokenissuer_mint_issuer_token"),
          2,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_method_tokenissuer_mint_issuer_token(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_method_tokenissuer_unfreeze_issuer_"
        "token"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_method_"
                                    "tokenissuer_unfreeze_issuer_token"),
      2,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_method_tokenissuer_unfreeze_issuer_token(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_init_callback_vtable_eventlistener"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_init_"
                                        "callback_vtable_eventlistener"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_init_callback_vtable_eventlistener(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_init_callback_vtable_logger"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_init_callback_vtable_logger"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_init_callback_vtable_logger(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_func_connect"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_func_connect"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_func_connect(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_func_connect_with_signer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_func_connect_with_signer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_func_connect_with_signer(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_func_connect_with_signing_only_"
        "signer"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_func_"
                                    "connect_with_signing_only_signer"),
      1,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_func_connect_with_signing_only_signer(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_func_create_turnkey_signer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_func_create_turnkey_signer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_func_create_turnkey_signer(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_func_create_turnkey_signing_only_"
        "signer"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_fn_func_"
                                    "create_turnkey_signing_only_signer"),
      1,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_fn_func_create_turnkey_signing_only_signer(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_fn_func_custom_storage"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_func_custom_storage"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_func_custom_storage(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_func_default_config"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_func_default_config"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_func_default_config(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_func_default_external_signers"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_fn_func_default_external_signers"),
          4,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_func_default_external_signers(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_func_default_server_config"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_func_default_server_config"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_func_default_server_config(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_func_default_session_store"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_func_default_session_store"),
          3,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_func_default_session_store(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_func_default_storage"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_func_default_storage"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_func_default_storage(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_func_get_spark_status"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_func_get_spark_status"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_func_get_spark_status(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_func_init_logging"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_func_init_logging"),
          3,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_fn_func_init_logging(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_func_new_rest_chain_service"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_func_new_rest_chain_service"),
          5,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_func_new_rest_chain_service(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_func_new_shared_sdk_context"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_func_new_shared_sdk_context"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_func_new_shared_sdk_context(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_fn_func_single_key_cpfp_signer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_fn_func_single_key_cpfp_signer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_fn_func_single_key_cpfp_signer(
                    rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_poll_u8"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_poll_u8"),
          3,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_poll_u8(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_cancel_u8"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_cancel_u8"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_cancel_u8(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_free_u8"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_free_u8"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_free_u8(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_complete_u8"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_complete_u8"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_complete_u8(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_poll_i8"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_poll_i8"),
          3,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_poll_i8(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_cancel_i8"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_cancel_i8"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_cancel_i8(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_free_i8"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_free_i8"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_free_i8(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_complete_i8"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_complete_i8"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_complete_i8(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_poll_u16"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_poll_u16"),
          3,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_poll_u16(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_cancel_u16"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_cancel_u16"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_cancel_u16(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_free_u16"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_free_u16"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_free_u16(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_complete_u16"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_complete_u16"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_complete_u16(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_poll_i16"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_poll_i16"),
          3,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_poll_i16(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_cancel_i16"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_cancel_i16"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_cancel_i16(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_free_i16"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_free_i16"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_free_i16(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_complete_i16"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_complete_i16"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_complete_i16(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_poll_u32"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_poll_u32"),
          3,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_poll_u32(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_cancel_u32"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_cancel_u32"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_cancel_u32(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_free_u32"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_free_u32"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_free_u32(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_complete_u32"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_complete_u32"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_complete_u32(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_poll_i32"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_poll_i32"),
          3,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_poll_i32(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_cancel_i32"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_cancel_i32"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_cancel_i32(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_free_i32"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_free_i32"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_free_i32(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_complete_i32"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_complete_i32"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_complete_i32(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_poll_u64"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_poll_u64"),
          3,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_poll_u64(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_cancel_u64"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_cancel_u64"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_cancel_u64(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_free_u64"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_free_u64"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_free_u64(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_complete_u64"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_complete_u64"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_complete_u64(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_poll_i64"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_poll_i64"),
          3,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_poll_i64(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_cancel_i64"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_cancel_i64"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_cancel_i64(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_free_i64"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_free_i64"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_free_i64(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_complete_i64"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_complete_i64"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_complete_i64(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_poll_f32"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_poll_f32"),
          3,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_poll_f32(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_cancel_f32"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_cancel_f32"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_cancel_f32(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_free_f32"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_free_f32"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_free_f32(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_complete_f32"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_complete_f32"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_complete_f32(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_poll_f64"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_poll_f64"),
          3,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_poll_f64(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_cancel_f64"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_cancel_f64"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_cancel_f64(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_free_f64"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_free_f64"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_free_f64(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_complete_f64"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_complete_f64"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_complete_f64(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_poll_pointer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_poll_pointer"),
          3,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_poll_pointer(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_cancel_pointer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_cancel_pointer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_cancel_pointer(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_free_pointer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_free_pointer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_free_pointer(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_complete_pointer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_complete_pointer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_complete_pointer(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_poll_rust_buffer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_poll_rust_buffer"),
          3,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_poll_rust_buffer(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_cancel_rust_buffer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_cancel_rust_buffer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_cancel_rust_buffer(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_free_rust_buffer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_free_rust_buffer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_free_rust_buffer(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_complete_rust_buffer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_complete_rust_buffer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_ffi_breez_sdk_spark_rust_future_complete_rust_buffer(
                    rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_poll_void"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_poll_void"),
          3,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_poll_void(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_cancel_void"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_cancel_void"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_cancel_void(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_free_void"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_free_void"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_free_void(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_rust_future_complete_void"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_rust_future_complete_void"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_rust_future_complete_void(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_func_connect"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_checksum_func_connect"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_checksum_func_connect(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_func_connect_with_signer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_checksum_func_connect_with_signer"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_func_connect_with_signer(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_func_connect_with_signing_only_"
        "signer"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_func_"
                                    "connect_with_signing_only_signer"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_func_connect_with_signing_only_signer(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_func_create_turnkey_signer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "func_create_turnkey_signer"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_func_create_turnkey_signer(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_func_create_turnkey_signing_only_"
        "signer"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_func_"
                                    "create_turnkey_signing_only_signer"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_func_create_turnkey_signing_only_signer(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_func_custom_storage"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_checksum_func_custom_storage"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_func_custom_storage(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_func_default_config"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_checksum_func_default_config"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_func_default_config(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_func_default_external_signers"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "func_default_external_signers"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_func_default_external_signers(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_func_default_server_config"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "func_default_server_config"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_func_default_server_config(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_func_default_session_store"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "func_default_session_store"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_func_default_session_store(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_func_default_storage"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_checksum_func_default_storage"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_func_default_storage(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_func_get_spark_status"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_checksum_func_get_spark_status"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_func_get_spark_status(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_func_init_logging"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_checksum_func_init_logging"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_checksum_func_init_logging(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_func_new_rest_chain_service"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "func_new_rest_chain_service"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_func_new_rest_chain_service(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_func_new_shared_sdk_context"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "func_new_shared_sdk_context"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_func_new_shared_sdk_context(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_func_single_key_cpfp_signer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "func_single_key_cpfp_signer"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_func_single_key_cpfp_signer(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_get_"
        "address_utxos"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "bitcoinchainservice_get_address_utxos"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_get_address_utxos(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_get_"
        "address_txos"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "bitcoinchainservice_get_address_txos"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_get_address_txos(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_get_"
        "transaction_status"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "bitcoinchainservice_get_transaction_status"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_get_transaction_status(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_tip_"
        "height"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_bitcoinchainservice_tip_height"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_tip_height(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_get_"
        "transaction_hex"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "bitcoinchainservice_get_transaction_hex"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_get_transaction_hex(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_get_"
        "outspend"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_bitcoinchainservice_get_outspend"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_get_outspend(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_"
        "broadcast_transaction"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "bitcoinchainservice_broadcast_transaction"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_broadcast_transaction(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_"
        "recommended_fees"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "bitcoinchainservice_recommended_fees"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_recommended_fees(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_add_contact"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_breezsdk_add_contact"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_add_contact(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_add_event_"
        "listener"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_breezsdk_add_event_listener"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_add_event_listener(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_authorize_"
        "lightning_address_transfer"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(
          rt, "ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_authorize_"
              "lightning_address_transfer"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_authorize_lightning_address_transfer(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_build_unsigned_"
        "batch_package"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "breezsdk_build_unsigned_batch_package"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_build_unsigned_batch_package(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_build_unsigned_"
        "lnurl_pay_package"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "breezsdk_build_unsigned_lnurl_pay_package"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_build_unsigned_lnurl_pay_package(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_build_unsigned_"
        "transfer_package"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "breezsdk_build_unsigned_transfer_package"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_build_unsigned_transfer_package(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_buy_bitcoin"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_breezsdk_buy_bitcoin"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_buy_bitcoin(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_check_lightning_"
        "address_available"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "breezsdk_check_lightning_address_available"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_check_lightning_address_available(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_check_message"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_breezsdk_check_message"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_check_message(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_check_unilateral_"
        "exit"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_breezsdk_check_unilateral_exit"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_check_unilateral_exit(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_claim_deposit"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_breezsdk_claim_deposit"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_claim_deposit(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_claim_htlc_"
        "payment"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_breezsdk_claim_htlc_payment"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_claim_htlc_payment(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_claim_lightning_"
        "address_transfer"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "breezsdk_claim_lightning_address_transfer"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_claim_lightning_address_transfer(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_delete_contact"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_breezsdk_delete_contact"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_delete_contact(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_delete_lightning_"
        "address"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_breezsdk_delete_lightning_address"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_delete_lightning_address(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_disconnect"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_breezsdk_disconnect"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_disconnect(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_export_"
        "unilateral_exit_state"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "breezsdk_export_unilateral_exit_state"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_export_unilateral_exit_state(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_fetch_claim_"
        "deposit_quote"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "breezsdk_fetch_claim_deposit_quote"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_fetch_claim_deposit_quote(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_fetch_conversion_"
        "limits"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_breezsdk_fetch_conversion_limits"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_fetch_conversion_limits(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_get_cross_chain_"
        "routes"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_breezsdk_get_cross_chain_routes"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_get_cross_chain_routes(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_get_info"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_get_info"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_get_info(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_get_lightning_"
        "address"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_breezsdk_get_lightning_address"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_get_lightning_address(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_get_payment"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_breezsdk_get_payment"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_get_payment(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_get_token_"
        "issuer"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_breezsdk_get_token_issuer"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_get_token_issuer(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_get_tokens_"
        "metadata"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_breezsdk_get_tokens_metadata"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_get_tokens_metadata(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_get_user_"
        "settings"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_breezsdk_get_user_settings"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_get_user_settings(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_import_"
        "unilateral_exit_state"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "breezsdk_import_unilateral_exit_state"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_import_unilateral_exit_state(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_list_contacts"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_breezsdk_list_contacts"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_list_contacts(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_list_fiat_"
        "currencies"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_breezsdk_list_fiat_currencies"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_list_fiat_currencies(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_list_fiat_"
        "rates"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_breezsdk_list_fiat_rates"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_list_fiat_rates(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_list_payments"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_breezsdk_list_payments"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_list_payments(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_list_unclaimed_"
        "deposits"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_breezsdk_list_unclaimed_deposits"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_list_unclaimed_deposits(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_list_webhooks"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_breezsdk_list_webhooks"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_list_webhooks(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_lnurl_auth"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_breezsdk_lnurl_auth"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_lnurl_auth(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_lnurl_pay"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_lnurl_pay"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_lnurl_pay(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_lnurl_withdraw"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_breezsdk_lnurl_withdraw"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_lnurl_withdraw(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_optimize_"
        "leaves"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_breezsdk_optimize_leaves"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_optimize_leaves(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_parse"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_parse"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_parse(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_prepare_lnurl_"
        "pay"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_breezsdk_prepare_lnurl_pay"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_prepare_lnurl_pay(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_prepare_payment_"
        "link"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_breezsdk_prepare_payment_link"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_prepare_payment_link(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_prepare_send_"
        "batch"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_breezsdk_prepare_send_batch"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_prepare_send_batch(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_prepare_send_"
        "payment"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_breezsdk_prepare_send_payment"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_prepare_send_payment(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_prepare_"
        "unilateral_exit"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_breezsdk_prepare_unilateral_exit"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_prepare_unilateral_exit(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_publish_signed_"
        "lnurl_pay_package"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "breezsdk_publish_signed_lnurl_pay_package"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_publish_signed_lnurl_pay_package(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_publish_signed_"
        "transfer_package"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "breezsdk_publish_signed_transfer_package"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_publish_signed_transfer_package(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_receive_"
        "payment"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_breezsdk_receive_payment"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_receive_payment(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_recommended_"
        "fees"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_breezsdk_recommended_fees"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_recommended_fees(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_refund_deposit"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_breezsdk_refund_deposit"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_refund_deposit(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_refund_pending_"
        "conversions"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "breezsdk_refund_pending_conversions"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_refund_pending_conversions(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_register_"
        "lightning_address"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "breezsdk_register_lightning_address"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_register_lightning_address(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_register_"
        "webhook"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_breezsdk_register_webhook"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_register_webhook(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_remove_event_"
        "listener"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_breezsdk_remove_event_listener"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_remove_event_listener(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_send_batch"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_breezsdk_send_batch"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_send_batch(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_send_payment"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_breezsdk_send_payment"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_send_payment(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_sign_message"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_breezsdk_sign_message"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_sign_message(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_sync_wallet"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_breezsdk_sync_wallet"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_sync_wallet(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_unilateral_"
        "exit"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_breezsdk_unilateral_exit"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_unilateral_exit(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_unregister_"
        "webhook"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_breezsdk_unregister_webhook"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_unregister_webhook(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_update_contact"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_breezsdk_update_contact"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_update_contact(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_breezsdk_update_user_"
        "settings"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_breezsdk_update_user_settings"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_update_user_settings(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_cpfpsigner_sign_psbt"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_cpfpsigner_sign_psbt"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_cpfpsigner_sign_psbt(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_"
        "derive_public_key"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "externalbreezsigner_derive_public_key"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_derive_public_key(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_sign_"
        "ecdsa"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_externalbreezsigner_sign_ecdsa"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_sign_ecdsa(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_sign_"
        "ecdsa_recoverable"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "externalbreezsigner_sign_ecdsa_recoverable"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_sign_ecdsa_recoverable(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_"
        "encrypt_ecies"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_externalbreezsigner_encrypt_ecies"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_encrypt_ecies(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_"
        "decrypt_ecies"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_externalbreezsigner_decrypt_ecies"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_decrypt_ecies(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_sign_"
        "hash_schnorr"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "externalbreezsigner_sign_hash_schnorr"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_sign_hash_schnorr(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_hmac_"
        "sha256"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_externalbreezsigner_hmac_sha256"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_hmac_sha256(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalsigningsigner_"
        "derive_public_key"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "externalsigningsigner_derive_public_key"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalsigningsigner_derive_public_key(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalsigningsigner_"
        "sign_ecdsa"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_externalsigningsigner_sign_ecdsa"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalsigningsigner_sign_ecdsa(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalsigningsigner_"
        "sign_ecdsa_recoverable"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "externalsigningsigner_sign_ecdsa_recoverable"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalsigningsigner_sign_ecdsa_recoverable(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalsigningsigner_"
        "sign_hash_schnorr"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "externalsigningsigner_sign_hash_schnorr"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalsigningsigner_sign_hash_schnorr(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_get_"
        "identity_public_key"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "externalsparksigner_get_identity_public_key"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_get_identity_public_key(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_get_"
        "public_key_for_leaf"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "externalsparksigner_get_public_key_for_leaf"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_get_public_key_for_leaf(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_is_"
        "remote"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_externalsparksigner_is_remote"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_is_remote(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_get_"
        "static_deposit_public_key"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(
          rt, "ubrn_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_"
              "get_static_deposit_public_key"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_get_static_deposit_public_key(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_"
        "authentication_challenge"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(
          rt, "ubrn_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_"
              "sign_authentication_challenge"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_authentication_challenge(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_"
        "message"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_externalsparksigner_sign_message"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_message(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_"
        "leaf_refund_spend"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "externalsparksigner_sign_leaf_refund_spend"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_leaf_refund_spend(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_"
        "frost"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_externalsparksigner_sign_frost"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_frost(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_"
        "prepare_transfer"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "externalsparksigner_prepare_transfer"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_prepare_transfer(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_"
        "prepare_claim"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_externalsparksigner_prepare_claim"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_prepare_claim(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_"
        "prepare_lightning_receive"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(
          rt, "ubrn_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_"
              "prepare_lightning_receive"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_prepare_lightning_receive(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_"
        "prepare_static_deposit"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "externalsparksigner_prepare_static_deposit"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_prepare_static_deposit(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_start_"
        "static_deposit_refund"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(
          rt, "ubrn_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_"
              "start_static_deposit_refund"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_start_static_deposit_refund(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_"
        "static_deposit_refund"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(
          rt, "ubrn_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_"
              "sign_static_deposit_refund"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_static_deposit_refund(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_"
        "spark_invoice"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "externalsparksigner_sign_spark_invoice"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_spark_invoice(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_"
        "prepare_token_transaction"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(
          rt, "ubrn_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_"
              "prepare_token_transaction"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_prepare_token_transaction(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_"
        "prepare_static_deposit_claim"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(
          rt, "ubrn_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_"
              "prepare_static_deposit_claim"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_prepare_static_deposit_claim(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_fiatservice_fetch_fiat_"
        "currencies"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_fiatservice_fetch_fiat_currencies"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_fiatservice_fetch_fiat_currencies(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_fiatservice_fetch_fiat_"
        "rates"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_fiatservice_fetch_fiat_rates"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_fiatservice_fetch_fiat_rates(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_passkeyclient_check_"
        "availability"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_passkeyclient_check_availability"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_passkeyclient_check_availability(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_passkeyclient_connect_"
        "with_passkey"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "passkeyclient_connect_with_passkey"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_passkeyclient_connect_with_passkey(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_passkeyclient_labels"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_passkeyclient_labels"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_passkeyclient_labels(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_passkeyclient_register"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_passkeyclient_register"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_passkeyclient_register(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_passkeyclient_sign_in"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_passkeyclient_sign_in"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_passkeyclient_sign_in(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_passkeylabels_list"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_checksum_method_passkeylabels_list"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_passkeylabels_list(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_passkeylabels_store"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_passkeylabels_store"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_passkeylabels_store(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_paymentobserver_before_"
        "send"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_paymentobserver_before_send"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_paymentobserver_before_send(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_paymentobserver_after_"
        "send"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_paymentobserver_after_send"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_paymentobserver_after_send(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_prfprovider_derive_"
        "seeds"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_prfprovider_derive_seeds"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_prfprovider_derive_seeds(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_prfprovider_is_"
        "supported"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_prfprovider_is_supported"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_prfprovider_is_supported(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_prfprovider_create_"
        "passkey"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_prfprovider_create_passkey"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_prfprovider_create_passkey(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_prfprovider_check_domain_"
        "association"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "prfprovider_check_domain_association"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_prfprovider_check_domain_association(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_restclient_get_request"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_restclient_get_request"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_restclient_get_request(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_restclient_post_request"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_restclient_post_request"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_restclient_post_request(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_restclient_delete_"
        "request"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_restclient_delete_request"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_restclient_delete_request(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_build"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_build"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_build(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_account_"
        "number"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_sdkbuilder_with_account_number"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_account_number(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_chain_"
        "service"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_sdkbuilder_with_chain_service"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_chain_service(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_default_"
        "storage"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_sdkbuilder_with_default_storage"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_default_storage(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_fiat_"
        "service"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_sdkbuilder_with_fiat_service"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_fiat_service(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_lnurl_"
        "client"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_sdkbuilder_with_lnurl_client"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_lnurl_client(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_payment_"
        "observer"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_sdkbuilder_with_payment_observer"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_payment_observer(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_rest_"
        "chain_service"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "sdkbuilder_with_rest_chain_service"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_rest_chain_service(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_session_"
        "store"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_sdkbuilder_with_session_store"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_session_store(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_shared_"
        "context"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_sdkbuilder_with_shared_context"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_shared_context(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_storage"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_sdkbuilder_with_storage"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_storage(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_storage_"
        "backend"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_sdkbuilder_with_storage_backend"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_storage_backend(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_sessionstore_get_"
        "session"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_sessionstore_get_session"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_sessionstore_get_session(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_sessionstore_set_"
        "session"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_sessionstore_set_session"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_sessionstore_set_session(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_delete_cached_"
        "item"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_storage_delete_cached_item"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_delete_cached_item(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_get_cached_item"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_storage_get_cached_item"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_get_cached_item(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_set_cached_item"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_storage_set_cached_item"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_set_cached_item(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_list_payments"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_storage_list_payments"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_list_payments(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_apply_payment_"
        "update"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_storage_apply_payment_update"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_apply_payment_update(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_insert_payment_"
        "metadata"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_storage_insert_payment_metadata"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_insert_payment_metadata(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_get_payment_by_"
        "id"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_storage_get_payment_by_id"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_get_payment_by_id(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_get_payment_by_"
        "invoice"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_storage_get_payment_by_invoice"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_get_payment_by_invoice(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_get_payments_by_"
        "parent_ids"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "storage_get_payments_by_parent_ids"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_get_payments_by_parent_ids(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_add_deposit"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_storage_add_deposit"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_add_deposit(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_delete_deposit"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_storage_delete_deposit"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_delete_deposit(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_list_deposits"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_storage_list_deposits"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_list_deposits(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_update_deposit"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_storage_update_deposit"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_update_deposit(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_set_lnurl_"
        "metadata"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_storage_set_lnurl_metadata"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_set_lnurl_metadata(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_list_contacts"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_storage_list_contacts"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_list_contacts(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_get_contact"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_storage_get_contact"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_get_contact(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_insert_contact"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_storage_insert_contact"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_insert_contact(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_delete_contact"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_storage_delete_contact"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_delete_contact(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_set_cross_chain_"
        "swap"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_storage_set_cross_chain_swap"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_set_cross_chain_swap(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_get_cross_chain_"
        "swap"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_storage_get_cross_chain_swap"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_get_cross_chain_swap(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_list_active_cross_"
        "chain_swaps"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "storage_list_active_cross_chain_swaps"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_list_active_cross_chain_swaps(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_add_outgoing_"
        "change"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_storage_add_outgoing_change"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_add_outgoing_change(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_complete_outgoing_"
        "sync"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_storage_complete_outgoing_sync"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_complete_outgoing_sync(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_get_pending_"
        "outgoing_changes"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "storage_get_pending_outgoing_changes"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_get_pending_outgoing_changes(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_get_last_"
        "revision"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_storage_get_last_revision"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_get_last_revision(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_insert_incoming_"
        "records"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_storage_insert_incoming_records"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_insert_incoming_records(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_delete_incoming_"
        "record"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_storage_delete_incoming_record"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_delete_incoming_record(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_get_incoming_"
        "records"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_storage_get_incoming_records"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_get_incoming_records(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_get_latest_"
        "outgoing_change"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "storage_get_latest_outgoing_change"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_get_latest_outgoing_change(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storage_update_record_"
        "from_incoming"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "storage_update_record_from_incoming"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_storage_update_record_from_incoming(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_storagebackend_create_"
        "stores"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_storagebackend_create_stores"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_storagebackend_create_stores(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_tokenissuer_burn_issuer_"
        "token"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_tokenissuer_burn_issuer_token"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_tokenissuer_burn_issuer_token(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_tokenissuer_create_issuer_"
        "token"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_tokenissuer_create_issuer_token"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_tokenissuer_create_issuer_token(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_tokenissuer_freeze_issuer_"
        "token"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_tokenissuer_freeze_issuer_token"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_tokenissuer_freeze_issuer_token(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_tokenissuer_get_issuer_"
        "token_balance"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "tokenissuer_get_issuer_token_balance"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_tokenissuer_get_issuer_token_balance(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_tokenissuer_get_issuer_"
        "token_metadata"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt,
                                "ubrn_uniffi_breez_sdk_spark_checksum_method_"
                                "tokenissuer_get_issuer_token_metadata"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_tokenissuer_get_issuer_token_metadata(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_tokenissuer_mint_issuer_"
        "token"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_tokenissuer_mint_issuer_token"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_tokenissuer_mint_issuer_token(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_tokenissuer_unfreeze_"
        "issuer_token"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "method_tokenissuer_unfreeze_issuer_token"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_method_tokenissuer_unfreeze_issuer_token(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_constructor_passkeyclient_new"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "constructor_passkeyclient_new"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_constructor_passkeyclient_new(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_constructor_sdkbuilder_new"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "constructor_sdkbuilder_new"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_constructor_sdkbuilder_new(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_constructor_sdkbuilder_new_with_"
        "signer"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                    "constructor_sdkbuilder_new_with_signer"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_constructor_sdkbuilder_new_with_signer(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_constructor_sdkbuilder_new_with_"
        "signing_only_signer"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(
          rt, "ubrn_uniffi_breez_sdk_spark_checksum_constructor_sdkbuilder_new_"
              "with_signing_only_signer"),
      0,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_breez_sdk_spark_checksum_constructor_sdkbuilder_new_with_signing_only_signer(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_eventlistener_on_event"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_breez_sdk_spark_checksum_"
                                        "method_eventlistener_on_event"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_breez_sdk_spark_checksum_method_eventlistener_on_event(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_breez_sdk_spark_checksum_method_logger_log"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_breez_sdk_spark_checksum_method_logger_log"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_uniffi_breez_sdk_spark_checksum_method_logger_log(
                rt, thisVal, args, count);
          });
  props["ubrn_ffi_breez_sdk_spark_uniffi_contract_version"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_ffi_breez_sdk_spark_uniffi_contract_version"),
          0,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this->cpp_ffi_breez_sdk_spark_uniffi_contract_version(
                rt, thisVal, args, count);
          });
  props["ubrn_uniffi_internal_fn_method_bitcoinchainservice_ffi__bless_"
        "pointer"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_internal_fn_method_"
                                    "bitcoinchainservice_ffi__bless_pointer"),
      1,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_internal_fn_method_bitcoinchainservice_ffi__bless_pointer(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_internal_fn_method_breezsdk_ffi__bless_pointer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_internal_fn_method_breezsdk_ffi__bless_pointer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_internal_fn_method_breezsdk_ffi__bless_pointer(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_internal_fn_method_cpfpsigner_ffi__bless_pointer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_internal_fn_method_cpfpsigner_ffi__bless_pointer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_internal_fn_method_cpfpsigner_ffi__bless_pointer(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_internal_fn_method_externalbreezsigner_ffi__bless_"
        "pointer"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_internal_fn_method_"
                                    "externalbreezsigner_ffi__bless_pointer"),
      1,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_internal_fn_method_externalbreezsigner_ffi__bless_pointer(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_internal_fn_method_externalsigningsigner_ffi__bless_"
        "pointer"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_internal_fn_method_"
                                    "externalsigningsigner_ffi__bless_pointer"),
      1,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_internal_fn_method_externalsigningsigner_ffi__bless_pointer(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_internal_fn_method_externalsparksigner_ffi__bless_"
        "pointer"] = jsi::Function::createFromHostFunction(
      rt,
      jsi::PropNameID::forAscii(rt, "ubrn_uniffi_internal_fn_method_"
                                    "externalsparksigner_ffi__bless_pointer"),
      1,
      [this](jsi::Runtime &rt, const jsi::Value &thisVal,
             const jsi::Value *args, size_t count) -> jsi::Value {
        return this
            ->cpp_uniffi_internal_fn_method_externalsparksigner_ffi__bless_pointer(
                rt, thisVal, args, count);
      });
  props["ubrn_uniffi_internal_fn_method_fiatservice_ffi__bless_pointer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_internal_fn_method_fiatservice_ffi__bless_pointer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_internal_fn_method_fiatservice_ffi__bless_pointer(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_internal_fn_method_passkeyclient_ffi__bless_pointer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_internal_fn_method_"
                                        "passkeyclient_ffi__bless_pointer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_internal_fn_method_passkeyclient_ffi__bless_pointer(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_internal_fn_method_passkeylabels_ffi__bless_pointer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_internal_fn_method_"
                                        "passkeylabels_ffi__bless_pointer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_internal_fn_method_passkeylabels_ffi__bless_pointer(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_internal_fn_method_paymentobserver_ffi__bless_pointer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_internal_fn_method_"
                                        "paymentobserver_ffi__bless_pointer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_internal_fn_method_paymentobserver_ffi__bless_pointer(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_internal_fn_method_prfprovider_ffi__bless_pointer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_internal_fn_method_prfprovider_ffi__bless_pointer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_internal_fn_method_prfprovider_ffi__bless_pointer(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_internal_fn_method_resolvedstores_ffi__bless_pointer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_internal_fn_method_"
                                        "resolvedstores_ffi__bless_pointer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_internal_fn_method_resolvedstores_ffi__bless_pointer(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_internal_fn_method_restclient_ffi__bless_pointer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_internal_fn_method_restclient_ffi__bless_pointer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_internal_fn_method_restclient_ffi__bless_pointer(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_internal_fn_method_sdkbuilder_ffi__bless_pointer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_internal_fn_method_sdkbuilder_ffi__bless_pointer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_internal_fn_method_sdkbuilder_ffi__bless_pointer(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_internal_fn_method_sdkcontext_ffi__bless_pointer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_internal_fn_method_sdkcontext_ffi__bless_pointer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_internal_fn_method_sdkcontext_ffi__bless_pointer(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_internal_fn_method_sessionstore_ffi__bless_pointer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_internal_fn_method_sessionstore_ffi__bless_pointer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_internal_fn_method_sessionstore_ffi__bless_pointer(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_internal_fn_method_storage_ffi__bless_pointer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt, "ubrn_uniffi_internal_fn_method_storage_ffi__bless_pointer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_internal_fn_method_storage_ffi__bless_pointer(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_internal_fn_method_storagebackend_ffi__bless_pointer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(rt, "ubrn_uniffi_internal_fn_method_"
                                        "storagebackend_ffi__bless_pointer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_internal_fn_method_storagebackend_ffi__bless_pointer(
                    rt, thisVal, args, count);
          });
  props["ubrn_uniffi_internal_fn_method_tokenissuer_ffi__bless_pointer"] =
      jsi::Function::createFromHostFunction(
          rt,
          jsi::PropNameID::forAscii(
              rt,
              "ubrn_uniffi_internal_fn_method_tokenissuer_ffi__bless_pointer"),
          1,
          [this](jsi::Runtime &rt, const jsi::Value &thisVal,
                 const jsi::Value *args, size_t count) -> jsi::Value {
            return this
                ->cpp_uniffi_internal_fn_method_tokenissuer_ffi__bless_pointer(
                    rt, thisVal, args, count);
          });
}

void NativeBreezSdkSpark::registerModule(
    jsi::Runtime &rt, std::shared_ptr<react::CallInvoker> callInvoker) {
  auto invoker =
      std::make_shared<uniffi_runtime::UniffiCallInvoker>(callInvoker);
  auto tm = std::make_shared<NativeBreezSdkSpark>(rt, invoker);
  auto obj = rt.global().createFromHostObject(rt, tm);
  rt.global().setProperty(rt, "NativeBreezSdkSpark", obj);
}

void NativeBreezSdkSpark::unregisterModule(jsi::Runtime &rt) {
  uniffi::breez_sdk_spark::registry::clearRegistry();
}

jsi::Value NativeBreezSdkSpark::get(jsi::Runtime &rt,
                                    const jsi::PropNameID &name) {
  try {
    return jsi::Value(rt, props.at(name.utf8(rt)));
  } catch (std::out_of_range &e) {
    return jsi::Value::undefined();
  }
}

std::vector<jsi::PropNameID>
NativeBreezSdkSpark::getPropertyNames(jsi::Runtime &rt) {
  std::vector<jsi::PropNameID> rval;
  for (auto &[key, value] : props) {
    rval.push_back(jsi::PropNameID::forUtf8(rt, key));
  }
  return rval;
}

void NativeBreezSdkSpark::set(jsi::Runtime &rt, const jsi::PropNameID &name,
                              const jsi::Value &value) {
  props.insert_or_assign(name.utf8(rt), &value);
}

NativeBreezSdkSpark::~NativeBreezSdkSpark() {
  // Cleanup for callback function RustFutureContinuationCallback
  uniffi::breez_sdk_spark::cb::rustfuturecontinuationcallback::cleanup();
  // Cleanup for "free" callback function CallbackInterfaceFree
  uniffi::breez_sdk_spark::st::foreignfuture::foreignfuture::free::cleanup();
  uniffi::breez_sdk_spark::st::vtablecallbackinterfaceeventlistener::
      vtablecallbackinterfaceeventlistener::free::cleanup();
  uniffi::breez_sdk_spark::st::vtablecallbackinterfacelogger::
      vtablecallbackinterfacelogger::free::cleanup();
  uniffi::breez_sdk_spark::st::vtablecallbackinterfacebitcoinchainservice::
      vtablecallbackinterfacebitcoinchainservice::free::cleanup();
  uniffi::breez_sdk_spark::st::vtablecallbackinterfacecpfpsigner::
      vtablecallbackinterfacecpfpsigner::free::cleanup();
  uniffi::breez_sdk_spark::st::vtablecallbackinterfaceexternalbreezsigner::
      vtablecallbackinterfaceexternalbreezsigner::free::cleanup();
  uniffi::breez_sdk_spark::st::vtablecallbackinterfaceexternalsigningsigner::
      vtablecallbackinterfaceexternalsigningsigner::free::cleanup();
  uniffi::breez_sdk_spark::st::vtablecallbackinterfaceexternalsparksigner::
      vtablecallbackinterfaceexternalsparksigner::free::cleanup();
  uniffi::breez_sdk_spark::st::vtablecallbackinterfacefiatservice::
      vtablecallbackinterfacefiatservice::free::cleanup();
  uniffi::breez_sdk_spark::st::vtablecallbackinterfacepaymentobserver::
      vtablecallbackinterfacepaymentobserver::free::cleanup();
  uniffi::breez_sdk_spark::st::vtablecallbackinterfaceprfprovider::
      vtablecallbackinterfaceprfprovider::free::cleanup();
  uniffi::breez_sdk_spark::st::vtablecallbackinterfacerestclient::
      vtablecallbackinterfacerestclient::free::cleanup();
  uniffi::breez_sdk_spark::st::vtablecallbackinterfacesessionstore::
      vtablecallbackinterfacesessionstore::free::cleanup();
  uniffi::breez_sdk_spark::st::vtablecallbackinterfacestorage::
      vtablecallbackinterfacestorage::free::cleanup();
  uniffi::breez_sdk_spark::st::vtablecallbackinterfacestoragebackend::
      vtablecallbackinterfacestoragebackend::free::cleanup();
  // Cleanup for callback function CallbackInterfaceEventListenerMethod0
  uniffi::breez_sdk_spark::cb::callbackinterfaceeventlistenermethod0::cleanup();
  // Cleanup for callback function CallbackInterfaceLoggerMethod0
  uniffi::breez_sdk_spark::cb::callbackinterfaceloggermethod0::cleanup();
  // Cleanup for callback function CallbackInterfaceBitcoinChainServiceMethod0
  uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod0::
      cleanup();
  // Cleanup for callback function CallbackInterfaceBitcoinChainServiceMethod1
  uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod1::
      cleanup();
  // Cleanup for callback function CallbackInterfaceBitcoinChainServiceMethod2
  uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod2::
      cleanup();
  // Cleanup for callback function CallbackInterfaceBitcoinChainServiceMethod3
  uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod3::
      cleanup();
  // Cleanup for callback function CallbackInterfaceBitcoinChainServiceMethod4
  uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod4::
      cleanup();
  // Cleanup for callback function CallbackInterfaceBitcoinChainServiceMethod5
  uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod5::
      cleanup();
  // Cleanup for callback function CallbackInterfaceBitcoinChainServiceMethod6
  uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod6::
      cleanup();
  // Cleanup for callback function CallbackInterfaceBitcoinChainServiceMethod7
  uniffi::breez_sdk_spark::cb::callbackinterfacebitcoinchainservicemethod7::
      cleanup();
  // Cleanup for callback function CallbackInterfaceCpfpSignerMethod0
  uniffi::breez_sdk_spark::cb::callbackinterfacecpfpsignermethod0::cleanup();
  // Cleanup for callback function CallbackInterfaceExternalBreezSignerMethod0
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod0::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalBreezSignerMethod1
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod1::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalBreezSignerMethod2
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod2::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalBreezSignerMethod3
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod3::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalBreezSignerMethod4
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod4::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalBreezSignerMethod5
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod5::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalBreezSignerMethod6
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalbreezsignermethod6::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalSigningSignerMethod0
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsigningsignermethod0::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalSigningSignerMethod1
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsigningsignermethod1::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalSigningSignerMethod2
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsigningsignermethod2::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalSigningSignerMethod3
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsigningsignermethod3::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalSparkSignerMethod0
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod0::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalSparkSignerMethod1
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod1::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalSparkSignerMethod2
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod2::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalSparkSignerMethod3
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod3::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalSparkSignerMethod4
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod4::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalSparkSignerMethod5
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod5::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalSparkSignerMethod6
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod6::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalSparkSignerMethod7
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod7::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalSparkSignerMethod8
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod8::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalSparkSignerMethod9
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod9::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalSparkSignerMethod10
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod10::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalSparkSignerMethod11
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod11::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalSparkSignerMethod12
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod12::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalSparkSignerMethod13
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod13::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalSparkSignerMethod14
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod14::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalSparkSignerMethod15
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod15::
      cleanup();
  // Cleanup for callback function CallbackInterfaceExternalSparkSignerMethod16
  uniffi::breez_sdk_spark::cb::callbackinterfaceexternalsparksignermethod16::
      cleanup();
  // Cleanup for callback function CallbackInterfaceFiatServiceMethod0
  uniffi::breez_sdk_spark::cb::callbackinterfacefiatservicemethod0::cleanup();
  // Cleanup for callback function CallbackInterfaceFiatServiceMethod1
  uniffi::breez_sdk_spark::cb::callbackinterfacefiatservicemethod1::cleanup();
  // Cleanup for callback function CallbackInterfacePaymentObserverMethod0
  uniffi::breez_sdk_spark::cb::callbackinterfacepaymentobservermethod0::
      cleanup();
  // Cleanup for callback function CallbackInterfacePaymentObserverMethod1
  uniffi::breez_sdk_spark::cb::callbackinterfacepaymentobservermethod1::
      cleanup();
  // Cleanup for callback function CallbackInterfacePrfProviderMethod0
  uniffi::breez_sdk_spark::cb::callbackinterfaceprfprovidermethod0::cleanup();
  // Cleanup for callback function CallbackInterfacePrfProviderMethod1
  uniffi::breez_sdk_spark::cb::callbackinterfaceprfprovidermethod1::cleanup();
  // Cleanup for callback function CallbackInterfacePrfProviderMethod2
  uniffi::breez_sdk_spark::cb::callbackinterfaceprfprovidermethod2::cleanup();
  // Cleanup for callback function CallbackInterfacePrfProviderMethod3
  uniffi::breez_sdk_spark::cb::callbackinterfaceprfprovidermethod3::cleanup();
  // Cleanup for callback function CallbackInterfaceRestClientMethod0
  uniffi::breez_sdk_spark::cb::callbackinterfacerestclientmethod0::cleanup();
  // Cleanup for callback function CallbackInterfaceRestClientMethod1
  uniffi::breez_sdk_spark::cb::callbackinterfacerestclientmethod1::cleanup();
  // Cleanup for callback function CallbackInterfaceRestClientMethod2
  uniffi::breez_sdk_spark::cb::callbackinterfacerestclientmethod2::cleanup();
  // Cleanup for callback function CallbackInterfaceSessionStoreMethod0
  uniffi::breez_sdk_spark::cb::callbackinterfacesessionstoremethod0::cleanup();
  // Cleanup for callback function CallbackInterfaceSessionStoreMethod1
  uniffi::breez_sdk_spark::cb::callbackinterfacesessionstoremethod1::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod0
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod0::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod1
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod1::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod2
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod2::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod3
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod3::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod4
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod4::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod5
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod5::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod6
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod6::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod7
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod7::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod8
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod8::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod9
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod9::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod10
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod10::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod11
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod11::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod12
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod12::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod13
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod13::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod14
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod14::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod15
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod15::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod16
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod16::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod17
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod17::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod18
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod18::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod19
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod19::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod20
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod20::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod21
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod21::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod22
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod22::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod23
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod23::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod24
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod24::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod25
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod25::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod26
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod26::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod27
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod27::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod28
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod28::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageMethod29
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragemethod29::cleanup();
  // Cleanup for callback function CallbackInterfaceStorageBackendMethod0
  uniffi::breez_sdk_spark::cb::callbackinterfacestoragebackendmethod0::
      cleanup();
}

// Utility functions for serialization/deserialization of strings.
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_internal_fn_func_ffi__string_to_byte_length(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  return uniffi_jsi::Bridging<std::string>::string_to_bytelength(rt, args[0]);
}

jsi::Value
NativeBreezSdkSpark::cpp_uniffi_internal_fn_func_ffi__string_to_arraybuffer(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  return uniffi_jsi::Bridging<std::string>::string_to_arraybuffer(rt, args[0]);
}

jsi::Value
NativeBreezSdkSpark::cpp_uniffi_internal_fn_func_ffi__arraybuffer_to_string(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  return uniffi_jsi::Bridging<std::string>::arraybuffer_to_string(rt, args[0]);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_internal_fn_method_bitcoinchainservice_ffi__bless_pointer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto pointer =
      uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]);
  auto static destructor = [](uint64_t p) {
    auto pointer = reinterpret_cast<void *>(static_cast<uintptr_t>(p));
    RustCallStatus status = {0};
    uniffi_breez_sdk_spark_fn_free_bitcoinchainservice(pointer, &status);
  };
  auto ptrObj =
      std::make_shared<uniffi_jsi::DestructibleObject>(pointer, destructor);
  auto obj = jsi::Object::createFromHostObject(rt, ptrObj);
  return jsi::Value(rt, obj);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_internal_fn_method_breezsdk_ffi__bless_pointer(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto pointer =
      uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]);
  auto static destructor = [](uint64_t p) {
    auto pointer = reinterpret_cast<void *>(static_cast<uintptr_t>(p));
    RustCallStatus status = {0};
    uniffi_breez_sdk_spark_fn_free_breezsdk(pointer, &status);
  };
  auto ptrObj =
      std::make_shared<uniffi_jsi::DestructibleObject>(pointer, destructor);
  auto obj = jsi::Object::createFromHostObject(rt, ptrObj);
  return jsi::Value(rt, obj);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_internal_fn_method_cpfpsigner_ffi__bless_pointer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto pointer =
      uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]);
  auto static destructor = [](uint64_t p) {
    auto pointer = reinterpret_cast<void *>(static_cast<uintptr_t>(p));
    RustCallStatus status = {0};
    uniffi_breez_sdk_spark_fn_free_cpfpsigner(pointer, &status);
  };
  auto ptrObj =
      std::make_shared<uniffi_jsi::DestructibleObject>(pointer, destructor);
  auto obj = jsi::Object::createFromHostObject(rt, ptrObj);
  return jsi::Value(rt, obj);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_internal_fn_method_externalbreezsigner_ffi__bless_pointer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto pointer =
      uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]);
  auto static destructor = [](uint64_t p) {
    auto pointer = reinterpret_cast<void *>(static_cast<uintptr_t>(p));
    RustCallStatus status = {0};
    uniffi_breez_sdk_spark_fn_free_externalbreezsigner(pointer, &status);
  };
  auto ptrObj =
      std::make_shared<uniffi_jsi::DestructibleObject>(pointer, destructor);
  auto obj = jsi::Object::createFromHostObject(rt, ptrObj);
  return jsi::Value(rt, obj);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_internal_fn_method_externalsigningsigner_ffi__bless_pointer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto pointer =
      uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]);
  auto static destructor = [](uint64_t p) {
    auto pointer = reinterpret_cast<void *>(static_cast<uintptr_t>(p));
    RustCallStatus status = {0};
    uniffi_breez_sdk_spark_fn_free_externalsigningsigner(pointer, &status);
  };
  auto ptrObj =
      std::make_shared<uniffi_jsi::DestructibleObject>(pointer, destructor);
  auto obj = jsi::Object::createFromHostObject(rt, ptrObj);
  return jsi::Value(rt, obj);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_internal_fn_method_externalsparksigner_ffi__bless_pointer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto pointer =
      uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]);
  auto static destructor = [](uint64_t p) {
    auto pointer = reinterpret_cast<void *>(static_cast<uintptr_t>(p));
    RustCallStatus status = {0};
    uniffi_breez_sdk_spark_fn_free_externalsparksigner(pointer, &status);
  };
  auto ptrObj =
      std::make_shared<uniffi_jsi::DestructibleObject>(pointer, destructor);
  auto obj = jsi::Object::createFromHostObject(rt, ptrObj);
  return jsi::Value(rt, obj);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_internal_fn_method_fiatservice_ffi__bless_pointer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto pointer =
      uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]);
  auto static destructor = [](uint64_t p) {
    auto pointer = reinterpret_cast<void *>(static_cast<uintptr_t>(p));
    RustCallStatus status = {0};
    uniffi_breez_sdk_spark_fn_free_fiatservice(pointer, &status);
  };
  auto ptrObj =
      std::make_shared<uniffi_jsi::DestructibleObject>(pointer, destructor);
  auto obj = jsi::Object::createFromHostObject(rt, ptrObj);
  return jsi::Value(rt, obj);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_internal_fn_method_passkeyclient_ffi__bless_pointer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto pointer =
      uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]);
  auto static destructor = [](uint64_t p) {
    auto pointer = reinterpret_cast<void *>(static_cast<uintptr_t>(p));
    RustCallStatus status = {0};
    uniffi_breez_sdk_spark_fn_free_passkeyclient(pointer, &status);
  };
  auto ptrObj =
      std::make_shared<uniffi_jsi::DestructibleObject>(pointer, destructor);
  auto obj = jsi::Object::createFromHostObject(rt, ptrObj);
  return jsi::Value(rt, obj);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_internal_fn_method_passkeylabels_ffi__bless_pointer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto pointer =
      uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]);
  auto static destructor = [](uint64_t p) {
    auto pointer = reinterpret_cast<void *>(static_cast<uintptr_t>(p));
    RustCallStatus status = {0};
    uniffi_breez_sdk_spark_fn_free_passkeylabels(pointer, &status);
  };
  auto ptrObj =
      std::make_shared<uniffi_jsi::DestructibleObject>(pointer, destructor);
  auto obj = jsi::Object::createFromHostObject(rt, ptrObj);
  return jsi::Value(rt, obj);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_internal_fn_method_paymentobserver_ffi__bless_pointer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto pointer =
      uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]);
  auto static destructor = [](uint64_t p) {
    auto pointer = reinterpret_cast<void *>(static_cast<uintptr_t>(p));
    RustCallStatus status = {0};
    uniffi_breez_sdk_spark_fn_free_paymentobserver(pointer, &status);
  };
  auto ptrObj =
      std::make_shared<uniffi_jsi::DestructibleObject>(pointer, destructor);
  auto obj = jsi::Object::createFromHostObject(rt, ptrObj);
  return jsi::Value(rt, obj);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_internal_fn_method_prfprovider_ffi__bless_pointer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto pointer =
      uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]);
  auto static destructor = [](uint64_t p) {
    auto pointer = reinterpret_cast<void *>(static_cast<uintptr_t>(p));
    RustCallStatus status = {0};
    uniffi_breez_sdk_spark_fn_free_prfprovider(pointer, &status);
  };
  auto ptrObj =
      std::make_shared<uniffi_jsi::DestructibleObject>(pointer, destructor);
  auto obj = jsi::Object::createFromHostObject(rt, ptrObj);
  return jsi::Value(rt, obj);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_internal_fn_method_resolvedstores_ffi__bless_pointer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto pointer =
      uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]);
  auto static destructor = [](uint64_t p) {
    auto pointer = reinterpret_cast<void *>(static_cast<uintptr_t>(p));
    RustCallStatus status = {0};
    uniffi_breez_sdk_spark_fn_free_resolvedstores(pointer, &status);
  };
  auto ptrObj =
      std::make_shared<uniffi_jsi::DestructibleObject>(pointer, destructor);
  auto obj = jsi::Object::createFromHostObject(rt, ptrObj);
  return jsi::Value(rt, obj);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_internal_fn_method_restclient_ffi__bless_pointer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto pointer =
      uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]);
  auto static destructor = [](uint64_t p) {
    auto pointer = reinterpret_cast<void *>(static_cast<uintptr_t>(p));
    RustCallStatus status = {0};
    uniffi_breez_sdk_spark_fn_free_restclient(pointer, &status);
  };
  auto ptrObj =
      std::make_shared<uniffi_jsi::DestructibleObject>(pointer, destructor);
  auto obj = jsi::Object::createFromHostObject(rt, ptrObj);
  return jsi::Value(rt, obj);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_internal_fn_method_sdkbuilder_ffi__bless_pointer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto pointer =
      uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]);
  auto static destructor = [](uint64_t p) {
    auto pointer = reinterpret_cast<void *>(static_cast<uintptr_t>(p));
    RustCallStatus status = {0};
    uniffi_breez_sdk_spark_fn_free_sdkbuilder(pointer, &status);
  };
  auto ptrObj =
      std::make_shared<uniffi_jsi::DestructibleObject>(pointer, destructor);
  auto obj = jsi::Object::createFromHostObject(rt, ptrObj);
  return jsi::Value(rt, obj);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_internal_fn_method_sdkcontext_ffi__bless_pointer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto pointer =
      uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]);
  auto static destructor = [](uint64_t p) {
    auto pointer = reinterpret_cast<void *>(static_cast<uintptr_t>(p));
    RustCallStatus status = {0};
    uniffi_breez_sdk_spark_fn_free_sdkcontext(pointer, &status);
  };
  auto ptrObj =
      std::make_shared<uniffi_jsi::DestructibleObject>(pointer, destructor);
  auto obj = jsi::Object::createFromHostObject(rt, ptrObj);
  return jsi::Value(rt, obj);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_internal_fn_method_sessionstore_ffi__bless_pointer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto pointer =
      uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]);
  auto static destructor = [](uint64_t p) {
    auto pointer = reinterpret_cast<void *>(static_cast<uintptr_t>(p));
    RustCallStatus status = {0};
    uniffi_breez_sdk_spark_fn_free_sessionstore(pointer, &status);
  };
  auto ptrObj =
      std::make_shared<uniffi_jsi::DestructibleObject>(pointer, destructor);
  auto obj = jsi::Object::createFromHostObject(rt, ptrObj);
  return jsi::Value(rt, obj);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_internal_fn_method_storage_ffi__bless_pointer(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto pointer =
      uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]);
  auto static destructor = [](uint64_t p) {
    auto pointer = reinterpret_cast<void *>(static_cast<uintptr_t>(p));
    RustCallStatus status = {0};
    uniffi_breez_sdk_spark_fn_free_storage(pointer, &status);
  };
  auto ptrObj =
      std::make_shared<uniffi_jsi::DestructibleObject>(pointer, destructor);
  auto obj = jsi::Object::createFromHostObject(rt, ptrObj);
  return jsi::Value(rt, obj);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_internal_fn_method_storagebackend_ffi__bless_pointer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto pointer =
      uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]);
  auto static destructor = [](uint64_t p) {
    auto pointer = reinterpret_cast<void *>(static_cast<uintptr_t>(p));
    RustCallStatus status = {0};
    uniffi_breez_sdk_spark_fn_free_storagebackend(pointer, &status);
  };
  auto ptrObj =
      std::make_shared<uniffi_jsi::DestructibleObject>(pointer, destructor);
  auto obj = jsi::Object::createFromHostObject(rt, ptrObj);
  return jsi::Value(rt, obj);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_internal_fn_method_tokenissuer_ffi__bless_pointer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto pointer =
      uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[0]);
  auto static destructor = [](uint64_t p) {
    auto pointer = reinterpret_cast<void *>(static_cast<uintptr_t>(p));
    RustCallStatus status = {0};
    uniffi_breez_sdk_spark_fn_free_tokenissuer(pointer, &status);
  };
  auto ptrObj =
      std::make_shared<uniffi_jsi::DestructibleObject>(pointer, destructor);
  auto obj = jsi::Object::createFromHostObject(rt, ptrObj);
  return jsi::Value(rt, obj);
}

// Methods calling directly into the uniffi generated C API of the Rust crate.
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_clone_bitcoinchainservice(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_clone_bitcoinchainservice(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_free_bitcoinchainservice(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  uniffi_breez_sdk_spark_fn_free_bitcoinchainservice(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_init_callback_vtable_bitcoinchainservice(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto vtableInstance = uniffi::breez_sdk_spark::Bridging<
      UniffiVTableCallbackInterfaceBitcoinChainService>::fromJs(rt, callInvoker,
                                                                args[0]);

  std::lock_guard<std::mutex> lock(
      uniffi::breez_sdk_spark::registry::vtableMutex);
  uniffi_breez_sdk_spark_fn_init_callback_vtable_bitcoinchainservice(
      uniffi::breez_sdk_spark::registry::putTable(
          "UniffiVTableCallbackInterfaceBitcoinChainService", vtableInstance));
  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_get_address_utxos(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_get_address_utxos(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_get_address_txos(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_get_address_txos(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_get_transaction_status(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_get_transaction_status(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_tip_height(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_tip_height(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_get_transaction_hex(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_get_transaction_hex(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_get_outspend(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_get_outspend(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]),
          uniffi_jsi::Bridging<uint32_t>::fromJs(rt, callInvoker, args[2]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_broadcast_transaction(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_broadcast_transaction(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_recommended_fees(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_bitcoinchainservice_recommended_fees(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_clone_breezsdk(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_clone_breezsdk(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_free_breezsdk(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  uniffi_breez_sdk_spark_fn_free_breezsdk(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return jsi::Value::undefined();
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_add_contact(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_add_contact(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_add_event_listener(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_add_event_listener(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_authorize_lightning_address_transfer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_breezsdk_authorize_lightning_address_transfer(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_build_unsigned_batch_package(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_breezsdk_build_unsigned_batch_package(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_build_unsigned_lnurl_pay_package(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_breezsdk_build_unsigned_lnurl_pay_package(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_build_unsigned_transfer_package(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_breezsdk_build_unsigned_transfer_package(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_buy_bitcoin(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_buy_bitcoin(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_check_lightning_address_available(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_breezsdk_check_lightning_address_available(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_check_message(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_check_message(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_check_unilateral_exit(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_check_unilateral_exit(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_claim_deposit(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_claim_deposit(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_claim_htlc_payment(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_claim_htlc_payment(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_claim_lightning_address_transfer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_breezsdk_claim_lightning_address_transfer(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_delete_contact(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_delete_contact(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_delete_lightning_address(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_breezsdk_delete_lightning_address(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_disconnect(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_disconnect(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_export_unilateral_exit_state(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_breezsdk_export_unilateral_exit_state(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_fetch_claim_deposit_quote(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_breezsdk_fetch_claim_deposit_quote(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_fetch_conversion_limits(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_breezsdk_fetch_conversion_limits(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_get_cross_chain_routes(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_get_cross_chain_routes(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_get_info(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_get_info(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_get_lightning_address(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_get_lightning_address(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_get_payment(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_get_payment(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_get_token_issuer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_get_token_issuer(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_get_tokens_metadata(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_get_tokens_metadata(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_get_user_settings(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_get_user_settings(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_import_unilateral_exit_state(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_breezsdk_import_unilateral_exit_state(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_list_contacts(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_list_contacts(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_list_fiat_currencies(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_list_fiat_currencies(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_list_fiat_rates(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_list_fiat_rates(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_list_payments(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_list_payments(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_list_unclaimed_deposits(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_breezsdk_list_unclaimed_deposits(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_list_webhooks(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_list_webhooks(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_lnurl_auth(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_lnurl_auth(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_lnurl_pay(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_lnurl_pay(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_lnurl_withdraw(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_lnurl_withdraw(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_optimize_leaves(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_optimize_leaves(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_parse(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_parse(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_prepare_lnurl_pay(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_prepare_lnurl_pay(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_prepare_payment_link(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_prepare_payment_link(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_prepare_send_batch(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_prepare_send_batch(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_prepare_send_payment(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_prepare_send_payment(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_prepare_unilateral_exit(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_breezsdk_prepare_unilateral_exit(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_publish_signed_lnurl_pay_package(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_breezsdk_publish_signed_lnurl_pay_package(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_publish_signed_transfer_package(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_breezsdk_publish_signed_transfer_package(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_receive_payment(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_receive_payment(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_recommended_fees(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_recommended_fees(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_refund_deposit(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_refund_deposit(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_refund_pending_conversions(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_breezsdk_refund_pending_conversions(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_register_lightning_address(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_breezsdk_register_lightning_address(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_register_webhook(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_register_webhook(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_remove_event_listener(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_remove_event_listener(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_send_batch(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_send_batch(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_send_payment(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_send_payment(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_sign_message(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_sign_message(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_sync_wallet(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_sync_wallet(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_unilateral_exit(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_unilateral_exit(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]),
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[2]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_unregister_webhook(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_unregister_webhook(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_update_contact(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_update_contact(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_breezsdk_update_user_settings(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_breezsdk_update_user_settings(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_clone_cpfpsigner(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_clone_cpfpsigner(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_free_cpfpsigner(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  uniffi_breez_sdk_spark_fn_free_cpfpsigner(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_init_callback_vtable_cpfpsigner(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto vtableInstance = uniffi::breez_sdk_spark::Bridging<
      UniffiVTableCallbackInterfaceCpfpSigner>::fromJs(rt, callInvoker,
                                                       args[0]);

  std::lock_guard<std::mutex> lock(
      uniffi::breez_sdk_spark::registry::vtableMutex);
  uniffi_breez_sdk_spark_fn_init_callback_vtable_cpfpsigner(
      uniffi::breez_sdk_spark::registry::putTable(
          "UniffiVTableCallbackInterfaceCpfpSigner", vtableInstance));
  return jsi::Value::undefined();
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_method_cpfpsigner_sign_psbt(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_cpfpsigner_sign_psbt(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_clone_externalbreezsigner(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_clone_externalbreezsigner(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_free_externalbreezsigner(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  uniffi_breez_sdk_spark_fn_free_externalbreezsigner(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_init_callback_vtable_externalbreezsigner(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto vtableInstance = uniffi::breez_sdk_spark::Bridging<
      UniffiVTableCallbackInterfaceExternalBreezSigner>::fromJs(rt, callInvoker,
                                                                args[0]);

  std::lock_guard<std::mutex> lock(
      uniffi::breez_sdk_spark::registry::vtableMutex);
  uniffi_breez_sdk_spark_fn_init_callback_vtable_externalbreezsigner(
      uniffi::breez_sdk_spark::registry::putTable(
          "UniffiVTableCallbackInterfaceExternalBreezSigner", vtableInstance));
  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalbreezsigner_derive_public_key(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_externalbreezsigner_derive_public_key(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalbreezsigner_sign_ecdsa(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_externalbreezsigner_sign_ecdsa(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[2]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalbreezsigner_sign_ecdsa_recoverable(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_externalbreezsigner_sign_ecdsa_recoverable(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[2]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalbreezsigner_encrypt_ecies(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_externalbreezsigner_encrypt_ecies(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[2]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalbreezsigner_decrypt_ecies(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_externalbreezsigner_decrypt_ecies(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[2]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalbreezsigner_sign_hash_schnorr(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_externalbreezsigner_sign_hash_schnorr(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[2]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalbreezsigner_hmac_sha256(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_externalbreezsigner_hmac_sha256(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[2]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_clone_externalsigningsigner(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_clone_externalsigningsigner(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_free_externalsigningsigner(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  uniffi_breez_sdk_spark_fn_free_externalsigningsigner(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_init_callback_vtable_externalsigningsigner(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto vtableInstance = uniffi::breez_sdk_spark::Bridging<
      UniffiVTableCallbackInterfaceExternalSigningSigner>::fromJs(rt,
                                                                  callInvoker,
                                                                  args[0]);

  std::lock_guard<std::mutex> lock(
      uniffi::breez_sdk_spark::registry::vtableMutex);
  uniffi_breez_sdk_spark_fn_init_callback_vtable_externalsigningsigner(
      uniffi::breez_sdk_spark::registry::putTable(
          "UniffiVTableCallbackInterfaceExternalSigningSigner",
          vtableInstance));
  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalsigningsigner_derive_public_key(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_externalsigningsigner_derive_public_key(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalsigningsigner_sign_ecdsa(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_externalsigningsigner_sign_ecdsa(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[2]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalsigningsigner_sign_ecdsa_recoverable(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_externalsigningsigner_sign_ecdsa_recoverable(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[2]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalsigningsigner_sign_hash_schnorr(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_externalsigningsigner_sign_hash_schnorr(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[2]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_clone_externalsparksigner(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_clone_externalsparksigner(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_free_externalsparksigner(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  uniffi_breez_sdk_spark_fn_free_externalsparksigner(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_init_callback_vtable_externalsparksigner(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto vtableInstance = uniffi::breez_sdk_spark::Bridging<
      UniffiVTableCallbackInterfaceExternalSparkSigner>::fromJs(rt, callInvoker,
                                                                args[0]);

  std::lock_guard<std::mutex> lock(
      uniffi::breez_sdk_spark::registry::vtableMutex);
  uniffi_breez_sdk_spark_fn_init_callback_vtable_externalsparksigner(
      uniffi::breez_sdk_spark::registry::putTable(
          "UniffiVTableCallbackInterfaceExternalSparkSigner", vtableInstance));
  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_get_identity_public_key(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_externalsparksigner_get_identity_public_key(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_get_public_key_for_leaf(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_externalsparksigner_get_public_key_for_leaf(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_is_remote(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_method_externalsparksigner_is_remote(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<int8_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_get_static_deposit_public_key(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_externalsparksigner_get_static_deposit_public_key(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi_jsi::Bridging<uint32_t>::fromJs(rt, callInvoker, args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_authentication_challenge(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_authentication_challenge(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_message(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_message(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_leaf_refund_spend(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_leaf_refund_spend(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[2]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_frost(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_frost(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_transfer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_transfer(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_claim(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_claim(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_lightning_receive(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_lightning_receive(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_static_deposit(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_static_deposit(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_start_static_deposit_refund(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_externalsparksigner_start_static_deposit_refund(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_static_deposit_refund(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_static_deposit_refund(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_spark_invoice(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_externalsparksigner_sign_spark_invoice(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_token_transaction(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_token_transaction(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_static_deposit_claim(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_externalsparksigner_prepare_static_deposit_claim(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_clone_fiatservice(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_clone_fiatservice(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_free_fiatservice(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  uniffi_breez_sdk_spark_fn_free_fiatservice(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_init_callback_vtable_fiatservice(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto vtableInstance = uniffi::breez_sdk_spark::Bridging<
      UniffiVTableCallbackInterfaceFiatService>::fromJs(rt, callInvoker,
                                                        args[0]);

  std::lock_guard<std::mutex> lock(
      uniffi::breez_sdk_spark::registry::vtableMutex);
  uniffi_breez_sdk_spark_fn_init_callback_vtable_fiatservice(
      uniffi::breez_sdk_spark::registry::putTable(
          "UniffiVTableCallbackInterfaceFiatService", vtableInstance));
  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_fiatservice_fetch_fiat_currencies(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_fiatservice_fetch_fiat_currencies(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_fiatservice_fetch_fiat_rates(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_fiatservice_fetch_fiat_rates(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_clone_passkeyclient(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_clone_passkeyclient(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_free_passkeyclient(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  uniffi_breez_sdk_spark_fn_free_passkeyclient(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_constructor_passkeyclient_new(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_constructor_passkeyclient_new(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[2]),
      &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_passkeyclient_check_availability(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_passkeyclient_check_availability(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_passkeyclient_connect_with_passkey(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_passkeyclient_connect_with_passkey(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_method_passkeyclient_labels(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_method_passkeyclient_labels(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_passkeyclient_register(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_passkeyclient_register(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_method_passkeyclient_sign_in(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_passkeyclient_sign_in(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_clone_passkeylabels(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_clone_passkeylabels(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_free_passkeylabels(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  uniffi_breez_sdk_spark_fn_free_passkeylabels(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return jsi::Value::undefined();
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_method_passkeylabels_list(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_passkeylabels_list(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_method_passkeylabels_store(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_passkeylabels_store(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_clone_paymentobserver(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_clone_paymentobserver(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_free_paymentobserver(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  uniffi_breez_sdk_spark_fn_free_paymentobserver(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_init_callback_vtable_paymentobserver(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto vtableInstance = uniffi::breez_sdk_spark::Bridging<
      UniffiVTableCallbackInterfacePaymentObserver>::fromJs(rt, callInvoker,
                                                            args[0]);

  std::lock_guard<std::mutex> lock(
      uniffi::breez_sdk_spark::registry::vtableMutex);
  uniffi_breez_sdk_spark_fn_init_callback_vtable_paymentobserver(
      uniffi::breez_sdk_spark::registry::putTable(
          "UniffiVTableCallbackInterfacePaymentObserver", vtableInstance));
  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_paymentobserver_before_send(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_paymentobserver_before_send(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_paymentobserver_after_send(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_paymentobserver_after_send(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_clone_prfprovider(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_clone_prfprovider(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_free_prfprovider(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  uniffi_breez_sdk_spark_fn_free_prfprovider(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_init_callback_vtable_prfprovider(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto vtableInstance = uniffi::breez_sdk_spark::Bridging<
      UniffiVTableCallbackInterfacePrfProvider>::fromJs(rt, callInvoker,
                                                        args[0]);

  std::lock_guard<std::mutex> lock(
      uniffi::breez_sdk_spark::registry::vtableMutex);
  uniffi_breez_sdk_spark_fn_init_callback_vtable_prfprovider(
      uniffi::breez_sdk_spark::registry::putTable(
          "UniffiVTableCallbackInterfacePrfProvider", vtableInstance));
  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_prfprovider_derive_seeds(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_prfprovider_derive_seeds(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_prfprovider_is_supported(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_prfprovider_is_supported(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_prfprovider_create_passkey(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_prfprovider_create_passkey(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[2]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_prfprovider_check_domain_association(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_prfprovider_check_domain_association(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_clone_resolvedstores(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_clone_resolvedstores(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_free_resolvedstores(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  uniffi_breez_sdk_spark_fn_free_resolvedstores(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_clone_restclient(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_clone_restclient(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_free_restclient(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  uniffi_breez_sdk_spark_fn_free_restclient(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_init_callback_vtable_restclient(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto vtableInstance = uniffi::breez_sdk_spark::Bridging<
      UniffiVTableCallbackInterfaceRestClient>::fromJs(rt, callInvoker,
                                                       args[0]);

  std::lock_guard<std::mutex> lock(
      uniffi::breez_sdk_spark::registry::vtableMutex);
  uniffi_breez_sdk_spark_fn_init_callback_vtable_restclient(
      uniffi::breez_sdk_spark::registry::putTable(
          "UniffiVTableCallbackInterfaceRestClient", vtableInstance));
  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_restclient_get_request(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_restclient_get_request(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[2]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_restclient_post_request(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_restclient_post_request(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[2]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[3]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_restclient_delete_request(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_restclient_delete_request(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[2]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[3]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_clone_sdkbuilder(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_clone_sdkbuilder(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_free_sdkbuilder(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  uniffi_breez_sdk_spark_fn_free_sdkbuilder(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return jsi::Value::undefined();
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_constructor_sdkbuilder_new(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_constructor_sdkbuilder_new(
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]),
      &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_constructor_sdkbuilder_new_with_signer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_constructor_sdkbuilder_new_with_signer(
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[0]),
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[1]),
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[2]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_constructor_sdkbuilder_new_with_signing_only_signer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value =
      uniffi_breez_sdk_spark_fn_constructor_sdkbuilder_new_with_signing_only_signer(
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[0]),
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[1]),
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[2]),
          &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_method_sdkbuilder_build(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_sdkbuilder_build(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_account_number(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_account_number(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi_jsi::Bridging<uint32_t>::fromJs(rt, callInvoker, args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_chain_service(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_chain_service(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_default_storage(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_default_storage(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_fiat_service(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_fiat_service(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_lnurl_client(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_lnurl_client(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_payment_observer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_payment_observer(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_rest_chain_service(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_rest_chain_service(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[2]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[3]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_session_store(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_session_store(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_shared_context(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_shared_context(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_storage(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_storage(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_storage_backend(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_sdkbuilder_with_storage_backend(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_clone_sdkcontext(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_clone_sdkcontext(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_free_sdkcontext(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  uniffi_breez_sdk_spark_fn_free_sdkcontext(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return jsi::Value::undefined();
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_clone_sessionstore(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_clone_sessionstore(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_free_sessionstore(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  uniffi_breez_sdk_spark_fn_free_sessionstore(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_init_callback_vtable_sessionstore(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto vtableInstance = uniffi::breez_sdk_spark::Bridging<
      UniffiVTableCallbackInterfaceSessionStore>::fromJs(rt, callInvoker,
                                                         args[0]);

  std::lock_guard<std::mutex> lock(
      uniffi::breez_sdk_spark::registry::vtableMutex);
  uniffi_breez_sdk_spark_fn_init_callback_vtable_sessionstore(
      uniffi::breez_sdk_spark::registry::putTable(
          "UniffiVTableCallbackInterfaceSessionStore", vtableInstance));
  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_sessionstore_get_session(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_sessionstore_get_session(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_sessionstore_set_session(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_sessionstore_set_session(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[2]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_clone_storage(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_clone_storage(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_free_storage(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  uniffi_breez_sdk_spark_fn_free_storage(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return jsi::Value::undefined();
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_init_callback_vtable_storage(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto vtableInstance = uniffi::breez_sdk_spark::Bridging<
      UniffiVTableCallbackInterfaceStorage>::fromJs(rt, callInvoker, args[0]);

  std::lock_guard<std::mutex> lock(
      uniffi::breez_sdk_spark::registry::vtableMutex);
  uniffi_breez_sdk_spark_fn_init_callback_vtable_storage(
      uniffi::breez_sdk_spark::registry::putTable(
          "UniffiVTableCallbackInterfaceStorage", vtableInstance));
  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_storage_delete_cached_item(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_storage_delete_cached_item(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_storage_get_cached_item(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_storage_get_cached_item(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_storage_set_cached_item(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_storage_set_cached_item(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[2]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_method_storage_list_payments(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_storage_list_payments(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_storage_apply_payment_update(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_storage_apply_payment_update(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_storage_insert_payment_metadata(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_storage_insert_payment_metadata(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[2]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_storage_get_payment_by_id(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_storage_get_payment_by_id(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_storage_get_payment_by_invoice(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_storage_get_payment_by_invoice(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_storage_get_payments_by_parent_ids(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_storage_get_payments_by_parent_ids(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_method_storage_add_deposit(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_storage_add_deposit(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]),
      uniffi_jsi::Bridging<uint32_t>::fromJs(rt, callInvoker, args[2]),
      uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[3]),
      uniffi_jsi::Bridging<int8_t>::fromJs(rt, callInvoker, args[4]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_storage_delete_deposit(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_storage_delete_deposit(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]),
      uniffi_jsi::Bridging<uint32_t>::fromJs(rt, callInvoker, args[2]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_method_storage_list_deposits(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_storage_list_deposits(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_storage_update_deposit(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_storage_update_deposit(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]),
      uniffi_jsi::Bridging<uint32_t>::fromJs(rt, callInvoker, args[2]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[3]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_storage_set_lnurl_metadata(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_storage_set_lnurl_metadata(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_method_storage_list_contacts(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_storage_list_contacts(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_method_storage_get_contact(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_storage_get_contact(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_storage_insert_contact(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_storage_insert_contact(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_storage_delete_contact(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_storage_delete_contact(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_storage_set_cross_chain_swap(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_storage_set_cross_chain_swap(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_storage_get_cross_chain_swap(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_storage_get_cross_chain_swap(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[2]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_storage_list_active_cross_chain_swaps(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_storage_list_active_cross_chain_swaps(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_storage_add_outgoing_change(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_storage_add_outgoing_change(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_storage_complete_outgoing_sync(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_storage_complete_outgoing_sync(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]),
      uniffi_jsi::Bridging<uint64_t>::fromJs(rt, callInvoker, args[2]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_storage_get_pending_outgoing_changes(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_storage_get_pending_outgoing_changes(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi_jsi::Bridging<uint32_t>::fromJs(rt, callInvoker, args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_storage_get_last_revision(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_storage_get_last_revision(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_storage_insert_incoming_records(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_storage_insert_incoming_records(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_storage_delete_incoming_record(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_storage_delete_incoming_record(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_storage_get_incoming_records(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_storage_get_incoming_records(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi_jsi::Bridging<uint32_t>::fromJs(rt, callInvoker, args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_storage_get_latest_outgoing_change(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_storage_get_latest_outgoing_change(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_storage_update_record_from_incoming(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_storage_update_record_from_incoming(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_clone_storagebackend(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_clone_storagebackend(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_free_storagebackend(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  uniffi_breez_sdk_spark_fn_free_storagebackend(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_storagebackend_create_stores(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_storagebackend_create_stores(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[2]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_clone_tokenissuer(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_clone_tokenissuer(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_free_tokenissuer(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  uniffi_breez_sdk_spark_fn_free_tokenissuer(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_tokenissuer_burn_issuer_token(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_tokenissuer_burn_issuer_token(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_tokenissuer_create_issuer_token(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_tokenissuer_create_issuer_token(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_tokenissuer_freeze_issuer_token(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_tokenissuer_freeze_issuer_token(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_tokenissuer_get_issuer_token_balance(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_tokenissuer_get_issuer_token_balance(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_tokenissuer_get_issuer_token_metadata(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_tokenissuer_get_issuer_token_metadata(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_tokenissuer_mint_issuer_token(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_method_tokenissuer_mint_issuer_token(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_method_tokenissuer_unfreeze_issuer_token(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_method_tokenissuer_unfreeze_issuer_token(
          uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[1]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_init_callback_vtable_eventlistener(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto vtableInstance = uniffi::breez_sdk_spark::Bridging<
      UniffiVTableCallbackInterfaceEventListener>::fromJs(rt, callInvoker,
                                                          args[0]);

  std::lock_guard<std::mutex> lock(
      uniffi::breez_sdk_spark::registry::vtableMutex);
  uniffi_breez_sdk_spark_fn_init_callback_vtable_eventlistener(
      uniffi::breez_sdk_spark::registry::putTable(
          "UniffiVTableCallbackInterfaceEventListener", vtableInstance));
  return jsi::Value::undefined();
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_init_callback_vtable_logger(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto vtableInstance = uniffi::breez_sdk_spark::Bridging<
      UniffiVTableCallbackInterfaceLogger>::fromJs(rt, callInvoker, args[0]);

  std::lock_guard<std::mutex> lock(
      uniffi::breez_sdk_spark::registry::vtableMutex);
  uniffi_breez_sdk_spark_fn_init_callback_vtable_logger(
      uniffi::breez_sdk_spark::registry::putTable(
          "UniffiVTableCallbackInterfaceLogger", vtableInstance));
  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_func_connect(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_func_connect(
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_func_connect_with_signer(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_func_connect_with_signer(
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_func_connect_with_signing_only_signer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_func_connect_with_signing_only_signer(
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_func_create_turnkey_signer(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_func_create_turnkey_signer(
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_func_create_turnkey_signing_only_signer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_fn_func_create_turnkey_signing_only_signer(
          uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                                args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_func_custom_storage(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_func_custom_storage(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]), &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_func_default_config(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_func_default_config(
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[0]),
      &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(rt, callInvoker,
                                                             value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_fn_func_default_external_signers(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_func_default_external_signers(
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[2]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[3]),
      &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(rt, callInvoker,
                                                             value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_func_default_server_config(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_func_default_server_config(
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[0]),
      &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(rt, callInvoker,
                                                             value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_func_default_session_store(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_func_default_session_store(
      uniffi_jsi::Bridging<void *>::fromJs(rt, callInvoker, args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[2]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_func_default_storage(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_func_default_storage(
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[0]),
      &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_func_get_spark_status(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_func_get_spark_status(
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_func_init_logging(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  uniffi_breez_sdk_spark_fn_func_init_logging(
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[2]),
      &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return jsi::Value::undefined();
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_func_new_rest_chain_service(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_func_new_rest_chain_service(
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[0]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[1]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[2]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[3]),
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[4]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_func_new_shared_sdk_context(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_fn_func_new_shared_sdk_context(
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[0]));

  return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker,
                                                         value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_fn_func_single_key_cpfp_signer(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = uniffi_breez_sdk_spark_fn_func_single_key_cpfp_signer(
      uniffi::breez_sdk_spark::Bridging<RustBuffer>::fromJs(rt, callInvoker,
                                                            args[0]),
      &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_poll_u8(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_poll_u8(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]),
      uniffi::breez_sdk_spark::Bridging<
          UniffiRustFutureContinuationCallback>::fromJs(rt, callInvoker,
                                                        args[1]),
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[2]));

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_cancel_u8(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_cancel_u8(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]));

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_free_u8(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_free_u8(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]));

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_complete_u8(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = ffi_breez_sdk_spark_rust_future_complete_u8(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]),
      &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<uint8_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_poll_i8(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_poll_i8(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]),
      uniffi::breez_sdk_spark::Bridging<
          UniffiRustFutureContinuationCallback>::fromJs(rt, callInvoker,
                                                        args[1]),
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[2]));

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_cancel_i8(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_cancel_i8(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]));

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_free_i8(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_free_i8(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]));

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_complete_i8(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = ffi_breez_sdk_spark_rust_future_complete_i8(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]),
      &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<int8_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_poll_u16(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_poll_u16(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]),
      uniffi::breez_sdk_spark::Bridging<
          UniffiRustFutureContinuationCallback>::fromJs(rt, callInvoker,
                                                        args[1]),
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[2]));

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_cancel_u16(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_cancel_u16(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]));

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_free_u16(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_free_u16(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]));

  return jsi::Value::undefined();
}
jsi::Value
NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_complete_u16(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = ffi_breez_sdk_spark_rust_future_complete_u16(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]),
      &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_poll_i16(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_poll_i16(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]),
      uniffi::breez_sdk_spark::Bridging<
          UniffiRustFutureContinuationCallback>::fromJs(rt, callInvoker,
                                                        args[1]),
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[2]));

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_cancel_i16(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_cancel_i16(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]));

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_free_i16(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_free_i16(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]));

  return jsi::Value::undefined();
}
jsi::Value
NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_complete_i16(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = ffi_breez_sdk_spark_rust_future_complete_i16(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]),
      &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<int16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_poll_u32(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_poll_u32(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]),
      uniffi::breez_sdk_spark::Bridging<
          UniffiRustFutureContinuationCallback>::fromJs(rt, callInvoker,
                                                        args[1]),
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[2]));

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_cancel_u32(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_cancel_u32(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]));

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_free_u32(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_free_u32(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]));

  return jsi::Value::undefined();
}
jsi::Value
NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_complete_u32(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = ffi_breez_sdk_spark_rust_future_complete_u32(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]),
      &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<uint32_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_poll_i32(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_poll_i32(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]),
      uniffi::breez_sdk_spark::Bridging<
          UniffiRustFutureContinuationCallback>::fromJs(rt, callInvoker,
                                                        args[1]),
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[2]));

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_cancel_i32(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_cancel_i32(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]));

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_free_i32(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_free_i32(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]));

  return jsi::Value::undefined();
}
jsi::Value
NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_complete_i32(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = ffi_breez_sdk_spark_rust_future_complete_i32(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]),
      &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<int32_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_poll_u64(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_poll_u64(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]),
      uniffi::breez_sdk_spark::Bridging<
          UniffiRustFutureContinuationCallback>::fromJs(rt, callInvoker,
                                                        args[1]),
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[2]));

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_cancel_u64(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_cancel_u64(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]));

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_free_u64(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_free_u64(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]));

  return jsi::Value::undefined();
}
jsi::Value
NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_complete_u64(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = ffi_breez_sdk_spark_rust_future_complete_u64(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]),
      &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<uint64_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_poll_i64(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_poll_i64(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]),
      uniffi::breez_sdk_spark::Bridging<
          UniffiRustFutureContinuationCallback>::fromJs(rt, callInvoker,
                                                        args[1]),
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[2]));

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_cancel_i64(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_cancel_i64(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]));

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_free_i64(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_free_i64(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]));

  return jsi::Value::undefined();
}
jsi::Value
NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_complete_i64(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = ffi_breez_sdk_spark_rust_future_complete_i64(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]),
      &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<int64_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_poll_f32(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_poll_f32(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]),
      uniffi::breez_sdk_spark::Bridging<
          UniffiRustFutureContinuationCallback>::fromJs(rt, callInvoker,
                                                        args[1]),
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[2]));

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_cancel_f32(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_cancel_f32(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]));

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_free_f32(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_free_f32(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]));

  return jsi::Value::undefined();
}
jsi::Value
NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_complete_f32(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = ffi_breez_sdk_spark_rust_future_complete_f32(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]),
      &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<float>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_poll_f64(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_poll_f64(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]),
      uniffi::breez_sdk_spark::Bridging<
          UniffiRustFutureContinuationCallback>::fromJs(rt, callInvoker,
                                                        args[1]),
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[2]));

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_cancel_f64(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_cancel_f64(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]));

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_free_f64(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_free_f64(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]));

  return jsi::Value::undefined();
}
jsi::Value
NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_complete_f64(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = ffi_breez_sdk_spark_rust_future_complete_f64(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]),
      &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<double>::toJs(rt, callInvoker, value);
}
jsi::Value
NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_poll_pointer(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_poll_pointer(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]),
      uniffi::breez_sdk_spark::Bridging<
          UniffiRustFutureContinuationCallback>::fromJs(rt, callInvoker,
                                                        args[1]),
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[2]));

  return jsi::Value::undefined();
}
jsi::Value
NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_cancel_pointer(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_cancel_pointer(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]));

  return jsi::Value::undefined();
}
jsi::Value
NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_free_pointer(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_free_pointer(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]));

  return jsi::Value::undefined();
}
jsi::Value
NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_complete_pointer(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = ffi_breez_sdk_spark_rust_future_complete_pointer(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]),
      &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi_jsi::Bridging<void *>::toJs(rt, callInvoker, value);
}
jsi::Value
NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_poll_rust_buffer(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_poll_rust_buffer(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]),
      uniffi::breez_sdk_spark::Bridging<
          UniffiRustFutureContinuationCallback>::fromJs(rt, callInvoker,
                                                        args[1]),
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[2]));

  return jsi::Value::undefined();
}
jsi::Value
NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_cancel_rust_buffer(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_cancel_rust_buffer(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]));

  return jsi::Value::undefined();
}
jsi::Value
NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_free_rust_buffer(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_free_rust_buffer(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]));

  return jsi::Value::undefined();
}
jsi::Value
NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_complete_rust_buffer(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  auto value = ffi_breez_sdk_spark_rust_future_complete_rust_buffer(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]),
      &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return uniffi::breez_sdk_spark::Bridging<RustBuffer>::toJs(rt, callInvoker,
                                                             value);
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_poll_void(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_poll_void(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]),
      uniffi::breez_sdk_spark::Bridging<
          UniffiRustFutureContinuationCallback>::fromJs(rt, callInvoker,
                                                        args[1]),
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[2]));

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_cancel_void(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_cancel_void(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]));

  return jsi::Value::undefined();
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_free_void(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  ffi_breez_sdk_spark_rust_future_free_void(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]));

  return jsi::Value::undefined();
}
jsi::Value
NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_rust_future_complete_void(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  RustCallStatus status =
      uniffi::breez_sdk_spark::Bridging<RustCallStatus>::rustSuccess(rt);
  ffi_breez_sdk_spark_rust_future_complete_void(
      uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker,
                                                        args[0]),
      &status);
  uniffi::breez_sdk_spark::Bridging<RustCallStatus>::copyIntoJs(
      rt, callInvoker, status, args[count - 1]);

  return jsi::Value::undefined();
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_checksum_func_connect(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_func_connect();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_func_connect_with_signer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_func_connect_with_signer();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_func_connect_with_signing_only_signer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_func_connect_with_signing_only_signer();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_func_create_turnkey_signer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_func_create_turnkey_signer();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_func_create_turnkey_signing_only_signer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_func_create_turnkey_signing_only_signer();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_checksum_func_custom_storage(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_func_custom_storage();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_checksum_func_default_config(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_func_default_config();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_func_default_external_signers(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_func_default_external_signers();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_func_default_server_config(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_func_default_server_config();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_func_default_session_store(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_func_default_session_store();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_checksum_func_default_storage(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_func_default_storage();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_checksum_func_get_spark_status(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_func_get_spark_status();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_checksum_func_init_logging(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_func_init_logging();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_func_new_rest_chain_service(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_func_new_rest_chain_service();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_func_new_shared_sdk_context(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_func_new_shared_sdk_context();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_func_single_key_cpfp_signer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_func_single_key_cpfp_signer();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_get_address_utxos(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_get_address_utxos();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_get_address_txos(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_get_address_txos();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_get_transaction_status(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_get_transaction_status();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_tip_height(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_tip_height();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_get_transaction_hex(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_get_transaction_hex();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_get_outspend(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_get_outspend();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_broadcast_transaction(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_broadcast_transaction();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_recommended_fees(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_bitcoinchainservice_recommended_fees();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_add_contact(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_breezsdk_add_contact();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_add_event_listener(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_add_event_listener();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_authorize_lightning_address_transfer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_authorize_lightning_address_transfer();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_build_unsigned_batch_package(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_build_unsigned_batch_package();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_build_unsigned_lnurl_pay_package(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_build_unsigned_lnurl_pay_package();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_build_unsigned_transfer_package(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_build_unsigned_transfer_package();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_buy_bitcoin(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_breezsdk_buy_bitcoin();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_check_lightning_address_available(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_check_lightning_address_available();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_check_message(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_breezsdk_check_message();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_check_unilateral_exit(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_check_unilateral_exit();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_claim_deposit(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_breezsdk_claim_deposit();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_claim_htlc_payment(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_claim_htlc_payment();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_claim_lightning_address_transfer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_claim_lightning_address_transfer();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_delete_contact(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_breezsdk_delete_contact();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_delete_lightning_address(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_delete_lightning_address();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_disconnect(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_breezsdk_disconnect();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_export_unilateral_exit_state(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_export_unilateral_exit_state();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_fetch_claim_deposit_quote(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_fetch_claim_deposit_quote();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_fetch_conversion_limits(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_fetch_conversion_limits();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_get_cross_chain_routes(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_get_cross_chain_routes();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_get_info(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_breezsdk_get_info();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_get_lightning_address(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_get_lightning_address();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_get_payment(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_breezsdk_get_payment();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_get_token_issuer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_get_token_issuer();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_get_tokens_metadata(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_get_tokens_metadata();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_get_user_settings(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_get_user_settings();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_import_unilateral_exit_state(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_import_unilateral_exit_state();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_list_contacts(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_breezsdk_list_contacts();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_list_fiat_currencies(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_list_fiat_currencies();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_list_fiat_rates(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_list_fiat_rates();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_list_payments(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_breezsdk_list_payments();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_list_unclaimed_deposits(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_list_unclaimed_deposits();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_list_webhooks(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_breezsdk_list_webhooks();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_lnurl_auth(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_breezsdk_lnurl_auth();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_lnurl_pay(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_breezsdk_lnurl_pay();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_lnurl_withdraw(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_breezsdk_lnurl_withdraw();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_optimize_leaves(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_optimize_leaves();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_parse(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_breezsdk_parse();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_prepare_lnurl_pay(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_prepare_lnurl_pay();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_prepare_payment_link(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_prepare_payment_link();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_prepare_send_batch(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_prepare_send_batch();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_prepare_send_payment(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_prepare_send_payment();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_prepare_unilateral_exit(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_prepare_unilateral_exit();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_publish_signed_lnurl_pay_package(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_publish_signed_lnurl_pay_package();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_publish_signed_transfer_package(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_publish_signed_transfer_package();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_receive_payment(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_receive_payment();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_recommended_fees(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_recommended_fees();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_refund_deposit(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_breezsdk_refund_deposit();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_refund_pending_conversions(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_refund_pending_conversions();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_register_lightning_address(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_register_lightning_address();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_register_webhook(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_register_webhook();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_remove_event_listener(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_remove_event_listener();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_send_batch(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_breezsdk_send_batch();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_send_payment(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_breezsdk_send_payment();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_sign_message(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_breezsdk_sign_message();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_sync_wallet(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_breezsdk_sync_wallet();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_unilateral_exit(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_unilateral_exit();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_unregister_webhook(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_unregister_webhook();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_update_contact(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_breezsdk_update_contact();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_breezsdk_update_user_settings(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_breezsdk_update_user_settings();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_cpfpsigner_sign_psbt(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_cpfpsigner_sign_psbt();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_derive_public_key(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_derive_public_key();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_sign_ecdsa(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_sign_ecdsa();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_sign_ecdsa_recoverable(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_sign_ecdsa_recoverable();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_encrypt_ecies(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_encrypt_ecies();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_decrypt_ecies(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_decrypt_ecies();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_sign_hash_schnorr(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_sign_hash_schnorr();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_hmac_sha256(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalbreezsigner_hmac_sha256();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalsigningsigner_derive_public_key(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalsigningsigner_derive_public_key();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalsigningsigner_sign_ecdsa(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalsigningsigner_sign_ecdsa();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalsigningsigner_sign_ecdsa_recoverable(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalsigningsigner_sign_ecdsa_recoverable();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalsigningsigner_sign_hash_schnorr(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalsigningsigner_sign_hash_schnorr();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_get_identity_public_key(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalsparksigner_get_identity_public_key();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_get_public_key_for_leaf(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalsparksigner_get_public_key_for_leaf();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_is_remote(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalsparksigner_is_remote();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_get_static_deposit_public_key(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalsparksigner_get_static_deposit_public_key();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_authentication_challenge(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_authentication_challenge();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_message(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_message();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_leaf_refund_spend(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_leaf_refund_spend();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_frost(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_frost();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_prepare_transfer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalsparksigner_prepare_transfer();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_prepare_claim(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalsparksigner_prepare_claim();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_prepare_lightning_receive(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalsparksigner_prepare_lightning_receive();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_prepare_static_deposit(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalsparksigner_prepare_static_deposit();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_start_static_deposit_refund(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalsparksigner_start_static_deposit_refund();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_static_deposit_refund(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_static_deposit_refund();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_spark_invoice(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalsparksigner_sign_spark_invoice();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_prepare_token_transaction(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalsparksigner_prepare_token_transaction();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_externalsparksigner_prepare_static_deposit_claim(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_externalsparksigner_prepare_static_deposit_claim();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_fiatservice_fetch_fiat_currencies(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_fiatservice_fetch_fiat_currencies();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_fiatservice_fetch_fiat_rates(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_fiatservice_fetch_fiat_rates();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_passkeyclient_check_availability(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_passkeyclient_check_availability();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_passkeyclient_connect_with_passkey(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_passkeyclient_connect_with_passkey();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_passkeyclient_labels(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_passkeyclient_labels();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_passkeyclient_register(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_passkeyclient_register();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_passkeyclient_sign_in(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_passkeyclient_sign_in();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_passkeylabels_list(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_passkeylabels_list();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_passkeylabels_store(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_passkeylabels_store();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_paymentobserver_before_send(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_paymentobserver_before_send();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_paymentobserver_after_send(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_paymentobserver_after_send();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_prfprovider_derive_seeds(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_prfprovider_derive_seeds();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_prfprovider_is_supported(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_prfprovider_is_supported();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_prfprovider_create_passkey(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_prfprovider_create_passkey();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_prfprovider_check_domain_association(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_prfprovider_check_domain_association();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_restclient_get_request(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_restclient_get_request();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_restclient_post_request(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_restclient_post_request();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_restclient_delete_request(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_restclient_delete_request();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_build(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_sdkbuilder_build();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_account_number(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_account_number();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_chain_service(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_chain_service();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_default_storage(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_default_storage();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_fiat_service(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_fiat_service();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_lnurl_client(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_lnurl_client();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_payment_observer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_payment_observer();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_rest_chain_service(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_rest_chain_service();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_session_store(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_session_store();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_shared_context(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_shared_context();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_storage(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_storage();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_storage_backend(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_sdkbuilder_with_storage_backend();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_sessionstore_get_session(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_sessionstore_get_session();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_sessionstore_set_session(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_sessionstore_set_session();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_delete_cached_item(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_storage_delete_cached_item();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_get_cached_item(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_storage_get_cached_item();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_set_cached_item(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_storage_set_cached_item();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_list_payments(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_storage_list_payments();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_apply_payment_update(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_storage_apply_payment_update();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_insert_payment_metadata(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_storage_insert_payment_metadata();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_get_payment_by_id(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_storage_get_payment_by_id();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_get_payment_by_invoice(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_storage_get_payment_by_invoice();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_get_payments_by_parent_ids(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_storage_get_payments_by_parent_ids();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_add_deposit(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_storage_add_deposit();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_delete_deposit(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_storage_delete_deposit();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_list_deposits(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_storage_list_deposits();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_update_deposit(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_storage_update_deposit();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_set_lnurl_metadata(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_storage_set_lnurl_metadata();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_list_contacts(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_storage_list_contacts();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_get_contact(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_storage_get_contact();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_insert_contact(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_storage_insert_contact();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_delete_contact(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_storage_delete_contact();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_set_cross_chain_swap(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_storage_set_cross_chain_swap();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_get_cross_chain_swap(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_storage_get_cross_chain_swap();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_list_active_cross_chain_swaps(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_storage_list_active_cross_chain_swaps();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_add_outgoing_change(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_storage_add_outgoing_change();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_complete_outgoing_sync(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_storage_complete_outgoing_sync();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_get_pending_outgoing_changes(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_storage_get_pending_outgoing_changes();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_get_last_revision(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_storage_get_last_revision();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_insert_incoming_records(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_storage_insert_incoming_records();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_delete_incoming_record(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_storage_delete_incoming_record();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_get_incoming_records(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_storage_get_incoming_records();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_get_latest_outgoing_change(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_storage_get_latest_outgoing_change();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storage_update_record_from_incoming(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_storage_update_record_from_incoming();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_storagebackend_create_stores(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_storagebackend_create_stores();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_tokenissuer_burn_issuer_token(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_tokenissuer_burn_issuer_token();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_tokenissuer_create_issuer_token(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_tokenissuer_create_issuer_token();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_tokenissuer_freeze_issuer_token(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_tokenissuer_freeze_issuer_token();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_tokenissuer_get_issuer_token_balance(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_tokenissuer_get_issuer_token_balance();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_tokenissuer_get_issuer_token_metadata(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_tokenissuer_get_issuer_token_metadata();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_tokenissuer_mint_issuer_token(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_tokenissuer_mint_issuer_token();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_tokenissuer_unfreeze_issuer_token(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_method_tokenissuer_unfreeze_issuer_token();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_constructor_passkeyclient_new(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_constructor_passkeyclient_new();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_constructor_sdkbuilder_new(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_constructor_sdkbuilder_new();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_constructor_sdkbuilder_new_with_signer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_constructor_sdkbuilder_new_with_signer();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_constructor_sdkbuilder_new_with_signing_only_signer(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value =
      uniffi_breez_sdk_spark_checksum_constructor_sdkbuilder_new_with_signing_only_signer();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::
    cpp_uniffi_breez_sdk_spark_checksum_method_eventlistener_on_event(
        jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
        size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_eventlistener_on_event();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value
NativeBreezSdkSpark::cpp_uniffi_breez_sdk_spark_checksum_method_logger_log(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = uniffi_breez_sdk_spark_checksum_method_logger_log();

  return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
}
jsi::Value NativeBreezSdkSpark::cpp_ffi_breez_sdk_spark_uniffi_contract_version(
    jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args,
    size_t count) {
  auto value = ffi_breez_sdk_spark_uniffi_contract_version();

  return uniffi_jsi::Bridging<uint32_t>::toJs(rt, callInvoker, value);
}