Skip to content

Logs

Send structured logs over HTTP, parse them with pipelines, search and watch them live.

Send logs

Logs are sent over HTTPS as JSON, one entry or up to 1,000 entries per request. Create a key with only write logs under Settings › API keys (preset Log ingestion).

curl
curl -X POST https://api.vitalrix.com/api/v1/logs \
  -H "x-api-key: $VITALRIX_API_KEY" \
  -H "content-type: application/json" \
  -d '{"logs":[{"level":"error","service":"my-shop","environment":"production","message":"card declined","traceId":"5b8efff798038103d269b633813fc60c","metadata":{"orderId":"o_123"}}]}'
# {"success":true,"data":{"accepted":1}}

The VitalRix packages for Node.js, Python, Go, Ruby and PHP send your logs for you, linked to the request's trace. Any OpenTelemetry SDK can also send OTLP logs (protobuf or JSON) to https://api.vitalrix.com/api/v1/logs/otlp/v1/logs.

Fields

Log entry fields
FieldRules
messageRequired. Up to 32 KB.
leveldebug, info, warn, error or fatal. Common aliases such as warning, critical and pino's numbers are understood. Default info.
serviceThe service name. Use your application’s slug to link logs to it.
environmentDefault production.
timestampISO 8601 or milliseconds since epoch. Default: when received. Up to 366 days old, at most 24 hours ahead.
traceIdThe OpenTelemetry trace id (32 hex characters) to link the line to its trace.
requestId, spanIdFree text, up to 128 characters.
metadataAny JSON object up to 16 KB. Searchable by key.

Live tail

Switch on Live tail to watch new lines arrive as they are sent, with your filters applied. Pause freezes the view while new lines are counted, so you can read without losing your place.

Reading logs from an AI agent

An AI agent connected through MCP can read your logs: summarize_logs gives lines per service, level and environment and the most common message patterns for a window up to 30 days, and search_logs pages through every matching line (filters, a date range and a cursor). Secrets in log lines are masked before the agent sees them.

Limits and retention

  • Up to 1,000 entries and 5 MB per request.
  • Up to 100,000 entries per minute per organization. Above that, requests get 429 with the number of seconds to wait.
  • How many lines per day and how long they are kept depend on your plan. See Plans and limits.

Something unclear or missing? Open VitalRix and use the in-app setup guides, or read Troubleshooting.