✈ Cabin API
Flight search and booking with USDC on Base. Built for the USDC hackathon.
Quick Start
npm install
npm start # API server on port 3320
REST API Endpoints
| Method | Path | Description |
|---|---|---|
POST | /v1/search | Search flights (Duffel API) |
GET | /v1/search/:id/image | Search results as PNG image |
POST | /v1/book | Create a booking |
GET | /v1/booking/:id | Get booking status |
GET | /v1/booking/:id/pay | USDC payment page (HTML) |
GET | /v1/booking/:id/confirmation | Booking confirmation page |
GET | /v1/booking/:id/checkin | Online check-in with seat selection |
MCP Server (for Claude Desktop, Cursor, etc.)
Cabin exposes flight tools via the Model Context Protocol, allowing AI assistants to search and book flights directly.
Tools Available
| Tool | Description |
|---|---|
cabin_search | Search for flights between airports |
cabin_book | Create a booking from an offer |
cabin_status | Check booking status |
cabin_pay | Get USDC payment instructions |
Claude Desktop Setup
- Add to your Claude Desktop config (
~/Library/Application Support/Claude/claude_desktop_config.jsonon macOS):
{
"mcpServers": {
"cabin-flights": {
"command": "node",
"args": ["/full/path/to/cabin-api/src/mcp-server.js"],
"env": {
"CABIN_API_URL": "https://api.cabin.team"
}
}
}
}
-
Restart Claude Desktop
-
Ask Claude: "Search for flights from London to New York on June 15, 2026"
Test MCP Server Locally
# stdio mode (pipe JSON-RPC messages)
node src/mcp-server.js
# HTTP mode on port 3321
node src/mcp-server.js --http
Search Example
curl -X POST https://api.cabin.team/v1/search \
-H 'Content-Type: application/json' \
-d '{"from":"HAN","to":"ATH","date":"2026-03-15","adults":1}'
Tech Stack
- Express — API server
- Duffel API — Flight search and booking (end-to-end)
- MCP SDK — Model Context Protocol for AI integration
- Puppeteer — HTML→PNG rendering for search result images
- USDC on Base — Payment
Live
- API: https://api.cabin.team
- Managed by PM2:
pm2 restart cabin-api