Portward
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| DATABASE_URI | No | The database URI read when setting up a wrapped Postgres MCP server in wrap mode (`wrap-add <name> -- uvx postgres-mcp`); otherwise asked for without showing what you type and kept in your keychain. | |
| DO_NOT_TRACK | No | Set to `1` to turn anonymous usage counts off for good (you are then never asked). | |
| PORTWARD_HOME | No | Overrides the app-data folder where Portward keeps its local database (default: `~/Library/Application Support/Portward` on macOS, `%APPDATA%\Portward` on Windows, `$XDG_DATA_HOME/portward` (default `~/.local/share/portward`) on Linux). | |
| SNOWFLAKE_PAT | No | A programmatic access token for a Snowflake-managed MCP server, or the password passed to Snowflake-Labs/mcp as `SNOWFLAKE_PASSWORD`, when setting up a wrapped Snowflake server in wrap mode; otherwise asked for and kept in your keychain. | |
| PORTWARD_USAGE | No | Set to `off` to turn anonymous usage counts off for good (you are then never asked). | |
| PORTWARD_SHARE_URL | No | The share service URL, used only when you share a pull. | https://share.portward.ai |
| PORTWARD_ACCOUNT_URL | No | The account service URL, used only if you sign in to a Personal account. | https://signup.portward.ai |
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
Portward lets you query the user's own databases and CSV or Excel files read-only. Call list_sources to see the sources, tables and columns, then query with one SELECT. Notes on tables and columns are the user's own words on what they mean: follow them when you write the SQL. Where the user has a results panel, the rows show to them and you get only the rows they put in the chat: their message gives a selection id, and get_selection with that id returns those rows. Otherwise you get a short preview. The user can block tables and columns; those are never sent to you, so don't try to work around a block. A source can run on the user's profiles instead: then you see only what its applied profiles grant, and nothing else exists for you. Its definitions are the user's approved meanings of their terms: use them, and cite the ones your answer relies on. You may draft meanings and definitions for the user to approve (draft_meanings, draft_definition); a draft isn't used until they approve it. If the user is new or has no sources yet, call get_started.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {
"listChanged": false
} |
| prompts | {
"listChanged": false
} |
| resources | {
"subscribe": false,
"listChanged": false
} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| queryB | Run one read-only SQL SELECT against a source. |
| rerunA | Re-run a past pull from history exactly: its stored SQL, unchanged, on the same source. |
| run_savedA | Re-run a saved pull by its name (see saved_pulls), exactly as it was saved. |
| tweakA | Tweak a past pull ('same, but last quarter'): run |
| kept_rowsA | Show the rows a past pull returned, if rows were kept for it (see keep_rows), without running it again. |
| compareA | Compare two pulls from history (e.g. a pull and its tweak): rows added, rows removed, rows whose numbers changed, and totals that moved, from |
| save_secretB | The panel's form sends what the user typed (a database password, the sharing code) for the ask in its _meta (or read with secret_request). App-only: the model never sees this tool, its input or result. |
| secret_requestB | The panel reads the form for an open ask (its request_id, in the visible result) when the host didn't hand it the result's _meta. App-only: the model never sees this tool or its result. |
| panel_rowsA | The results panel reads a pull's rows. App-only: the model never sees this result. |
| put_in_chatC | The results panel records the user's selection (row positions, column names) and gets the short chat message it posts: the selection's id, never its values. App-only. |
| value_sourceB | The results panel asks where one value came from (its row position and column name): the source tables and columns behind it and the query's filters. App-only. |
| share_linkB | The share panel reads a new share's link (its # part is the key) to show and copy. App-only: the model never sees this tool or its result. |
| share_mailB | The share panel's 'Open in mail app': opens a draft to the teammate with the link in the user's mail app. App-only. |
| add_sourceA | Connect a source; adding a name again replaces it. The file kinds take |
| update_passwordA | Have the user enter a new password for a database source (when it changed, or test_source says it's missing or wrong). Never takes the password: the user types it where you can't see it. The old password stays until the new one works. |
| usage_seenC | The results panel showed the user the usage-counts question. App-only. |
| usage_choiceC | The user turned usage counts on or off in the results panel. App-only. |
| more_rowsA | Send more rows of a pull than its preview. The user is asked first, every time; only call this when the preview isn't enough. |
| get_selectionA | Get the rows the user put in the chat from the Portward results panel: exactly the rows and columns they picked. Call it only with a selection id the user's message gave you ("use my selection sel_..."); don't guess ids or reuse a pull_id. You can read a selection again while it lasts (24 hours at most). |
| exportA | Export a past pull to a file on the user's machine: format 'csv' or 'xlsx' (Excel). Runs the pull's stored SQL again and writes every row; you get only the file's path. |
| test_sourceB | Test a connected source: says whether it opens, and if not, why. |
| matching_login_sqlA | Write setup SQL for a read-only database login that can read exactly what a connection's applied profiles grant (Postgres or Snowflake), for the user or their DBA to run, so the database itself hides what isn't granted. |
| remove_sourceC | Remove a connected source, and its password from the keychain. |
| list_sourcesB | List the connected sources with the tables and columns the AI may use. |
| describe_sourceB | Browse one source's tables and columns, with the user's notes and which are blocked. |
| set_noteA | Write or edit the user's note on what a table, or one of its columns, means. Leave out |
| get_startedA | The first-run guide: call it when the user is new or has no sources. It says the next step (connect a source, then a first pull) and gives a query to try. use_sample=true connects a small sample database for a user with no file to hand. |
| historyB | Show the user's last pulls, newest first (for 'show my last pulls'). Each has an id that rerun takes. |
| lineageB | List a pull's lineage: the pull it tweaks (parent, and that one's ancestors) and the pulls that tweak it (children). |
| save_pullA | Save a pull from history under a name (e.g. 'Monthly revenue by region') so it can be re-run by name with run_saved. Saving a name again moves it to this pull. |
| saved_pullsA | List the saved pulls by name. run_saved re-runs one. |
| keep_rowsA | Turn keeping result rows on or off (off by default). When on, each new pull's rows are kept on this machine, encrypted with a key in the OS keychain, for 30 days; kept_rows shows them. |
| sent_to_aiA | Show what the AI was sent (for 'what did you see?'). With no conversation_id, list the conversations, newest first; with one, every response sent in it, in order. |
| ai_logA | Show the AI log's summary (for 'what did my AI see?'): every read, with when, which AI app, the route, the profiles and versions that allowed it, the tables and columns at the level each was shown, and how many rows. Never the values. Optional start and end are dates (YYYY-MM-DD, both included). |
| export_proof_reportA | Export the proof report, 'what my AI saw', for a date range: start and end are dates (YYYY-MM-DD, both included). Writes a PDF and a CSV with the same facts to the user's exports folder: per AI app and profile the tables and columns, levels and row counts, and every read. Never the values. Unsigned. You get the files' paths and the totals. |
| usage_countsA | Anonymous usage counts: with no argument, say whether they're on and exactly what is counted and would be sent next. on=false turns them off (and deletes the counts kept so far); on=true turns them back on once the user has been asked (Portward asks them itself). |
| open_pageA | Open the user's Portward page in their web browser, on this computer: their history, saved pulls, block rules, settings and what the AI was sent. Call it when the user asks to see or manage those. The page opens for the user; you aren't given its address. |
| dismiss_offerA | Stop one kind of Portward offer on this computer for good (kind as the offer gave it: "web", "profile" or "anonymised_or_totals"). Call it when the user says they don't want that offer again. |
| blockB | Block a table, or one column of it, from the AI for good: it is never sent, whatever the query. Leave |
| unblockA | Remove a block rule so the AI can read that table or column again. Portward asks the user to confirm it themselves; only call this when the user asks for it. |
| list_rulesA | List the user's block rules: the tables and columns never sent to the AI. Leave |
| create_profileA | Create a profile: a named bundle of what the AI may see, for one job. |
| update_profileA | Save a new version of a profile: rename it, change its description, add grants in full ( |
| start_profile_from_block_rulesB | Turn a connection's Free block rules and notes into a starting profile and switch the connection to it: the profile grants in full, by name, every column not blocked now, and the notes on those become its context (notes on blocked tables and columns are dropped). |
| apply_profileA | Apply a profile to a connection. Shows each grant as matched, hidden here instead (with why) or not in your data, with counts; refused only when nothing matches. From then on the AI sees only what the applied profiles grant on that connection, and its block rules stop applying. Several profiles on one connection add up. Switching from block rules, or showing more, asks the user first. |
| unapply_profileB | Take a profile off a connection. The connection stays on profiles: with none left, the AI sees nothing of it (use_block_rules goes back to block rules). |
| use_block_rulesA | Switch a connection from profiles back to Free's block rules (anything not blocked is seen). Asks the user first; only call it when they ask. |
| list_profilesA | List the user's profiles: their grants, version and where each is applied. |
| draft_meaningsA | Draft what tables and columns a profile grants mean, from their schema and sample rows (pull a few first). Each draft waits on this computer for the user's approval and is used for nothing until then; then ask the user to review them with approve_context. Only tables and columns the profile grants can have a meaning. |
| draft_definitionA | Draft a named definition for a profile ("active customer", "MRR"): what the term means in the user's data, naming the tables and columns it uses. It waits on this computer for the user's approval and is used for nothing until then; ask them to review it with approve_context. Once approved, the definition is given with the schema and you must use it. |
| draft_linkA | Draft a link for a profile: |
| context_draftsB | The context drafts waiting for the user's approval: each draft's id, profile and what it's about (not its text, which isn't used until approved). approve_context asks the user about one. |
| discard_draftC | Throw away a context draft the user doesn't want. |
| approve_contextA | Ask the user to approve a context draft (see context_drafts): they see its text, can edit it, and say yes or no in their own prompt. Approved, it joins the profile as a new version and is given to the AI with the schema from then on. |
| settle_contextA | When list_sources says two profiles describe a column or term differently, ask the user which one the AI should use. The pick is remembered until either description changes. |
| assumptionsB | What you (the AI) assumed when no definition covered a question, newest first: each assumption with the answer (pull) and question it was made for, and the definition it became, if the user turned it into one. Offer to turn an open one into a definition with define_assumption. |
| define_assumptionB | Turn one of your assumptions (see assumptions) into a named definition: the user sees it with |
| import_dictionaryA | Import a data dictionary the user already has (a spreadsheet, Word document, README or text file on this computer: .csv, .tsv, .xlsx, .docx, .md, .markdown, .txt) into a profile, as what its tables and columns mean. Portward reads the file, matches each entry onto a table or column the profile grants and shows the user the mapping; only what they confirm is saved. For entries named differently from the columns, pass |
| share_sign_inA | Confirm the user's email for sharing, once per device: Portward emails them a code, and the user types it where you can't see it (never ask for it in the chat). |
| share_confirmA | Ask the user again for the code Portward emailed them (when the form or page closed before they typed it). Takes no code: the user types it where you can't see it. |
| shareA | Share a pull from history with a teammate by email: the table is encrypted on this machine and the link is shown to the user in the Portward share panel to copy and send (or open in their mail app from there; without a panel a draft opens in their mail app). You never see the link. The teammate opens it with a code emailed to them; it expires after |
| sharesC | List what the user has shared: who with, when, and when each share expires. |
| account_sign_inA | Sign this computer in to the user's Portward Personal account: opens the account page in their browser, where they sign in (emailed code, Google or GitHub) and approve. Then call account_status. Only call it when the user asks to sign in or to use their account. |
| account_statusB | Whether this computer is signed in to the user's Portward account, and as whom. |
| account_deleteA | Open the page where the user can download their Portward account data or delete their account, in their browser. It deletes nothing: the user signs in again there and confirms. Only call it when the user asks to download their account data, delete their account or leave Personal. History on this computer stays. |
| account_sign_outA | Sign this computer out of the user's Portward account (the token is ended on the server and removed from the keychain). |
| account_sharesA | List the shares the user sent from their Portward account's email (every computer), with when each was opened by the person it was shared with and whether it is live, expired or withdrawn. Personal only. |
| withdraw_shareA | Withdraw one of the user's shares: its link stops opening at once and Portward deletes the encrypted copy. Only when the user asks to withdraw (or revoke, unshare) that share. Personal only. |
| set_share_expiryA | Change how long one of the user's live shares lasts: |
| sync_turn_onA | Turn on encrypted sync of history, saved pulls, notes, rules and profiles with the user's other computers (Personal). On the first computer it shows the user a recovery key in their browser; on another it asks the user for that key where you can't see it (never ask for it in the chat). Only call it when the user asks to sync. |
| sync_nowA | Sync history, saved pulls, notes, rules and profiles with the user's other computers now (encrypted; Personal). |
| sync_statusA | Whether sync is on for this computer, when it last ran, and anything it is holding. |
| sync_turn_offA | Stop syncing on this computer. Nothing is deleted, here or on the sync service. |
| sync_new_recovery_keyA | Make a new recovery key for the user's synced data and show it to them in their browser (the old one stops working; the data key is replaced too, and the other computers move over on their next sync). Only when the user asks, e.g. they lost theirs. |
| approve_browserA | Approve the user's browser to build the proof report (what my AI saw) on their Portward account page (Personal, sync on). The user types the code the page shows where you can't see it; never ask for it in the chat. Only call it when the user asks to open or export the report in their browser. |
| web_routesC | List each connection's web routes for claude.ai and ChatGPT on the web: which it may use (files and databases only this computer reaches: direct only) and which it's on. Also hands the hosted engine anything it's missing and brings its AI log in. |
| web_routeA | Put a connection on the 'hosted' route (Portward runs this: works with this computer off; its login and applied profiles go, sealed, to Portward's hosted engine) or the 'direct' route (the AI reaches this computer; Portward never sees your data). Tell the user which, in those words, before choosing hosted. Personal only. |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
| ui://portward/results.html | |
| ui://portward/password.html | |
| ui://portward/share.html |
TDQS
Scored across 77 tools
The core data path (query, rerun, run_saved, tweak, compare, kept_rows) is documented carefully and mostly separable, but with 77 tools several boundaries blur: use_block_rules vs unapply_profile, kept_rows vs panel_rows vs more_rows, assumptions vs define_assumption vs draft_definition, and share vs share_sign_in vs share_confirm. A third of the tools are explicitly app-only (never seen by the model), which trims the practical surface but the remaining set still has clusters where an agent must re-read descriptions to choose.
Everything is snake_case, which is good, but verb conventions vary widely: prefixed verbs (list_sources, get_selection, set_note, remove_source) sit alongside bare verbs (query, tweak, compare, block, share, export) and bare nouns (history, lineage, assumptions, shares, panel_rows, context_drafts). Readable, but not a single predictable pattern an agent can rely on.
77 tools is far past what an agent-facing surface should carry; even discounting the app-only panel/secret tools, the model still faces 60+ options across querying, sharing, profiles, context drafting, sync, account and routing. It behaves like several servers glued together, and the volume itself drives misselection.
Coverage of the domain is genuinely deep: sources (add/test/describe/remove), querying and history, saved pulls, sharing with expiry/withdrawal, profiles and grants, block rules, context drafts and definitions, sync, account, and export/proof reporting. Only minor gaps remain, e.g. no way to delete or prune history entries or a pull's children.