SkillDB API & Integration Guide
Everything you need to integrate agent skills into your workflow. Designed for agents first, developers always.
Quick Setup
The fastest way to get started is with the CLI. Search for skills, get exactly the one you need, and your agent reads it instantly.
# Install and initialize
npm install -g skilldb
skilldb init
# Search for the skill you need
skilldb search react hooks
# Get exactly the skill you need
skilldb get react-patterns-skills/custom-hooks
# Your agent reads it from .skilldb/skills/ — zero latencyYou can also reference the library directly in your project's CLAUDE.md file.
# CLAUDE.md
## Skills
This project uses SkillDB skills cached in .skilldb/skills/.
Read skill files from that directory before starting tasks.
To add more skills: skilldb search <query> && skilldb get <pack>/<skill>
Full index: https://skilldb.dev/api/v1/skillsHow Agents Discover Skills
Agents discover SkillDB skills through a simple chain:
- Agent reads
CLAUDE.md(or equivalent config) at session start. - Config points to the
/api/v1/skillsAPI -- the index of all skills, packs, and categories. - Agent selects a relevant skill by name or category and fetches its markdown file.
- Agent applies the skill's instructions as behavioral guidance for the current task.
File Structure
skilldb/
skills-data.json # Full index (categories, packs, skill metadata)
packs/
author-styles/
hemingway.md # Individual skill file
orwell.md
software-skills/
react-architect.md
api-design.md
...
web/ # This Next.js app
src/app/
api/skills/route.ts # REST API
api/stats/route.tsAPI Reference
/api/v1/skillsReturns the full list of skills. Supports filtering by category, pack, and free-text search.
Query Parameters
categorystringFilter by category name, e.g. "Writing & Literature"packstringFilter by pack slug, e.g. "author-styles"searchstringFree-text search across skill name, title, and descriptionsortstringSort results: name, -name (desc), lines, -lines, pack, -pack, category, -categoryidsstringComma-separated skill IDs for batch retrieval (max 50). Example: ?ids=software-skills/code-review.md,devops-skills/docker.mdRequest
curl https://skilldb.dev/api/v1/skills?category=WritingResponse
{
"skills": [
{
"pack": "author-styles",
"name": "hemingway",
"title": "Ernest Hemingway",
"category": "Writing & Literature"
}
],
"total": 67,
"categories": ["Writing & Literature", ...],
"packs": ["author-styles", "poet-styles", ...]
}/api/v1/skills/:idReturns a single skill by its pack and name. The :id parameter is formatted as pack/skill-name.
Request
curl https://skilldb.dev/api/v1/skills/author-styles/hemingwayResponse
{
"pack": "author-styles",
"name": "hemingway",
"title": "Ernest Hemingway",
"category": "Writing & Literature",
"content": "---\ntitle: Ernest Hemingway\n---\n\n# Hemingway Style Guide\n..."
}/api/v1/skills/suggestReturns search autocomplete suggestions for typeahead interfaces. Lightweight and fast.
Query Parameters
qstringSearch query for autocomplete suggestionsRequest
curl https://skilldb.dev/api/v1/skills/suggest?q=reactResponse
{
"suggestions": [
{
"title": "React Architect",
"pack": "software-skills",
"category": "Technology & Engineering",
"id": "software-skills/react-architect.md"
}
]
}/api/postsReturns the list of blog posts with metadata. Used by the blog page and RSS feed.
Request
curl https://skilldb.dev/api/postsResponse
{
"posts": [
{
"slug": "launch-announcement",
"title": "Introducing SkillDB",
"date": "2026-03-13",
"excerpt": "The agent-first skills platform..."
}
],
"total": 12
}/api/statsReturns platform-level statistics. Useful for dashboards and status pages.
Request
curl https://skilldb.dev/api/statsResponse
{
"totalSkills": 4960,
"totalPacks": 327,
"totalCategories": 37,
"generated": "2026-03-20T...",
"topCategories": [
{ "name": "Film & Television", "packs": 15 },
{ "name": "Technology & Engineering", "packs": 13 },
{ "name": "Writing & Literature", "packs": 12 }
]
}/api/v1/profileReturns the authenticated user's profile. Requires a Bearer token in the Authorization header.
Request
curl https://skilldb.dev/api/v1/profile \
-H "Authorization: Bearer <token>"Response
{
"uid": "abc123",
"email": "user@example.com",
"displayName": "Jane Dev",
"plan": "pro"
}/api/v1/profileUpdates the authenticated user's profile. Requires a Bearer token in the Authorization header.
Request
curl -X PUT https://skilldb.dev/api/v1/profile \
-H "Authorization: Bearer <token>" \
-H "Content-Type: application/json" \
-d '{"displayName": "Jane Dev"}'Response
{
"success": true,
"displayName": "Jane Dev"
}/api/v1/bookmarksReturns the authenticated user's bookmarked skills. Requires a Bearer token.
Request
curl https://skilldb.dev/api/v1/bookmarks \
-H "Authorization: Bearer <token>"Response
{
"bookmarks": [
{
"skillId": "software-skills/code-review.md",
"addedAt": "2026-03-20T12:00:00Z"
}
]
}/api/v1/bookmarksAdds a skill to the authenticated user's bookmarks. Requires a Bearer token.
Request
curl -X POST https://skilldb.dev/api/v1/bookmarks \
-H "Authorization: Bearer <token>" \
-H "Content-Type: application/json" \
-d '{"skillId": "software-skills/code-review.md"}'Response
{
"success": true,
"skillId": "software-skills/code-review.md"
}/api/v1/bookmarksRemoves a skill from the authenticated user's bookmarks. Requires a Bearer token.
Request
curl -X DELETE https://skilldb.dev/api/v1/bookmarks \
-H "Authorization: Bearer <token>" \
-H "Content-Type: application/json" \
-d '{"skillId": "software-skills/code-review.md"}'Response
{
"success": true,
"removed": "software-skills/code-review.md"
}Skill File Format
Every skill is a plain Markdown file with YAML frontmatter. This makes skills portable, version-controllable, and readable by any agent or tool.
YAML Frontmatter
---
title: "React Architect"
description: "Senior React architect specializing in scalable component design"
category: "Technology & Engineering"
pack: "software-skills"
type: "functional" # functional | person-style | critic-style
version: "1.0"
tags: ["react", "architecture", "frontend"]
---Markdown Body
The body contains the actual skill instructions. Structure varies by skill type but typically includes:
- Identity -- who the agent becomes when this skill is active
- Principles -- core rules and guidelines
- Patterns -- specific techniques or approaches
- Examples -- sample outputs demonstrating the skill
- Anti-patterns -- what to avoid
Skill Types
Functional
Task-oriented skills like API design, testing, or deployment. Agent gains a capability.
e.g. react-architect, api-designPerson Style
Emulates a specific person's style, voice, or approach. Agent writes/thinks like them.
e.g. hemingway, kubrickCritic Style
Evaluative skills that review and critique work using specific frameworks.
e.g. film-critic, code-reviewerExample Skill File
---
title: "Ernest Hemingway"
description: "Write with Hemingway's iconic minimalist prose style"
category: "Writing & Literature"
pack: "author-styles"
type: "person-style"
version: "1.0"
tags: ["writing", "fiction", "minimalism"]
---
# Ernest Hemingway
## Identity
You write in the style of Ernest Hemingway. Your prose is
spare, direct, and emotionally resonant through what is
left unsaid.
## Principles
- Use short, declarative sentences
- Prefer concrete nouns and active verbs
- Omit needless words — apply the Iceberg Theory
- Let dialogue carry the emotional weight
- Avoid adverbs and adjectives where the verb suffices
## Anti-patterns
- Do NOT use flowery or ornate language
- Do NOT explain emotions — show them through action
- Do NOT use passive voice unless deliberatelyIntegration Guides
Claude Code
Claude Code reads CLAUDE.md at the start of every session. Add the skill index reference there.
# CLAUDE.md
## Skills
Use SkillDB skills from https://skilldb.dev/api/v1/skills
When a task matches a skill category, fetch and apply the relevant skill.
## Active Skills
- author-styles/hemingway — for blog posts
- software-skills/react-architect — for component workCursor
Cursor uses .cursorrules for project-level instructions. Add skill references the same way.
# .cursorrules
You have access to SkillDB skills.
Skills index: https://skilldb.dev/api/v1/skills
When writing React code, apply the react-architect skill.
When writing API routes, apply the api-design skill.
Fetch the skill markdown and follow its instructions.Codex CLI
For OpenAI Codex CLI, include the skills index URL in your system prompt or project instructions file.
# Initialize and get a skill for offline use
skilldb init
skilldb get author-styles/hemingway
# Skills are cached in .skilldb/skills/ for zero-latency reads
# Reference in codex instructions
echo "Apply the skill in .skilldb/skills/author-styles/hemingway.md" >> instructions.mdCustom Agents
For custom agent implementations, use the JSON index to programmatically discover and load skills.
// Fetch the skills index
const res = await fetch("https://skilldb.dev/api/v1/skills");
const { skills } = await res.json();
// Find skills matching a task
const writingSkills = skills.filter(
s => s.category === "Writing & Literature"
);
// Load a specific skill's content
const skill = await fetch(
"https://skilldb.dev/api/v1/skills/author-styles/hemingway"
);
const { content } = await skill.json();
// Inject into your agent's system prompt
const systemPrompt = `${basePrompt}\n\n## Active Skill\n${content}`;Installation
The skilldb npm package gives you a CLI and TypeScript SDK for discovering, installing, and managing skills from the terminal. No API key required for browsing — just install and go.
# Use directly with npx (no install needed)
npx skilldb search react hooks
npx skilldb get react-patterns-skills/custom-hooks
# Or install globally for the full workflow
npm install -g skilldb
# Initialize SkillDB in your project
skilldb init
# Search → Get → Done
skilldb search code review
skilldb get software-skills/code-reviewskilldb init auto-detects your IDE (Claude Code, Cursor, or Codex CLI), creates a local .skilldb/ cache directory, and adds an integration snippet to your config file.
CLI Commands
# Search skills by keyword (multi-word search supported)
skilldb search react hooks
skilldb search code review
skilldb search api design --category "Technology & Engineering"
# Get exactly the skill you need (recommended)
skilldb get react-patterns-skills/custom-hooks
skilldb get software-skills/code-review
skilldb get autonomous-agent-skills/self-correction
# Download an entire pack (when you want everything)
skilldb add software-skills
skilldb add autonomous-agent-skills
# List available categories and skills
skilldb list
skilldb list --category "Autonomous Agents"
skilldb list --pack software-skills
# Show skill details and preview
skilldb info software-skills/code-review
# Save your API key (for full content access)
skilldb login
# Remove inactive cached skills to free disk space
skilldb purge
skilldb purge --all # remove everything including active
skilldb purge --inactive # only remove unused skills
skilldb purge --dry-run # preview what would be removedRecommended workflow: Use skilldb search to find what you need, then skilldb get <pack>/<skill> to download individual skills. Use skilldb add <pack> when you want an entire pack. Both commands cache skills locally in .skilldb/skills/ for zero-latency reads and are idempotent — running them again skips already-cached skills.
TypeScript SDK
Import createClient from the skilldb package for programmatic access. The client auto-loads your API key from environment variables or config files.
import { createClient } from 'skilldb';
const db = createClient(); // auto-loads key from env/config
// Search for skills
const results = await db.search('code review');
console.log(results.skills);
// Get a single skill with full content
const skill = await db.get('software-skills/code-review.md');
console.log(skill.title, skill.content);
// List with filters
const listing = await db.list({
category: 'Autonomous Agents',
limit: 10,
});The SDK also exports cache utilities for local skill management:
import { createClient, initCache, cacheSkill } from 'skilldb';
const db = createClient();
initCache(); // creates .skilldb/ directory
// Download and cache a skill locally
const skill = await db.get('software-skills/code-review.md');
const path = cacheSkill(skill);
console.log('Cached to:', path);Authentication
Browsing and searching works without authentication. Full skill content requires a Pro or Studio API key. The SDK resolves your key in this order:
# 1. Environment variable (CI-friendly)
export SKILLDB_API_KEY=sk_live_xxx
# 2. Project-level config
echo '{"apiKey":"sk_live_xxx"}' > .skilldbrc
# 3. User-wide config (set via skilldb login)
# Saved to ~/.skilldbrcRun skilldb login to save your API key interactively, or set the SKILLDB_API_KEY environment variable for CI/CD pipelines. Get your key at Get Started.
MCP Server — Overview
SkillDB includes an MCP (Model Context Protocol) server that exposes 5,000+ skills directly to any MCP-compatible AI coding tool — Claude Code, Cursor, Windsurf, VS Code Copilot, and 30+ others. No copy-pasting, no manual configuration. Your agent can search, retrieve, and use skills natively.
What is MCP?
The Model Context Protocol is an open standard that lets AI tools connect to external data sources. When you add the SkillDB MCP server, your AI assistant can search and load skills on demand — like giving it access to a library of expert knowledge.
Installation
The MCP server ships with the skilldb npm package:
# Step 1: Install globally (one time)
npm install -g skilldb
# Step 2: Add to Claude Code
claude mcp add skilldb -- skilldb-mcp
# With API key (for full skill content)
claude mcp add skilldb -- skilldb-mcp --api-key sk_live_xxx
# Cursor — add to .cursor/mcp.json
{
"mcpServers": {
"skilldb": {
"command": "skilldb-mcp"
}
}
}
# Windsurf — add to mcp_config.json
{
"mcpServers": {
"skilldb": {
"command": "npx",
"args": ["skilldb-mcp", "--api-key", "sk_live_xxx"]
}
}
}
# Any MCP client
skilldb-mcpAvailable Tools
The MCP server exposes 6 tools that your AI assistant can call:
skilldb_searchSearch 5,000+ skills by keyword. Filter by category or pack. Returns skill metadata, descriptions, and optionally full content.
Parameters: query (required), category, pack, limit
skilldb_getRetrieve the full content of a specific skill by ID. Returns the complete markdown with instructions, patterns, and best practices.
Parameters: id (required, e.g. "software-skills/code-review.md")
skilldb_listBrowse all available skills with filtering and sorting. Great for exploring what's available.
Parameters: category, pack, sort, limit, offset
skilldb_suggestFast autocomplete suggestions. Useful for quick lookups when you know part of a skill name.
Parameters: query (min 2 chars)
skilldb_recommendRecommend skill packs based on your tech stack. Tell it your technologies and role, get tailored pack suggestions.
Parameters: technologies (array), role (optional)
skilldb_purgeRemove cached skills from the local .skilldb/ directory to free disk space. Supports dry-run preview and multiple purge modes.
Parameters: mode (default/all/inactive/slim), dryRun (boolean)
Usage Examples
Once installed, your AI assistant can use SkillDB tools naturally in conversation:
# In Claude Code or Cursor, just ask:
"Search SkillDB for React performance patterns"
→ Agent calls skilldb_search("react performance")
→ Returns matching skills with descriptions
"Load the code review skill"
→ Agent calls skilldb_get("software-skills/code-review.md")
→ Full skill content loaded into context
"What skills should I use for this project?"
→ Agent calls skilldb_recommend with your tech stack
→ Returns tailored pack recommendations
"Show me all security skills"
→ Agent calls skilldb_list(category: "Security")
→ Lists all available security skill packs
"Clean up unused skills from my project"
→ Agent calls skilldb_purge(mode: "inactive")
→ Removes cached skills not in active profileThe MCP server runs locally on your machine and calls the SkillDB API. Metadata browsing works without authentication. Full skill content requires a Pro or Studio API key.