# Spikelog > Spikelog stores numeric metrics as charts and alerts when a chart spikes, drops or goes quiet. Charts are created on the first value. Built for side projects and small apps; set it up with one API call per metric. Base URL: https://api.spikelog.com Auth for writes: header `X-API-Key: sk_...` (one key per project, from the project settings page in https://spikelog.com/dashboard). ## Send data - `POST /api/v1/ingest` body `{"chart": "signups", "value": 1}`. Optional `timestamp` (ISO 8601) and `tags` (object, max 4KB). 401 bad key, 422 bad body, 429 chart limit reached. - `POST /api/v1/ingest/batch` body `{"points": [ ...up to 100 of the above ]}` returns `{"success", "accepted", "rejected": [{"index", "chart", "error"}]}`. Patterns: - Measurement: send the actual value (`checkout_ms` = 234). - Counter: send 1 per event (`signups`); the user can switch the chart to Cumulative mode for a running total. - Gauge: send the current value on a schedule (`queue_depth`). - Heartbeat: send 1 every time a cron job or worker runs (`nightly_backup`), so "gone quiet" alerts fire if it stops. ## Client libraries Node / TypeScript (`npm install spikelog`), zero dependencies, never throws: ```js import { init, log, increment, gauge, flush } from "spikelog" init({ apiKey: process.env.SPIKELOG_API_KEY }) increment("signups"); log("checkout_ms", 234); gauge("queue_depth", 12) await flush() // in serverless functions, before returning ``` Python (`pip install spikelog`), stdlib only: ```python import spikelog spikelog.init() # reads SPIKELOG_API_KEY spikelog.increment("signups"); spikelog.log("checkout_ms", 234); spikelog.gauge("queue_depth", 12) ``` ## Alerts (on by default for every chart) - Spike / drop: value far outside the chart's last 200 points (median + MAD, needs 30 points, and at least 20% from typical). - Gone quiet: current gap much longer than the chart's usual gap (needs 10 points; minimum 15 minutes). - Limits: optional fixed above / below values. Delivered by email; Pro adds Slack, Discord, ntfy and HTTPS webhooks. A digest email goes out on Mondays. ## MCP server `claude mcp add --transport http spikelog https://api.spikelog.com/mcp --header "Authorization: Bearer sk_..."` Tools: log_metric, list_charts, get_chart, list_alerts, explain_change (compare the last N hours with the previous N hours), set_alert_limits. ## Public charts Public charts and projects have SVG badges and sparkline cards: - `/api/v1/public/badge/c/{chart_slug}.svg?period=7d&label=...` - `/api/v1/public/spark/c/{chart_slug}.svg?theme=dark&period=30d` - `/api/v1/public/badge/p/{project_slug}/{chart_name}.svg` ## Limits Free: 10 charts, 1,000 recent points per chart, email alerts, 1 connected source. Pro ($6/month): 100 charts, 10,000 points, all alert channels, 20 sources. Daily summaries are kept forever on both. Docs: https://spikelog.com/docs Example public dashboard (Spikelog's own metrics): https://spikelog.com/p/spikelog Status: https://spikelog.com/status Contact: hello@spikelog.com