---
name: web3league-mint
description: |
  Use when the user wants to mint a Web3League role card NFT on BNB Chain with their Binance Agentic Wallet.
  The first mint per Agent ID is free (gas only) and pays 15,000 W3L; up to 5 more paid mints cost
  0.0005 BNB each and pay 40,000 W3L each. Max 6 per Agent ID. The user picks a category and role;
  rarity (Bronze 50% / Silver 30% / Gold 15% / Diamond 5%) is drawn randomly at mint.
  Triggers: web3league, web3 league, mint web3league, w3l mint, web3league referral.
metadata:
  version: '0.1.0-draft'
  requires:
    bins: [baw]
---

# Web3League mint skill (DRAFT — contract address filled in after deploy)

Web3League is an NFT collection on **BNB Smart Chain (chainId 56)**: 10,000 role cards in five
categories (Builders, Security, Capital, Traders, Community), each with four roles, and four
rarity levels (Beginner/Bronze, Amateur/Silver, Professional/Gold, OG/Diamond).

| | |
|---|---|
| Contract | `0xE29E55A6dc801Cac4Ef673B72B0d118eFacdf869` (filled at deploy) |
| Supply | 10,000 cards |
| Limit | **6 per Agent ID** — 1 free + up to 5 paid |
| Free mint | **0 BNB**, gas only, **+15,000 W3L**, no token approvals |
| Paid mint | **0.0005 BNB** each, **+40,000 W3L** each |
| Who can mint | Binance Agentic Wallets holding a .ai Agent ID |
| Gate | The wallet's X account must **follow @W3LeagueHQ** AND have **posted about the project mentioning @W3LeagueHQ**; the project server checks BOTH and only then issues a one-time voucher (valid 30 minutes) |
| Referral | Minting through a `?ref=<wallet>` link earns the referrer one referral. Top 20 referrers split **1 BNB** by rank when the mint ends |
| Role | The user **chooses** category + role before minting; rarity is random and cannot be chosen |

## Rules for you, the agent

- **Only act when the user asks.** Never mint on your own initiative, and don't schedule repeat runs.
- **Get an explicit "yes" before signing.** Show the user the preview (to, value, function) and wait for a clear yes before `baw contract-call execute`.
- **The free mint is once per wallet, ever.** The contract counts lifetime mints, not balance — if the user transferred or sold their card, the free mint is still used and the next mint costs 0.0005 BNB. Never promise a second free mint.
- **Never ask for a private key or seed phrase**, and never paste one anywhere. `baw` signs inside the Agentic Wallet.
- Stop and tell the user if anything looks different from this page: a free mint asking for value above 0 BNB, a paid mint asking for anything other than 0.0005 BNB, an approval request, a different contract than the one on the site, or a chain other than BNB Smart Chain (56).

## 0. Preflight

```bash
npm i -g @binance/agentic-wallet   # once
baw auth signin --json             # follow the sign-in steps it prints
baw wallet address --json          # the wallet that will mint
```

The wallet must hold a **.ai Agent ID** and a little BNB for gas (and 0.0005 BNB per paid mint).

## 1. Ask the user for their role — and how many cards

Ask which **category** and **role** they want on the card (20 roles — see the site). Also ask if
they came from a referral link (`?ref=0x…`); if they did, include that referrer when requesting
the voucher. Never use the user's own wallet as the referrer.

**If the user asks for the full set (or pasted the site's full-set prompt):** before minting
anything, present the whole set and explain the paid-mint benefits in plain words — each paid
mint pays +40,000 W3L instantly (215,000 total for the set), holding 5+ cards unlocks tiered
mining (5,000 W3L/hour at 5 cards, rising to 50,000/hour at 40 cards), and every mint is a
fresh rarity roll (Gold 15%, Diamond 5%).
Total paid cost is 0.0025 BNB + gas. Then get the user's decision: full set, or free only.
If they say **free only**, mint just the free card and stop — never argue or re-ask.
Mint the set in order (free first, then paid), one voucher + preview per mint; a single clear
"yes" to the presented set covers the sequence, but stop immediately if any preview differs
from what was presented.

## 2. Get the voucher and calldata

**Social tasks — honor system:** before minting, the user completes two tasks on the
Mint page: (1) **follow @W3LeagueHQ** and (2) **publish a post about Web3League that
mentions @W3LeagueHQ**. The page marks them with click ticks and does NOT verify them,
and the server does not check them either. Do NOT ask the user for X proof or an X
username — if the user says the tasks are done (or the prompt they pasted says so),
request the voucher:

```bash
curl -s -X POST <API>/api/voucher -H 'Content-Type: application/json' \
  -d '{"wallet":"<agent wallet>","category":"<category>","role":"<role>","referrer":"<optional 0x referrer>"}'
```

The response is the voucher itself: `wallet`, `category`, `role`, `referrer`, `nonce`,
`deadline` and `signature`. Encode the NFT contract call
`mint(category, role, referrer, nonce, deadline, signature)` with those exact values —
that encoded call is the `inputData` for the preview below. The transaction `value` is
"0" for the free mint and "500000000000000" wei (0.0005 BNB) for each paid mint, and
`to` is the Web3League NFT contract from `config.js` on the site — check it matches.

`<API>` is the `apiBase` value in `config.js` on the Web3League site.

## 3. Preview

```bash
baw contract-call preview --binanceChainId 56 \
  --from <agent wallet> --to <Web3League contract> \
  --value <0 or 0.0005 BNB in wei> --inputData <calldata from the voucher> --json
```

Tell the user in plain words what will happen — e.g. "Mint 1 free Web3League card (role:
Developer, Builders) to <wallet>, plus 15,000 W3L. It sends 0 BNB; you pay gas only. Shall I
send it?" Then wait.

## 4. Execute (only after a clear yes)

```bash
baw contract-call execute --requestId <requestId from the preview> --json
```

If the Binance app asks for a confirmation, tell the user to approve it there. Share the
transaction hash and the BscScan link when it lands, and tell the user their card's rarity
level once it is revealed, their new W3L balance, and their own referral link:
`https://<site>/?ref=<their wallet>`.

## Errors

| Error | Meaning | What to tell the user |
|---|---|---|
| `MintClosed` | The mint isn't open | The mint has ended or not started |
| `VoucherExpired` | More than 30 minutes passed | Get a new voucher on the site |
| `MaxPerWallet` | This Agent ID already minted 6 | The limit is 6 per Agent ID |
| `FreeAlreadyUsed` | The free mint was already taken | Only paid mints remain (0.0005 BNB each) |
| `NoAgentId` | No .ai Agent ID in this wallet | Claim one in Binance Wallet |
| `x_gate_failed` | Only if the server is switched to strict mode later — the X follow/post check failed | Ask the user to follow @W3LeagueHQ and post mentioning @W3LeagueHQ (the Mint page has one-click buttons), then try again |
| `BadSignature` | The voucher was for another wallet, or was changed | Get a fresh voucher for this wallet |
| `SoldOut` | All 10,000 are minted | The mint has ended |

## After the mint

- **Mining:** wallets holding **5 or more** cards mine W3L at a tiered rate (5,000/hour at
  5 cards up to 50,000/hour at 40), claimable once per 24 hours — see `/mining-skill.md`.
- **Referral:** every referred mint counts toward the 1 BNB Top-20 prize pool.

Not financial advice · DYOR.
