Documentation
106 AI tools, custom agent builder, scheduling, and 15 AI models — all in one API.
Overview
AiPayGen is the most comprehensive AI toolkit for developers and agents. Build custom AI agents, access 106 tools, 1500+ skills, and 4000+ APIs — all through a single API key or MCP connection.
Quick Start
Option 1: API Key (Recommended)
import httpx
BASE = "https://api.aipaygen.com"
# 1. Buy an API key
key = httpx.post(f"{BASE}/credits/buy",
json={"amount_usd": 5.0}).json()["key"] # apk_xxx
# 2. Use it on any endpoint
result = httpx.post(f"{BASE}/research",
json={"topic": "quantum computing"},
headers={"Authorization": f"Bearer {key}"}
).json()
print(result)
Option 2: MCP (Claude / Cursor)
# Install
pip install aipaygen-mcp
# Add to Claude Code
claude mcp add aipaygen -- aipaygen-mcp
# Or connect remotely (no install needed)
# URL: https://mcp.aipaygen.com/mcp
Option 3: Free Preview
# No payment or key needed
curl -X POST https://api.aipaygen.com/preview \
-H "Content-Type: application/json" \
-d '{"topic": "AI agents"}'
Payment Options
| Method | How | Best For |
|---|---|---|
| API Key | POST /credits/buy with Stripe | Most users — simple, prepaid credits |
| x402 USDC | HTTP 402 + X-Payment header | Crypto-native agents, no accounts |
| MCP | pip install aipaygen-mcp | Claude/Cursor — 10 free/day, unlimited with key |
Build Your Own Agent NEW
Create custom AI agents with their own personality, tools, model, memory, and scheduling — all through the API or the visual builder.
# Create a crypto monitoring agent
agent = httpx.post(f"{BASE}/agents/build",
json={
"name": "Crypto Watcher",
"system_prompt": "Monitor crypto prices and alert on big moves",
"tools": ["get_crypto_prices", "analyze", "memory_store"],
"model": "claude-haiku",
"schedule": {"type": "loop", "config": {"minutes": 30}}
},
headers={"Authorization": f"Bearer {key}"}
).json()
agent_id = agent["agent_id"]
# Run the agent
result = httpx.post(f"{BASE}/agents/custom/{agent_id}/run",
json={"task": "Check BTC and ETH prices, analyze trends"},
headers={"Authorization": f"Bearer {key}"}
).json()
Agent Templates
Start from a pre-built template and customize. 10 templates available:
- Research Agent — web search + summarize + scraping
- Crypto Tracker — price monitoring on a 30-min loop
- Content Writer — blog posts, social media, copywriting
- Customer Support — Q&A with sentiment detection
- Social Media Manager — daily posts + platform monitoring
- Code Helper — code generation + testing
- Data Analyst — data analysis + SQL + charts
- News Monitor — hourly news briefings
- Personal Assistant — planning + email + memory
- Sales Bot — lead scoring + outreach
Scheduling & Automation
Agents can run automatically on three trigger types:
Loop (Interval)
httpx.post(f"{BASE}/agents/custom/{agent_id}/schedule",
json={"type": "loop", "config": {"minutes": 30}},
headers={"Authorization": f"Bearer {key}"})
Cron (Schedule)
httpx.post(f"{BASE}/agents/custom/{agent_id}/schedule",
json={"type": "cron", "config": {"hour": 9, "minute": 0, "day_of_week": "mon-fri"}},
headers={"Authorization": f"Bearer {key}"})
Event (Trigger)
httpx.post(f"{BASE}/agents/custom/{agent_id}/schedule",
json={"type": "event", "config": {"trigger": "message"}},
headers={"Authorization": f"Bearer {key}"})
AI Tools
40+ AI-powered endpoints. All accept an optional model parameter.
Plus: /rewrite, /extract, /qa, /compare, /outline, /explain, /proofread, /keywords, /headline, /social, /pitch, /diagram, /json_schema, /workflow, /pipeline, /batch, /chain, /test_cases, /sql, /regex, /mock, /debate, /decide, /plan, /score, /tag, /fact, /questions, /email, /enrich
Data Lookups
Web Scraping
Agent System
Agent Memory
Persistent key-value memory for agents across conversations.
Skills Library
1500+ searchable, executable skills. Create your own or use community skills.
API Catalog
4000+ indexed APIs — search, discover, and invoke third-party APIs through AiPayGen.
MCP Integration
All 106 tools are available as MCP tools. Three ways to connect:
1. PyPI Package (Recommended)
# Install
pip install aipaygen-mcp
# Add to Claude Code
claude mcp add aipaygen -- aipaygen-mcp
# Add to Claude Desktop (claude_desktop_config.json)
{
"mcpServers": {
"aipaygen": {
"command": "aipaygen-mcp",
"env": { "AIPAYGEN_API_KEY": "apk_xxx" }
}
}
}
2. Remote SSE (No Install)
# Connect directly — works in any MCP client
URL: https://mcp.aipaygen.com/mcp
3. MCP Registry
# Listed on registry.modelcontextprotocol.io
# ID: io.github.Damien829/aipaygen
Available Models
| Model | Provider | Best For |
|---|---|---|
| auto | AiPayGen | Automatic — picks best model for the task |
| claude-sonnet | Anthropic | Complex reasoning, analysis |
| claude-haiku | Anthropic | Fast, cheap, good enough for most tasks |
| gpt-4o | OpenAI | General purpose, strong coding |
| gpt-4o-mini | OpenAI | Fast and cheap |
| deepseek-chat | DeepSeek | Coding, technical tasks |
| deepseek-reasoner | DeepSeek | Complex reasoning chains |
| gemini-2.0-flash | Fast, multimodal | |
| grok-3-mini | xAI | Real-time knowledge |
| mistral-small | Mistral | Efficient, multilingual |
| llama-4-scout | Meta | Open-weight, fast |
# Use any model on any endpoint
httpx.post(f"{BASE}/research",
json={"topic": "AI", "model": "deepseek-chat"},
headers={"Authorization": f"Bearer {key}"})
Discovery Endpoints
/discover— machine-readable service catalog (JSON)/.well-known/agent.json— A2A Agent Card/openapi.json— OpenAPI 3.1 spec/llms.txt— LLMs.txt format/builder/templates— Agent templates
Free Endpoints
No payment or API key needed:
Payment Details
- Protocol: x402 (HTTP 402 Payment Required)
- Network: Base Mainnet (eip155:8453)
- Token: USDC (6 decimals)
- Wallet:
0x366D488a48de1B2773F3a21F1A6972715056Cb30 - Bulk discount: 20% when balance >= $2.00