Three ways to get Kronos forecasts into your agent. Use our API, install the free skill, or run the model yourself. Pick the one that fits.
Live today: BTC-USD and ETH-USD, 1h candles. Coming soon: stocks, ETFs, forex. Payments: live in USDC on Base and Solana mainnet. Live payment activity: /stats.
1. Use the API
No signup and no API key. Start free, then pay per call when you need the latest forecast.
| Endpoint | What you get | Price |
|---|---|---|
GET /api/v1/forecast?symbol=BTC-USD&tf=1h |
Latest hourly fact list: direction, chance up, median move, 80% band, invalidation level, strike shares, per-step percentiles | $0.02 via x402 |
GET /api/v1/sample?symbol=BTC-USD&tf=1h |
The same fact list, at least 2 hours old | Free |
GET /api/v1/chart?symbol=BTC-USD&tf=1h |
Per-step percentiles for drawing the forecast, at least 2 hours old | Free |
GET /api/v1/health |
Data freshness, worker status, payment network mode | Free |
Symbols: BTC-USD, ETH-USD. Timeframe: 1h.
Machine-readable docs: /openapi.json · /llms.txt · /llms-full.txt · /.well-known/x402
Try it now:
curl "https://quantx402.app/api/v1/sample?symbol=BTC-USD&tf=1h"
# The paid endpoint answers 402 + a PAYMENT-REQUIRED header (base64 JSON) until you pay:
curl -i "https://quantx402.app/api/v1/forecast?symbol=BTC-USD&tf=1h"
You're never charged for errors. Unsupported symbols, missing forecasts, and forecasts that are 2+ candles old return 4xx/5xx and the payment isn't settled.
2. Pay per call with x402
When you call /api/v1/forecast without paying, it answers HTTP 402 with a PAYMENT-REQUIRED header: the price (20000 USDC base units = $0.02), the accepted networks, and the pay-to address. Your client signs a USDC payment, retries with a PAYMENT-SIGNATURE header, and gets 200 with the JSON plus a PAYMENT-RESPONSE receipt.
// npm i @x402/fetch @x402/core @x402/evm viem
// Pays real USDC on Base mainnet: use a dedicated agent wallet with a small balance
import { wrapFetchWithPayment, x402Client } from "@x402/fetch";
import { ExactEvmScheme } from "@x402/evm/exact/client";
import { privateKeyToAccount } from "viem/accounts";
const client = new x402Client();
client.register("eip155:8453", new ExactEvmScheme(privateKeyToAccount(process.env.EVM_PRIVATE_KEY)));
const payFetch = wrapFetchWithPayment(fetch, client);
const res = await payFetch("https://quantx402.app/api/v1/forecast?symbol=BTC-USD&tf=1h");
const facts = await res.json();
console.log(facts.direction, facts.prob_up, facts.band_80_pct, facts.invalidation_level);
Payments run on Base mainnet (eip155:8453) and Solana mainnet (solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp). To pay from Solana, also register ExactSvmScheme (@x402/svm/exact/client) with a Solana signer for that network. The step-by-step post walks through every request and header.
Good habits: give the agent wallet a small balance, check the decoded price before paying, and keep keys in environment variables, never in code or prompts.
3. Install the free skill
FDWA Kronos agent skill (MIT). It gives an agent the instructions and a script to run Kronos locally on any OHLCV data and return the same fact-list format the API uses. You need no account, and the guide covers the payment side.
4. Run Kronos yourself
Kronos is open source (MIT) by its original authors: paper, code, weights on Hugging Face. QuantX402 isn't affiliated with them. It runs on a CPU, and a GPU makes it faster.
git clone https://github.com/shiyu-coder/Kronos && cd Kronos
python -m venv .venv && source .venv/bin/activate
pip install torch pandas einops huggingface_hub safetensors
from model import Kronos, KronosTokenizer, KronosPredictor
tok = KronosTokenizer.from_pretrained("NeoQuasar/Kronos-Tokenizer-base")
mdl = Kronos.from_pretrained("NeoQuasar/Kronos-small")
p = KronosPredictor(mdl, tok, device="cpu", max_context=512)
pred = p.predict(df, x_timestamp, y_timestamp, pred_len=24, T=1.0, top_p=0.9, sample_count=1)
Pitfalls we hit in testing:
sample_countaverages the paths and returns one line, so you lose the spread. To keep all paths, repeat the series N times inpredict_batchwithsample_count=1.- Use closed candles only, and pass no NaNs. You have to build the future timestamps yourself. For stocks, that means using a market calendar so weekends and overnight hours are skipped.
- Settings change answers. Model size, lookback and temperature can flip the direction. Compare two setups and report it when they disagree.
Running it yourself is free. The API exists for when you'd rather not maintain PyTorch, weights, data feeds, a scheduler and the interpretation layer.
5. Go deeper: Kronos for AI Agents
This guide is free. For the full walkthrough, the PDF Kronos for AI Agents — Teach Your Trading Bot to Read Candles (19 pages, $47 on Gumroad) covers, per its product page: setup in 5 minutes, multi-path forecasts, Alpaca paper trading, agent fact lists, data storage, a sentiment add-on, and Kalshi & Polymarket mapping.
Building a wider AI agent workforce? FDWA's other playbook, AI Agents Money Lab (21 pages, $47), reviews 8 agent systems and includes setups with code and 5 money-making automations.
Educational material, not financial advice. Neither guide promises returns.
QuantX402 forecasts are probabilistic model output for research and education. Not financial advice. Past results do not guarantee future results. Payments are live in USDC on Base and Solana mainnet.