Ingest Setup

Recommended: Tailstream Agent

Install the Tailstream agent with one command:

curl -fsSL https://install.tailstream.io | bash

The agent will automatically:

  • Discover your log files
  • Configure streaming to your endpoints
  • Handle authentication and retries
  • Monitor logs in real-time

The agent is open source and available at github.com/tailstream-io/tailstream-agent.

Manual Configuration

For users who prefer manual setup, Tailstream accepts log events over HTTP using Newline Delimited JSON.

Manual Setup Steps

  1. Copy your credentials. Use the endpoint URL and token from your stream's setup page in your log shipper configuration.
  2. Configure your log shipper. Refer to the examples below (cURL, Nginx + Vector, Laravel).
  3. Start sending logs. Deploy your configuration and watch your HTTP requests appear in real time.

Required settings

  • Endpoint: https://tailstream.io/api/ingest/{streamId}
  • Authorization: Bearer <INGEST_TOKEN> (signed JWT containing the stream UUID via the stream_id claim)
  • Content-Type: application/x-ndjson
  • Compression (optional): Content-Encoding: gzip

What to send

Send newline-delimited JSON (NDJSON). Each line is one event. Tailstream supports two formats:

Format 1: Direct structured logs

Each line is a JSON object with log fields at the top level:

Field Type Notes
host string Host/service name.
path string Request path or resource.
method string HTTP method.
status integer HTTP status code.
rt number Response time in seconds (e.g., 0.047).
bytes integer Response size.
src string Source identifier (e.g., container id).
ts integer Epoch ms. Auto-generated if not provided.

Format 2: Wrapped logs with metadata

The Tailstream agent uses this format to include source file information:

Field Type Notes
log string Required. The actual log content (plain text or JSON).
filename string Source file path (e.g., /var/log/nginx/access.log).

Both formats are supported and can be mixed in the same stream. Tailstream automatically parses and processes each format appropriately.

Configuration examples

Use the tabs below to see working configurations for cURL, Nginx + Vector, and Laravel. Replace {streamId} and <INGEST_TOKEN> with your values.

Rotate your ingest token regularly and reload your services after updating credentials. For full API details, see the API overview and endpoint reference.

Configuration examples