# Pixel Trump — Agent Guide (agent.md)

For AI agents acting for a Binance Agentic Wallet holder. Read this file, then follow the steps exactly. Never change the user's numbers. For any paid step, show the exact cost first and wait for the user's explicit approval.

## Project

- Pixel Trump: 3,333 pixel-art agent NFTs on BSC (chainId 56).
- One identical body and posture on every token; only 5 trait layers change: background, hair/hat, clothes, expression, accessories.
- Tiers: Common 999, Uncommon 888, Rare 666, Epic 555, Legendary 222, Mythic 3 (token IDs 3331 McPy, 3332 Coli-coli, 3333 BFC — reserved for the top-10 referral raffle, never sold in the public mint).
- Website: https://pixeltrump.pages.dev/ — official X: https://x.com/PixelTrumpBSC
- **Mint is LIVE** (opened 2026-11-04). Still check `paused()` before minting: while `paused()` is true, any mint reverts — tell the user instead of sending a doomed transaction.

## Contracts (v2, verified Sourcify exact_match)

- NFT: `0x3054a5530F1852C33bD2749BFAF7155F162A581b` — BscScan: https://bscscan.com/address/0x3054a5530F1852C33bD2749BFAF7155F162A581b — Sourcify: https://repo.sourcify.dev/56/0x3054a5530F1852C33bD2749BFAF7155F162A581b (exact_match, matchId 58235702)
- Market: `0xdd68181966cB59ded902d896C882F0a0d1847fA3` — BscScan: https://bscscan.com/address/0xdd68181966cB59ded902d896C882F0a0d1847fA3 — Sourcify: https://repo.sourcify.dev/56/0xdd68181966cB59ded902d896C882F0a0d1847fA3 (exact_match, matchId 58235715)
- Agent ID registry (SPACE ID): `0x60B9262456dE011F7d15a54CdD8c48bAaa8B022F`

## Eligibility (Agent ID gate, enforced on-chain)

1. The wallet must hold at least 1 Agent ID: call `balanceOf(wallet)` on the registry (`0x70a08231` + wallet padded to 32 bytes). If 0, the wallet cannot mint — stop and tell the user.
2. The user's Agent ID token id is `keccak256(handle without the .ai suffix)` as uint256. You do not need it for minting; the contract checks registry balance only.

## Mint rules

- Max 10 per wallet. Mint #1 per wallet is always FREE (gas only). Mints #2–10 are always PAID, priced by GLOBAL minted count at mint time: 1–1000 → 0.001 BNB, 1001–2000 → 0.002 BNB, 2001–3000 → 0.003 BNB, 3001–3333 → 0.004 BNB.
- A batch that crosses a bracket boundary pays the new bracket price for the later tokens. Referral commission (5% of each PAID mint) is paid to the referrer at mint time; free mint = 0 commission.
- Self-referral is treated as no referrer at all: the mint proceeds, no commission is paid, and the mint is not counted as a referral.
- If a referral payout fails at mint time (a referrer that rejects BNB), the mint does NOT revert: the amount accrues in `referralOwed(referrer)` and the referrer can pull it later with `claimReferral()`.
- Random mint (sequential IDs + pre-shuffled metadata), instant reveal. Metadata: baseURI + tokenId + ".json", e.g. https://pixeltrump.pages.dev/collection/meta/1.json

## Mint call (exact)

- Function: `mint(uint256 qty, address referrer)` payable on the NFT contract.
- `referrer` = the referrer's wallet address, or `0x0000000000000000000000000000000000000000` when there is none.
- Before sending: read `priceFor(wallet, qty)` for the exact total, read `mintedBy(wallet)` and `freeUsed(wallet)` for the wallet's state, and confirm the numbers with the user when any BNB is charged. Value sent must equal `priceFor` exactly.
- After sending: verify the receipt's `Minted` event and `ownerOf(newTokenId)` before reporting success. Report the BscScan tx hash.

## Market (own market, live)

- `list(tokenId, price)` — min price 0.001 BNB (`MIN_PRICE`), fee 10% (seller nets 90%). Listings are non-custodial (NFT stays in the wallet). Before a listing can actually sell, the seller must have approved the market: `setApprovalForAll(market, true)` on the NFT, or a per-token `approve`. `buy(tokenId)` reverts while the market is not approved by the seller.
- `buy(tokenId)` payable with exactly the listed price.
- `placeOffer(tokenId)` payable, min offer 0.001 BNB, only on UNLISTED tokens; funds are escrowed in the market contract until accept / cancel / reject (no expiry). One active offer per (token, buyer).
- `acceptOffer(tokenId, buyer)` — token owner only; same 10% fee split; requires the owner's market approval (see above). `rejectOffer(tokenId, buyer)` refunds the buyer in full. `cancelOffer(tokenId)` lets the buyer reclaim their escrow.
- `unlist(tokenId)` and `updatePrice(tokenId, price)` — seller only; updatePrice enforces the same 0.001 BNB minimum.
- Royalty 10% (EIP-2981) to the project wallet, on top of secondary-market sales where supported.

## Referral + Mythic raffle

- Referral window: now (mint live) → sold out. Score = referral mint count + holder tickets (1 ticket per NFT held at snapshot). Top 10 enter the draw; winners 1 → McPy (#3331), 2 → Coli-coli (#3332), 3 → BFC (#3333). Ties break by earliest first-referral timestamp.
- X tasks (follow, like, RT, quote @PixelTrumpBSC) are verified automatically by the project backend — no manual proof.

## Safety rules

- Never invent a price, token ID, contract address, or date.
- Simulate/preview every call first. If a preview differs from the user's order in any digit, stop and report — never execute a mismatched preview.
- Paid steps always need the user's explicit approval with the exact cost shown first.
