#!/usr/bin/env bash # Optional smoke check: POST one minimal event to the ingest API. # Usage: # export INGEST_API_BASE=http://127.0.0.1:3210 # export INGEST_API_TOKEN= # ./scripts/examples/ingest_smoke.sh set -euo pipefail : "${INGEST_API_BASE:?set INGEST_API_BASE}" : "${INGEST_API_TOKEN:?set INGEST_API_TOKEN (project ingest key)}" BODY='{"events":[{"schema_version":1,"occurred_at":"2026-04-02T12:00:00.000Z","level":"error","message":"ingest_smoke.sh probe"}]}' curl -sf --max-time 30 -X POST "${INGEST_API_BASE}/v1/ingest/events" \ -H "Authorization: Bearer ${INGEST_API_TOKEN}" \ -H "Content-Type: application/json" \ -d "${BODY}" >/dev/null echo "ingest_smoke: ok"