$npx -y skills add basezh/agent-skills-on-base --skill qrcoinInteract with QR Coin auctions on Base. Use when the user wants to participate in qrcoin.fun QR code auctions — check auction status, view current bids, create new bids, or contribute to existing bids. QR Coin lets you bid to display URLs on QR codes; the highest bidder's URL get
| 1 | # QR Coin Auction |
| 2 | |
| 3 | Participate in [QR Coin](https://qrcoin.fun) auctions on Base blockchain. QR Coin lets you bid to display URLs on QR codes — the highest bidder's URL gets encoded when the auction ends. |
| 4 | |
| 5 | ## Contracts (Base Mainnet) |
| 6 | |
| 7 | | Contract | Address | |
| 8 | |----------|---------| |
| 9 | | QR Auction | `0x7309779122069EFa06ef71a45AE0DB55A259A176` | |
| 10 | | USDC | `0x833589fCD6eDb6E08f4c7c32D4f71b54bdA02913` | |
| 11 | |
| 12 | ## How It Works |
| 13 | |
| 14 | 1. Each auction runs for a fixed period (~24h) |
| 15 | 2. Bidders submit URLs with USDC (6 decimals — 1 USDC = 1000000 units) |
| 16 | 3. Creating a new bid costs ~11.11 USDC (createBidReserve) |
| 17 | 4. Contributing to an existing bid costs ~1.00 USDC (contributeReserve) |
| 18 | 5. Highest bid wins; winner's URL is encoded in the QR code |
| 19 | 6. Losers get refunded; winners receive QR tokens |
| 20 | |
| 21 | ## Auction Status Queries |
| 22 | |
| 23 | > **Note**: The examples below use `https://mainnet.base.org` (public RPC). You can substitute your own RPC endpoint if preferred. |
| 24 | |
| 25 | ### Get Current Token ID |
| 26 | |
| 27 | Always query this first to get the active auction ID before bidding. |
| 28 | |
| 29 | ```bash |
| 30 | curl -s -X POST https://mainnet.base.org \ |
| 31 | -H "Content-Type: application/json" \ |
| 32 | -d '{"jsonrpc":"2.0","method":"eth_call","params":[{"to":"0x7309779122069EFa06ef71a45AE0DB55A259A176","data":"0x7d9f6db5"},"latest"],"id":1}' \ |
| 33 | | jq -r '.result' | xargs printf "%d\n" |
| 34 | ``` |
| 35 | |
| 36 | ### Get Auction End Time |
| 37 | |
| 38 | ```bash |
| 39 | # First get the current token ID, then use it here |
| 40 | TOKEN_ID=329 # Replace with result from currentTokenId() |
| 41 | TOKEN_ID_HEX=$(printf '%064x' $TOKEN_ID) |
| 42 | |
| 43 | curl -s -X POST https://mainnet.base.org \ |
| 44 | -H "Content-Type: application/json" \ |
| 45 | -d '{"jsonrpc":"2.0","method":"eth_call","params":[{"to":"0x7309779122069EFa06ef71a45AE0DB55A259A176","data":"0xa4d0a17e'"$TOKEN_ID_HEX"'"},"latest"],"id":1}' \ |
| 46 | | jq -r '.result' | xargs printf "%d\n" |
| 47 | ``` |
| 48 | |
| 49 | ### Get Reserve Prices |
| 50 | |
| 51 | ```bash |
| 52 | # Create bid reserve (~11.11 USDC) |
| 53 | curl -s -X POST https://mainnet.base.org \ |
| 54 | -H "Content-Type: application/json" \ |
| 55 | -d '{"jsonrpc":"2.0","method":"eth_call","params":[{"to":"0x7309779122069EFa06ef71a45AE0DB55A259A176","data":"0x5b3bec22"},"latest"],"id":1}' \ |
| 56 | | jq -r '.result' | xargs printf "%d\n" | awk '{print $1/1000000 " USDC"}' |
| 57 | |
| 58 | # Contribute reserve (~1.00 USDC) |
| 59 | curl -s -X POST https://mainnet.base.org \ |
| 60 | -H "Content-Type: application/json" \ |
| 61 | -d '{"jsonrpc":"2.0","method":"eth_call","params":[{"to":"0x7309779122069EFa06ef71a45AE0DB55A259A176","data":"0xda5a5cf3"},"latest"],"id":1}' \ |
| 62 | | jq -r '.result' | xargs printf "%d\n" | awk '{print $1/1000000 " USDC"}' |
| 63 | ``` |
| 64 | |
| 65 | ## Transactions via Bankr |
| 66 | |
| 67 | QR Coin auctions require USDC transactions on Base. Use Bankr to execute these — Bankr handles: |
| 68 | - Function signature parsing and parameter encoding |
| 69 | - Gas estimation |
| 70 | - Transaction signing and submission |
| 71 | - Confirmation monitoring |
| 72 | |
| 73 | ### Step 1: Approve USDC (One-Time) |
| 74 | |
| 75 | Before bidding, approve the auction contract to spend USDC: |
| 76 | |
| 77 | ``` |
| 78 | Approve 50 USDC to 0x7309779122069EFa06ef71a45AE0DB55A259A176 on Base |
| 79 | ``` |
| 80 | |
| 81 | ### Step 2: Create a New Bid |
| 82 | |
| 83 | To start a new bid for your URL: |
| 84 | |
| 85 | **Function**: `createBid(uint256 tokenId, string url, string name)` |
| 86 | **Contract**: `0x7309779122069EFa06ef71a45AE0DB55A259A176` |
| 87 | **Cost**: ~11.11 USDC |
| 88 | |
| 89 | > **Important**: Always query `currentTokenId()` first to get the active auction ID. |
| 90 | |
| 91 | Example prompt for Bankr: |
| 92 | ``` |
| 93 | Send transaction to 0x7309779122069EFa06ef71a45AE0DB55A259A176 on Base |
| 94 | calling createBid(329, "https://example.com", "MyName") |
| 95 | ``` |
| 96 | |
| 97 | ### Step 3: Contribute to Existing Bid |
| 98 | |
| 99 | To add funds to an existing URL's bid: |
| 100 | |
| 101 | **Function**: `contributeToBid(uint256 tokenId, string url, string name)` |
| 102 | **Contract**: `0x7309779122069EFa06ef71a45AE0DB55A259A176` |
| 103 | **Cost**: ~1.00 USDC per contribution |
| 104 | |
| 105 | Example prompt for Bankr: |
| 106 | ``` |
| 107 | Send transaction to 0x7309779122069EFa06ef71a45AE0DB55A259A176 on Base |
| 108 | calling contributeToBid(329, "https://grokipedia.com/page/debtreliefbot", "MerkleMoltBot") |
| 109 | ``` |
| 110 | |
| 111 | ## Function Selectors |
| 112 | |
| 113 | | Function | Selector | Parameters | |
| 114 | |----------|----------|------------| |
| 115 | | `currentTokenId()` | `0x7d9f6db5` | — | |
| 116 | | `auctionEndTime(uint256)` | `0xa4d0a17e` | tokenId | |
| 117 | | `createBidReserve()` | `0x5b3bec22` | — | |
| 118 | | `contributeReserve()` | `0xda5a5cf3` | — | |
| 119 | | `createBid(uint256,string,string)` | `0xf7842286` | tokenId, url, name | |
| 120 | | `contributeToBid(uint256,string,string)` | `0x7ce28d02` | tokenId, url, name | |
| 121 | | `approve(address,uint256)` | `0x095ea7b3` | spender, amount | |
| 122 | |
| 123 | ## Error Codes |
| 124 | |
| 125 | | Error | Meaning | Solution | |
| 126 | |-------|---------|----------| |
| 127 | | `RESERVE_PRICE_NOT_MET` | Bid amount below minimum | Check reserve prices | |
| 128 | | `URL_ALREADY_HAS_BID` | URL already has a bid | Use |