notlogs rocket
notlogs

SDK

Event Fields Reference

Full specification of the structured event schema and metadata objects supported by NotLogs.

Core Event Fields

FieldTypeDescription
messagestringHuman-readable description of the log event
typestring“info” | “error” | “warning” | “metric” | “audit” | “debug” | “success”
importancestring“critical” | “high” | “medium” | “low”
servicestringMicroservice or module name (e.g. “auth-api”)
subsystemstring“db” | “cache” | “queue” | “network”
operationstringFunction or action name (e.g. “stripe_charge”)

Importance Levels

CriticalSev-1 Outages
HighDegraded Actions
MediumStandard Logs
LowVerbose / Trace

Tracking & Security Metadata

interface LogPayload {
  track?: {
    userId?: string;
    sessionId?: string;
    traceId?: string;
    spanId?: string;
  };
  security?: {
    ip?: string;
    userAgent?: string;
    authStatus?: "success" | "failed" | "expired";
    userRole?: "super-admin" | "admin" | "user";
  };
  metrics?: {
    durationMs?: number;
    memoryUsageMb?: number;
    statusCode?: number;
  };
}