← Back to GhostNot

API Reference

29 endpoints across bookings, reputation, wallet, MCP, and more.

Base URL

https://ghostnot.com/api

Authentication

Session — Supabase auth cookie (browser sessions). Set automatically on login.

API Key — Pass via X-API-Key header. Create keys at /dashboard/api-keys.

None — Public endpoints, no authentication required.

Health

GET
/api/health

Service status, version, database connectivity

None

Bookings

POST
/api/bookings/create

Create a booking with stake hold. Returns Stripe client_secret for payment.

Optional
POST
/api/bookings/[id]/cancel

Cancel a booking. Refund depends on timing (early vs late).

Session

Host Management

POST
/api/host/setup

Create or update host profile (slug, stake, trust threshold).

Session
GET
/api/host/settings

Get current host settings.

Session
PUT
/api/host/settings

Update host settings (stake amount, calendar, etc.).

Session
GET
/api/host/account

Get host account details.

Session
POST
/api/host/check-slug

Check if a booking slug is available.

Session

Trust (Public)

GET
/api/trust/[slug]

Get public trust profile: score, tier, show-up rate, meetings. CORS enabled, 5min cache.

None

Reputation

GET
/api/reputation/stake-requirement

Calculate stake for a host slug. Pass requester_id for trust-adjusted amount.

None

Wallet

GET
/api/wallet/balance

Get wallet balance, lifetime deposits, lifetime earnings.

Session
POST
/api/wallet/deposit

Initiate a deposit. Returns Stripe client_secret.

Session
POST
/api/wallet/deposit/confirm

Confirm deposit after Stripe payment succeeds.

Session
POST
/api/wallet/withdraw

Withdraw from wallet (5% fee). Min $5.

Session
GET
/api/wallet/transactions

Paginated wallet transaction history.

Session

API Keys

GET
/api/keys

List your API keys.

Session
POST
/api/keys

Create a new API key with permissions and max stake.

Session
POST
/api/keys/[id]/revoke

Revoke an API key.

Session

Disputes

POST
/api/disputes/create

Raise a dispute on a meeting (48h window, min 20 char reason).

Session
POST
/api/disputes/[id]/resolve

Resolve a dispute (for_host or for_requester).

Admin

MCP (AI Agents)

GET
/api/mcp/tools

List available MCP tools and their schemas.

None
POST
/api/mcp/ghostnot/[tool]

Invoke an MCP tool. See /docs/mcp for details.

API Key

Auth

GET
/api/auth/callback

OAuth callback handler (Supabase Auth).

None
POST
/api/auth/associate-meetings

Link anonymous bookings to authenticated user.

Session
GET
/api/auth/google-calendar

Initiate Google Calendar OAuth.

Session
GET
/api/auth/google-calendar/callback

Google Calendar OAuth callback.

None

Webhooks

POST
/api/stripe/webhook

Stripe webhook handler for payment events.

Stripe Signature

Discovery

GET
/.well-known/mcp.json

MCP server auto-discovery (server card).

None
GET
/llms.txt

AI/LLM discoverability file.

None

Related docs