Skip to main content
Niadra tells your systems when something happens in the memory, through signed webhooks. There are two kinds. A webhook subscription delivers every occurrence of an event type, such as action.recorded. A trigger is a rule of yours over what the memory knows, with parameters, a window and deduplication per subject, such as “a company promise one day past due”. In both cases Niadra notifies by webhook, and your agent or your system acts. A trigger never calls a system of record, never opens a ticket, never messages the end customer and never branches.

Outgoing event types

Endpoints, subscriptions and trigger rules are versioned configuration in the control API, changed through diffs a person approves. Every endpoint belongs to a source with an audience class, and a rule is only accepted, and only fires, if its condition and payload are readable by that source. trait.present(overdue_invoices) never reaches a marketing system.

The trigger catalog

New conditions come through the product catalog, never through free text. A rule fires at most once per subject per window (24 hours by default), with a ceiling of 100 firings per minute per space and 50 rules per space. Event conditions are evaluated right after the memory is updated; time conditions every 5 minutes. A late firing is marked late or suppressed, as the rule says.
Before turning a rule on, run it dry with POST /v1/triggers/dry-run: the draft names rule_id, condition, params, the target endpoint_id, window_hours (24 by default, up to 90 days) and late_policy (deliver_marked or suppress). The answer, over the last 30 days, says how many firings there would have been (would_fire), with a sample, and target_problem when the endpoint’s source may not read the payload. Adjust the parameters before anyone gets paged. It takes the integration role or an admin key.
Example: “notify the CRM one day after a missed technician visit”. When Marina’s rescheduled visit passes its due date by one day with no action that closes it, Niadra sends trigger.fired to the CRM endpoint, and your CRM agent reschedules the visit.

What a delivery looks like

Deliveries follow the open Standard Webhooks format.
The body carries ids, the rule and its version, state and pointers to evidence. It never carries conversation content. The subject may carry your own system_id for the customer, never a phone, an e-mail or a document number. links.open is the API route that opens the item, and it only works with a credential of your space that has the scope for it. Three headers come with every delivery:
  • webhook-id: unique per message; the same on every retry. Use it to deduplicate.
  • webhook-timestamp: Unix seconds. Reject anything more than 5 minutes away from your clock.
  • webhook-signature: v1, followed by the base64 HMAC-SHA256 of {webhook-id}.{webhook-timestamp}.{body}. During a secret rotation, two signatures separated by a space are valid at once.

Verify the signature

The secret is written once, through the Console or PUT /v1/secrets/webhook/{id}, and starts with whsec_; the key is the base64 part after the prefix. Verify on the raw body, before parsing it.

Delivery guarantees

  • At least once. A message may arrive more than once; deduplicate by webhook-id.
  • No ordering. Messages may arrive out of order; every event carries as_of and a version so you can order them.
  • Retries with exponential backoff for up to 24 hours. After that the delivery goes to the dead-letter queue, visible in the Console and kept for 7 days.
  • An endpoint that fails continuously for 24 hours is disabled, and your space is notified.
  • Controlled egress. Every outgoing call goes through an egress proxy with an allow list per space. Private addresses, cloud metadata and loopback are blocked, DNS is resolved and pinned on each attempt, and only HTTPS goes out.
Answer with any 2xx quickly and do the work asynchronously. A delivery is pending, delivered, failing while it retries, or dead. These routes take a Console person with the integration role (firings also analysis) or a key with the admin scope. To inspect deliveries use Webhook deliveries; to send a dead delivery again, with the same webhook-id, use Redeliver. Firings, with the rule, the version and the evidence, are listed at Trigger firings.

Next steps

Patterns

the signals trait.present can watch.

Webhooks from your systems

the other direction, events coming in.

Context use

the repetition rate behind context_use.repetition_rate.

Receipts and audit

receipts delivered to your SIEM through the same mechanism.