Overview
The TheBiggestBrain API lets you integrate all 9 AI tools — chat, image generation, documents, research, slides, podcasts, spreadsheets, fact-checking, and code — directly into your own applications.
All requests and responses use JSON. The API is RESTful and follows standard HTTP conventions.
Authentication
All API requests require a Bearer token in the Authorization header. Get your API key from My Account → API Keys in the app.
Authorization: Bearer tbb_sk_live_xxxxxxxxxxxxxxxxxxxxxxxx
POST /chat
Send a message and receive an AI response. Supports multi-turn conversation history.
Request Body
| Parameter | Type | Required | Description |
|---|---|---|---|
| message | string | required | The user's message |
| history | array | optional | Prior conversation turns [{role, content}] |
| system | string | optional | Custom system prompt override |
| max_tokens | integer | optional | Max tokens in response (default: 1500) |
curl -X POST https://api.thebiggestbrain.com/v1/chat \ -H "Authorization: Bearer tbb_sk_live_xxx" \ -H "Content-Type: application/json" \ -d '{ "message": "Explain quantum computing in simple terms", "max_tokens": 800 }'
{
"id": "chat_abc123",
"content": "Quantum computing uses quantum bits (qubits)...",
"tokens_used": 312,
"model": "claude-sonnet-4-20250514",
"created_at": "2025-01-15T10:23:44Z"
}
POST /generate-image
Generate images using DALL-E 3 with optional AI prompt enhancement.
| Parameter | Type | Required | Description |
|---|---|---|---|
| prompt | string | required | Image description |
| style | string | optional | photorealistic | illustration | logo | 3d | watercolor | minimalist | anime | pixel |
| size | string | optional | 1024x1024 | 1792x1024 | 1024x1792 (default: 1024x1024) |
| quality | string | optional | standard | hd (default: standard) |
| enhance_prompt | boolean | optional | Auto-enhance prompt with Claude (default: true) |
| n | integer | optional | Number of images 1–4 (default: 1) |
{
"images": [
{
"url": "https://oaidalleapiprodscus.blob.core.windows.net/...",
"enhanced_prompt": "A photorealistic minimalist logo for...",
"revised_prompt": "DALL-E revised prompt..."
}
],
"credits_used": 1
}POST /docs/generate
Generate a complete document — article, report, proposal, email, or bio.
| Parameter | Type | Required | Description |
|---|---|---|---|
| prompt | string | required | Document topic and instructions |
| type | string | optional | article | report | proposal | email | bio | outline |
| tone | string | optional | professional | casual | persuasive | academic |
| length | string | optional | short | medium | long |
| format | string | optional | html | markdown | plain (default: html) |
GET /projects
List all saved projects for the authenticated user.
| Query Param | Type | Description |
|---|---|---|
| tool | string | Filter by tool (chat, docs, designer, etc.) |
| limit | integer | Max results (default: 50, max: 200) |
| offset | integer | Pagination offset |
curl https://api.thebiggestbrain.com/v1/projects?tool=docs&limit=10 \ -H "Authorization: Bearer tbb_sk_live_xxx"
Webhooks
TheBiggestBrain sends real-time webhook events to your endpoint for key platform events.
Events
| Event | Description |
|---|---|
| user.signup | New user registered |
| subscription.created | User upgraded to Pro or Business |
| subscription.cancelled | User cancelled their subscription |
| project.created | New project saved |
| affiliate.conversion | A referred user converted to Pro |
// Example webhook payload { "event": "subscription.created", "data": { "user_id": "usr_abc123", "plan": "pro", "amount": 19.00, "currency": "usd" }, "created_at": "2025-01-15T10:23:44Z" }
White-Label Guide
Resell TheBiggestBrain under your own brand. White-label is available on the Business plan. Your customers see your brand, your domain, your pricing — powered by our infrastructure.
What you can customize
- ✓ App name, logo, favicon
- ✓ Color palette and typography
- ✓ Custom domain (app.yourbrand.com)
- ✓ Your own Stripe account (keep 100% of revenue)
- ✓ Hide or rename any tools
- ✓ Custom system prompts per tool
- ✓ Remove all TheBiggestBrain branding
White-Label Config
Add a whitelabel.config.js file to your deployment:
// whitelabel.config.js const WL = { // Brand identity appName: "BrainPower AI", appTagline: "Your team's AI platform", logoUrl: "/assets/logo.svg", faviconUrl: "/assets/favicon.ico", domain: "app.brainpowerai.com", // Colors (CSS variable overrides) colors: { primary: "#3b82f6", // replaces --gold accent: "#8b5cf6", // replaces --cyan background: "#0f0f1a", surface: "#1a1a2e", }, // Tools — hide any you don't want tools: { chat: { enabled: true, label: "AI Assistant" }, designer: { enabled: true, label: "Image Studio" }, docs: { enabled: true, label: "Doc Writer" }, slides: { enabled: true, label: "Slide Builder" }, pods: { enabled: false, label: "AI Pods" }, research: { enabled: true, label: "Research" }, code: { enabled: true, label: "Code Helper" }, sheets: { enabled: true, label: "Spreadsheets" }, fact: { enabled: false, label: "Fact Check" }, }, // Custom prompts per tool systemPrompts: { chat: "You are a helpful assistant for BrainPower AI users. Be professional and concise.", docs: "You write in our company's voice: bold, clear, and action-oriented.", }, // Your Stripe keys (Business plan only) stripe: { publishableKey: "pk_live_your_key", priceIdPro: "price_your_pro_price", priceIdBiz: "price_your_biz_price", }, // Remove TBB branding hidePoweredBy: true, hideAffiliateTab: false, }; export default WL;