Skip to main content

node

Attribute Macro node 

Source
#[node]
Expand description

Marks a function as a XERV node.

§Attributes

  • namespace: The node namespace (e.g., “std”, “plugins”)
  • name: The node name (e.g., “switch”, “fraud_model”)

§Example

ⓘ
#[xerv::node(namespace = "std", name = "slack_post")]
pub async fn run(
    ctx: Context,
    cfg: SlackConfig,
    input: AlertInput
) -> Result<NodeOutput> {
    // Node logic here
    Ok(NodeOutput::out(ptr))
}