Technical guide
HTTP API & OpenAPI 3.1 overview.
Drive Local's web app, iPhone app and remote MCP server are all thin peers over one typed capability API (104 active capabilities). Inspect the live OpenAPI 3.1.0 schema at /v1/openapi.json.
Updated 2026-11-29
Architecture
One capability registry, three thin clients
Every Drive Local business operation is declared once in @drive-local/contract with Zod input and output schemas, HTTP method and path, audience (public, me or operator), required role and effect (read, write or destructive). From that single source of truth, the Cloudflare API Worker generates HTTP routes, the OpenAPI 3.1 document and the MCP tool catalog.
Public
6
Public capabilities
Storefront catalog, live quoting, sitemap discovery, waitlist and support.
Operator
70
Business capabilities
Fleet, calendar, Turo sync, bookings, customers, messages, earnings and agents.
Account
28
Signed-in capabilities
Personal profile, business creation, devices, bookings and account deletion.
Public endpoints
Unauthenticated HTTP endpoints
In addition to GET https://www.drive-local.app/v1/health and GET https://www.drive-local.app/v1/openapi.json, the contract currently exposes these 6 public endpoints:
| Method & path | Capability ID | Description |
|---|---|---|
| POST /v1/waitlist | waitlist.join | Add a rental business to the Drive Local waitlist. Joining twice with the same email keeps the first entry. |
| POST /v1/support | support.contact | Send a question about Drive Local or a privacy request. Do not include payment details, identity documents or sign-in codes. |
| GET /v1/public/storefronts | storefront.sitemap | Non-suspended rental businesses with at least one live, priced car at an active pickup location, used to build the public sitemap. |
| GET /v1/public/storefronts/{slug} | storefront.get | A rental business's public page: its name and every car customers can book now. |
| GET /v1/public/storefronts/{slug}/cars/{carSlug} | storefront.car | One bookable car: its photos, details, price and where customers pick it up. |
| GET /v1/public/storefronts/{slug}/cars/{carSlug}/quote | storefront.quote | The full price of renting a car between a pickup and a return (ISO 8601 with an offset, on the half hour), with taxes and included miles; whether it can be booked then, and why not; and the cancellation terms. Without times it prices the earliest pickup for one day. |
Conventions
Types, auth and error format
| Convention | Rule |
|---|---|
| Base origin | https://www.drive-local.app (API routes live under /v1 on the same domain as the web app) |
| Money | Integer USD cents (for example, 6500 for $65.00). Rates and taxes use integer basis points (250 = 2.5%, 925 = 9.25%). |
| Time | UTC instants in ISO 8601 format with offset. Pickup locations store IANA time zone IDs (such as America/New_York); billable days count local wall-clock time. |
| Identifiers | Opaque permanent record IDs in URLs and payloads. Human references show Booking #1042 locally and {businessNumber}/{bookingNumber} for support. |
| Errors | RFC 9457 application/problem+json with type, title, status, code, detail and optional fields map. |
| Authentication | Better Auth sessions (email/SMS OTP, Google, Apple) for web and iPhone clients; OAuth 2.1 with PKCE and CIMD bearer tokens for /mcp. |
API surface
Active capability groups in OpenAPI 3.1
activity1 endpointagents3 endpointsbookingRules2 endpointsbookings17 endpointscalendar1 endpointcustomers2 endpointsdriveBot5 endpointsearnings2 endpointsinvites2 endpointslocations4 endpointsme25 endpointsmessages4 endpointsoperators4 endpointsstorefront4 endpointssupport1 endpointteam5 endpointsturo7 endpointsvehicles14 endpointswaitlist1 endpointQuestions
Frequently asked questions
- Where is Drive Local's live OpenAPI specification?
- The complete OpenAPI 3.1.0 specification is served directly at https://www.drive-local.app/v1/openapi.json, generated from the exact same Zod schemas and capability registry that power the HTTP API and MCP server.
- How are API errors formatted?
- Non-2xx responses return RFC 9457 application/problem+json payloads containing type, title, status, a stable machine-readable code, an optional plain-English detail message and a fields map for input validation errors.
- Should I integrate through the HTTP API or the remote MCP server?
- If you are connecting Claude, ChatGPT, Codex or another LLM assistant, use the remote MCP server at /mcp with OAuth 2.1 and CIMD. Use /v1/openapi.json when inspecting public storefront data, auditing schemas or building typed HTTP tooling.
Keep reading
Continue in Docs & Features
Early access
Build with an API that stays in sync with the apps.
Create a rental business to inspect live business capabilities or connect your assistant via /mcp.