---
name: sky-lantern
description: |
  Use when the user wants to take part in SKY LANTERN · 天灯 on BNB Chain: buy mint shares on the 48-hour price ladder
  (12,000 shares in 6 tiers, 0.0005 → 0.001 BNB per share, 50,000 LANTERN each, 1–10 per agent), launch the
  PancakeSwap pool, claim LANTERN, or burn LANTERN to light on-chain pixel lantern NFTs. Only AI agents with a
  .ai Agent ID can mint. Triggers: sky lantern, 天灯, LANTERN mint, price ladder, light a lantern, my lanterns.
metadata:
  version: '0.2.0'
  requires:
    bins: [baw, curl]
  install:
    - kind: node
      package: '@binance/agentic-wallet'
      bins: [baw]
      label: Binance Agentic Wallet CLI
---

# SKY LANTERN · 天灯 skill

LANTERN is a BEP-20 token on BNB Chain with a **48-hour price-ladder mint for AI agents** (Binance Agentic Wallets
holding a **.ai Agent ID**), and **Sky Lanterns**: pixel-lantern NFTs lit by **burning LANTERN**.

| | |
|---|---|
| Shares | 12,000 × **50,000 LANTERN**, in **6 tiers of 2,000** |
| Ladder | tier 1 **0.0005** · 0.0006 · 0.0007 · 0.0008 · 0.0009 · tier 6 **0.001 BNB** per share |
| Per agent | **1–10 shares**; a purchase that crosses a tier pays each share at its own tier's price |
| Launch | at a sell-out, or after 48 h with **however many** shares sold. No soft cap, **no refunds** |
| Pool | 80% of the BNB + LANTERN **at the last share's price** → PancakeSwap, **LP tokens burned**; 20% → treasury |
| Tax | **none**: LANTERN is a plain token |
| Lanterns | burn to light: 6 floors × 400 = **2,400 max**; 25k · 50k · 75k · 100k · 150k · 200k LANTERN per lantern |

## Contracts (BNB Chain, chain id 56, verified on Sourcify)

| | Address |
|---|---|
| LanternMint | `0x3AEBc36B3caf8744B6d476131Db801fbc6D3957e` |
| LANTERN token | `0x60eD741dBD6f84d72Be3C8ea18ADC74FCC935E88` |
| Lanterns (NFT) | `0xFf5A0C336b47e3c7b2F9E19d15DAc30DAf700D45` |

No extra CLI is needed. You read the chain with a plain JSON-RPC `eth_call`, and every transaction is previewed and
signed by the user's Binance Agentic Wallet through `baw`. **Never ask the user for a private key or seed phrase.**

Rules for you, the agent:
- Only act when the user asks. Never buy, sell or burn on your own initiative, and don't schedule recurring runs.
- **Every** `requestId` needs the user's explicit "yes" before `baw contract-call execute`. Tell them what it does
  and the exact BNB / LANTERN amount.
- LANTERN is a speculative token and lanterns are collectibles. Never promise profit, a price or a return. A cheaper
  tier is not a guarantee of anything; there are no refunds. Lighting a lantern **burns LANTERN forever**.
- Mention that the contracts are unaudited.

## 0. Preflight
```bash
npm i -g @binance/agentic-wallet
baw auth signin
baw wallet status --json
baw wallet address --json        # use the address with binanceChainId 56 as $ME
```
The wallet needs a **.ai Agent ID** (claim one in Binance Wallet) and a little BNB for the shares + gas.

## 1. Reading the chain
```bash
RPC=https://bsc-rpc.publicnode.com
call() { curl -s $RPC -H 'content-type: application/json' \
  -d "{\"jsonrpc\":\"2.0\",\"id\":1,\"method\":\"eth_call\",\"params\":[{\"to\":\"$1\",\"data\":\"$2\"},\"latest\"]}"; }
MINT=0x3AEBc36B3caf8744B6d476131Db801fbc6D3957e
```
| Read | data | Returns |
|---|---|---|
| `state()` | `0xc19d93fb` | phase (0 not started · 1 minting · 2 ready to launch · 3 launched · 4 ended, nothing sold), startAt, endAt, soldOutAt, sold, tier, nextPrice (wei), raised, buyers, pair, token |
| `quote(n)` | `0xed1bd76c` + n as a 32-byte hex word | exact cost in wei for n shares right now |
| `agentInfo(addr)` | `0x62c885ee` + address left-padded to 32 bytes | isAgent, handle, shares, paid, claimed, room, claimable |

Each return value is a 32-byte word (hex, in order). Example: quote 3 shares
`call $MINT 0xed1bd76c0000000000000000000000000000000000000000000000000000000000000003`.
Tell the user the phase, the current tier and price, and how many shares they can still buy (`room`) before buying.

## 2. Buy shares (phase 1, 48 hours)
Calldata for `buy(n)` = `0xd96a094a` + n as a 32-byte word. Value = `quote(n)` in wei.
```bash
# e.g. 3 shares on tier 1 = 0.0015 BNB → 150,000 LANTERN after launch
baw contract-call preview --binanceChainId 56 --from $ME --to $MINT \
  --value 1500000000000000 \
  --inputData 0xd96a094a0000000000000000000000000000000000000000000000000000000000000003 --json
# → requestId. Ask the user; only after a clear yes:
baw contract-call execute --requestId <id> --json
```
If another agent moves the ladder up a tier first, the transaction fails with `TooLittle`. Quote and preview again.
Overpayment is refunded automatically.

## 3. Launch and claim
- phase **2** (ready to launch): anyone can send `launch()`: `--inputData 0x01339c21 --value 0` (≈ 2,800,000 gas).
- phase **3** (launched): `claim()`: `--inputData 0x4e71d92d --value 0` → 50,000 LANTERN per share.
- phase **4**: nothing to do (no BNB was paid in).

Both use `baw contract-call preview ... --to $MINT`, then `execute` after the user's yes.

## 4. Trading (after launch)
LANTERN trades on PancakeSwap V2 (router `0x10ED43C718714eb63d5aA57B78B54704E256024E`) with no tax. Use the
user's usual swap flow in Binance Wallet.

## 5. Light lanterns (burn LANTERN)
LANTERNS = `0xFf5A0C336b47e3c7b2F9E19d15DAc30DAf700D45`, TOKEN = `0x60eD741dBD6f84d72Be3C8ea18ADC74FCC935E88`.
1. Cost: `call $LANTERNS 0xed1bd76c<count as 32-byte word>` → LANTERN (wei) to burn.
2. Step 1 of 2, approve: to TOKEN, data `0x095ea7b3` + LANTERNS padded to 32 bytes + cost as a 32-byte word.
3. Step 2 of 2, light: to LANTERNS, data `0x3e365b72` + count (1–10) as a 32-byte word, value 0.

Each step is a `baw contract-call preview` and then `execute` after the user's yes. The floor sets the shape:
round (1–2), palace 宫灯 (3–4), sky lantern 孔明灯 (5–6); silver frame from floor 4, gold on 6. Colours come from a
seed. Lanterns are plain ERC-721s; `tokenURI` holds the on-chain picture.

## 6. Notes
Requests expire in about 5 minutes. If the Binance App asks for a confirmation, follow baw's `next` hint. Website:
https://skylantern.online
