Logs

Send structured log lines from your app to the Logs page. Logs show what your app sends with traceiq.log(), every custom event you track() (as User actions: the event name plus its first few properties, linked to the session, user and request), exceptions, and a warning whenever TraceIQ rejects one of your SDK deliveries (for example an invalid write key), so you know data isn't arriving.

Already logging with console.log? Turn on autoCaptureConsole: true in the browser SDK (or captureConsole: true in the Node SDK) and console output is forwarded to Logs as well; the console still prints as usual.

Browser / games: entries are buffered, sent in batches, and tagged with the current session (so they link to its replay) and user:

ts
traceiq.log('info', 'Level 3 started', { level: 3 });
traceiq.log('error', 'Level 3 assets failed to load', {
  service: 'game-client',   // optional, defaults to "web-client"
  error,                    // optional Error: its stack is attached
  level: 3,                 // anything else becomes searchable metadata
});

Node: inside traceiq.middleware() each log carries the current request's request and trace IDs, so it appears on that request in the Requests explorer:

ts
const traceiq = new TraceIQ({ projectId: 'YOUR_PROJECT_ID', writeKey, serviceName: 'game-server' });

traceiq.log('warn', 'Matchmaking queue is backing up', { queued: 412 });
await traceiq.shutdown(); // flushes events and logs
levelRequireddebug, info, warn, error or fatal.
messageRequiredUp to 4,000 characters.
serviceOptionalGroups and filters logs by component.
errorOptionalAn Error whose name, message and stack are attached.
…other keysOptionalStored as metadata (up to 16 KB); keys like password or token are redacted.

Any other runtime can post directly to POST https://api.traceiq.run/v1/logs/batch with the x-traceiq-write-key header and a body of { projectId, logs: [{ level, message, … }] } (up to 100 entries).

To read logs from the terminal, use the CLI:

bash
traceiq logs --level error --since 24h
traceiq logs --search checkout --follow