Purpose
nightlife-mcp is an MCP (Model Context Protocol) server for nightlife scenarios, used to discover and search nightlife events, venues, and performers, and to handle matters such as VIP table bookings. Its data backend is Supabase, and the production endpoint is located at https://api.nightlife.dev/mcp,用户可在 nightlife.dev to get a free API key.
Main capabilities
According to official information, the tools already implemented in v0.3 include:
- get_event_details: get event details
- search_performers: search performers
- get_performer_info: get performer info
- log_unmet_request: log user requests that cannot be fulfilled
- create_vip_booking_request: create a VIP table booking request
- get_vip_booking_status: query VIP booking status
- cancel_vip_booking_request: cancel a VIP booking request
- get_vip_pricing: query venue/date pricing, open status, areas, and optional layout diagrams
- submit_to_guest_list: submit to the guest list
- get_guest_list_entry_status: query guest list entry status
- get_recommendations (v0.2, requires setting MCP_ENABLE_RECOMMENDATIONS=true): returns up to 10 diverse modal slots, with city-aware dynamic fallback
In addition, the server provides a Streamable HTTP endpoint and API key middleware, structured tool output schemas (outputSchema), deterministic tool error payloads with stable error codes, and runtime request/tool metrics exposed via /health.
How to use
Connect to Claude Desktop
Add the server to the Claude Desktop configuration file claude_desktop_config.json. For connection methods for curl, the TypeScript SDK, and other clients, see CLIENT_SETUP.md.
Environment variables
Set in .env:
- SUPABASE_SERVICE_ROLE_KEY
- DEFAULT_CITY (default: tokyo)
- MCP_TOP_LEVEL_CITIES (default example: tokyo,san-francisco; controls available_cities in unsupported city responses)
- DEFAULT_COUNTRY_CODE (default: JP)
- NIGHTLIFE_BASE_URL (default:https://nightlifetokyo.com)
- MCP_HTTP_REQUIRE_API_KEY (default: true)
- MCP_HTTP_USE_DB_KEYS (default: true)
- MCP_HTTP_ALLOW_ENV_KEY_FALLBACK (default: true)
- MCP_HTTP_API_KEYS (comma-separated legacy fallback keys)
- MCP_ENABLE_RECOMMENDATIONS (default: false; enables get_recommendations)
Database API key mode (recommended)
HTTP authentication can use persistent API keys in Supabase and track quotas. You need to run the SQL migration in the Supabase SQL editor and enable the database authentication flag in .env. When creating an API key record, the raw api_key is printed once; it must be saved securely and used for MCP HTTP calls. If the database RPC is unavailable, fall back to MCP_HTTP_API_KEYS only when MCP_HTTP_ALLOW_ENV_KEY_FALLBACK=true.
Transport methods
- Stdio (local desktop clients): no API key check required.
- Streamable HTTP (/mcp): requires an API key by default (MCP_HTTP_REQUIRE_API_KEY=true). API key request headers: Authorization: Bearer <key> or x-api-key: <key>.
When database-backed authentication is active, HTTP responses include key tier/source and rate limit headers: X-API-Key-Tier, X-API-Key-Source, X-RateLimit-Daily-Limit, X-RateLimit-Daily-Remaining, X-RateLimit-Minute-Limit, X-RateLimit-Minute-Remaining.
Date handling
Supports tonight, this_weekend, YYYY-MM-DD, and YYYY-MM-DD/YYYY-MM-DD formats.
VIP booking phase one
VIP table booking submission and status tracking are provided by Supabase Supported. The conversation policy for create_vip_booking_request requires: confirm the booking date/time in the venue's local time before submission; use dual-date confirmation wording for late-night arrivals (00:00 - 05:59); use the specified confirmation template; if the user gives something like 2am but does not specify a date, ask whether it is after Thursday night (early Friday morning) or after Friday night (early Saturday morning); if the user changes the date, regenerate the confirmation before submission.
The ops-layer session also provides internal queue tools: list_vip_reservations, list_vip_requests_for_alerting, mark_vip_request_alert_sent, claim_vip_request_after_ack, update_vip_booking_status, upsert_vip_venue_tables, upsert_vip_table_availability, upload_vip_table_chart_image.
To discover bookable venues, use search_venues with vip_booking_supported_only=true, or use get_venue_info to check vip_booking_supported. The internal venue booking worker can claim queue tasks via the database function public.claim_next_vip_agent_task(p_agent_id text).
VIP Ops Dashboard
Internal dashboard routes: POST /ops/login, POST /ops/logout, GET /ops/vip-dashboard. Internal admin API routes (protected by cookie session): GET /api/v1/admin/vip-bookings, GET /api/v1/admin/vip-bookings/:id, PATCH /api/v1/admin/vip-bookings/:id. Required environment variable: VIP_DASHBOARD_ADMINS (comma-separated username:password pairs). Optional environment variables: VIP_DASHBOARD_SESSION_TTL_MINUTES (default: 720), VIP_DASHBOARD_SESSION_COOKIE_NAME (default: vip_dashboard_session).
Running and Debugging
Supports Stdio (local desktop clients) and Streamable HTTP. See the project documentation for production builds and production HTTP run methods. An authenticated production smoke check is available. Optional environment overrides: NLT_MCP_URL (default:https://api.nightlife.dev/mcp)、NLT_REST_BASE_URL(默认:https://api.nightlife.dev/api/v1)、NLT_SMOKE_CITY(默认:tokyo)。推荐功能的调试 Web UI is at /debug/recommendations. Health endpoint: /health.
Use Cases
- Search nightlife events, venues, and performers in Tokyo and other supported cities
- Get event details, performer information, and venue information
- Submit and track VIP table booking requests
- Submit guest lists and check status
- Get personalized nightlife recommendations
- Internal ops staff manage the VIP booking queue and venue table inventory
Limitations
- Tool errors are returned as JSON text payloads in result.content[0].text, with error codes including: INVALID_DATE_FILTER, INVALID_EVENT_ID, UNSUPPORTED_EVENT_ID, EVENT_NOT_FOUND, INVALID_VENUE_ID, VENUE_NOT_FOUND, INVALID_PERFORMER_ID, PERFORMER_NOT_FOUND, INVALID_BOOKING_REQUEST, BOOKING_REQUEST_NOT_FOUND, BOOKING_STATUS_UPDATE_FAILED, VIP_TASK_NOT_AVAILABLE, VIP_ALERT_UPDATE_FAILED, VIP_CLAIM_FAILED, INVALID_REQUEST, REQUEST_WRITE_FAILED, DB_QUERY_FAILED, INTERNAL_ERROR.
- create_vip_booking_request only accepts venues with vip_booking_supported=true.
- vip_booking_supported comes from public.venues.vip_booking_enabled and is separate from guest_list_enabled.
- City handling is supported by public.cities (slug, timezone, and service day cutoff time).
- Supported top-level cities can be configured via environment, with Tokyo available as the default city.
- get_recommendations is disabled by default and requires MCP_ENABLE_RECOMMENDATIONS=true.
- Regarding charges, prices, platform compatibilityand other further details, the materials do not currently provide them.