Quick Setup Start Here
Terminal / CLI
pip install in seconds, run from any shell or script
Claude Code
Agentic CLI — Claude runs ka commands autonomously in your terminal
OpenAI Codex CLI
OpenAI's agentic terminal assistant with native shell execution
Cursor IDE
AI-assisted coding with live market data in your editor
MCP Protocol
Universal AI tool standard — works with any MCP client
Claude (Anthropic)
Claude API tool use, Claude Desktop via MCP
OpenAI
Responses API with MCP or function calling
Bash / Shell Agents
curl + cron pipelines, no frameworks needed
HTTP / REST API
One HTTPS endpoint for serverless functions and other languages
ClawHub / OpenClaw
Install the KlickAnalytics skill for OpenClaw agents
NemoClaw
OpenClaw agents in NVIDIA sandboxes, with the KlickAnalytics skill
Setup at local machine
- FREE Register at klickanalytics.com/signup
- Generate your key from API Keys / Account Page
Terminal / Command Line CLI
The simplest way to use KlickAnalytics. Install once, run from any shell — bash, zsh, PowerShell, or Windows CMD.
Step 1 — Check if Python & pip are installed
Open your terminal (macOS/Linux) or Command Prompt / PowerShell (Windows) and run:
If either command is not found, install Python first:
- macOS: Install via Homebrew —
brew install python3 - Windows: Download the installer from python.org/downloads — check "Add python.exe to PATH" during install
- Linux (Ubuntu/Debian):
sudo apt update && sudo apt install python3 python3-pip - Linux (RHEL/CentOS):
sudo yum install python3 python3-pip
python3 and pip3 instead of python / pip on some systems.Step 2 — Install KlickAnalytics CLI
To upgrade an existing installation:
Step 3 — Set your API Key (safely)
There are several ways to store your API key. Choose the method that matches your setup:
- Never paste your API key directly into code files or notebooks that you share
- Never commit your key to git — add
.envand any config files to.gitignore - Use separate keys for development and production if possible
- Rotate your key from the API Keys page if you suspect it was exposed
Step 4 — Verify & Explore
-datatype json to any command for machine-readable JSON output — great for piping into scripts or other tools. Example: ka prices TSLA -datatype jsonClaude Code Agentic CLI
Claude Code is Anthropic's agentic coding tool. It runs in your terminal and can execute shell commands, so once the KlickAnalytics CLI is installed Claude Code can call ka directly — no plugins required.
Install
macOS, Linux or WSL:
Windows PowerShell:
Then install the KlickAnalytics CLI and set your key as described in Terminal / Command Line:
Sign in
Run claude and sign in with your Claude account (Pro, Max, Team or Enterprise) or an Anthropic Console account. No Anthropic API key is needed for a subscription sign-in; the only key Claude Code needs from you is KLICKANALYTICS_CLI_API_KEY.
How it works
When you ask a market question, Claude Code runs ka commands with its Bash tool, reads the output and answers. It asks for your permission before running a command it has not been allowed to run yet.
Example prompts (run inside claude)
CLAUDE.md — project context
Add a CLAUDE.md file to your project root so Claude Code always knows about KlickAnalytics:
claude -p runs a single prompt non-interactively, which is useful in scripts: claude -p "Get the TSLA quote with ka and return just the price". Prefer tools over shell commands? Connect KlickAnalytics as an MCP server instead.OpenAI Codex CLI Agentic CLI
Codex CLI (codex) is OpenAI's agentic terminal assistant. Like Claude Code it runs shell commands, so it can call ka — once it is allowed to reach the network.
Install
or on macOS: brew install --cask codex. Run codex and choose Sign in with ChatGPT, or sign in with an OpenAI API key.
Allow network access (required)
Codex runs commands in a sandbox that blocks outbound network access by default, and ka needs to reach the KlickAnalytics API. Add this to ~/.codex/config.toml:
Usage
AGENTS.md — standing instructions
Codex reads AGENTS.md from your project root, and ~/.codex/AGENTS.md for every project:
Cursor IDE IDE Integration
Cursor is an AI code editor. Run ka in its integrated terminal alongside your code, or let Cursor's Agent run the commands for you.
Terminal
Open the integrated terminal (Ctrl+`) and run any ka command:
Agent
Open Agent (Cmd+I on macOS, Ctrl+I on Windows/Linux) and ask a market question. The Agent can run ka in the terminal and reason over the output.
Project rules
Cursor reads AGENTS.md in your project root, or a rule in .cursor/rules/. Create .cursor/rules/klickanalytics.mdc so every Agent session knows the commands:
.cursorrules file is legacy — use .cursor/rules or AGENTS.md for new projects.MCP — Model Context Protocol New
MCP is the open standard AI apps use to connect to outside tools. KlickAnalytics runs a hosted MCP server, so any MCP client can search, read and run the same 160+ commands as the CLI — nothing to install on the KlickAnalytics side.
Server details
- Use your CLI API key from the API Keys page — it is the same key.
- MCP access is included with paid plans. A key from a free account is refused with an upgrade message.
- Send the key in the header. Do not put it in the URL, where it ends up in logs and history.
Tools the server exposes
search_endpoints— find the right command for a questiondescribe_endpoint— read how a command is used, with examplescall_endpoint— run it and return the result (commands that change your account, such as watchlist edits, requireconfirm)
Claude Code
Check the connection with claude mcp list, or /mcp inside Claude Code.
Claude Desktop
Claude Desktop reaches remote servers through the mcp-remote helper, which needs Node.js. Open Settings → Developer → Edit Config and add:
Authorization:${AUTH_HEADER} with no space after the colon. Quit and reopen Claude Desktop after saving.OpenAI Codex CLI
Or add it to ~/.codex/config.toml:
Claude API and OpenAI API
Both APIs can connect to the server on your app's behalf:
- Claude API — MCP connector: server URL above, API key in
authorization_token. - OpenAI Responses API —
mcptool: server URL above, key inheadersasAuthorization: Bearer …, sent with every request.
What You Can Do via MCP
- Ask: "What were TSLA's last 8 earnings beats/misses?"
- Ask: "Run technical analysis on NVDA and summarise the signals"
- Ask: "Compare the 30-day volatility of AAPL, MSFT, and GOOGL"
- Ask: "Build a correlation matrix for SPY, QQQ, TLT and GLD"
- Ask: "How risky is SPY? Give me volatility, max drawdown and value at risk"
Claude by Anthropic AI Agent
There are three ways to give Claude KlickAnalytics data, depending on where you use Claude:
- In your terminal — Claude Code runs
kacommands directly. - In the Claude Desktop app — connect the MCP server.
- In your own application — use the Claude API, either with the MCP connector (see MCP) or with tool use, below.
Claude on claude.ai in the browser cannot run commands on your computer.
Claude API + tool use (Python)
Give Claude a tool that runs ka on your machine. The SDK's tool runner calls the tool whenever Claude asks and feeds the output back until Claude has an answer.
OpenAI AI Agent
In the terminal, use Codex CLI. In your own application, use the OpenAI Responses API — either with the KlickAnalytics MCP server or with function calling.
Method 1 — Responses API + MCP server
OpenAI connects to the KlickAnalytics MCP server for you (paid KlickAnalytics plans). OpenAI does not store the key, so send the tool with every request.
Method 2 — Responses API + function calling (Python)
Define a function that runs ka locally, then loop until the model stops asking for it:
Bash & Shell Script Agents Scripting
The simplest possible agent: a bash script that calls ka, captures the output, and sends it to an LLM API with curl. No frameworks — just the CLI, curl and jq (which builds the JSON safely, whatever the output contains).
One symbol, one commentary (OpenAI)
Morning briefing (Claude)
Schedule it with cron
cron does not load your shell profile, so set the keys at the top of the crontab (crontab -e):
JSON output for scripts
Add -datatype json to a command and pipe it into jq or Python:
ka writes the error to stderr and exits with a non-zero code — so set -e stops a script at the first failed command instead of sending an error message to the model.HTTP-Based Agents REST / API
Where you cannot install the CLI — serverless functions, cloud workers, other languages — call the same API the CLI uses. Every ka command works: send the command text, get its output back.
Endpoint & authentication
The command's output is in stdout. On an error — missing or invalid key, unknown command, bad arguments — ok is false and stderr says why.
Example — curl
Python — requests
Node.js (18+)
AWS Lambda / cloud function
KLICKANALYTICS_CLI_API_KEY in your platform's secret store (AWS Secrets Manager, GCP Secret Manager, Vercel environment variables) — never in function source or in a browser app, where anyone could read it.OpenClaw & ClawHub Skill
OpenClaw is an open-source AI agent, and ClawHub is its skill registry. The KlickAnalytics skill teaches an OpenClaw agent the ka commands: klickanalytics-cli on ClawHub.
Step 1 — Install the CLI on the machine running OpenClaw
Step 2 — Install the skill
Add --global to make it available to all your agents.
Step 3 — Add your API key
In ~/.openclaw/openclaw.json, add the key under the skill's entry (merge it into your existing skills section if you have one):
Using it
Your OpenClaw agent can now run ka commands. Example prompts:
- "Fetch AAPL earnings for the last 4 quarters and identify the trend"
- "Run technical analysis on NVDA and tell me if it's overbought"
- "Get volatility metrics for SPY, QQQ, and IWM side by side"
- "Build a correlation matrix for SPY, TLT and GLD"
NemoClaw Agent
NemoClaw is NVIDIA's open-source stack for running OpenClaw agents inside secure OpenShell sandboxes, with policies for network, filesystem and process access. The KlickAnalytics skill works the same way as in OpenClaw, with one extra step: the sandbox must be allowed to reach the KlickAnalytics API.
Step 1 — Install NemoClaw and create an agent
Then run nemoclaw onboard and follow the prompts.
Step 2 — Install the KlickAnalytics skill in the sandbox
Download the skill from ClawHub, then install that folder into your agent's sandbox:
Step 3 — Allow network access to KlickAnalytics
Sandboxes block outbound connections by default. Allow api.klickanalytics.com on port 443 with a custom policy preset (nemoclaw <agent-name> policy add --from-file <preset>.yaml), or approve the blocked request in the OpenShell terminal UI when the agent first runs ka. See NVIDIA's guide to network policies for the preset format.
Step 4 — Provide your API key
The ka command inside the sandbox reads KLICKANALYTICS_CLI_API_KEY. Supply it through NemoClaw's credential settings rather than writing it into the skill folder.
Use cases
- Morning market briefing on a schedule
- Earnings season monitoring for a watchlist
- Portfolio risk checks with alerts
- Peer comparison & relative strength ranking
Ask the market a question. Get a calculated answer.
The AI is not a chatbot bolted onto a document store. It calls the same analytics engine that powers every screen on this platform — so what comes back is a number it computed from raw history, with the command that produced it.
86,000+ instruments
Global equities, ETFs, funds, options, FX, commodities, crypto, economics, filings, transcripts and news — one normalised symbol universe with adjusted history.
A real analytics engine
Screening, backtesting, technicals, options analytics, correlations, seasonality and factor models — computed on demand from raw prices, never a stale cache.
It shows its working
Answers arrive with the charts, tables and tool calls behind them, so you can check the number instead of trusting a paraphrase.
Your own documents
Upload filings, decks and research. Ask across them and the answer cites the page it came from.
Agents and workflows
Multi-step research that runs the platform's tools for you — screen, pull the history, compute, compare, then write it up.
MCP, CLI and API
The same command catalogue from Claude, your own agent, a shell or your pipeline. The answer on screen is the answer your job gets at 4am.
You ask
“How does NVDA usually trade through earnings?”
It calls
→ ka.options_expected_move(NVDA)
It answers
NVDA has averaged a 9.2% absolute move on the day after earnings and closed higher 67% of the time. Two in three reactions land between −4.2% and +16.3% — the distribution is skewed right, not symmetric.
Every figure computed live from our own history — not scraped, not summarised.
Or start with