On this page
Sommatic Docs
Open portal

Vectry Log

Emits a structured causal event to the Vectry Operational Intelligence Platform.

View as Markdown
Open in
Operations Experimental vectry.log Version 1.0.0 Execution: fire-and-forget

Meant to send one event to the Vectry ingest API (POST <endpoint>/v1/ingest). In the current runtime it leaves through error with logger.debug is not a function right before the request, so no event is sent.

Vectry uses these events to construct a Causal Graph of your system, enabling advanced XAI (Explainable AI), anomaly detection, and root cause analysis. Unlike standard logs, Vectry events are linked by entities and operations to model cause and effect.

Key Concepts:

  • Entity: The noun (e.g., "Order", "User").
  • Operation: The verb (e.g., "Created", "Updated").
  • Context: Payload data that helps explain the event.

Use Cases:

  • Reporting significant business milestones (e.g., "LoanApproved").
  • Logging internal AI reasoning steps (SpikingBrain integration).
  • Tracking distributed system interactions.

How it works

  1. Merges the input item with the resolved config (config wins).
  2. Leaves through error with Missing 'api_key' for Vectry when no API key is available, and with Missing 'operation' when operation is empty.
  3. Builds the event name <system_domain>.<system_entity>.<operation> (both default to default) and the body { dataset, event, level, timestamp, data, tags, source: "sommatic-orchestrator" }, where data is payload plus entity_id and operation.
  4. Calls logger.debug(), which throws; the worker catches it and leaves through error. The step below is not reached today.
  5. Sends the body with Authorization: Bearer <api_key> and returns { port: "success", success: true }.

In a workflow

The node as it appears in a workflow file (draft_nodes[]), and the envelope of a successful run.

{
  "node_id": "node-log-order-shipped",
  "label": "Log order shipped",
  "operator_slug": "vectry.log",
  "operator_version": "1.0.0",
  "config": {
    "api_key": "<vectry_api_key>",
    "endpoint": "https://api.example.com",
    "system_domain": "sales",
    "system_entity": "order",
    "operation": "shipped",
    "system_entity_id": "{{ $json.order_id }}",
    "severity": "info"
  }
}

Configuration

api_key string Required
endpoint string Optional

Default: https://api.vectry.io

system_domain string Optional
system_entity string Optional

Its configuration shows the shared execution settings, but this node does not apply retries (retryOnFail, maxTries) yet. continueOnFail is not applied by any node.

Behaviour in the code

What the implementation does with these keys beyond what the schema says.

api_key
A literal secret: the node has no connection_id, so the key is stored in the flow, its version history and Git.
endpoint
Base URL; /v1/ingest is appended.
operation
Not in the config schema (only in the input contract), but read from the node config or, when unset there, from the input item: operation, system_entity_id, severity (default info), tags (default []) and payload.
payload
The configured payload, or the node input item when none is configured. Its keys are spread into data.

Output ports

success default

Not reached in the current runtime: the logger.debug() call fails first. Shown with the shape the code builds.

Data
{
  "port": "success",
  "success": true
}
error

Every run today. The output is the whole returned object, { port, success, error }.

Data
{
  "port": "error",
  "success": false,
  "error": "logger.debug is not a function"
}

In expressions

What a later node can read from this node's output with $("Vectry Log").item.json.<path> (write your node's label instead of Vectry Log). Editor marks the paths the workflow editor suggests under Previous Nodes (the output contract); Worker marks the paths the worker really returns through success, from the output shown in Ports.

ExpressionEditorWorker
$("Vectry Log").item.json.successboolean= true
$("Vectry Log").item.json.portstringNot suggested by the editor= "success"—

— Worker: The worker returns it but the editor does not suggest it: write it by hand. Keys inside objects can depend on your data or configuration (for example one key per label).

Errors

Message Port Cause and fix
logger.debug is not a function error The worker calls logger.debug(), which the runtime logger does not provide. It happens on every run; there is no configuration that avoids it.
Missing 'api_key' for Vectry error No API key is available for the call. Set api_key.
Missing 'operation' error operation is set neither on the node nor in the input item.
Request failed with status code <status> error Not reached today. It would mean Vectry rejected the event (for example a wrong key or endpoint).

Input contract

operation string Required

Event Name

system_entity_id string Optional

Unique Entity ID

severity string Optional

Allowed values: infowarnerrordebug

payload object Optional

Event Context

tags array<string> Optional

Output contract

success boolean Optional

Contracts (JSON Schema)

The definition exactly as the orchestrator declares it. All is the whole *.definition.js; compare it with the sections above to spot differences between the documentation and the schema. Use it to validate a node before you publish.

