CLI
The cs command-line tool — sign in through the browser, mint API keys, write agent configuration, administer connectors and remote MCP servers, tie this computer, call tools from a terminal, and move files in and out of your Drive.
cs runs every command against the same authenticated gateway your agents
use. It needs Node.js 20 or Bun and has no runtime dependencies.
Installing
npm install -g @corespeed/csRun the same command again to update.
Running without installing
Agents and CI jobs can run any command through npx or bunx:
npx @corespeed/cs --help
bunx @corespeed/cs --helpNon-interactive environments
cs login needs a browser, and every other command runs under that sign-in —
the CLI takes no API key, except cs tie with CS_API_KEY
set. For CI and headless agents, mint a key once with
cs keys create and send it directly, as in
the MCP server page; the CLI itself is not part of the
job.
Available commands
login
Sign in through the browser, choose an organization, and store a member session on this machine.
cs login
cs login --org <org-id>Learn more about the login command
logout
Remove the session stored on this machine.
cs logoutLearn more about the logout command
whoami
Show the signed-in user, the active organization, and the permissions you hold there.
cs whoamiLearn more about the whoami command
switch
Change the active organization without signing in again.
cs switch
cs switch <org-id>Learn more about the switch command
token
Print a fresh session JWT for scripts.
cs token
curl https://api.corespeed.io/connectors -H "Authorization: Bearer $(cs token)"Learn more about the token command
keys
Create, list, rotate, and revoke sk-cs- API keys. A key holds no
organization permissions unless you give it ones you hold.
cs keys create production
cs keys create ops --permission keys:org
cs keys list
cs keys rotate <id>
cs keys revoke <id>Learn more about the keys command
mcp-config
Print an mcpServers block for /mcp that carries your session token.
cs mcp-configLearn more about the mcp-config command
connectors
List connectors, open the dashboard to connect one, and manage connected accounts.
cs connectors list
cs connectors connect notion
cs connectors accounts listLearn more about the connectors command
remote
Register and administer your organization's own MCP servers.
cs remote add acme --url https://mcp.acme.internal/mcp --auth oauth
cs remote listLearn more about the remote command
mcp
Find a tool for a task, read its schema, and call it as yourself.
cs mcp search remember facts
cs mcp get memory__search
cs mcp call memory__search '{"query": "rollout window"}'Learn more about the mcp command
drive
Upload, download, list, move, delete and share files in your organization's Drive, with a local file on one end.
cs drive put ./q3.pdf reports/q3.pdf
cs drive get reports/q3.pdf ~/Downloads/
cs drive ls reports/
cs drive share reports/q3.pdf orgLearn more about the drive command
tie
Tie this computer to your organization, so your agents can use its shell, files and local MCP servers, and switch what it shares.
cs tie --name "Hao's MacBook"
cs tie provider shell on --root ~/code
cs tie statusLearn more about the tie command
usage
Show available credit and plan.
cs usageLearn more about the usage command
Output and exit codes
Results go to stdout; prompts, warnings, and errors go to stderr, so
cs token and cs keys list pipe cleanly. A failure is reported as
Error: <message>, and the exit code tells a script what to do about it
without parsing the text:
| Code | Meaning |
|---|---|
0 | Success. |
1 | A usage error, or the request was refused (not found, conflict, invalid input). |
3 | Not signed in, or the session was rejected — run cs login. |
4 | The account cannot do this now: no active organization, payment required, suspended, or the admin role needed. |
5 | CoreSpeed unreachable, rate-limited, or answering badly — retry later. |
6 | A cs mcp call is waiting for a human's approval and has not run. |
A refusal the CLI has no message of its own for prints the API's message with the HTTP status and error code.
When no HTTP answer came back, the message names the network's reason, for
example could not reach CoreSpeed (POST /mcp): fetch failed: other side closed (UND_ERR_SOCKET). Credentials in it are redacted. A connection that
closed after the request went out may still have reached CoreSpeed, so check
before you retry a cs mcp call that changes something.
Environment variables
| Variable | Default | Purpose |
|---|---|---|
CS_CONFIG_DIR | ~/.config/cs | Where the session is stored. A separate directory keeps a separate sign-in, such as a second account. |
DO_NOT_TRACK | unset | Set to 1 to send a bare cs user agent instead of the product/version string. Nothing else changes: authorization and protocol headers remain, and activity, billing, and audit records are unaffected. |
Signing in on a remote machine takes one more: see
cs login.