nyno-sql-insert

nyno-sql-insert — Insert JSON data into a PostgreSQL database


Description

- step: nyno-sql-insert
  args:
    - '${JSON}'

The nyno-sql-insert step inserts JSON data into a PostgreSQL database table (json_storage) as a jsonb column.

Usage in a workflow YAML:

workflow:
  - step: nyno-sql-insert
    args:
      - { "user": "Alice", "action": "login", "timestamp": "2025-12-27T12:00:00Z" }

Parameters

Parameter Type Description
payload string or object The JSON data to insert. Objects are automatically serialized to JSON strings.

Context requirements / environment:


Return Values

{
  "command": "INSERT",
  "rowCount": 1,
  "oid": 0,
  "rows": [],
  "fields": [...]
}

Behavior


Examples

Example #1 — Insert simple object

workflow:
  - step: nyno-sql-insert
    args:
      - { "user": "Bob", "action": "logout", "timestamp": "2025-12-27T12:05:00Z" }

Stores the insert response in ${prev}.

Example #2 — Insert JSON string

workflow:
  - step: nyno-sql-insert
    args:
      - '{"event":"signup","user":"Charlie","plan":"Pro"}'

Notes


See Also