All workAndrew Cates.

Project 26 of 84

cogs

Shared backend/identity plane and Claude Code plugin for the catesworks site families: @cogs/* npm packages (auth, transactional email, typed fetch-client/react-query seam, env tooling, lint configs) plus 7 production-mined Claude Code skills and the Terraform SES/DNS/Turnstile infra behind them.

Status
Shipped
Area
Workloom Platform Suite
Last activity
2026
Stack
  • TypeScript
  • pnpm workspaces
  • Turborepo
  • Changesets
  • Biome
  • Vitest
  • Node
  • Hono

Highlights

  1. Rebuilt the cogs typed API codegen seam for Kubb v5 as breaking releases of @cogs/fetch-client (xior transport with streaming) and @cogs/kubb-transforms (post-generate codemods), adding end-to-end tests that run the real Kubb CLI to catch fixture drift and type-check generated output.
  2. Added a server mode to @cogs/fetch-client for multi-user processes such as MCP servers and workers, passing auth context per request with instance-ownership checks, backed by 23 ported and new security tests.
  3. Hardened @cogs/auth for Zitadel SSO with strict multi-issuer token verification (azp, jti, required claims, algorithm allowlist), a signed last-known-good JWKS fallback, production env assertions, role non-uplift and Hono middleware, adding about 200 tests; a security review drove an ADR that removes the lenient legacy issuer path once an app migrates.
  4. Closed auth gaps across the fleet's shared verifier: multi-audience AUTH_AUDIENCE allowlist, azp/client_id audience checks for SSO, an opt-in role floor, and userinfo responses bound to the token subject with per-token negative caching.
  5. Designed a two-tool fix for a recurring production bug (quote-wrapped secrets breaking auth after copy-paste into Render): a local config-lint CLI on the public @cogs/config and a private env-doctor CLI that checks live Render env vars and fixes one key at a time with read-back verification, both shipped as Claude Code skills after five Architect/Critic plan reviews.
  6. Published @cogs/skills-site, a Docusaurus plugin and React skills browser (category rail, detail dialog, zip downloads, generated previews), taking it from 0.1.0 to 0.4.1 in one day of CI-driven Changesets releases.
  7. Built and deployed a static Next.js 16 marketing site whose skill, package and CLI pages are generated from repo sources and pinned by catalog tests, with a build gate that crawls 63 sitemap URLs and 2,439 internal links and an axe WCAG 2.2 AA pass reporting 0 issues across 64 pages in light/dark at desktop and mobile widths.
  8. Launched the cogs.catesworks.dev Docusaurus documentation site with a per-skill catalog and package docs written from real CLI output, kept as a standalone workspace so its dependencies stay out of the library build graph.
  9. Created and published fleet-shared @cogs/eslint-config, @cogs/prettier-config and @cogs/biome-config, iterating the ESLint config through more than a dozen releases during fleet adoption and later adding rules that guard the react-query seam and NEXT_PUBLIC_ env reads.
  10. Migrated the central transactional-email send service from Render to CapRover with a deploy pipeline that polls the live /health endpoint before reporting success, a slimmer production-only Docker stage, and a gitleaks + trufflehog published-artifact secret scan gating Vercel deploys.
  11. Tightened release and infra controls: moved the repo into the catesworks GitHub org, adopted Beads issue tracking, gated Terraform Apply behind an explicit workflow_dispatch input, and root-caused npm trusted-publishing 404s to expired trusted-publisher entries.
  12. Wrote CODING_STANDARDS.md and GLOSSARY.md from measured repo conventions, recording outliers (lint errors, mixed test layouts, doc count drift) instead of silently normalizing them.
  13. Added two default-on convention guards to the shared @cogs/eslint-config (PR #53): an error on direct @tanstack/react-query imports so every app goes through the @cogs/react-query seam, and a warning on process.env.NEXT_PUBLIC_* reads in favor of the runtime @cogs/environment registry, with documented opt-outs and a dedicated guards test file; shipped as the 0.3.0 minor release.
  14. Root-caused a failed Changesets release run to a changeset that mixed a private skill mirror with a public package, and landed the fix through a protected-branch PR (#54) rather than bypassing the required-checks rule, then shipped two Version Packages releases the same afternoon (PRs #55, #57) with the follow-up release runs green.
  15. Diagnosed npm publish E404s as expired trusted-publisher configurations on two @cogs packages and had them recreated, restoring OIDC trusted publishing for the fetch-client and skill releases (evidence: session transcript; npm registry now shows @cogs/fetch-client 0.5.1 and @cogs/eslint-config 0.3.0).
  16. Corrected the @cogs/fetch-client docs example to read the API base URL from @cogs/environment instead of a NEXT_PUBLIC_ variable, aligning docs with the new lint guard (PR #56).