log

Writes a line to the agent server's log. Logs stay in your environment and are never sent to Search2o Cloud.

Value

A plain string is logged at info level to the default logger. An object selects the logger and the level:

FieldTypeDefaultDescription
namenameName of the logger.
level"critical" | "fatal" | "error" | "warning" | "info" | "debug""info"The level to log at.
messagerequireddynamic stringMessage to log. This must evaluate to a string.

Example

"log": "{ f'Order {orderId} placed by {sys.userEmail}' }",
"log.audit": {
  "name": "audit",
  "level": "warning",
  "message": "{ f'Override applied to {orderId}' }"
}

Rules

  • The message must evaluate to a string.
  • The agent server's logging configuration decides where the log lines go; see Agent servers.