Install for OpenCode
Add the server to opencode.json in a project root, or
~/.config/opencode/opencode.json for a global install:
{ "$schema": "https://opencode.ai/config.json", "mcp": { "persql": { "type": "remote", "url": "https://mcp.persql.com", "enabled": true } }}OpenCode connects over remote MCP and runs the OAuth flow on the first tool call — sign in, pick a workspace, and the token is stored automatically. No header to paste.
Bearer fallback
Section titled “Bearer fallback”If your OpenCode build doesn’t drive interactive OAuth for remote
servers yet, create a psql_live_… token under
console.persql.com → API tokens and
pass it as a header:
{ "mcp": { "persql": { "type": "remote", "url": "https://mcp.persql.com", "enabled": true, "headers": { "Authorization": "Bearer psql_live_…" } } }}What you get
Section titled “What you get”About sixty SQL-shaped tools. The full list is in the MCP reference.