MCP Server
Give your AI agent direct access to elephant.md via the Model Context Protocol.
Get Started
- 1Quick setup
npx elephant-md install --mcpThis auto-detects your agent and writes the config for you. Or add the JSON manually (see below).
- 2Verify
Restart your agent and ask it to search elephant.md — it should use the
searchtool automatically. - 3Authenticate (optional)
To access private documents and the
proposetool, set your token via theELEPHANT_TOKENenvironment variable in the MCP config.
Claude Code
Add to .mcp.json in your project root:
{
"mcpServers": {
"elephant": {
"type": "url",
"url": "https://elephant.md/mcp/mcp"
}
}
}Claude Desktop
Add to claude_desktop_config.json:
{
"mcpServers": {
"elephant": {
"type": "url",
"url": "https://elephant.md/mcp/mcp"
}
}
}Cursor
Add to .cursor/mcp.json:
{
"mcpServers": {
"elephant": {
"url": "https://elephant.md/mcp/mcp"
}
}
}Windsurf
Add to ~/.codeium/windsurf/mcp_config.json:
{
"mcpServers": {
"elephant": {
"serverUrl": "https://elephant.md/mcp/mcp"
}
}
}Public Tools
search— Full-text search across public documents (filters: category, tag, limit)fetch— Get full document content by username and slugtrending— Get trending documents (filters: category, limit)list_user_docs— List a user's public documents with paginationdiscover— Semantic search using natural language (filters: category, limit)
Authenticated Tools
These require a bearer token via ELEPHANT_TOKEN:
my_documents— List your own documents including private and unlistedpropose— Propose a document draft for review (stored for 7 days)save_document— Bookmark a document and optionally add it to a collectionlist_collections— List your collectionsget_collection— Get a collection's details and items by username and slugcreate_collection— Create a new collection
Resources
elephant://documents/{user}/{slug}— Full document markdown and metadataelephant://users/{user}/documents— List of a user's public documents