AMM Swaps & Exchanges
This guide will explain the basics of using Redgold's native swap AMMs to exchange Redgold for other assets, as well as some brief information on how they work, if you are more comfortable in purchasing wrapped assets on another network, this will contain the links and addresses of approved wrapper tokens.
Wrapper Tokens - Ethereum
RDG is available on Ethereum Mainnet via this PancakeSwap liquidity pool with a 0.01% fee (lowest possible.) https://pancakeswap.finance/liquidity/14366?chain=eth
To execute a swap, please navigate to: https://pancakeswap.finance/?outputCurrency=0xb7F964684AFd11baEed81ff433F6701b701Ea16E?chain=eth
Please ensure you double check the links and addresses before sending any funds, as this token contract: https://etherscan.io/token/0xb7f964684afd11baeed81ff433f6701b701ea16e is the only officially approved Redgold ERC-20. It will be natively redeemable for RDG on the Redgold network via bridge, or can be held in perpetuity on Ethereum Mainnet.
Wrapper Tokens - Solana
RDG is available on Solana Mainnet via this Raydium liquidity pool with a 0.01% fee (lowest possible.) https://raydium.io/clmm/create-position/?pool_id=CvyiGhxsgtz7MjpGogDM4aHe3zQMsGQCZfdMbQVQbPZM
To execute a swap, please navigate to: https://raydium.io/swap/?outputMint=CkZ3633K79GiXMqMPCWHKdfrqZgDvygvFxr5nrcKytYZ&inputMint=sol
Please ensure you double check the links and addresses before sending any funds, as this token contract: https://solscan.io/token/CkZ3633K79GiXMqMPCWHKdfrqZgDvygvFxr5nrcKytYZ is the only officially approved Redgold SPL. It will be natively redeemable for RDG on the Redgold network via bridge, or can be held in perpetuity on Solana Mainnet.
Native Swaps
Redgold swaps are still under development, please use the above wrapper tokens for now, the documentation below describes future intended behavior.
Native swaps are a type of automated market maker (AMM) that allows users to swap one asset for another, using a either a multiparty encryption scheme or multi-sig contract for a group of nodes to hold the keys to the underlying assets being swapped. This allows for (mostly) avoiding the use of wrapper tokens and trusted intermediaries. Liquidity is provided to the multiparty group in a permission-less fashion, and the execution of swap requests and overall stake determines the current price automatically.
Execution Requirements
The most important concept to understand before attempting a swap, is that you must have direct access to the keys or mnemonics used to generate the source address of the funds. This is because the output of the swap is sent directly to the corresponding address of the source funds, and can only be unlocked by a signature from the exact same key that was used to send the funds.
This feature is primarily intended for ease-of-use and security, as Redgold can reconstruct Bitcoin and other addresses the same way to verify signatures. Simply having access to a key that sends funds to an AMM is the criteria for unlocking the funds on the other side.
In the future, more complex swapping parameters will be supported for arbitrary key changes during exchange, but this requires a multi-transaction workflow with additional fees, for now, this is the simplest recommended path to follow.
How can I execute a swap?
The native swap API is still under development, it is recommended to use ETH / SOL pools listed above for now. While there is debugging support for swaps in the UI / CLI, it is NOT recommended to use this feature yet.