@salesforce/b2c-tooling-sdk / operations/logs / parseLogEntry
Function: parseLogEntry()
parseLogEntry(
firstLine,file,fullMessage,pathNormalizer?):LogEntry
Defined in: packages/b2c-tooling-sdk/src/operations/logs/tail.ts:56
Parses the first line of a log entry to extract timestamp, level, and message.
Expected format: [timestamp GMT] LEVEL context - message Example: [2025-01-25 10:30:45.123 GMT] ERROR PipelineCallServlet|... - Error message
The message field will contain:
- The content portion from the first line (after LEVEL)
- Plus any continuation lines (stack traces, etc.)
Parameters
firstLine
string
First line of the log entry
file
string
File name the entry came from
fullMessage
string
Complete raw message including all lines
pathNormalizer?
(msg) => string
Optional function to normalize paths in the message
Returns
Parsed log entry