Skip to content

Commit 212bb73

Browse files
Add workspace audit history
Co-authored-by: Max schwenk <maschwenk@gmail.com>
1 parent 390aa48 commit 212bb73

34 files changed

Lines changed: 3545 additions & 109 deletions
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@executor-js/fumadb": major
3+
---
4+
5+
MySQL Drizzle schema generation now rejects unbounded string primary keys instead of emitting invalid `text` primary-key SQL. Before upgrading, change every MySQL `idColumn(..., "string")` to an explicit bound such as `idColumn(..., "varchar(255)")` (or use `"uuid"`). The `IdColumnType` type is now exported from `@executor-js/fumadb/schema` for reusable schema helpers.
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
---
2+
"@executor-js/sdk": minor
3+
"@executor-js/api": minor
4+
---
5+
6+
**Workspace audit history**
7+
8+
Connection, integration, OAuth-client, and tool-policy mutations now append
9+
tenant-scoped audit events containing only actor and safe resource identifiers.
10+
Admins can inspect the history in the Users page Activity tab or through
11+
`GET /admin/audit-events`.
12+
13+
The history records `created`, `updated`, and `removed` row intent. When
14+
post-commit credential persistence fails, successful row compensation appends
15+
`rolled_back`; a later provider-cleanup failure appends `rollback_failed`, so
16+
the history never claims complete compensation when credential restoration was
17+
incomplete.
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
CREATE TABLE "audit_event" (
2+
"id" text NOT NULL,
3+
"actor_id" text,
4+
"action" text NOT NULL,
5+
"resource_type" text NOT NULL,
6+
"resource_owner" text,
7+
"resource_parent" text,
8+
"resource_id" text NOT NULL,
9+
"created_at" timestamp NOT NULL,
10+
"row_id" text PRIMARY KEY NOT NULL,
11+
"tenant" text NOT NULL
12+
);
13+
--> statement-breakpoint
14+
CREATE UNIQUE INDEX "audit_event_uidx" ON "audit_event" USING btree ("tenant","created_at","id");

0 commit comments

Comments
 (0)