For AI agents: the documentation index is at /llms.txt, and this page is available as Markdown at /cli/overview.md.
True Markets CLI
tm lets you buy, sell, transfer and check balances from your terminal. It's built for developers, strategy builders and AI agents.
Your wallet's private key stays in Turnkey's secure enclave, and the key the CLI signs with never leaves your device.
- The fee is in the quote. A dry run shows it before you confirm.
- The CLI trades the assets in the catalog and resolves the chain from the token symbol. See What you can trade.
- Every command prints JSON with
-o json, so it composes withjqand scripts. - Dry run first. Simulate any trade or transfer before it spends anything.
The CLI trades the same DeFi assets as the Trading API. The credentials differ: the CLI logs you in with an emailed code and keeps your keys on your device, while the Trading API uses an API key file. The institutional CeFi venue has its own credentials and account model, so a login there does not carry over.
Set up the CLI
- Install: one-liner, Homebrew, or a pre-built binary.
- Authenticate:
tm signuportm login, verified by emailed code. - Run a command:
tm assets,tm balances,tm buy. - Wire it to an agent: skills for local agents, MCP for hosted clients.
Make your first trade
--dry-run prices the trade and shows the fee without executing.
$ tm buy SOL 100 --dry-run
Chain: Solana
Asset: SOL
Amount: $100.00
Price: $142.38
Qty: 0.7024 SOL
Fee: $0.20
When the quote looks right, run it again with --force to skip the confirmation prompt.
$ tm buy SOL 100 --force
✓ Order filled: 0.7024 SOL @ $142.38
Add -o json to get output you can pipe.
$ tm balances -o json
[{"asset":"SOL","balance":"0.7024","chain":"solana"}, ...]
Next steps
- Install the CLI: one-liner, Homebrew, or a pre-built binary.
- MCP: per-client setup for the hosted MCP server.
- SDKs: typed TypeScript and Python clients for the Trading API.