All schemas (parameters, output, output_schema, conf_schema) now use the
StackStorm-style flat format expected by Attune:
{ param_name: { type, description, required, secret, ... } }
Instead of the standard JSON Schema format:
{ type: object, properties: { ... }, required: [...] }
Also fix rule template syntax: trigger.payload.* -> event.payload.*
53 lines
1.3 KiB
YAML
53 lines
1.3 KiB
YAML
# Read Counter Action
|
|
# Consumes a counter value and returns a formatted message
|
|
|
|
ref: nodejs_example.read_counter
|
|
label: "Read Counter"
|
|
description: "Receives a counter value (typically from the counter trigger) and returns a formatted message containing it"
|
|
enabled: true
|
|
|
|
# Runner type
|
|
runner_type: nodejs
|
|
|
|
# Entry point
|
|
entry_point: read_counter.js
|
|
|
|
# Parameter delivery: stdin for secure parameter passing
|
|
parameter_delivery: stdin
|
|
parameter_format: json
|
|
|
|
# Output format: json (structured data)
|
|
output_format: json
|
|
|
|
# Action parameters schema (StackStorm-style: inline required per parameter)
|
|
parameters:
|
|
counter:
|
|
type: integer
|
|
description: "The counter value to consume"
|
|
required: true
|
|
rule_ref:
|
|
type: string
|
|
description: "The rule reference the counter is scoped to"
|
|
default: ""
|
|
|
|
# Output schema (StackStorm-style: inline required per parameter)
|
|
output_schema:
|
|
message:
|
|
type: string
|
|
description: "Formatted message containing the counter value"
|
|
required: true
|
|
counter:
|
|
type: integer
|
|
description: "The counter value that was consumed"
|
|
required: true
|
|
rule_ref:
|
|
type: string
|
|
description: "The rule reference the counter is scoped to"
|
|
|
|
# Tags for categorization
|
|
tags:
|
|
- counter
|
|
- example
|
|
- nodejs
|
|
- consumer
|