### Install Dependencies and Start GUI Dev Server Source: https://github.com/eigenwallet/core/blob/master/src-gui/README.md Navigate to the GUI directory, install Node.js dependencies, and start the Vite development server. This command should be run first to ensure the frontend is ready. ```bash cd src-gui yarn install && yarn run dev # let this run ``` -------------------------------- ### Run Orchestrator Wizard Source: https://github.com/eigenwallet/core/blob/master/swap-orchestrator/README.md Starts the orchestrator setup wizard. This command guides users through generating configuration files for a Dockerized ASB environment. ```bash ./orchestrator ``` -------------------------------- ### Discover and Take Script Example Source: https://github.com/eigenwallet/core/blob/master/dev-docs/cli/README.md An example script demonstrating how to automate the process of discovering sellers and initiating a swap. This script composes the `buy-xmr` and `list-sellers` commands. ```bash #!/bin/bash # This script is an example of what can be done by composing # the `buy-xmr` and `list-sellers` commands. # Deciding on the seller to use is non-trivial to automate which is why it is not implemented as part of the tool. # Example usage: # ./discover_and_take.sh --testnet --rendezvous-point "/dns4/discovery.eigenwallet.org/tcp/443/wss/p2p/12D3KooWGRvf7qVQDrNR5nfYD6rKrbgeTi9x8RrbdxbmsPvxL4mw" # Parse command-line arguments TESTNET_FLAG="" RENDEZVOUS_POINT="" while [[ "$#" -gt 0 ]]; do key="$1" case $key in --testnet) TESTNET_FLAG="--testnet" shift # past argument ;; --rendezvous-point) RENDEZVOUS_POINT="$2" shift # past argument shift # past value ;; *) echo "Unknown option: $1" exit 1 ;; esac done if [ -z "$RENDEZVOUS_POINT" ]; then echo "Error: --rendezvous-point is required." exit 1 fi # Construct the list-sellers command LIST_SELLERS_CMD="swap list-sellers $TESTNET_FLAG --rendezvous-point \"$RENDEZVOUS_POINT\"" echo "Running: $LIST_SELLERS_CMD" # Execute the list-sellers command and capture output SELLER_OUTPUT=$($LIST_SELLERS_CMD) echo "Seller Discovery Output:" echo "$SELLER_OUTPUT" # --- Automation Logic Placeholder --- # In a real scenario, you would parse the SELLER_OUTPUT here # to select a suitable seller based on criteria like price, min/max quantity, and status. # For example: # SELECTED_SELLER=$(echo "$SELLER_OUTPUT" | awk 'NR>6 {print $5; exit}') # Simplified: takes the first seller address # if [ -n "$SELECTED_SELLER" ]; then # echo "Selected seller: $SELECTED_SELLER" # # Construct and execute the buy-xmr command with the selected seller # BUY_XMR_CMD="swap buy-xmr $TESTNET_FLAG --seller \"$SELECTED_SELLER\" ..." # echo "Running: $BUY_XMR_CMD" # # $BUY_XMR_CMD # else # echo "No suitable seller found." # fi echo "\nNote: Deciding on the seller to use is non-trivial to automate and is not implemented in this example script." ``` -------------------------------- ### Start Docker Compose Services Source: https://github.com/eigenwallet/core/blob/master/docs/content/becoming_a_maker/overview.mdx Builds images if necessary and starts all defined services in the background. Use this for the initial setup or when changes require a rebuild. ```bash docker compose up -d --build ``` -------------------------------- ### Install and Run Tests with Cargo-Nextest Source: https://github.com/eigenwallet/core/blob/master/README.md Install cargo-nextest and run the test suite for the repository. Ensure you have cargo installed first. ```bash cargo install cargo-nextest ``` ```bash cargo nextest run ``` -------------------------------- ### Run Eigenwallet Application Source: https://github.com/eigenwallet/core/blob/master/flatpak/index.html Execute this command to launch the Eigenwallet application after installation. Ensure the application is correctly installed. ```bash flatpak run org.eigenwallet.app ``` -------------------------------- ### Install Eigenwallet Application Source: https://github.com/eigenwallet/core/blob/master/flatpak/index.html After adding the repository, use this command to install the Eigenwallet application. This requires Flatpak 1.0 or newer. ```bash flatpak install eigenwallet org.eigenwallet.app ``` -------------------------------- ### Install Eigenwallet using Flatpak Source: https://github.com/eigenwallet/core/blob/master/docs/content/getting_started/install_instructions.mdx Install Eigenwallet on Linux distributions with Flatpak support. This involves adding the Eigenwallet repository, installing necessary dependencies, and then installing the application. ```bash # Add eigenwallet repo flatpak remote-add --if-not-exists eigenwallet https://eigenwallet.github.io/core/eigenwallet.flatpakrepo # Add dependencies flatpak install flathub org.gnome.Platform//47 # Install eigenwallet flatpak install eigenwallet org.eigenwallet.app ``` -------------------------------- ### Start Tauri Dev Server with Testnet Source: https://github.com/eigenwallet/core/blob/master/src-gui/README.md Navigate to the Tauri directory and start the Tauri development server. The `--no-watch` flag prevents automatic rebuilding, and `-- -- --testnet` passes the testnet argument to the backend. ```bash cd src-tauri cargo tauri dev --no-watch -- -- --testnet # let this run as well ``` -------------------------------- ### Launch UnstoppableSwap GUI in Testnet Mode (Linux) Source: https://github.com/eigenwallet/core/blob/master/docs/content/advanced/swap_on_testnet.mdx Execute this command to start the UnstoppableSwap GUI in testnet mode on Linux. ```bash ./UnstoppableSwap_*_amd64.AppImage --testnet ``` -------------------------------- ### Start Electrum in Testnet Mode (Linux) Source: https://github.com/eigenwallet/core/blob/master/docs/content/advanced/swap_on_testnet.mdx Use this command to launch the Electrum wallet in testnet mode on Linux. ```bash ./electrum --testnet ``` -------------------------------- ### Install Eigenwallet from AUR Source: https://github.com/eigenwallet/core/blob/master/docs/content/getting_started/install_instructions.mdx Install the community-maintained `eigenwallet-bin` package from the Arch User Repository (AUR) using `yay`. Note that AUR packages are not officially supported and should be reviewed for security. ```bash yay -S eigenwallet-bin ``` -------------------------------- ### Initiate BTC to XMR Swap (CLI) Source: https://github.com/eigenwallet/core/blob/master/swap/README.md Execute this command to start a swap where you send BTC and receive XMR on the testnet. Replace placeholders with your actual Monero receive address, Bitcoin change address, and the seller's multiaddress. ```shell ./swap --testnet buy-xmr --receive-address --change-address --seller ``` -------------------------------- ### Start Electrum in Testnet Mode (macOS) Source: https://github.com/eigenwallet/core/blob/master/docs/content/advanced/swap_on_testnet.mdx Use this command to launch the Electrum wallet in testnet mode on macOS. ```bash open -n /Applications/Electrum.app --args --testnet ``` -------------------------------- ### Start Docker Compose Environment Source: https://github.com/eigenwallet/core/blob/master/swap-orchestrator/README.md Starts the Docker Compose environment in detached mode. This command is used to bring up all the necessary containers for the swap orchestrator. ```bash docker compose up -d ``` -------------------------------- ### Establish a Tor Connection in libp2p Source: https://github.com/eigenwallet/core/blob/master/libp2p-tor/README.md Example of bootstrapping a Tor connection and dialing a remote address using the libp2p-tor transport. Ensure you have parsed the address correctly. ```rust let address = "/dns/www.torproject.org/tcp/1000".parse()?; let mut transport = libp2p_tor::TorTransport::bootstrapped().await?; // we have achieved tor connection let _conn = transport.dial(address)?.await?; ``` -------------------------------- ### Add Eigenwallet Flatpak Repository Source: https://github.com/eigenwallet/core/blob/master/flatpak/index.html Use this command to add the Eigenwallet Flatpak repository to your system. Ensure Flatpak is installed and up to date. ```bash flatpak remote-add --if-not-exists eigenwallet https://eigenwallet.github.io/core/eigenwallet.flatpakrepo ``` -------------------------------- ### Start React DevTools Server Source: https://github.com/eigenwallet/core/blob/master/src-gui/README.md Launch the standalone React DevTools server. The frontend application will automatically connect to this server for debugging React components. ```bash npx react-devtools ``` -------------------------------- ### Start Redux DevTools Server Source: https://github.com/eigenwallet/core/blob/master/src-gui/README.md Start the Redux DevTools server with specified hostname and port. This allows debugging the global Redux state, including observing changes and time-travel capabilities. Ensure to configure the devtools client to use this local server. ```bash npx redux-devtools --hostname=localhost --port=8098 --open ``` -------------------------------- ### Successful Seller Discovery Output Source: https://github.com/eigenwallet/core/blob/master/dev-docs/cli/README.md Example output showing a successful connection to a rendezvous point and the discovery of an online seller with their price, quantity limits, and address. ```text Connected to rendezvous point, discovering nodes in 'xmr-btc-swap-testnet' namespace ... Discovered peer 12D3KooWPZ69DRp4wbGB3wJsxxsg1XW1EVZ2evtVwcARCF3a1nrx at /dns4/ac4hgzmsmekwekjbdl77brufqqbylddugzze4tel6qsnlympgmr46iid.onion/tcp/8765 +----------------+----------------+----------------+--------+----------------------------------------------------------------------------------------------------------------------------------------+ | PRICE | MIN_QUANTITY | MAX_QUANTITY | STATUS | ADDRESS | +====================================================================================================================================================================================================+ | 0.00665754 BTC | 0.00010000 BTC | 0.00100000 BTC | Online | /dns4/ac4hgzmsmekwekjbdl77brufqqbylddugzze4tel6qsnlympgmr46iid.onion/tcp/8765/p2p/12D3KooWPZ69DRp4wbGB3wJsxxsg1XW1EVZ2evtVwcARCF3a1nrx | +----------------+----------------+----------------+--------+----------------------------------------------------------------------------------------------------------------------------------------+ ``` -------------------------------- ### Download and Run AppImage on Linux Source: https://github.com/eigenwallet/core/blob/master/docs/content/getting_started/install_instructions.mdx Use this script to download the latest Eigenwallet AppImage from GitHub, make it executable, and run it. Ensure you have `curl` and `wget` installed. ```bash # Find the latest AppImage file EIGENWALLET_APPIMAGE=$(curl -s https://api.github.com/repos/eigenwallet/core/releases/latest | grep -o 'https://[^"]*\.AppImage' | head -1 | xargs basename) # Download the lastest file wget https://github.com/eigenwallet/core/releases/latest/download/$EIGENWALLET_APPIMAGE # Make it executable chmod +x $EIGENWALLET_APPIMAGE # Start eigenwallet ./$EIGENWALLET_APPIMAGE ``` -------------------------------- ### Unreachable Seller Discovery Output Source: https://github.com/eigenwallet/core/blob/master/dev-docs/cli/README.md Example output indicating that a discovered node is not reachable, showing '???' for price and quantity details, and 'Unreachable' for the status. ```text Connected to rendezvous point, discovering nodes in 'xmr-btc-swap-testnet' namespace ... Discovered peer 12D3KooWPZ69DRp4wbGB3wJsxxsg1XW1EVZ2evtVwcARCF3a1nrx at /dns4/ac4hgzmsmekwekjbdl77brufqqbylddugzze4tel6qsnlympgmr46iid.onion/tcp/8765 +-------+--------------+--------------+-------------+----------------------------------------------------------------------------------------------------------------------------------------+ | PRICE | MIN_QUANTITY | MAX_QUANTITY | STATUS | ADDRESS | +============================================================================================================================================================================================+ | ??? | ??? | ??? | Unreachable | /dns4/ac4hgzmsmekwekjbdl77brufqqbylddugzze4tel6qsnlympgmr46iid.onion/tcp/8765/p2p/12D3KooWPZ69DRp4wbGB3wJsxxsg1XW1EVZ2evtVwcARCF3a1nrx | +-------+--------------+--------------+-------------+----------------------------------------------------------------------------------------------------------------------------------------+ ``` -------------------------------- ### Download Orchestrator Binary for Linux x86_64 Source: https://github.com/eigenwallet/core/blob/master/swap-orchestrator/README.md Downloads the latest orchestrator release archive for Linux x86_64 from GitHub. This command is useful for quick installation or updating on a Linux server. ```bash name="$( curl -fsSL https://api.github.com/repos/eigenwallet/core/releases/latest \ | grep -oE '"name":\s*"orchestrator_[^ vital]*_Linux_x86_64.tar"' \ | head -n1 | cut -d'"' -f4 )" curl -fL -o "orchestrator_linux.tar" "https://github.com/eigenwallet/core/releases/latest/download/$name" ``` -------------------------------- ### Default Mainnet Configuration Source: https://github.com/eigenwallet/core/blob/master/docs/content/becoming_a_maker/overview.mdx This TOML configuration file outlines the default settings for the Eigenwallet Maker on the mainnet. It includes parameters for maker operations, Bitcoin and Monero node connections, Tor hidden service setup, data directory, and network rendezvous points. ```toml [maker] min_buy_btc = 0.001 max_buy_btc = 0.1 ask_spread = 0.02 price_ticker_ws_url_kraken = "wss://ws.kraken.com/" price_ticker_ws_url_bitfinex = "wss://api-pub.bitfinex.com/ws/2" external_bitcoin_address = "bc1..." [bitcoin] electrum_rpc_urls = ["tcp://mainnet_electrs:50001"] target_block = 1 use_mempool_space_fee_estimation = true network = "Mainnet" [monero] daemon_url = "http://mainnet_monerod:18081" network = "Mainnet" [tor] register_hidden_service = true hidden_service_num_intro_points = 5 wormhole_enabled = true wormhole_max_concurrent_rend_requests = 3 wormhole_num_intro_points = 3 [data] dir = "/asb-data/" [network] listen = ["/ip4/0.0.0.0/tcp/9939"] rendezvous_point = [ "/dns4/discovery.eigenwallet.org/tcp/443/wss/p2p/12D3KooWGRvf7qVQDrNR5nfYD6rKrbgeTi9x8RrbdxbmsPvxL4mw", "/dns4/rendezvous.atomicworld.fun/tcp/443/wss/p2p/12D3KooWMc39w7bZz4RLmJKuUiK9YkbKoEHACZWcL71XNns5dPuD", "/dns4/dht.stealthswap.ninja/tcp/443/wss/p2p/12D3KooWGjcxdpsEWspGGwkQJ9BRJQjtBQFsLk36zJxrXSBPQWov", "/dns4/discovery2.eigenwallet.org/tcp/443/wss/p2p/12D3KooWA6cnqJpVnreBVnoro8midDL9Lpzmg8oJPoAGi7YYaamE" ] external_addresses = [] ``` -------------------------------- ### Build Project Source: https://github.com/eigenwallet/core/blob/master/monero-sys/CLAUDE.md Use this command to compile the project. ```bash cargo build ``` -------------------------------- ### Swap Buy XMR Command Help Output Source: https://github.com/eigenwallet/core/blob/master/dev-docs/cli/README.md Running `swap buy-xmr --help` provides detailed usage information for initiating a BTC to XMR swap. It lists the required options and available flags for this specific command. ```shell swap-buy-xmr 0.8.0 Start a BTC for XMR swap USAGE: swap buy-xmr [FLAGS] [OPTIONS] --change-address --receive-address --seller FLAGS: -h, --help Prints help information --testnet Swap on testnet and assume testnet defaults for data-dir and the blockchain related parameters -V, --version Prints version information OPTIONS: --change-address The bitcoin address where any form of change or excess funds should be sent to --receive-address The monero address where you would like to receive monero --seller The seller's address. Must include a peer ID part, i.e. `/p2p/` --electrum-rpc Provide the Bitcoin Electrum RPC URL --bitcoin-target-block Estimate Bitcoin fees such that transactions are confirmed within the specified number of blocks --monero-daemon-address Specify to connect to a monero daemon of your choice: : --tor-socks5-port Your local Tor socks5 proxy port [default: 9050] ``` -------------------------------- ### Swap CLI Help Output Source: https://github.com/eigenwallet/core/blob/master/dev-docs/cli/README.md Running `swap --help` displays the available commands, flags, and options for the Swap CLI. This output provides a comprehensive overview of the tool's capabilities. ```shell swap 0.8.0 The COMIT guys CLI for swapping BTC for XMR USAGE: swap [FLAGS] [OPTIONS] FLAGS: --debug Activate debug logging -h, --help Prints help information -j, --json Outputs all logs in JSON format instead of plain text --testnet Swap on testnet and assume testnet defaults for data-dir and the blockchain related parameters -V, --version Prints version information OPTIONS: --data-base-dir The base data directory to be used for mainnet / testnet specific data like database, wallets etc SUBCOMMANDS: buy-xmr Start a BTC for XMR swap list-sellers Discover and list sellers (i.e. ASB providers) cancel Try to cancel an ongoing swap (expert users only) help Prints this message or the help of the given subcommand(s) history Show a list of past, ongoing and completed swaps refund Try to cancel a swap and refund the BTC (expert users only) resume Resume a swap ``` -------------------------------- ### Display All Available Options for Rendezvous Server Source: https://github.com/eigenwallet/core/blob/master/libp2p-rendezvous-node/README.md Run this command to view all command-line options available for configuring the libp2p rendezvous server. ```bash cargo run --release -- --help ``` -------------------------------- ### Swap List Sellers Help Output Source: https://github.com/eigenwallet/core/blob/master/dev-docs/cli/README.md Displays the help information for the `swap list-sellers` command, outlining available flags and options for discovering sellers. ```bash swap list-sellers --help ``` -------------------------------- ### List Available Sellers (CLI) Source: https://github.com/eigenwallet/core/blob/master/swap/README.md Use this command to discover sellers available for swapping on the testnet. Ensure you have the `swap` binary downloaded and executable. ```shell ./swap --testnet list-sellers ``` -------------------------------- ### Using Swap CLI on Testnet Source: https://github.com/eigenwallet/core/blob/master/dev-docs/cli/README.md To use the Swap CLI on testnet for testing and familiarization, append the `--testnet` flag to your command. This flag directs the CLI to transact on Bitcoin testnet and Monero stagenet. ```shell swap --testnet ``` -------------------------------- ### Run the Standalone Rendezvous Server Source: https://github.com/eigenwallet/core/blob/master/libp2p-rendezvous-node/README.md Execute the built rendezvous server binary. It will use default settings for the secret file and listen port. ```bash cargo run --release ``` -------------------------------- ### Build the Standalone Rendezvous Server Binary Source: https://github.com/eigenwallet/core/blob/master/libp2p-rendezvous-node/README.md Use this command to compile the release version of the libp2p rendezvous server binary. ```bash cargo build --release ``` -------------------------------- ### Update Eigenwallet Application Source: https://github.com/eigenwallet/core/blob/master/flatpak/index.html Use this command to update the Eigenwallet application to the latest version available in the Flatpak repository. This command requires the application to be already installed. ```bash flatpak update org.eigenwallet.app ``` -------------------------------- ### Download Release Binary and Signature Source: https://github.com/eigenwallet/core/blob/master/docs/content/getting_started/install_instructions.mdx Download the specific release binary (e.g., a .dmg file) and its corresponding .asc signature file. Ensure the version numbers match. ```bash # Download both the binary and its signature wget https://github.com/eigenwallet/core/releases/download/3.1.3/eigenwallet_3.1.3_aarch64.dmg wget https://github.com/eigenwallet/core/releases/download/3.1.3/eigenwallet_3.1.3_aarch64.dmg.asc ``` -------------------------------- ### Download and Verify Release Binary Signature Source: https://github.com/eigenwallet/core/blob/master/utils/gpg_keys/readme.md Download a release binary archive and its corresponding GPG signature file. Then, use GPG to verify that the signature matches the archive, confirming its integrity. ```bash # Download both the binary archive and its signature wget https://github.com/eigenwallet/core/releases/download/3.0.7/asb_3.0.7_Linux_x86_64.tar wget https://github.com/eigenwallet/core/releases/download/3.0.7/asb_3.0.7_Linux_x86_64.tar.asc # Verify the signature gpg --verify asb_3.0.7_Linux_x86_64.tar.asc asb_3.0.7_Linux_x86_64.tar ``` -------------------------------- ### Verify Binary Signature with GPG Source: https://github.com/eigenwallet/core/blob/master/docs/content/getting_started/install_instructions.mdx Use GPG to verify that the downloaded binary has not been tampered with and was indeed signed by the imported key. A 'Good signature' indicates successful verification. ```bash # Verify the signature gpg --verify eigenwallet_3.1.3_aarch64.dmg.asc eigenwallet_3.1.3_aarch64.dmg ``` -------------------------------- ### Build Process Configuration Source: https://github.com/eigenwallet/core/blob/master/monero-sys/CLAUDE.md Configures the build process using `build.rs` to compile Monero C++ code with CMake, set up include paths, link libraries, and configure CXX for bridging Rust and C++. ```rust // build.rs fn main() { // Compile Monero C++ code with CMake // Configure CXX to build the bridge // Link necessary libraries // ... } ``` -------------------------------- ### ASB Network Configuration Source: https://github.com/eigenwallet/core/blob/master/docs/content/becoming_a_maker/overview.mdx Set up the ASB's network parameters, including listen addresses and rendezvous points. ```toml # ... [network] # the ip and port the asb will listen on listen = ["/ip4/0.0.0.0/tcp/9939"] # the rendezvous points the asb will connect to (address, port and peer id) rendezvous_point = [ "/dns4/discovery.eigenwallet.org/tcp/443/wss/p2p/12D3KooWGRvf7qVQDrNR5nfYD6rKrbgeTi9x8RrbdxbmsPvxL4mw", "/dns4/rendezvous.atomicworld.fun/tcp/443/wss/p2p/12D3KooWMc39w7bZz4RLmJKuUiK9YkbKoEHACZWcL71XNns5dPuD", "/dns4/dht.stealthswap.ninja/tcp/443/wss/p2p/12D3KooWGjcxdpsEWspGGwkQJ9BRJQjtBQFsLk36zJxrXSBPQWov", "/dns4/discovery2.eigenwallet.org/tcp/443/wss/p2p/12D3KooWA6cnqJpVnreBVnoro8midDL9Lpzmg8oJPoAGi7YYaamE" ] # the external addresses the asb will advertise to the rendezvous points (only address) external_addresses = [ # e.g. "/dns4/your.domain.com/tcp/9939/p2p/your1peer2id" ] ``` -------------------------------- ### Import GPG Signing Key Source: https://github.com/eigenwallet/core/blob/master/docs/content/getting_started/install_instructions.mdx Download and import the official Eigenwallet GPG signing key to your local machine. This key is used to verify the authenticity of release signatures. ```bash # Download the key from GitHub wget https://raw.githubusercontent.com/eigenwallet/core/master/utils/gpg_keys/binarybaron_and_einliterflasche.asc # Import it gpg --import binarybaron_and_einliterflasche.asc ``` -------------------------------- ### Launch UnstoppableSwap GUI in Testnet Mode (macOS) Source: https://github.com/eigenwallet/core/blob/master/docs/content/advanced/swap_on_testnet.mdx Use this command to launch the UnstoppableSwap GUI in testnet mode on macOS. ```bash open -n /Applications/UnstoppableSwap.app --args --testnet ``` -------------------------------- ### Test Project Source: https://github.com/eigenwallet/core/blob/master/monero-sys/CLAUDE.md Run all tests to ensure code integrity. ```bash cargo test ``` -------------------------------- ### Import GPG Signing Key Source: https://github.com/eigenwallet/core/blob/master/utils/gpg_keys/readme.md Download and import the public GPG key used for signing Eigenwallet Core releases. This key is necessary for signature verification. ```bash # Download the key from GitHub wget https://raw.githubusercontent.com/eigenwallet/core/master/utils/gpg_keys/binarybaron_and_einliterflasche.asc # Import it gpg --import binarybaron_and_einliterflasche.asc ``` -------------------------------- ### ASB Market Making Configuration Source: https://github.com/eigenwallet/core/blob/master/dev-docs/asb/README.md Configure market-making parameters for the ASB, including minimum and maximum trade amounts, spread, exchange websocket URLs, and developer tip percentage. The external Bitcoin address for swap redemption/punishment can also be specified. ```toml [maker] min_buy_btc = 0.0001 max_buy_btc = 0.0001 ask_spread = 0.02 price_ticker_ws_url_kraken = "wss://ws.kraken.com" price_ticker_ws_url_bitfinex = "wss://api-pub.bitfinex.com/ws/2" price_ticker_rest_url_kucoin = "https://api.kucoin.com/api/v1/bullet-public" external_bitcoin_address = "bc1..." developer_tip = 0.02 ``` -------------------------------- ### Run Rendezvous Server with Custom Secret File and TCP Port Source: https://github.com/eigenwallet/core/blob/master/libp2p-rendezvous-node/README.md Customize the rendezvous server by specifying a custom secret file path and a TCP listen port. ```bash cargo run --release -- --secret-file --listen-tcp ``` -------------------------------- ### Maker Section Configuration Source: https://github.com/eigenwallet/core/blob/master/docs/content/becoming_a_maker/overview.mdx Configure the core behavior of the asb, including trading limits, spread, and API endpoints for price tickers. This section is essential for defining how the bot interacts with markets. ```toml [maker] min_buy_btc = 0.001 max_buy_btc = 0.1 ask_spread = 0.02 price_ticker_ws_url_kraken = "wss://ws.kraken.com/" price_ticker_ws_url_bitfinex = "wss://api-pub.bitfinex.com/ws/2" price_ticker_rest_url_kucoin = "https://api.kucoin.com/api/v1/bullet-public" external_bitcoin_address = "bc1..." developer_tip = 0.02 # ... ``` -------------------------------- ### Make Orchestrator Binary Executable Source: https://github.com/eigenwallet/core/blob/master/swap-orchestrator/README.md Grants execute permissions to the orchestrator binary. This command must be run before executing the orchestrator. ```bash chmod +x orchestrator ``` -------------------------------- ### Add libp2p-tor to Dependencies Source: https://github.com/eigenwallet/core/blob/master/libp2p-tor/README.md Add the libp2p-tor crate to your project's Cargo.toml file using the cargo add command. This crate requires tokio with rustls for its runtime and TLS implementation. ```bash cargo add libp2p-tor ``` -------------------------------- ### Rust: Use anyhow's context for error reporting Source: https://github.com/eigenwallet/core/blob/master/CONTRIBUTING.md Leverage the `.context()` method from the `anyhow` crate along with the `?` operator for streamlined and informative error handling in Rust. This provides better context to errors when they propagate. ```rust let result = some_operation().context("Failed to perform some operation")?; ``` -------------------------------- ### List Docker Compose Services Source: https://github.com/eigenwallet/core/blob/master/docs/content/becoming_a_maker/overview.mdx Displays the status of all services managed by Docker Compose. ```bash docker compose ps ``` -------------------------------- ### Monero Section Configuration Source: https://github.com/eigenwallet/core/blob/master/docs/content/becoming_a_maker/overview.mdx Configure the asb's interaction with the Monero blockchain. The asb uses direct FFI wallet access, eliminating the need for monero-wallet-rpc. These settings are generally not recommended for modification. ```toml # ... [monero] daemon_url = "http://your.monero-daemon.org:18081" network = "Mainnet" ``` -------------------------------- ### Follow Docker Compose Logs Source: https://github.com/eigenwallet/core/blob/master/docs/content/becoming_a_maker/overview.mdx Streams the logs for all services in real-time. You can append a service name like 'asb' to filter the output. ```bash docker compose logs -f --tail 100 ``` -------------------------------- ### ASB Network Configuration with Rendezvous Source: https://github.com/eigenwallet/core/blob/master/dev-docs/asb/README.md Configure rendezvous points and external addresses for ASB discovery. This TOML snippet shows how to set up multiple rendezvous points and specify external addresses for network reachability. ```toml [network] rendezvous_point = [ "/dns4/discovery.eigenwallet.org/tcp/443/wss/p2p/12D3KooWGRvf7qVQDrNR5nfYD6rKrbgeTi9x8RrbdxbmsPvxL4mw", "/dns4/rendezvous.atomicworld.fun/tcp/443/wss/p2p/12D3KooWMc39w7bZz4RLmJKuUiK9YkbKoEHACZWcL71XNns5dPuD", "/dns4/dht.stealthswap.ninja/tcp/443/wss/p2p/12D3KooWGjcxdpsEWspGGwkQJ9BRJQjtBQFsLk36zJxrXSBPQWov", "/dns4/discovery2.eigenwallet.org/tcp/443/wss/p2p/12D3KooWA6cnqJpVnreBVnoro8midDL9Lpzmg8oJPoAGi7YYaamE", ] external_addresses = ["/dns4/example.com/tcp/9939"] ``` -------------------------------- ### Discover Sellers on Testnet via Rendezvous Point Source: https://github.com/eigenwallet/core/blob/master/dev-docs/cli/README.md Command to discover sellers on the testnet using a specified rendezvous point. This is useful for finding ASB providers in a test environment. ```bash swap --testnet list-sellers --rendezvous-point /dns4/discovery.eigenwallet.org/tcp/443/wss/p2p/12D3KooWGRvf7qVQDrNR5nfYD6rKrbgeTi9x8RrbdxbmsPvxL4mw ``` ```bash swap --testnet list-sellers --rendezvous-point /dns4/discovery2.eigenwallet.org/tcp/443/wss/p2p/12D3KooWA6cnqJpVnreBVnoro8midDL9Lpzmg8oJPoAGi7YYaamE ``` -------------------------------- ### Build Docker Images with No Cache Source: https://github.com/eigenwallet/core/blob/master/swap-orchestrator/README.md Builds the Docker images for the ASB environment using Docker Compose. The `--no-cache` flag is recommended to fix potential git caching issues. ```bash docker compose build --no-cache # --no-cache fixes a git caching issue (error: tag clobbered) ``` -------------------------------- ### Navigate to Orchestrator Output Directory Source: https://github.com/eigenwallet/core/blob/master/docs/content/becoming_a_maker/overview.mdx Change to the directory where the orchestrator generated its output files, including the docker-compose.yml. ```bash cd /path/to/orchestrator-output ``` -------------------------------- ### Check Tauri API Bindings Status Source: https://github.com/eigenwallet/core/blob/master/src-gui/README.md Run this command to verify if the current TypeScript bindings for the Tauri API are up-to-date with the Rust backend. ```bash yarn run check-bindings ``` -------------------------------- ### Rust: Use let else for early returns Source: https://github.com/eigenwallet/core/blob/master/CONTRIBUTING.md Employ the `let ... else` construct for cleaner early return patterns in Rust. This is particularly useful when dealing with `Option` or `Result` types. ```rust let Some(value) = optional_value else { // Return early if optional_value is None return; }; // Continue with processing value ``` -------------------------------- ### Rust Wrapper for WalletManager Source: https://github.com/eigenwallet/core/blob/master/monero-sys/CLAUDE.md Provides an idiomatic Rust interface to C++ code, using wrapper types like `WalletManager` with safer methods. It handles memory management and ensures raw pointers are not exposed to users, implementing `Send` and `Sync` where appropriate. ```rust pub struct WalletManager { inner: cxx::UniquePtr } impl WalletManager { // ... pub fn get_wallet_manager() -> Self { let manager = unsafe { ffi::getWalletManager() }; WalletManager { inner: manager } } // ... } ``` -------------------------------- ### Bitcoin Section Configuration Source: https://github.com/eigenwallet/core/blob/master/docs/content/becoming_a_maker/overview.mdx Configure the asb's interaction with the Bitcoin blockchain, including target block confirmation and Electrum server URLs. These settings are generally not recommended for modification. ```toml # ... [bitcoin] target_block = 1 electrum_rpc_urls = ["tcp://mainnet_electrs:50001"] use_mempool_space_fee_estimation = true network = "Mainnet" # ... ``` -------------------------------- ### Generate RPC Authentication Source: https://github.com/eigenwallet/core/blob/master/swap-orchestrator/README.md Generates a hashed verifier for authenticating the JSON-RPC endpoint. This command prompts for a password and stores it in './rpc-auth'. ```bash ./orchestrator gen-rpc-auth ```