BrewPage API
OpenAPI specification, interactive documentation, and MCP server for BrewPage -- HTML/KV/JSON/file hosting platform.
Quick Start -- 4 Ways
Web UI
Open brewpage.app -> Drop a file or paste HTML -> Publish -> Get a shareable link.
Claude Skill
/brewpage "Hello, world!"
Publish content instantly via the brewcode plugin skill.
MCP Server
Add brewpage-mcp to your Claude config:
{
"mcpServers": {
"brewpage": {
"command": "npx",
"args": ["-y", "brewpage-mcp"]
}
}
}
Then ask Claude: "Publish this HTML to BrewPage".
API
curl -X POST https://brewpage.app/api/html \
-H "Content-Type: application/json" \
-d '{"content": "<h1>Hello, world!</h1>"}'
Response:
{
"id": "aBcDeFgHiJ",
"namespace": "public",
"link": "https://brewpage.app/public/aBcDeFgHiJ",
"ownerLink": "https://brewpage.app/api/html/public/aBcDeFgHiJ",
"ownerToken": "your-secret-token",
"expiresAt": "2026-04-05T12:00:00Z",
"sizeBytes": 22
}
Overview
BrewPage is a content hosting platform that lets you publish and share:
- HTML pages -- publish raw HTML or Markdown with instant short URLs
- Key-value store -- create named key-value pairs grouped in stores, up to 1,000 keys per store
- JSON documents -- store and retrieve arbitrary JSON with collection management
- File hosting -- upload files up to 5 MB with automatic MIME detection and inline preview
Every resource gets a short URL (brewpage.app/{ns}/{id}), optional password protection, configurable TTL (1--365 days), and tagging. Public content appears in a browsable gallery with search.
API Examples
Get platform stats:
curl https://brewpage.app/api/stats
Publish Markdown:
curl -X POST "https://brewpage.app/api/html?format=markdown" \
-H "Content-Type: application/json" \
-d '{"content": "# My Document\n\nHello **world**"}'
Store a JSON document:
curl -X POST https://brewpage.app/api/json \
-H "Content-Type: application/json" \
-d '{"name": "config", "version": 1}'
API Reference
- Interactive docs -- kochetkov-ma.github.io/brewpage-openapi
- API Reference (Scalar) -- kochetkov-ma.github.io/brewpage-openapi/api-reference
- OpenAPI spec (YAML) --
openapi/openapi.yaml - OpenAPI spec (JSON) --
openapi/openapi.json
Endpoints
| Tag | Description |
|---|---|
| HTML | Publish, retrieve, update, delete HTML/Markdown pages |
| KV | Key-value store CRUD (get, set, list, delete keys) |
| JSON | JSON document CRUD with collection listing |
| Files | File upload, download, list, delete |
| Gallery | Browse public content with search and pagination |
| Stats | Platform-wide usage statistics |
| Short Links | URL shortener for published content |
| SEO | Sitemap and robots.txt endpoints |
MCP Server
The brewpage-mcp package provides a Model Context Protocol server with 5 tools for AI-assisted content publishing. See mcp-server/README.md for full documentation.
Claude Desktop
Add to claude_desktop_config.json:
{
"mcpServers": {
"brewpage": {
"command": "npx",
"args": ["-y", "brewpage-mcp"]
}
}
}
Claude Code
Add to settings.json:
{
"mcpServers": {
"brewpage": {
"command": "npx",
"args": ["-y", "brewpage-mcp"]
}
}
}
Documentation
Full documentation is deployed to GitHub Pages:
kochetkov-ma.github.io/brewpage-openapi
The docs site includes getting started guides, API examples, and MCP server usage instructions.
Project Structure
brewpage-openapi/
openapi/
openapi.json # OpenAPI 3.1 spec (JSON)
openapi.yaml # OpenAPI 3.1 spec (YAML)
docs-site/ # Astro documentation site
src/
pages/ # Documentation pages
components/ # Scalar API reference
mcp-server/ # MCP server (brewpage-mcp)
src/
index.ts # Server entry point
tools/ # MCP tool implementations
.github/
workflows/ # CI/CD (docs deploy, releases)
README.md
RELEASE-NOTES.md
LICENSE
Links
- BrewPage -- brewpage.app
- BrewData (alias) -- brewdata.app
- API Docs -- kochetkov-ma.github.io/brewpage-openapi
- API Reference (Scalar) -- kochetkov-ma.github.io/brewpage-openapi/api-reference
- OpenAPI Spec --
openapi/openapi.yaml - MCP Server --
mcp-server/ - Claude Skill -- brewpage-publish
- Skill Docs -- doc-claude.brewcode.app/brewdoc/brewpage
- Brewcode Plugin -- github.com/kochetkov-ma/claude-brewcode
- Wiki -- github.com/kochetkov-ma/brewpage-openapi/wiki
- Releases -- github.com/kochetkov-ma/brewpage-openapi/releases
- GitHub -- github.com/kochetkov-ma/brewpage-openapi