CubeCobra MCP Server
Local setup
Running locally
Or, for iterating in TypeScript:
Environment configuration
The server uses optional environment variables:
CUBECOBRA_BASE_URL— override the base URL (defaults tohttps://cubecobra.com).CUBECOBRA_COOKIE— your CubeCobra session cookie (needed for private/owner-only endpoints).CUBECOBRA_CSRF— CSRF token to accompany the cookie for POSTs.DEFAULT_CUBE_SHORT_ID— fallback short ID for cube tools (list/csv/json/plaintext).DEFAULT_CUBE_ID— fallback cube UUID for records tools.DEFAULT_RECORD_ID— fallback record ID for record page/data tools.
Persisting secrets locally
To avoid retyping these on every run, create a local env file (not committed) and load it when you start the server. For example, create .env.local in the project root:
Then start with:
Make sure .env.local is in your .gitignore to keep secrets out of version control.
Notes on CubeCobra auth
Auth is only required for endpoints like
list_cube_records; public tools (list, csv, json, plaintext) work without auth.The CSRF token can be copied from the
x-csrf-tokenheader of a successful POST in the browser’s Network tab when logged in.