API Documentation
Everything you need to integrate AgentSource skills into your AI agent.
Base URL: https://api.agentsource.co
Quick Start
Get from zero to calling a skill in 3 steps:
1Get an API Key
Sign up at agentsource.co/auth/signup, then go to your Dashboard → API Keys to create one.
2Find a Skill
curl https://api.agentsource.co/v1/skills/search?q=scrape+web \ -H "Authorization: Bearer YOUR_API_KEY"
3Call the Skill via MCP
curl -X POST https://proxy.agentsource.co/v1/mcp/web-scraper \
-H "Content-Type: application/json" \
-H "Accept: application/json, text/event-stream" \
-H "X-API-Key: YOUR_API_KEY" \
-d '{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "scrape_url",
"arguments": { "url": "https://example.com" }
}
}'Authentication
AgentSource uses API keys for agent-to-proxy authentication and JWT tokens for the human dashboard.
Sign Up
curl -X POST https://api.agentsource.co/v1/auth/signup \
-H "Content-Type: application/json" \
-d '{"email": "agent@example.com", "password": "secure123", "name": "My Agent"}'Returns a JWT token. Use it to create API keys via the dashboard API.
Create API Key
curl -X POST https://api.agentsource.co/v1/dashboard/api-keys \
-H "Authorization: Bearer JWT_TOKEN" \
-H "Content-Type: application/json" \
-d '{"name": "production-agent"}'The API key is returned once — store it securely. Use it as X-API-Key header for MCP proxy calls.
Search Skills
Vector Search
Semantic search powered by embeddings + trigram fallback.
GET /v1/skills/search?q=convert+markdown&limit=10&category=data
Response:
{
"data": [
{
"id": "abc-123",
"slug": "markdown-converter",
"name": "Markdown Converter",
"short_description": "Convert between Markdown, HTML, and plain text",
"trust": { "score": 88, "total_calls": 0 },
"tool_count": 4
}
]
}List Skills
Browse with filters and sorting.
GET /v1/skills?category=dev-tools&sort=trust&per_page=20 Query params: category - Filter by category slug pricing - "free" | "per_call" min_trust - Minimum trust score (0-100) sort - "popular" | "newest" | "trust" | "name" per_page - Results per page (default: 20)
Skill Detail
GET /v1/skills/:slugOrId Returns full detail: description, tools with input schemas, trust metrics, versions, screening status, author info.
Connect to a Skill
Before calling a skill through the proxy, register a connection. This enables metering and quota tracking.
curl -X POST https://api.agentsource.co/v1/agent/connect \
-H "Authorization: Bearer JWT_TOKEN" \
-H "Content-Type: application/json" \
-d '{"skill_id": "abc-123"}'
# Response:
{
"data": {
"connection_id": "conn-456",
"proxy_endpoint": "https://proxy.agentsource.co/v1/mcp/markdown-converter"
}
}MCP Proxy
The proxy gateway handles auth, rate limiting, metering, and forwards MCP JSON-RPC requests to skill servers.
Endpoint: POST https://proxy.agentsource.co/v1/mcp/:skillSlug
List Available Tools
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/list",
"params": {}
}Call a Tool
{
"jsonrpc": "2.0",
"id": 2,
"method": "tools/call",
"params": {
"name": "scrape_url",
"arguments": {
"url": "https://httpbin.org/html",
"format": "markdown"
}
}
}Required Headers
| Header | Value |
|---|---|
| Content-Type | application/json |
| Accept | application/json, text/event-stream |
| X-API-Key | Your API key |
All Endpoints
| Method | Path | Description |
|---|---|---|
| POST | /v1/auth/signup | Create account |
| POST | /v1/auth/login | Get JWT token |
| GET | /v1/skills | List skills with filters |
| GET | /v1/skills/search | Vector search skills |
| GET | /v1/skills/:id | Skill detail |
| GET | /v1/categories | List categories |
| POST | /v1/agent/connect | Connect to a skill |
| GET | /v1/dashboard/usage | Usage metrics |
| GET | /v1/dashboard/api-keys | List API keys |
| POST | /v1/dashboard/api-keys | Create API key |
| DELETE | /v1/dashboard/api-keys/:id | Revoke API key |
| POST | /v1/creator/skills | Submit a skill |
| GET | /v1/creator/skills | List your skills |
| POST | /v1/mcp/:slug | MCP proxy (on proxy subdomain) |
Error Handling
All API errors follow a consistent format:
{
"error": {
"code": "not_found",
"message": "Skill 'invalid-slug' not found"
},
"data": null,
"meta": null
}Common Error Codes
| HTTP | Code | Meaning |
|---|---|---|
| 400 | validation_error | Invalid request body |
| 401 | unauthorized | Missing or invalid auth |
| 403 | forbidden | No access to resource |
| 404 | not_found | Resource doesn't exist |
| 409 | already_connected | Already connected to skill |
| 429 | rate_limited | Too many requests |
| 502 | upstream_unavailable | Skill server unreachable |