Commit Graph
16 Commits
Author SHA1 Message Date
sharangandClaude Opus 5.5 1b9e2f1183 feat: role and authority dataset (R1 S0) (#93)
ci / shared (push) Successful in 12s
ci / test (push) Successful in 24m37s
ci / image (push) Successful in 44s
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014aRnCGqELxoix5TfpX8Ejf
2026-10-26 21:18:57 +00:00
sharang fdebac1735 feat(entitlements): Staff preview grants for products not for sale yet (#72)
ci / shared (push) Successful in 18s
ci / test (push) Successful in 25m44s
ci / image (push) Successful in 41s
2026-10-14 08:42:40 +00:00
sharang 5b4590d3bc feat(api-keys): CI licences by API key and integration keys (#71)
ci / shared (push) Successful in 13s
ci / image (push) Successful in 36s
ci / test (push) Successful in 25m10s
2026-10-13 22:12:05 +00:00
sharang 97284b5008 feat(api-keys): Scope catalogue, kinds, expiry and sha256 keys (#70)
ci / shared (push) Successful in 14s
ci / test (push) Successful in 25m3s
ci / image (push) Successful in 39s
2026-10-13 21:21:16 +00:00
sharangandClaude Opus 5.5 557fbf85f5 feat(server): public GET /version with build version and commit (#63)
ci / shared (push) Successful in 12s
ci / test (push) Successful in 24m47s
ci / image (push) Successful in 39s
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DmXxNULoSNPvjF7buKipsB
2026-10-05 19:51:40 +00:00
sharangandClaude Opus 5.5 1f6236a754 feat(members): team management: role, block, remove, revoke, resend (#64)
ci / shared (push) Successful in 12s
ci / test (push) Successful in 24m46s
ci / image (push) Successful in 33s
portal#74: PATCH/DELETE /v1/tenants/{id}/members/{uid}, POST .../resend and the staff variants; per-workspace block via org_blocked, session logout, last-admin and self guards, audit events.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DmXxNULoSNPvjF7buKipsB
2026-10-05 18:43:31 +00:00
sharangandClaude Opus 5.5 85934567f1 feat(services): managed services per tenant for the portal (#77) (#61)
ci / shared (push) Successful in 13s
ci / test (push) Successful in 24m12s
ci / image (push) Successful in 35s
ci / shared (pull_request) Successful in 14s
ci / test (pull_request) Successful in 24m17s
ci / image (pull_request) Skipped
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DmXxNULoSNPvjF7buKipsB
2026-10-04 19:33:20 +00:00
sharangandClaude Opus 5.5 e8dcd1d259 feat(admin): repair a tenant's sign-in, delete an archived tenant (#42)
ci / shared (push) Successful in 15s
ci / test (push) Successful in 23m50s
ci / image (push) Successful in 45s
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DmXxNULoSNPvjF7buKipsB
2026-09-26 11:00:14 +00:00
sharangandClaude Opus 5.5 e0bff8c793 feat(notify): branded mails for published documents and new findings (#35)
ci / shared (push) Successful in 13s
ci / test (push) Successful in 23m16s
ci / image (push) Successful in 36s
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DmXxNULoSNPvjF7buKipsB
2026-09-23 21:10:06 +00:00
sharangandClaude Opus 5.5 8d3cda4bb0 feat(documents): tenant documents with staff upload and signed downloads (#34)
ci / test (push) Successful in 23m15s
ci / shared (push) Successful in 12s
ci / image (push) Successful in 31s
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DmXxNULoSNPvjF7buKipsB
2026-09-23 20:31:55 +00:00
sharang 54e9f6a720 feat(admin): staff tenant list, detail, trial extension, invite resend (#33)
ci / shared (push) Successful in 11s
ci / test (push) Successful in 22m43s
ci / image (push) Successful in 44s
2026-09-23 19:57:59 +00:00
sharangandSharang Parnerkar 99214c088b feat(members): tenant organization members, invites, admin email (#28)
ci / shared (push) Successful in 13s
ci / test (push) Successful in 22m21s
ci / image (push) Successful in 25s
Demonstration plan, phase D1 (registry side). The portal's Settings/Users page renders design fixtures today and its "Invite member" button posts to a route that does not exist, because the registry had no membership surface.

**`GET /v1/tenants/{id}/members`** lists the tenant's Keycloak organization members — user id, email, first/last name, `org_roles`, `enabled`, `created_at`. A tenant whose organization was never created (sales-led) answers an empty list rather than an error.

**`POST /v1/tenants/{id}/invites`** `{email, first_name?, last_name?, role?}` creates the Keycloak user if missing, adds the organization member (KC 26: the member body is the bare user id), writes the tenant-context user attributes, sends the same execute-actions mail the first admin gets, and audits `user.invited` with the caller as actor. Idempotent: an existing member answers `200 {status:"member"}` and sends no mail; a new one `202 {status:"invited"}`.

**Scope.** A user token may only touch its own tenant — another tenant's id is a 404, never a hint that it exists. Inviting needs the `IT_ADMIN` or `OWNER` org role, so `Principal` now carries the `org_roles` claim and `IsTenantAdmin()`. Service clients stay gated by `AUTHZ_RULES` route groups: members on `tenants.read`, invites on `tenants.write`.

**`admin_email` on the tenant** (migration `0006`, backfilled from the `keycloak.invite_sent` audit trail, and from `keycloak.provision_failed` metadata where the first invite failed) so Settings can show a real contact instead of an em dash. The first `IT_ADMIN`/`OWNER` invite fills it in when it was empty.

**Routing note worth keeping:** `GET /v1/tenants/{id}/members` cannot be registered — Go's ServeMux calls it a conflict with `GET /v1/tenants/by-slug/{slug}`, since both match `/v1/tenants/by-slug/members` and neither pattern is more specific. It is registered as `GET /v1/tenants/{id}/{sub}` instead, which *is* less specific than the by-slug lookup, so the two coexist; anything but `members` answers 404.

`openapi.yaml` documents both endpoints, the `OrgMember`/`Invite` schemas, `admin_email` and a `Forbidden` response.

Verified locally: `go vet ./...`, `gofmt` clean, `go test ./...` green, CI coverage command at **74.3%** (gate 70%).

🤖 Generated with [Claude Code](https://claude.com/claude-code)

https://claude.ai/code/session_01DmXxNULoSNPvjF7buKipsB
Co-authored-by: Sharang Parnerkar <30073382+mighty840@users.noreply.github.com>
Reviewed-on: #28
2026-09-14 08:27:12 +00:00
sharang 209524e5ac feat(erp): always-on ERP link, usage events, outbox, CLI licences (#25)
ci / shared (push) Successful in 14s
ci / image (push) Successful in 28s
ci / test (push) Successful in 22m28s
2026-09-12 08:35:13 +00:00
sharang 2ea49be29d feat(m-mig-5): products table, entitlement check, tenant ladder, per-client authz (#23)
ci / shared (push) Successful in 12s
ci / test (push) Successful in 21m58s
ci / image (push) Successful in 56s
2026-09-12 07:38:47 +00:00
sharang 9138731eea feat(keycloak): M4.3 — Admin API adapter + claim resolver
ci / shared (push) Successful in 5s
ci / test (push) Successful in 1m32s
ci / image (push) Has been skipped
internal/keycloak Adapter (HTTPAdapter + Mock). POST /v1/tenants now provisions a KC organization + IT_ADMIN invite when admin_email is set; KC failures emit keycloak.provision_failed but don't roll back. POST /v1/internal/keycloak/claims resolves the current claim bundle for any (tenant_id|tenant_slug|user_attrs.*) lookup. Mock used in tests + when KEYCLOAK_ADMIN_URL is empty. HTTPAdapter tested against an in-process stub KC (httptest.Server).

Refs: M4.3
2026-05-19 11:51:09 +00:00
sharang ffab866c87 feat(api): M4.2 — REST surface + pgx Postgres store + OpenAPI 3.1
ci / shared (push) Successful in 6s
ci / test (push) Successful in 1m15s
ci / image (push) Has been skipped
Full M4.2 deliverable: 16 endpoints (tenants CRUD + lifecycle, catalog, entitlements, API keys with argon2 hashing, audit append + filter), Store interface with pgx-backed Postgres + in-memory parallel implementations exercised by the same eachStore harness, openapi.yaml at 3.1 with kin-openapi contract test. M4.3 adds auth.

Refs: M4.2
2026-05-19 10:51:59 +00:00