← Registry

Developer Tools

leash.build

Manages Leash apps, including creation, allowed origins, per-app Postgres schemas, sign-in, and storage usage and compaction.

1 endpoint16 known toolsFirst detected November 23, 2026Last detected November 23, 2026

ENDPOINT 1

https://leash.build/mcp

No auth detected

MCP server metadata

Name
leash
Version
1.0.0
Capabilities
tools.listChanged
Server instructions

# Using Leash Leash gives each of the person's apps its own Postgres schema plus sign-in. These tools act only within the signed-in person's account; every app-scoped tool takes `app` = the app's slug or id. Whoever signs in on a site approves it and picks which of THEIR apps' data it uses; no per-user rows or shared data, not for multi-user apps. ## Set up an app 1. `create_app` with a slug and the web origins the app is served from (e.g. https://myapp.example.com, http://localhost:5173). Change them later with `set_app_origins`. 2. Create tables with `apply_schema_change` (one statement per call, with a description), e.g. `create table notes (id bigserial primary key, body text not null, created_at timestamptz default now())`. 3. Inspect with `list_tables`, `describe_table`, `query` (read-only); change data with `execute`. ## Web apps (browser): no keys in the code - To sign in, send the browser to https://leash.build/authorize?app=<app id>&return=<URL of the app page> (https, or http on localhost). A new site gets an approval screen first (which data, read & change or read only); the app's own origins skip it. Leash returns `#leash_token=<token>`: read it, keep it in memory, clear the address bar. - The token lasts 1 hour; there is no refresh token. On 401, send the browser to /authorize again: while the person's Leash sign-in lasts (30 days) it comes straight back with a new token, otherwise via sign-in. - Data API: https://leash.build/api/v1/data/<table>, header `Authorization: Bearer <token>`, JSON replies: - GET <table>?select=a,b&<col>=eq.<v>&order=<col>.desc&limit=50&offset=0 → 200 {"rows":[…]} - GET <table>/<id> (matches the `id` column) → 200 the row object itself, not wrapped; 404 not_found - POST <table>, body: a row object or an array of up to 1000 rows → 201 {"rows":[…inserted rows]} - PATCH <table>?<filters>, body: the columns to change → 200 {"rows":[…updated rows]} - DELETE <table>?<filters> → 200 {"rows":[…deleted rows]} Filters: eq, neq, gt, gte, lt, lte, like, ilike, in.(a,b), is.null. limit: default 100, max 1000. PATCH/DELETE need a filter; over 1000 rows they still apply but reply {"count":n}. `select` also picks what writes return. - bigint and numeric values are returned as strings (a bigserial id is "1", not 1), here and in `query`. - Errors are {"error":"<code>"}. 409 constraint_violation adds "constraint" and "column" (null when Postgres doesn't say) and a "message" naming them. 400: invalid_query, unknown_column (+ "column"), invalid_value, filter_required, invalid_body. 404 table_not_found. 429 = slow down (Retry-After). 403 storage_limit = over the storage limit (reads and deletes still work). 403 app_read_only = Free account, not its oldest app: reads only until it upgrades. 423 paused = account idle 90 days: the owner signs in to Leash, then the same token/key works again. 403 origin_not_allowed = Origin isn't the approved site's; a server-side client (script, proxy) must send none. 403 read_only_access = the person allowed this site to read only. 401 after they disconnect it in Leash. ## Device apps (scripts, extensions, phone apps) - `mint_device_key` returns a key (lk_…) shown once. Put it in the device's local config or secret store, never in browser code or a public repo. Use it as `Authorization: Bearer lk_…` on the same data API. A device key doesn't expire: it works until `revoke_device_key` or the app is deleted (then 401). - A server of the app's own can check a device key: POST https://leash.build/api/v1/keys/verify {"key":"lk_…"}. ## SQL rules - One SQL statement per `execute` / `apply_schema_change` / `query` call; use $1, $2 … with `params` for values. Allowed: select, insert, update, delete, create/alter/drop table, index, view, sequence, truncate, comment. Not allowed: functions, triggers, DO blocks, roles, grants, SET, COPY, transactions, extensions. Names starting with pg_ and system functions (e.g. pg_sleep, lo_*, dblink, set_config, current_setting) are reserved, even as column names. Tables live in the app's own schema: don't schema-qualify them. ## Safety net - Before a destructive change (drop table or column, change a column's type, truncate, or an update/delete touching more than 100 rows, or any inside a WITH clause) Leash saves a snapshot of the table, kept 7 days. `list_snapshots` and `restore_snapshot` bring data back. If a snapshot can't be taken (cap reached), the change is refused; pass `allowWithoutSnapshot: true` only when the person agrees to lose that safety net. ## Agents - To give an AI agent (Claude, ChatGPT, Grok, or your own) an app's data, add https://leash.build/mcp/agent as its connector. The approval screen has the person pick ONE app (or create one) and Read & change or Read only. The agent gets structured tools for that app only (list_tables, describe_table, select_rows; with write access insert_rows, update_rows, delete_rows, create_table, add_column, create_index): no raw SQL, other apps, drop, truncate or keys. A device key (lk_…) works too (device keys: rows only; tables are created by the owner or a connected agent). Per connection: 60 calls a minute; 50 tables, 100 columns per table; writes stop (app_storage_limit) when the app uses over half the plan's storage or the account reaches 90% of it. A prompt injection can damage only that app's data: use Read only where you can. Bulk changes are snapshotted 7 days. ## Limits - Free: 1 app, 100 MB. Pro: 25 apps, 5 GB. `usage` shows where the account stands (`bytes: null` = not measured yet; sizes are measured a few minutes after writes). `reclaim_space` compacts after large deletes. - Time: each MCP statement gets the plan's limit (Free 5 s, Pro 30 s); each data API request at most 10 s (5 s on Free). Rate limits (429) are abuse backstops per user, OAuth client and app; per-IP ones are generous. - This connector's tokens last 1 hour and renew by themselves; reconnect after 30 days unused or 90 in all.

