Function event

View as Markdown

Generated from cargo doc --no-deps -p nemo-relay -p nemo-relay-adaptive -p nemo-relay-ffi.

pub fn event(params: EmitMarkEventParams<'_>) -> Result<()>

Emit a standalone mark event under the current or provided scope.

This creates a point-in-time lifecycle event without pushing or popping a new scope.

Parameters

  • name: Event name to emit.
  • parent: Optional explicit parent scope. When None, the current top of stack is used.
  • data: Optional JSON payload recorded on the emitted event.
  • metadata: Optional JSON metadata recorded on the emitted event.
  • timestamp: Optional timestamp recorded on the emitted mark event. When None, the current UTC time is used.

Returns

A Result that is Ok(()) after the event has been emitted.

Errors

Returns an error when the runtime owner check fails or when internal state cannot be read safely.

Notes

Scope-local subscribers attached to ancestor scopes observe the emitted mark event just like scope, tool, and LLM lifecycle events.