ccxt-cli
O que ela faz
Esta skill mostra como usar a ferramenta de linha de comando ccxt para chamar funções de exchanges a partir de um terminal, sem escrever código. Ela é para quem quer acesso rápido a dados ou ações de exchanges.
Quando usar
- ✓Quando você quiser conferir o preço ou o livro de ofertas de uma criptomoeda pelo terminal.
- ✓Quando quiser ver seu saldo na exchange ou suas ordens abertas.
- ✓Quando quiser acompanhar tickers ou livros de ofertas ao vivo no terminal.
Link da skill
https://github.com/ccxt/ccxt/blob/master/.claude/skills/ccxt-cli/SKILL.mdCopie e cole na sua IA (Claude, ChatGPT ou Cursor) pedindo para seguir as instruções.
Como usar
O jeito mais fácil: copie a mensagem e cole na sua IA. Ela lê a skill e segue as instruções.
Mensagem pronta para colar
Para Claude Code, Codex ou Cursor: rode na pasta do projeto e a skill fica instalada.
Baixe o SKILL.md e coloque na pasta de skills do seu agente.
Exemplo do que pedir para a IA
“Mostre o ticker atual do Bitcoin na Kraken pelo meu terminal.”
5 skills novas por semana. 1 minuto de leitura.
Como funciona
Você digita um comando com o nome da exchange e o método, como uma consulta de ticker. A ferramenta chama a exchange e imprime o resultado.
Conteúdo técnico (SKILL.md original)
Texto original do autor, em inglês, direto do GitHub.
CCXT CLI
The CCXT CLI (ccxt-cli on npm) exposes the entire unified CCXT API as a terminal command. Anything you can call in code — fetchTicker, fetchOHLCV, createOrder, fetchBalance, withdraw, exchange-specific implicit methods — you can call as:
ccxt <exchangeId> <methodName> [args...] [options]
It supports 100+ exchanges, REST and WebSocket, public and private endpoints, live terminal dashboards, and interactive OHLCV charts.
Installation
npm install -g ccxt-cli # installs the `ccxt` command
ccxt --help
One-off use without installing (note -p ccxt-cli — the package name differs from the binary name):
npx -y -p ccxt-cli ccxt kraken fetchTicker BTC/USD
From a clone of the CCXT repository (contributor mode — uses the local source tree instead of the published package):
npm run cli.ts -- kraken fetchTicker BTC/USD # runs cli/ts/cli.ts against local ts/
Quick start
# Public data — no API keys needed
ccxt kraken fetchTicker BTC/USD
ccxt kraken fetchOrderBook ETH/BTC
ccxt bybit fetchOHLCV BTC/USDT 15m
ccxt okx fetchTrades BTC/USDT
# Private data — needs API keys (see Authentication)
ccxt kraken fetchBalance
ccxt binance fetchOpenOrders BTC/USDT
# Place an order (start with --sandbox and small amounts!)
ccxt binance createOrder BTC/USDT limit buy 0.001 60000 --sandbox
Every run prints the CCXT version, the resolved call (e.g. kraken.fetchTicker ("BTC/USD")), the result, and timing. Use --raw to suppress everything except the JSON result.
Discovering methods and arguments
ccxt --help # all options, commands, and the config path for your OS
ccxt methods kraken # every method the exchange supports (its `has` capabilities)
ccxt explain createOrder # required/optional arguments for any unified method
ccxt history # your previously executed commands
ccxt explain <method> output shows the argument order you must follow:
Method: createOrder
Usage:
binance createOrder <symbol> <type> <side> <amount> [price] [params]
Arguments:
- symbol (required) — Market symbol e.g., BTC/USDT
- type (required) — e.g., limit or market
- side (required) — order side e.g., buy or sell
- amount (required)
- price (optional) — Price per unit of asset e.g., 26000.50
- params (optional) — Extra parameters for the exchange
Argument rules (important)
Arguments are positional and must follow the method's signature order. The CLI auto-converts each argument:
| You type | The method receives |
|---|---|
BTC/USDT |
string 'BTC/USDT' |
0.001, 100 |
number |
undefined |
undefined (placeholder to skip an optional arg — the call echo displays it as null, which is expected) |
true / false / null |
boolean / null |
"2025-05-01T01:23:45Z" |
milliseconds timestamp (ISO8601 datetimes auto-convert; date-only strings like 2025-05-01 do NOT — include the time part) |
'{"recvWindow":5000}' |
object (JSON must be shell-quoted) |
'["BTC/USDT","ETH/USDT"]' |
array (shell-quoted) |
Rule 1 — pad skipped optionals with undefined. To pass limit without since:
ccxt binance fetchOHLCV BTC/USDT 1h undefined 10 # since=undefined, limit=10
Rule 2 — --param key=value appends to the trailing params object. Repeat it for multiple keys. Values are coerced the same way (true, false, null, numbers, strings):
ccxt binance createOrder BTC/USDT market buy 0.01 undefined --param test=true --param clientOrderId=myOrder
Rule 3 — when using --param, explicitly fill ALL earlier optional positionals with undefined. If you leave gaps, the CLI mis-assigns arguments (a known quirk — the params object can end up in the wrong position). Correct:
ccxt bybit fetchOHLCV BTC/USDT 15m undefined undefined --param until=1722161166530 # ✅
ccxt bybit fetchOHLCV BTC/USDT --param until=1722161166530 # ❌ args get scrambled
Authentication
Private methods (fetchBalance, createOrder, fetchMyTrades, ...) need credentials. Three sources:
1. Environment variables
Pattern: <EXCHANGEID>_<CREDENTIAL> upper-cased. The credential names come from each exchange's requiredCredentials (apiKey, secret, password, uid, walletAddress, privateKey, ...):
export BINANCE_APIKEY=your_api_key
export BINANCE_SECRET=your_s
Perguntas frequentes
Como instalo a ferramenta?
A skill manda instalar globalmente o pacote ccxt-cli pelo npm, que fornece o comando ccxt.
Preciso de chaves de API?
Dados públicos não precisam de chaves, mas dados privados, como saldos, precisam de chaves de API.
Existe uma forma segura de testar ordens?
A skill recomenda a opção de sandbox e valores pequenos ao fazer ordens.
Detalhes
Descrição original do autor
CCXT command-line interface (ccxt-cli) for interacting with 100+ cryptocurrency exchanges directly from the terminal — no code required. Covers installing the CLI, calling any unified CCXT method (fetchTicker, fetchOHLCV, createOrder, fetchBalance), passing arguments and exchange-specific params, authenticating with API keys, sandbox/testnet mode, streaming live tickers and orderbooks over WebSocket, plotting OHLCV charts, and scripting with raw JSON output. Use when the user wants to query an exchange, test API credentials, place or inspect orders, or debug exchange requests from the command
repo: ccxt/ccxt
Popularidade
- Estrelas no GitHub
- 45 mil
- Posição no ranking
- #6379
- Licença
- MIT
- Atualizada em
- 02/11/2026
Comentários
- …
Mais skills deste repositório
binance-agentic-wallet
45 milPermite que seu agente gerencie uma carteira Web3 da Binance pela linha de comando baw, incluindo login, saldos, transferências, trocas de tokens e ordens limitadas.
binance-sports-ai-analyzer
45 milAjuda seu agente a consultar previsões de partidas da Copa do Mundo, análises de IA e insights de notícias, e recalcular as probabilidades de vitória depois que você ajustar os sinais.
binance-tokenized-securities-info
45 milPermite que seu agente consulte ações tokenizadas dos EUA da Ondo na Binance Web3, cobrindo listas de tokens, informações das empresas, status de negociação e preços on-chain.
binance
45 milPermite que seu agente use Binance Spot, USD-M Futures e Convert pela ferramenta binance-cli. Exige que você configure a autenticação antes.
Skills parecidas
api-connector-builder
280 milFaz seu agente construir novas conexões com APIs seguindo o padrão já existente. Use quando precisar adicionar mais uma integração sem criar um novo jeito de fazer.
api-design
280 milAjuda seu agente a projetar APIs REST seguindo as melhores práticas. É útil para definir como as APIs se comunicam, como os erros são mostrados e como organizar os dados.
backend-patterns
280 milAjuda seu agente com padrões de arquitetura do lado do servidor e otimização de banco de dados. É útil para construir ou revisar o código que roda no servidor.