Known tools 16

list_apps

List the person's Leash apps (id, slug, allowed origins).

Inferred read-only
create_app

Create a Leash app: its own walled-off Postgres schema and sign-in.

Potential side effects
set_app_origins

Replace the app's allowed web origins (sign-in return URLs and CORS).

Inferred read-only
usage

Show the account's storage: bytes per app as last measured (null with a note until first measured, a few minutes after the first write), total vs the plan's limit, plan, whether writes are blocked for being over the limit, snapshot usage, and the database server's state (running/stopped: it sleeps when idle and wakes on the next request).

Potential side effects
reclaim_space

Compact the app's tables that have many deleted rows (VACUUM FULL), then re-measure storage.

Inferred read-only
list_tables

List the app's tables and views (name, kind, estimated row count).

Inferred read-only
describe_table

Describe one of the app's tables or views: columns (name, type, nullable, default), primary key, constraints, indexes, and a view's definition.

Inferred read-only
query

Run one read-only SQL SELECT against the app's tables (its own schema).

Inferred read-only
execute

Run one SQL statement that changes data (insert/update/delete) or the schema.

Potential side effects
apply_schema_change

Apply one schema change (create/alter/drop table, index, view, sequence; truncate) to the app's own schema, recorded in its change log with your description.

Potential side effects
mint_device_key

Mint a device key for a non-browser client of the app (script, extension, phone app).

Inferred read-only
list_device_keys

List the app's device keys (id, name, created, last used, revoked).

Inferred read-only
revoke_device_key

Revoke one of the app's device keys (it stops working immediately).

Inferred read-only
list_snapshots

List the app's safety snapshots (taken automatically before destructive changes; kept 7 days), newest first.

Inferred read-only
restore_snapshot

Restore a snapshot as a table in the app: under its original name if that table no longer exists, otherwise as <table>_restored_<timestamp>, or as asTable.

Inferred read-only
get_direct_connection

Pro only: a Postgres connection locked to the app's own schema, for apps with their own server (Drizzle, migrations).

Inferred read-only

CONNECT WITH APPROVAL

Client installation

Review this server and its permissions before adding it. Secret placeholders must be set locally.

Codex

~/.codex/config.toml

[mcp_servers.leash]
url = "https://leash.build/mcp"
enabled = true
Claude Code

.mcp.json

{
  "mcpServers": {
    "leash": {
      "type": "http",
      "url": "https://leash.build/mcp"
    }
  }
}
Claude Desktop

Settings → Connectors → Add custom connector

Name: leash
Remote MCP URL: https://leash.build/mcp

Add this remote URL as a custom connector in Claude Desktop. Availability depends on the user plan and workspace policy.

Cursor

.cursor/mcp.json

{
  "mcpServers": {
    "leash": {
      "url": "https://leash.build/mcp"
    }
  }
}
Visual Studio Code

.vscode/mcp.json

Add to Visual Studio Code
{
  "servers": {
    "leash": {
      "type": "http",
      "url": "https://leash.build/mcp"
    }
  }
}
Generic MCP

Client-specific MCP configuration

{
  "name": "leash",
  "transport": "streamable-http",
  "url": "https://leash.build/mcp"
}
MCP Inspector

Run the official MCP Inspector locally and enter the indexed Streamable HTTP endpoint.

TRUST AND VERIFICATION EVIDENCE

Trust Data Available

BuiltWith Trust API v2 evidence for leash.build was fetched 2026-11-23T14:23:30.154Z.

Trust status Neutral

leash.build is assessed as Neutral: No suspicious signals found, but no strong positive signal either

Indexed

Evidence is source-attributed and does not guarantee that a third-party server is safe. Risk labels are conservative metadata heuristics.