Skip to main content

URL Scheme

The tablepro:// URL scheme drives the TablePro GUI from outside the app. Use it from the shell with open, from another app with NSWorkspace.shared.open(url:), or from a Raycast extension with open() from @raycast/api. The scheme covers two kinds of actions:
  • Navigate: open a connection, table, or query tab.
  • Pair: bootstrap an MCP token for an extension.
Data exchange is not part of the URL scheme. For that, use MCP.

Connection IDs are UUIDs

Connection paths use the connection’s UUID, not its display name.
There is no UI action that copies a connect link. To find a connection’s UUID, call the MCP list_connections tool or read the tablepro://connections resource; both return the UUID for each saved connection. The welcome screen’s Copy TablePro Link context menu item copies a tablepro://import?... link for sharing the connection, not a connect link.
Pre-0.38 builds accepted tablepro://connect/<name>/... paths. Name-based paths were removed in 0.38.0. Bookmarks built against older versions must be regenerated with UUID-keyed paths.

Open a connection

Opens the saved connection. If the connection is already open in a window, that window comes to front. If the UUID does not match a saved connection, an error sheet appears. If the connection has a pre-connect script, TablePro shows the script text in a confirmation dialog before connecting. Cancelling the dialog cancels the whole deep link. This applies to every connect/... link: connection, table, and query.

Open a table

The first form opens the table in the connection’s current database and schema. The second selects a database first. The third (Postgres-style) selects both. Table and schema names with spaces or special characters must be percent-encoded.

Run a query

Opens a new query tab with the SQL pre-filled. TablePro always shows a confirmation dialog first, previewing the first 300 characters of the SQL. The query does not auto-execute; the user runs it from the editor. The SQL has a 51,200-character cap. To run SQL from a script and read rows back, use the MCP execute_query tool instead. The URL scheme is for handing SQL into the GUI, not for headless execution.

Start pairing

Starts a pairing flow. TablePro presents an approval sheet, the user picks scopes and connections, and TablePro returns a one-time code via the redirect URL. The user can change scopes and connections in the approval sheet. The query parameters are a request, not a grant. Example invocation from a Raycast extension:
See Pairing for the full sequence and the exchange step.

Lazy-start the MCP server

Starts the MCP server if it is not already running, then returns. Used by the bundled tablepro-mcp CLI to bootstrap on cold launch. The user does not need to enable MCP in Settings beforehand. The server binds to the configured port (default 23508); if that port is taken, it falls back to a free port in the 51000-52000 range. Either way it writes a handshake file at ~/Library/Application Support/TablePro/mcp-handshake.json with the actual port.

Import a connection

Adds a saved connection from query parameters. TablePro shows a review sheet with the parsed details before saving anything; the name is editable, everything else is read-only. Add Connection saves it, or Add as Copy when a connection with the same name, host, and type already exists. Passwords are never accepted in the URL; the user adds one in the connection editor before connecting. Required parameters: name, host, type. type accepts any registered database type name (case-insensitive). Examples: MySQL, PostgreSQL, MongoDB, Redis, ClickHouse, Oracle, DuckDB, Cassandra.
Enum-valued parameters below must match the listed values exactly (they are raw values, not display names). Percent-encode values with spaces: sslMode=Verify%20CA.

Core parameters

SSH parameters

Set ssh=1 to enable SSH tunneling.

SSL parameters

Plugin-specific fields

Use the af_ prefix to pass driver-specific fields. For example, af_replicaSet=myrs passes replicaSet to the MongoDB plugin. af_preConnectScript is stripped on import. Imported connections cannot carry a pre-connect shell script; the user has to add one by hand in the connection editor.

Errors

Malformed URLs are dropped without any UI: an invalid UUID, unknown path, missing required parameter, or over-limit SQL is logged to the system log (subsystem com.TablePro) and nothing opens. Check Console.app when a link does nothing. Failures after parsing show an error sheet. Example: a valid UUID with no matching connection shows No saved connection with ID "9F1F0C3E-2E3D-4B14-9C3A-1D2F4AD1F6F1". under the title Connection Failed.