greentic-flow 0.4.36

Generic YGTC flow schema/loader/IR for self-describing component nodes.
Documentation
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "additionalProperties": false,
  "allOf": [
    {
      "if": {
        "properties": {
          "card_source": {
            "const": "asset"
          }
        },
        "required": [
          "card_source"
        ]
      },
      "then": {
        "required": [
          "asset_path"
        ]
      }
    },
    {
      "if": {
        "properties": {
          "card_source": {
            "const": "inline"
          }
        },
        "required": [
          "card_source"
        ]
      },
      "then": {
        "required": [
          "inline_json"
        ]
      }
    },
    {
      "if": {
        "properties": {
          "card_source": {
            "const": "catalog"
          }
        },
        "required": [
          "card_source"
        ]
      },
      "then": {
        "required": [
          "catalog_name"
        ]
      }
    },
    {
      "if": {
        "properties": {
          "card_source": {
            "const": "catalog"
          }
        },
        "required": [
          "card_source"
        ]
      },
      "then": {
        "required": [
          "catalog_item"
        ]
      }
    },
    {
      "if": {
        "properties": {
          "needs_interaction": {
            "const": true
          }
        },
        "required": [
          "needs_interaction"
        ]
      },
      "then": {
        "required": [
          "interaction_type"
        ]
      }
    },
    {
      "if": {
        "properties": {
          "needs_interaction": {
            "const": true
          }
        },
        "required": [
          "needs_interaction"
        ]
      },
      "then": {
        "required": [
          "action_id"
        ]
      }
    },
    {
      "if": {
        "properties": {
          "needs_interaction": {
            "const": true
          }
        },
        "required": [
          "needs_interaction"
        ]
      },
      "then": {
        "required": [
          "card_instance_id"
        ]
      }
    }
  ],
  "properties": {
    "action_id": {
      "default": "action-1",
      "description": "Action id (used for routing/handlers)?",
      "type": "string"
    },
    "asset_path": {
      "default": "assets/cards/incident.json",
      "description": "Asset path (relative path or registry path)",
      "type": "string"
    },
    "card_instance_id": {
      "default": "card-1",
      "description": "Card instance id (unique identifier for this card)?",
      "type": "string"
    },
    "card_source": {
      "default": "asset",
      "description": "Where does the Adaptive Card come from?",
      "enum": [
        "asset",
        "inline",
        "catalog"
      ]
    },
    "catalog_item": {
      "default": "incident_summary",
      "description": "Catalog item/template key",
      "type": "string"
    },
    "catalog_name": {
      "default": "default",
      "description": "Catalog name",
      "type": "string"
    },
    "envelope": {
      "default": {},
      "description": "Optional Greentic invocation envelope metadata.",
      "type": "object"
    },
    "inline_json": {
      "default": {
        "actions": [],
        "body": [],
        "type": "AdaptiveCard",
        "version": "1.3"
      },
      "description": "Paste the Adaptive Card JSON for inline mode",
      "type": "object"
    },
    "interaction_type": {
      "default": "Submit",
      "description": "What kind of interaction should the placeholder use?",
      "enum": [
        "Submit",
        "Execute"
      ]
    },
    "mode": {
      "default": "renderAndValidate",
      "description": "Whether to render, validate only, or both.",
      "enum": [
        "render",
        "validate",
        "renderAndValidate"
      ]
    },
    "needs_interaction": {
      "default": false,
      "description": "Does this card need user interaction (Submit/Execute actions)?",
      "type": "boolean"
    },
    "node_id": {
      "description": "Optional node id used to scope persisted state and helper context.",
      "type": "string"
    },
    "payload": {
      "default": {},
      "description": "Explicit input payload used for binding/expression resolution.",
      "type": "object"
    },
    "raw_inputs": {
      "default": {},
      "description": "Raw inputs placeholder (default empty)",
      "type": "object"
    },
    "session": {
      "default": {},
      "description": "Optional explicit session metadata (not injected by the runner).",
      "type": "object"
    },
    "state": {
      "default": {},
      "description": "Optional explicit state override (persistent state uses state-store).",
      "type": "object"
    },
    "template_params": {
      "default": {},
      "description": "Template params to inject into the card template (optional)",
      "type": "object"
    }
  },
  "required": [
    "node_id"
  ],
  "type": "object"
}