This guide will walk you through the process of swapping your oneUNI, oneBTC, or oneDODO tokens for Ally tokens using Etherscan.
The process involves interacting with the AllySwap smart contracts.
Prerequisites
- An Ethereum wallet with your oneTokens (oneUNI, oneBTC, or oneDODO)
- Enough ETH in your wallet to cover gas fees
- Your wallet connected to Etherscan
Step 1: Check if You've Accepted the Terms
- Go to the appropriate AllySwap contract on Etherscan
- Connect your wallet to Etherscan
- Navigate to "Contract" → "Read Contract"
- Find the
isAgreedToTerms
function
- Enter your wallet address
- Click "Query"
- Note the result:
- If
true
→ proceed to Step 3 (Checking Balance)
- If
false
→ proceed to Step 2 (Accepting Terms)
Step 2: Accept Terms and Conditions
If you haven't accepted the terms yet:
- First, read the terms by calling the
termsAndConditions
view function
- Get your terms hash:
- Navigate to "Read Contract"
- Find the
termsHash
function
- Enter your wallet address
- Click "Query"
- Copy the returned hash value
- Accept the terms:
- Navigate to "Contract" → "Write Contract"
- Connect your wallet if not already connected
- Find the
consentAndAgreeToTerms
function
- Paste the hash value you copied earlier
- Click "Write"
- Confirm the transaction in your wallet and pay the gas fee
- Wait for the transaction to be confirmed
Step 3: Check Your oneToken Balance
- Go to your specific oneToken contract address
- Navigate to "Contract" → "Read Contract"
- Find the
balanceOf
function
- Enter your wallet address
- Click "Query"
- Note down your balance - you'll need this for the next step
Step 4: Approve the AllySwap Contract
Before swapping, you need to approve the AllySwap contract to spend your oneTokens:
- Go to your oneToken contract on Etherscan
- Navigate to "Contract" → "Write Contract"
- Find the
approve
function
- Enter:
spender
: The AllySwap contract address for your token
amount
: Your oneToken balance (in wei)
- Click "Write"
- Confirm the transaction in your wallet
Step 5: Perform the Swap
- Return to the AllySwap contract
- Navigate to "Contract" → "Write Contract"
- Find the
swap
function
- Enter:
amountIn
: The amount of oneTokens you want to swap (in wei)
to
: Your wallet address
- Click "Write"
- Confirm the transaction in your wallet
Note: The swap rate is fixed at 7.22491224 Ally tokens per 100 oneTokens.
Verifying Your Swap
After the swap transaction is confirmed:
- Check your Ally token balance in your wallet
- The amount of Ally tokens received should be:
- (Your oneToken amount ÷ 100) × 7.22491224
Troubleshooting
If you encounter any errors:
- Ensure you have enough ETH for gas fees
- Verify you've approved enough oneTokens for the swap
- Double-check all addresses are correct
- Confirm your oneToken balance is sufficient