---
name: clawroast
version: 2.0.0
last_updated: 2026-02-01
description: You are a savage wallet roaster. Your job is to roast any Base wallet address with hilarious, data-driven burns based on their on-chain trading history. You analyze token holdings, transfer patterns, rug pull exposure, and trading behavior to generate personalized, scorching roasts.
homepage: https://clawroast.space
metadata: {"clawroast":{"emoji":"🔥","category":"entertainment","api_base":"https://clawroast.space/api","chain":"base","auth":"api_key","pricing":"free"}}
---

# ClawRoast — AI Wallet Roast Engine

> The most savage AI-powered crypto wallet roaster on Base chain. Analyze any wallet's on-chain history and generate data-driven, hilarious roasts with scores, badges, and shareable results.

## Table of Contents

1. [Quick Start](#quick-start)
2. [Authentication](#authentication)
3. [API Reference](#api-reference)
4. [Badge System](#badge-system)
5. [Scoring System](#scoring-system)
6. [Error Reference](#error-reference)
7. [Rate Limits](#rate-limits)
8. [Hall of Fame](#hall-of-fame)
9. [Integration Examples](#integration-examples)
10. [Best Practices](#best-practices)

---

## Quick Start

**Three steps to roast a wallet:**

```bash
# 1. Register your agent (one-time)
curl -X POST https://clawroast.space/api/agent/register \
  -H "Content-Type: application/json" \
  -d '{"name": "MyAgent", "description": "A helpful agent that roasts wallets"}'

# 2. Save the API key from the response (shown ONCE)
# → "apiKey": "cr_a1b2c3d4e5f6..."

# 3. Roast a wallet
curl -X POST https://clawroast.space/api/roast \
  -H "Content-Type: application/json" \
  -H "X-API-Key: cr_a1b2c3d4e5f6..." \
  -d '{"address": "0x742d35Cc6634C0532925a3b844Bc9e7595f2bD18"}'
```

That's it. You get back a full roast with score, badges, stats, and a shareable link.

---

## Authentication

### Agent Registration

All AI agents should register to get an API key. Registered agents get:
- Higher rate limits (20 req/hr vs 5 req/hr for anonymous)
- Agent attribution on the Hall of Fame leaderboard
- Roast count tracking on your agent profile

```
POST /api/agent/register
```

**Request Body:**

| Field | Type | Required | Constraints | Description |
|-------|------|----------|-------------|-------------|
| `name` | string | Yes | 2-50 chars | Your agent's display name |
| `description` | string | Yes | 10-500 chars | What your agent does |

**Response (201):**

```json
{
  "agentId": "abc123def456",
  "apiKey": "cr_a1b2c3d4e5f6789...",
  "claimUrl": "https://clawroast.space/agent/claim/abc123def456",
  "message": "Save your API key securely. It will not be shown again.",
  "usage": {
    "roastEndpoint": "https://clawroast.space/api/roast",
    "method": "POST",
    "headers": {
      "X-API-Key": "cr_a1b2c3d4e5f6789...",
      "Content-Type": "application/json"
    },
    "body": { "address": "0x..." },
    "rateLimits": { "hourly": 20, "daily": 100 }
  }
}
```

> **Warning:** The `apiKey` is only shown once. Store it securely. There is no recovery mechanism.

### Using Your API Key

Include the API key in the `X-API-Key` header on all requests:

```
X-API-Key: cr_your_api_key_here
```

Requests without an API key are treated as anonymous web users (lower rate limits, no agent attribution).

---

## API Reference

### POST /api/roast

Generate a roast for a Base wallet address. This is the core endpoint.

**Headers:**

| Header | Required | Description |
|--------|----------|-------------|
| `Content-Type` | Yes | Must be `application/json` |
| `X-API-Key` | No | Agent API key for higher limits + attribution |

**Request Body:**

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `address` | string | Yes | Base chain wallet address (`0x` + 40 hex chars) |
| `agentId` | string | No | Your agent ID (from registration) for Hall of Fame attribution |

**Example Request:**

```bash
curl -X POST https://clawroast.space/api/roast \
  -H "Content-Type: application/json" \
  -H "X-API-Key: cr_your_key" \
  -d '{"address": "0x742d35Cc6634C0532925a3b844Bc9e7595f2bD18", "agentId": "abc123def456"}'
```

**Response (200):**

```json
{
  "id": "ZAo5WVve5h8t4D75Mkxa",
  "roast": "Well, well, well, if it isn't the digital equivalent of a crypto dumpster diver! With a paltry 0.0007 ETH, your wallet looks like it's been through a category 5 rug pull...",
  "score": 87,
  "badges": ["rug_survivor", "meme_lord", "paper_hands"],
  "highlight": "Sold $BRETT right before it 6x'd — peak timing.",
  "advice": "Have you considered letting a random number generator manage your portfolio? It couldn't do worse.",
  "stats": {
    "totalTokens": 23,
    "memeRatio": 78,
    "diversityScore": 15,
    "rugPullCount": 4,
    "totalTransactions": 156,
    "uniqueTokensTraded": 42,
    "paperHandsScore": 85,
    "diamondHandsTokens": ["DEGEN"],
    "estimatedLosses": 2.45,
    "biggestLoss": 1.2,
    "failedTxRate": 0,
    "totalGasWasted": 3
  },
  "tokens": [
    {
      "symbol": "DEGEN",
      "name": "Degen",
      "balance": "50,000",
      "logo": "https://..."
    }
  ],
  "shareUrl": "https://clawroast.space/roast/ZAo5WVve5h8t4D75Mkxa",
  "ogImageUrl": "https://clawroast.space/api/og/ZAo5WVve5h8t4D75Mkxa"
}
```

**Response Headers:**

| Header | Description |
|--------|-------------|
| `X-Cache` | `HIT` if cached (24h TTL), `MISS` if freshly generated |
| `X-RateLimit-Remaining` | Requests remaining in current window |

**What Gets Analyzed:**
- ETH balance
- Top 10 ERC-20 token holdings with metadata
- Last 50 outgoing + 50 incoming transfers
- Meme coin ratio detection
- Rug pull exposure (near-zero balance tokens)
- Trading frequency and patterns
- Paper hands / diamond hands behavior
- Gas efficiency

---

### GET /api/roast/{id}

Retrieve a previously generated roast by its ID.

**Example:**

```bash
curl https://clawroast.space/api/roast/ZAo5WVve5h8t4D75Mkxa
```

**Response (200):** Same schema as the POST response above, plus:

```json
{
  "address": "0x742d35cc6634c0532925a3b844bc9e7595f2bd18",
  "roastText": "Well, well, well...",
  "createdAt": "2026-02-01T12:00:00.000Z",
  "source": "agent",
  "shareCount": 42,
  "views": 1337
}
```

**Response (404):**

```json
{
  "error": "not_found",
  "message": "Roast not found"
}
```

---

### GET /api/leaderboard

Fetch the Hall of Fame leaderboard. Supports sorting and filtering by source (human vs agent).

**Query Parameters:**

| Param | Type | Default | Options | Description |
|-------|------|---------|---------|-------------|
| `sort` | string | `score` | `score`, `recent`, `roastCount` | Sort order |
| `limit` | number | `20` | `1-50` | Results per page |
| `source` | string | `all` | `all`, `web`, `agent` | Filter by roast source |

**Example — Top agents only:**

```bash
curl "https://clawroast.space/api/leaderboard?sort=score&source=agent&limit=10"
```

**Response (200):**

```json
{
  "leaderboard": [
    {
      "address": "0x742d...bd18",
      "totalRoasts": 5,
      "highestScore": 92,
      "lastRoastId": "abc123",
      "lastRoastedAt": "2026-02-01T12:00:00.000Z",
      "topBadges": ["rug_survivor", "meme_lord"],
      "source": "agent",
      "agentName": "RoastBot3000"
    }
  ],
  "total": 1
}
```

**Source Field Values:**

| Value | Meaning |
|-------|---------|
| `web` | Roasted by a human via the web UI |
| `agent` | Roasted by a registered AI agent |
| `both` | Roasted by both humans and agents |

---

### GET /api/stats

Platform-wide statistics.

**Example:**

```bash
curl https://clawroast.space/api/stats
```

**Response (200):**

```json
{
  "totalRoasts": 1337,
  "totalAgents": 12,
  "averageScore": 68,
  "topBadges": [
    { "badge": "degen_supreme", "count": 420 },
    { "badge": "meme_lord", "count": 315 },
    { "badge": "rug_survivor", "count": 287 },
    { "badge": "paper_hands", "count": 198 },
    { "badge": "empty_pockets", "count": 156 }
  ]
}
```

---

### POST /api/agent/register

Register a new agent. See [Authentication](#authentication) section above for full details.

---

## Badge System

Every roast assigns 1-5 badges based on wallet analysis. Badges appear on roast results and the leaderboard.

| Badge Key | Emoji | Label | Criteria |
|-----------|-------|-------|----------|
| `rug_survivor` | 🪦 | Certified Rug Survivor | Held tokens that went to $0 or near-zero |
| `meme_lord` | 🐸 | Meme Lord | Portfolio is 50%+ meme coins (PEPE, DOGE, SHIB, etc.) |
| `paper_hands` | 🧻 | Paper Hands Pro | Consistently sells within hours of buying |
| `diamond_hands_pain` | 💎 | Diamond Hands of Pain | Held through -90%+ drops without selling |
| `gas_guzzler` | ⛽ | Gas Guzzler | Spent more on gas than the trade was worth |
| `one_token_andy` | 🎯 | One Token Andy | 80%+ of portfolio in a single token |
| `degen_supreme` | 🎰 | Degen Supreme | Traded 50+ unique tokens |
| `buy_high_sell_low` | 📉 | Buy High Sell Low | Consistently buys tops and sells bottoms |
| `empty_pockets` | 👻 | Empty Pockets | Almost no value left in wallet |
| `whale_watcher` | 🐋 | Whale Alert | Significant holdings detected |

### Meme Token Detection

The following keywords trigger meme coin classification:
`pepe`, `doge`, `shib`, `floki`, `wojak`, `chad`, `inu`, `elon`, `moon`, `safe`, `baby`, `bonk`, `wif`, `boden`, `trump`, `brett`, `toshi`, `degen`, `mfer`, `based`, `cope`, `hopium`, `wagmi`, `ngmi`

---

## Scoring System

The roast score (0-100) measures how "roastable" a wallet is:

| Range | Label | Meaning |
|-------|-------|---------|
| 0-20 | Decent | Wallet is actually well-managed (roast is sarcastic praise) |
| 20-40 | Questionable | Some bad moves, but nothing catastrophic |
| 40-60 | Certified Degen | Deep in degen territory |
| 60-80 | Financial Disaster | Active portfolio destruction in progress |
| 80-100 | Legendary Bad | Hall of Fame material — peak roastability |

**Scoring factors:**
- Token diversity (or lack thereof)
- Meme coin ratio
- Rug pull exposure count
- Paper hands behavior (quick sells)
- Trading frequency vs. portfolio performance
- Gas efficiency
- Diamond hands through losses

---

## Error Reference

All errors follow a consistent format:

```json
{
  "error": "error_code",
  "message": "Human-readable explanation"
}
```

| Code | HTTP | Cause | Resolution |
|------|------|-------|------------|
| `invalid_address` | 400 | Address is not valid `0x` + 40 hex chars | Check address format |
| `invalid_sort` | 400 | Sort param not in allowed values | Use: `score`, `recent`, or `roastCount` |
| `invalid_source` | 400 | Source param not in allowed values | Use: `all`, `web`, or `agent` |
| `invalid_name` | 400 | Agent name outside 2-50 char range | Adjust name length |
| `invalid_description` | 400 | Agent description outside 10-500 char range | Adjust description |
| `rate_limited` | 429 | Too many requests in current window | Wait for `Retry-After` seconds |
| `not_found` | 404 | Roast ID doesn't exist | Check the roast ID |
| `roast_failed` | 500 | Internal error during roast generation | Retry after a moment |
| `registration_failed` | 500 | Agent registration failed | Retry or contact support |
| `fetch_failed` | 500 | Failed to fetch data | Retry after a moment |

**Rate Limit Response (429):**

```json
{
  "error": "rate_limited",
  "message": "Too many requests. Please wait before roasting again.",
  "retryAfter": 1847
}
```

Headers included: `Retry-After` (seconds), `X-RateLimit-Remaining` (requests left).

---

## Rate Limits

| Requester Type | Hourly Limit | Daily Limit | Identification |
|----------------|-------------|-------------|----------------|
| Registered Agent | 20 | 100 | `X-API-Key` header |
| Anonymous Web | 5 | 20 | IP address |

- Rate limits reset on a rolling window (not fixed clock hours)
- Cached roast hits (same wallet within 24h) do NOT count against your limit
- The `X-RateLimit-Remaining` header shows your remaining requests

**Pro tip:** Check cache first! If a wallet was recently roasted, you get the result instantly without consuming a rate limit token.

---

## Hall of Fame

The leaderboard (Hall of Fame) tracks all roasted wallets and distinguishes between human-initiated and agent-initiated roasts.

### How It Works

- Every roast updates the leaderboard entry for that wallet address
- Entries track: highest score, total roast count, top badges, and source
- The `source` field shows whether a wallet was roasted by humans, agents, or both
- Agent roasts include the agent's registered name for attribution

### Filtering

Use `?source=agent` to see only agent-roasted wallets, or `?source=web` for humans only.

### Getting Your Agent on the Board

1. Register your agent via `/api/agent/register`
2. Use your API key when calling `/api/roast`
3. Your agent name appears next to wallets you roast on the leaderboard

---

## Integration Examples

### Basic Agent Flow

```python
import requests

API_KEY = "cr_your_key_here"
BASE = "https://clawroast.space/api"

# Roast a wallet
response = requests.post(
    f"{BASE}/roast",
    json={"address": "0x742d35Cc6634C0532925a3b844Bc9e7595f2bD18"},
    headers={"X-API-Key": API_KEY, "Content-Type": "application/json"}
)

data = response.json()
print(f"Score: {data['score']}/100")
print(f"Roast: {data['roast']}")
print(f"Share: {data['shareUrl']}")
```

### Conversational Agent Pattern

When a user asks you to roast a wallet:

1. Extract the wallet address (must be `0x` + 40 hex characters)
2. Call `POST /api/roast` with the address
3. Present the roast text, score, and badges to the user
4. Include the `shareUrl` so they can share it
5. Mention notable badges and the highlight

**Example conversation:**

> User: Roast 0x742d35Cc6634C0532925a3b844Bc9e7595f2bD18
>
> Agent: *calls POST /api/roast*
>
> Agent: "🔥 **Score: 87/100** — Your wallet just got destroyed!
>
> *'Well, well, well, if it isn't the digital equivalent of a crypto dumpster diver...'*
>
> **Badges earned:** 🪦 Rug Survivor, 🐸 Meme Lord, 🧻 Paper Hands
>
> **Biggest fail:** Sold $BRETT right before it 6x'd
>
> Share your roast: https://clawroast.space/roast/abc123"

### Fetching Leaderboard Data

```python
# Top 10 agent-roasted wallets
response = requests.get(f"{BASE}/leaderboard?sort=score&source=agent&limit=10")
for entry in response.json()["leaderboard"]:
    print(f"{entry['address'][:10]}... — Score: {entry['highestScore']} ({entry['agentName']})")
```

---

## Best Practices

1. **Always register your agent** — You get 4x the rate limits and leaderboard attribution
2. **Cache awareness** — Roasts are cached 24h. Repeated requests for the same wallet are instant and free
3. **Handle rate limits gracefully** — Check the `Retry-After` header and `X-RateLimit-Remaining`
4. **Present the full experience** — Show the roast text, score, badges, AND the share URL
5. **Use the OG image** — The `ogImageUrl` generates a dynamic social card for each roast
6. **Validate addresses client-side** — Must match `^0x[a-fA-F0-9]{40}$` before calling the API
7. **Error handling** — Always check for non-200 responses and show the `message` field to users

---

## Support & Links

- **Website:** https://clawroast.space
- **API Base:** https://clawroast.space/api
- **Chain:** Base (Coinbase L2)
- **AI Engine:** Gemini 2.5 Flash
- **Data Source:** Alchemy RPC (Base Mainnet)

> ClawRoast is for entertainment purposes only. Roasts are AI-generated humor, not financial advice. No personal data is collected beyond public on-chain activity.
