Commit Graph
36 Commits
Author SHA1 Message Date
sam 60d9b6b7aa feat: record access decisions, not just denials
- add an outcome column and migration so allowed and denied decisions share one audit trail
- fail closed when an allowed decision cannot be recorded
- expose outcome filtering in the API and dashboard

Route chat through the recording authorizer so its decisions are audited too.
2026-11-23 01:00:46 +11:00
sam e1ada94d78 fix: redact link codes and guard shipped policies
- redact single-use link codes from stored account.link events after handling, with a migration to scrub existing rows
- refuse deletion of shipped org policies and hide the delete action in the UI
- validate agent step models against the workflow model policy at save time, including the default model
2026-11-23 00:38:54 +11:00
sam 8c267b6edd feat: record skipped dispatches and approver ids
- store trigger dispatches as started or skipped, with a JSON reason surfaced in the API and UI
- persist the answering account's identity id beside its display name for approvals and judgements
- save connector acceptances and their declarations in one transaction so a refused change stores nothing
2026-11-22 23:24:30 +11:00
sam 33f7ebdff4 feat: add member candidates endpoint and approvals page
- serve active identities outside the org at /api/orgs/{id}/member-candidates and back the members page from it
- add an org approvals page for default owner, deadline and escalation path over /api/settings
2026-11-22 23:03:01 +11:00
sam 4707427759 feat: trust configured proxies for webhook intake
- add trusted proxy settings, migration, API, and UI
- derive client addresses from X-Forwarded-For behind trusted hops
- enforce delivery policy for listener batches and record denials
2026-11-22 22:29:36 +11:00
sam 787a213db6 Merge branch 'main' into worktree-agent-ac0944b265396932d
# Conflicts:
#	modules/governance/accounts_api.go
2026-11-22 15:42:43 +11:00
sam 51a1cf5128 feat(governance): model aliases resolve through providers with a policy (#2063) 2026-11-22 15:41:40 +11:00
sam 07d14c8d50 merge main into the workflow editor branch (#2061) 2026-11-22 11:48:30 +11:00
sam 61f576a25c feat(events): capture, event types, mappings and trigger approval on the binary (#2062, #2098)
Event types, field mappings and the stored-delivery inspector move into
modules/events: copied from internal/domain/eventtype and
internal/domain/mapping, which the old services still import. Each stored
event records how its delivery was verified; a source that checks nothing
refuses deliveries until approved; triggers gain approve, pause, resume,
event-type and mapping binding, dispatch history and delete. The captures,
mappings and bindings sections are reported as served.
2026-11-22 11:39:46 +11:00
sam a5826156a3 feat(runs): filter runs by workflow and name each tool call in a trail entry (#2061) 2026-11-22 11:36:08 +11:00
sam 682995bdf7 feat(runs): workflow drafts, publish with an expected version, delete, enabled flag, run on demand, run stages and statistics (#2061, #2113, #2098)
A disabled workflow is never started by a trigger, another workflow or a
person. Delete is refused while a trigger, another workflow or a run in
progress names it. A parked or ended run restarts from a step.
2026-11-22 11:34:49 +11:00
sam eadb88d3bf feat(governance): serve the organisation's instructions to every agent (#2023)
The organisation's standing instructions are stored per organisation and
join the system prompt of chat turns and workflow agent steps. The Org
configuration group is served: schedules, alert webhook, playbooks,
models, connections and credential bindings open the page that already
owns the concept.
2026-11-22 11:24:25 +11:00
sam bd212ec9ac Merge branch 'worktree-agent-a521e2c3ea8457fdc'
# Conflicts:
#	modules/governance/accounts_api.go
2026-11-22 11:16:42 +11:00
sam 9aceaa15bc feat(system): report module, connector and runner health and what waits on a person (#2023) 2026-11-22 02:44:13 +11:00
sam 5004e8b40b feat(governance): serve members, access policies and denials (#2023) 2026-11-22 02:43:06 +11:00
sam 1a0c697858 Merge branch 'worktree-agent-a124e124e24c6a56b' 2026-11-22 02:13:32 +11:00
sam e127b2b05d feat(approvals): gate answers by role and link channel accounts through single-use codes, replacing the people model (#2095) 2026-11-22 02:13:08 +11:00
sam 763cd0e581 feat(governance): delete a model or alias from /settings/models (#2090) 2026-11-22 02:03:24 +11:00
sam b9a60e03a3 feat(chat): bind held-action approvals to the whole action and require fresh passkey confirmation for irreversible ones (#2072) 2026-11-21 21:35:27 +11:00
sam bc72655c8e feat(judgement): refuse privileged and undeclared actions in chat (#2071)
Connector actions and lookups now declare privilege change and secret access,
and an MCP server declares both per installation. Chat withholds and refuses
any tool that has either effect or declared nothing, in judgement and at
execution, so an approval cannot convert the refusal. Workflows and the
dashboard are unchanged.
2026-11-21 21:28:06 +11:00
sam d318f912a8 fix(runs): cancel a run from the API and the dashboard (#2088)
POST /api/runs/{id}/cancel now reaches Engine.Cancel, which cancels the
run and the runs it started with workflow.call, and returns the run.
Cancelling a run that has already ended is refused with a 409, and a run
from another organisation is not found. The run page shows a Cancel
action for a run that has not ended.
2026-11-21 18:21:31 +11:00
sam 14060675cd feat(connectors): check workflow and trigger references against declared capabilities (#2087) 2026-11-21 17:14:00 +11:00
sam 64ef2c9af7 feat(connectors): group extensions as platform, integration or agent (#2084) 2026-11-21 14:58:53 +11:00
sam 3513dad609 Merge branch 'worktree-agent-a3fd604fba0fb36cc' 2026-11-21 13:55:00 +11:00
sam a88f5630fe feat(runs): the first step that sets an outcome ends the run (#2042)
Add workflow.finish (completed, parked, waiting_approval, declined). A failed
step parks the run unless it continues on failure, and a parked run retries
from a top-level step, replaying the earlier steps' recorded results. Adds the
retry-run operation and a Retry button on the run page.
2026-11-21 13:52:52 +11:00
sam f47e60db00 refactor(events,deliveries): split source saving and plain the new prose (#2021, #2016) 2026-11-21 13:52:33 +11:00
sam 01eb4aaf7c fix(events): verify webhook signatures before parsing (#2021)
A source now declares how its deliveries prove themselves: token (the
default, unchanged), hmac (HMAC-SHA256 over the raw body, per-source header
and prefix, secret sealed at rest and write-only) or none. The events module
verifies before the connector parses, answers 401 and logs the refusal.

The digest comparison is ported from internal/webhookguard/hmac.go and the
header-borne signature from internal/infrastructure/captureintake/receiver.go;
the old copies stay until their service goes. The seal package moves to
internal/platform/seal so events can seal the secret.
2026-11-21 13:46:48 +11:00
sam 073959b4f9 feat(memory): scope chat notes and preserve deletions on restore (#2069)
Keep personal notes private by default and require review before publishing shared notes. Restore backups and replay forgotten notes in one transaction, and retain the installed release when an unattended rollback could bring back forgotten notes.
2026-11-21 13:20:31 +11:00
sam 064eeab748 feat(governance): let owners rename the organisation and workspaces
Adds the organisation routes the single binary's dashboard needs (list, get, workspace list and create) plus owner-only renames of the organisation and its workspaces. A rename is guarded by the version the caller read, writes only the display label, and appends an actor-attributed event in governance.org_events in the same transaction. The Organisation page shows those name changes, and a deep link is no longer replaced by the landing page while the router is still resolving it.

Refs #2077
2026-11-20 21:10:34 +11:00
samandCopilot 264062866c feat(ui): run events, workflows, runs, controls and settings pages on the archie binary (#2023)
Events (sources, triggers), workflows (list, document, YAML publish,
read-only canvas), runs with approvals and the decision trail, controls
(policies, guards, action classes), agent models, accepted extensions,
secret engines and credentials now read the binary's API. Capabilities
name every section, so pages the binary can't back yet (the visual
workflow editor, captures, mappings, bindings, the extension catalogue,
model aliases and the rest) stay in the tree, hidden. Adds
GET /api/credential-kinds for the credentials form.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-11-20 01:04:29 +11:00
samandCopilot 59b0ac03c9 feat(dashboard): serve the live stream the Vue dashboard connects to
Same frames as internal/webui/sse.go with a keepalive; signed-in only.
Topics are added as each page moves onto the binary.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-11-20 00:34:46 +11:00
samandCopilot c12f6b7947 feat(governance): sign in to the archie binary from the Vue dashboard (#2017)
The binary serves the account routes the Vue client already calls: status,
setup, password and passkey sign-in, recovery, sign-out, OIDC, account
passkeys, password and recovery codes, personal tokens and capabilities.
The API authenticates a session cookie, a personal token or the bootstrap
admin token, and unsafe requests pass cross-origin protection. The
dashboard serves the Vue app at /.

Copied from internal/webui/{accounts,passkeys,personal_tokens,
api_capabilities,auth}.go, internal/infrastructure/oidc/{flow,oidc}.go and
internal/app/archieui/account_oidc.go, which archie-ui still imports.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-11-20 00:30:11 +11:00
samandCopilot cbfcd43018 feat(chat): add the chat module to the archie binary (#2018)
Conversations are the chat module's own tables. A turn is stored before it
is acknowledged, runs after the turns before it in its session, and records
everything it streams, so a reader replays it from a cursor. The agent uses
the configured agent model, the same connector tools as a run and the
dashboard's own reads; every action is judged, and one judgement holds is
put to people through approvals and run once when approved. A restart fails
the turns it interrupted visibly and never restarts a started action.

Conversation memory is a set of notes in the memory module. The chat
prompts are copied from internal/prompts (chat-system.tmpl, soul.md,
session-title.md) into internal/platform/prompts while the gateway still
reads them; the tool parameter redaction is copied from
internal/domain/messaging/tool_parameters.go.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-11-19 19:40:44 +11:00
samandCopilot 64dfad6d53 feat(runs): add typed results and model aliases (#2043)
Also fix repository-free message.send validation (#2046) and add a single-binary development smoke path (#1977).

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-11-18 23:47:35 +11:00
sam ce70d4f3ee feat(runs): workflow documents take today's step shape, references and when (#2039)
A step is id/type/settings with when and on_failure; the five kinds become
the types agent.run (inline mission), connector.action, approval.wait,
run.notify and workflow.sleep. Documents declare inputs, repository,
instructions, identity and profile; references are {{ task|inputs|steps }}
checked at save. Any number of approval steps, each asking only about what
was held since; actions still held at the end are put to people before the
run finishes. Triggers are refused for a workflow they can't start, and the
workflows API lists, reads and saves documents beside a step-type catalog.

Copied from internal/domain/workflow: definition.go, step_refs.go,
step_flow.go's checks, control_steps.go's when parser, vocabulary.go and
task/interface.go. stableid moves to internal/platform.
2026-11-17 18:43:45 +11:00
sam 1026d5e3b6 feat(httpapi): the API is described by an OpenAPI document generated with Huma (#2028)
Every /api operation is registered with Huma behind one admin-token
middleware, served at /api/openapi.json with a docs page at /api/docs,
and committed as api/openapi.yaml, which task check keeps current.
2026-11-16 20:05:05 +11:00