{
  "slug": "vectry.log",
  "name": "Vectry Log",
  "category": "ops",
  "version": "1.0.0",
  "description": "Emits a structured causal event to the Vectry Operational Intelligence Platform.\n\n  Vectry uses these events to construct a Causal Graph of your system, enabling advanced XAI (Explainable AI), anomaly detection, and root cause analysis. Unlike standard logs, Vectry events are linked by entities and operations to model *cause and effect*.\n\n  **Key Concepts:**\n  - **Entity:** The noun (e.g., \"Order\", \"User\").\n  - **Operation:** The verb (e.g., \"Created\", \"Updated\").\n  - **Context:** Payload data that helps explain the event.\n\n  **Use Cases:**\n  - Reporting significant business milestones (e.g., \"LoanApproved\").\n  - Logging internal AI reasoning steps (SpikingBrain integration).\n  - Tracking distributed system interactions.",
  "capabilities": [
    "observability",
    "causal-ai",
    "vectry",
    "xai"
  ],
  "config_schema": {
    "type": "object",
    "required": [
      "api_key"
    ],
    "properties": {
      "api_key": {
        "type": "string",
        "title": "Vectry API Key",
        "format": "password"
      },
      "endpoint": {
        "type": "string",
        "default": "https://api.vectry.io",
        "title": "API Endpoint"
      },
      "system_domain": {
        "type": "string",
        "title": "Domain (e.g. Sales)"
      },
      "system_entity": {
        "type": "string",
        "title": "Entity Type (e.g. Order)"
      },
      "execution": {
        "type": "object",
        "title": "Execution Settings",
        "properties": {
          "alwaysOutputData": {
            "type": "boolean",
            "title": "Always Output Data",
            "description": "Always output data, even on error (if configured).",
            "default": false
          },
          "retryOnFail": {
            "type": "boolean",
            "title": "Retry On Fail",
            "description": "Retry the execution if it fails.",
            "default": false
          },
          "maxTries": {
            "type": "integer",
            "title": "Max Retries",
            "description": "Number of retries.",
            "default": 3,
            "displayOptions": {
              "show": {
                "retryOnFail": [
                  true
                ]
              }
            }
          },
          "waitBetweenTries": {
            "type": "integer",
            "title": "Wait Between Retries (ms)",
            "default": 1000,
            "displayOptions": {
              "show": {
                "retryOnFail": [
                  true
                ]
              }
            }
          },
          "continueOnFail": {
            "type": "boolean",
            "title": "Continue On Fail",
            "description": "Do not crash workflow on error.",
            "default": false
          },
          "timeout_ms": {
            "type": "integer",
            "title": "Timeout (ms)",
            "description": "Max execution time for this node before it is killed, in milliseconds. Honored by long-running operators (e.g. OCR/extraction, inline code). Default 300000 (5 min).",
            "default": 300000
          }
        }
      }
    }
  },
  "input_contract_schema": {
    "type": "object",
    "properties": {
      "operation": {
        "type": "string",
        "description": "Event Name"
      },
      "system_entity_id": {
        "type": "string",
        "description": "Unique Entity ID"
      },
      "severity": {
        "type": "string",
        "enum": [
          "info",
          "warn",
          "error",
          "debug"
        ]
      },
      "payload": {
        "type": "object",
        "description": "Event Context"
      },
      "tags": {
        "type": "array",
        "items": {
          "type": "string"
        }
      }
    },
    "required": [
      "operation"
    ]
  },
  "output_contract_schema": {
    "type": "object",
    "properties": {
      "success": {
        "type": "boolean"
      }
    }
  },
  "ports": [
    {
      "port_id": "success",
      "label": "Logged",
      "is_default": true
    },
    {
      "port_id": "error",
      "label": "Error"
    }
  ],
  "execution_mode": "fire-and-forget",
  "tags": [
    "observability",
    "vectry",
    "ai"
  ],
  "is_stateful": false,
  "publisher": {
    "identity": "org_vectry",
    "profile": {
      "name": "Vectry Analytics",
      "verified": true,
      "url": "https://me.veripass.com/vectry",
      "logo_url": null
    }
  }
}

Execution

Execution
fire-and-forget
Stateful
No
Retries (retryOnFail)
No
Capabilities
observabilitycausal-aivectryxai
Tags
observabilityvectryai

Notes and limits

  • The worker calls logger.debug(), which the runtime logger does not provide (it offers info, warning, error, log and success). The call throws on every run.
  • Until it is fixed, send events with io.http to the same ingest endpoint and body.
  • Leaving through error does not fail the run: the engine follows the edges wired to error, and if there are none the branch simply ends.
  • The execution settings (retryOnFail, maxTries, waitBetweenTries, continueOnFail, timeout_ms) are accepted, but neither this worker nor the engine applies them.

Reviewed against the orchestrator code · 31e874b · 2026-11-26

Install agent tools

Give your coding agent the official Sommatic AI docs: skills, the docs MCP server and Markdown pages, so it never has to scrape the site.

Skills only. They do not update by themselves; run it again to refresh.

npx skills add https://docs.sommatic.ai
How agents read these docs