Coding agents speak SQL. The schema fits in a prompt: 100+ queryable fields (e.g. RSI, gaps, volume spikes, 52-week highs), no joins, no window functions. Hand off the loop: your agent composes the query, backtests against history, and wires the webhook once the edge looks real.
agent workflow
The grammar is restricted on purpose: a flat WHERE clause over named columns and flags. No surprises, no SQL dialect ambiguity, no schema introspection round trips. The agent reads the schema once, composes the query, and runs the same surface a human dev would use.
-- agent-generated from:
-- "find oversold names bouncing
-- today on heavy volume"
rsi_oversold
AND volume_unusual_2x
AND day_change_pct > 0| ticker | rsi_14 | relative_volume | day_change_pct |
|---|---|---|---|
| SOFI | 28.4 | 2.8× | +2.1% |
| PLTR | 29.1 | 3.4× | +3.8% |
| SQ | 27.6 | 2.1× | +1.4% |
| NET | 29.7 | 2.6× | +2.9% |
prompts → outcomes
Your users ask in English, you don’t need to write SQL, the agent does the rest. Same prompts on different stacks — only the Tickerbot column produces an actual answer.
| You ask | Claude alone | Claude + raw data API | Claude + Tickerbot |
|---|---|---|---|
| "Find oversold semis above their 200-day on heavy volume." | No live market data. Can't answer. | Pulls OHLCV per ticker, writes RSI math, paginates the sector universe. Slow, error-prone, and the agent has to invent thresholds. | One /scan call: sector='Semiconductors' AND rsi_oversold AND above_sma_200 AND volume_unusual_2x |
| "Tell me when NVDA breaks out on 2× average volume." | Can't watch markets in real time. | Agent has to build a polling loop or run its own cron. State management lives in the agent. | One /webhooks subscription with that WHERE clause. We POST when it fires. |
| "Did this momentum strategy work last year?" | No historical data access. | Backtest loop in Python — agent has to track point-in-time carefully or get lookahead bias for free. | Same query plus ?asof=YYYY-MM-DD in a loop. Point-in-time clean by default. |
why this works
100+ queryable fields: numeric columns plus named boolean flags. The whole API surface loads into a Claude or GPT context window with room to spare for instructions.
Flat SQL grammar over a single wide row per ticker. Agents don’t need to model relationships or pick a join strategy, so they can’t hallucinate dialect.
RSI, MACD, ATR, Bollinger Bands, SMAs — all queryable as columns. The agent never has to write moving-average math or keep its own price-history buffer.
Your agent and your dev team query the same surface. Whatever the agent builds, you can read, edit, or hand back to a human reviewer.
the agent’s toolbelt
The whole API fits in a tool-call schema. Your agent picks whichever endpoint serves the current task.
/v2/scanCompose any SQL filter; get the matching tickers. The agent’s default screening tool.
Docs →/v2/tickers/{ticker}Get every field and flag for one ticker. Useful when the agent has narrowed down a candidate.
Docs →/v2/signals/.../historyTime series for context. Agents can fetch indicator history to ground their reasoning.
Docs →/v2/webhooksAgent can set up its own watch list. Subscribe a query, get pushed when conditions fire.
Docs →drop-in starter
Anthropic tool-definition format below. Works with Claude, Cursor, Continue, Cline, or any agent framework that accepts Anthropic-style tool schemas. OpenAI function-calling shape is structurally identical — same field names, same JSON Schema.
{
"name": "tickerbot_scan",
"description": "Scan the live US equity + crypto universe against a SQL WHERE clause. ~12,000 tickers, recomputed every minute. Numeric columns (rsi_14, macd_histogram, volume, market_cap, day_change_pct, ...) plus named boolean flags (rsi_oversold, breakout, gap_up_3pct, volume_unusual_2x, above_sma_200, ...). No joins, no window functions.",
"input_schema": {
"type": "object",
"properties": {
"q": {
"type": "string",
"description": "SQL WHERE clause referencing fields by name."
}
},
"required": ["q"]
}
}ship it