Skip to main content

Module set_vars

Module set_vars 

Source
Expand description

Derived variables plugin (set-vars, featherbit-native): pull values out of the context — a path segment, a header, a query parameter, a JSON body field — optionally through a JSONPath and/or a regex capture, and store them in context.message so every downstream node can read them as $msg_<name> / {{message.<name>}}.

Always pass-through: wire success onward; the error port is never taken. Malformed regexes and JSONPaths reject the policy at compile time.

Structs§

SetVarsPlugin
Evaluates every rule in order and writes each result into context.message[name] as a string. Later rules see earlier results ($msg_<name>), so rules can build on each other.
VarRule 🔒

Enums§

Group 🔒
Which regex capture becomes the value.

Constants§

ALLOWED_KEYS 🔒

Functions§

json_nodes_text 🔒
Text for a JSONPath selection: one scalar → its text, one container → its JSON, several nodes → a JSON array; nothing → None.
str_field 🔒