You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: skills/objectstack-automation/SKILL.md
+32-4Lines changed: 32 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -57,7 +57,7 @@ parallel. Flows are the primary automation building block in ObjectStack.
57
57
|`screen`| Interactive — presents UI screens to the user (wizards, forms) |
58
58
|`schedule`| Runs on a cron schedule (daily cleanup, weekly reports) |
59
59
|`record_change`| Fires automatically on record create/update/delete (bind via the `start` node's `triggerType`) |
60
-
|`api`| Invoked explicitly via the API / `engine.execute()`|
60
+
|`api`| Invoked explicitly via the API / `engine.execute()`, **or** bound as an inbound **webhook**: `POST /api/v1/automation/hooks/:flowName/:hookId` (see *Inbound webhook triggers* below)|
61
61
62
62
### Flow Node Types
63
63
@@ -342,6 +342,7 @@ branch — you never resume the flow by hand.
342
342
|`lockRecord`| Lock the triggering record from edits while pending. Default `true`|
343
343
|`approvalStatusField`| Business-object field to mirror `pending`/`approved`/`rejected`/`recalled` onto (should be readonly) |
|`maxRevisions`| ADR-0044 — max **send-backs-for-revision** per run before auto-reject. Default `3`; `0` disables send-back. Only meaningful when the node has a `revise` out-edge |
345
346
346
347
### Branching, side-effects & rejection
347
348
@@ -353,6 +354,12 @@ These are wired on the **graph**, not in node config:
353
354
`http_request`, an email node, …) to the `approve` / `reject` out-edge.
354
355
-**Roll back on reject** — route the `reject` edge as a **back-edge** to an
355
356
earlier node so the submitter can revise (the old `back_to_previous`).
357
+
-**Send back for revision (ADR-0044)** — distinct from a plain reject: an
358
+
Approval node can emit a third decision **`revise`** on a `revise`-labeled
359
+
out-edge that routes to a rework wait point. The submitter edits and
360
+
resubmits, re-entering the node via an edge `type: 'back'` (a declared
361
+
back-edge — traversed at run time but excluded from DAG cycle validation).
362
+
`maxRevisions` (node config, default `3`) caps the loop before auto-reject.
356
363
-**Hard reject** — route the `reject` edge to an `end` node (the old
357
364
`reject_process`).
358
365
@@ -381,17 +388,38 @@ ObjectQL lifecycle hook.
381
388
382
389
### Prerequisite — enable the `triggers` capability
383
390
384
-
Record-change (and schedule) triggers ship as a plugin gated behind the
391
+
Record-change, schedule, **and inbound-webhook (`api`)** triggers ship behind the
385
392
`triggers` capability. **Without it the flows register but never fire.** Add it
386
-
to the package config (pair with `job` for schedule/cron triggers):
393
+
to the package config:
387
394
388
395
```typescript
389
396
defineStack({
390
397
// …
391
-
requires: ['automation', 'triggers'], // + 'job' for scheduled flows
398
+
requires: ['automation', 'triggers'],
399
+
// + 'job' for scheduled (cron) flows
400
+
// + 'queue' for inbound-webhook ('api') flows — the trigger-api plugin
401
+
// depends on the queue service; without it every inbound POST
-**Idempotency:**`x-idempotency-key` dedupes retries — author the flow to be idempotent (delivery is at-least-once).
420
+
-**Queue-backed:** the endpoint ACKs `202` and enqueues; the flow runs on the consumer, never in-band. Requires the `queue` service (see prerequisite).
421
+
- The JSON body surfaces to the flow as the trigger record (`record.*` / bare fields) plus `params`.
Copy file name to clipboardExpand all lines: skills/objectstack-platform/SKILL.md
+25-4Lines changed: 25 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -297,7 +297,9 @@ manifest: {
297
297
}
298
298
```
299
299
300
-
**Object naming:** The object `name` is the canonical identifier and equals the physical table name. If you want a domain prefix, embed it directly in the name (e.g. `name: 'crm_account'`). There is no automatic namespace prefixing.
300
+
**Object naming:** The object `name` is the canonical identifier and equals the physical table name. Embed any domain prefix directly in the name (e.g. `name: 'crm_account'`); the object-level `namespace`*field* is deprecated and ignored by the runtime.
301
+
302
+
**`manifest.namespace` (ADR-0048):** Optional, but **enforced once set**. When a package declares `manifest.namespace: 'crm'`, every `object.name` must start with `crm_` or `defineStack` errors (`validateNamespacePrefix` in `@objectstack/spec`); the legacy `<ns>__<short>` double-underscore form is rejected, and `sys_`-prefixed names are platform-reserved and exempt. The namespace is also a package-ownership key — installing two packages that both claim `crm` fails with `NamespaceConflictError` (downgrade to a warning with `OS_METADATA_COLLISION=warn`). `os lint` additionally emits a non-fatal `naming/namespace-prefix` warning for bare-named UI/automation items (app, page, dashboard, flow, action, report, dataset) when a namespace is set.
|`os package publish [dist/objectstack.json] [--env … --install --visibility org]`| Upload the compiled artifact as a versioned package to the cloud catalog (ADR-0008 P3) |
1138
+
|`os package install <manifest-id │ ./dist/objectstack.json> [--version │ --runtime http://localhost:3000]`| Install a package into a **running** runtime via its install-local endpoint. Catalog mode (by manifest id) or air-gapped local-artifact mode. Auths with the **target runtime's** session (`--email/--password` or `OS_RUNTIME_EMAIL`/`OS_RUNTIME_PASSWORD`), not the cloud login |
0 commit comments