LogOptions
Defined in: bindings/node/dist/index.d.ts:1030
Specify options for the logger
Properties
Section titled “Properties”level?
Section titled “level?”
optionallevel?:LogLevel
Defined in: bindings/node/dist/index.d.ts:1040
Filter logs by level. Also the level exported to OTLP when otelEndpoint
is set (the appender ships events at this level).
otelEndpoint?
Section titled “otelEndpoint?”
optionalotelEndpoint?:string
Defined in: bindings/node/dist/index.d.ts:1052
OTLP endpoint (e.g. “http://collector:4317”). When set, spans AND logs are exported via OTLP to this endpoint. A downstream OpenTelemetry Collector derives metrics from the spans and forwards the correlated logs.
otelSampleRatio?
Section titled “otelSampleRatio?”
optionalotelSampleRatio?:number
Defined in: bindings/node/dist/index.d.ts:1056
Fraction of root spans sampled, from 0 to 1.
otelServiceName?
Section titled “otelServiceName?”
optionalotelServiceName?:string
Defined in: bindings/node/dist/index.d.ts:1054
Service name attached to exported telemetry.
resourceAttributes?
Section titled “resourceAttributes?”
optionalresourceAttributes?:Record<string,string>
Defined in: bindings/node/dist/index.d.ts:1062
Resource attributes attached to all exported spans (e.g. { “service.instance.id”: “herald-7”, “deployment.environment”: “prod” }). Use these to attribute telemetry to its source.
stdoutLevel?
Section titled “stdoutLevel?”
optionalstdoutLevel?:LogLevel
Defined in: bindings/node/dist/index.d.ts:1046
Level for the stdout console layer only. Defaults to level. Set to warn
to quiet stdout below the OTLP export level — e.g. so a log shipper does not
duplicate logs already exported via OTLP, while OTLP still receives level.
structured?
Section titled “structured?”
optionalstructured?:boolean
Defined in: bindings/node/dist/index.d.ts:1035
enable structured JSON logging to stdout.Useful for third-party log viewers an option so that it does not require being specified in js object.

