HTTP JSON
HTTP JSON is the simplest authenticated sender path. It accepts one JSON object or an array through TLS port 443.
Prerequisites
Section titled “Prerequisites”- An active HTTP JSON receiver.
- Its exact receiver URL.
- A token bound to that receiver with
ingest:write.
Send one event
Section titled “Send one event”export FLUXTAIL_RECEIVER_URL='https://ingest.fluxtail.io/v1/receivers/RECEIVER_ID/logs'export FLUXTAIL_TOKEN='ftl_RECEIVER_BOUND_TOKEN'
curl --fail-with-body -X POST "$FLUXTAIL_RECEIVER_URL" \ -H "Authorization: Bearer $FLUXTAIL_TOKEN" \ -H 'Content-Type: application/json' \ -d '{ "message": "order accepted", "severity": "INFO", "service_name": "checkout", "host": "api-1", "labels": {"environment": "production"} }'Success is HTTP 202 with {"accepted":1}. For a batch, send a JSON array; accepted is the number of accepted objects.
Verify
Section titled “Verify”Open Live Tail for the receiver’s stream and search for order accepted. Confirm the service, severity, host, and labels.
Troubleshooting
Section titled “Troubleshooting”- Use the receiver URL exactly as copied. Do not add
/logsto an already complete URL. - A token for another receiver is rejected.
- Use
Content-Type: application/json. - Split large batches if the edge returns
413.
See the Ingest API reference for status codes and payload details.