Merged
Size
L
Change Breakdown
Refactor60%
Feature40%
#3390feat(webapp): extend admin workers endpoint and unify admin api auth

Administrators can list and configure worker groups

The Admin API has been updated to support worker group retrieval and advanced configuration fields, alongside a massive cleanup of authentication boilerplate.

Administrators can retrieve lists of worker groups directly from the admin API and configure advanced routing options when creating them.

The updated worker groups endpoint accepts detailed infrastructure configurations. Administrators can specify cloud providers, static IP addresses, workload types, and fast-path routing rules during creation. This upgrade, located in the core webapp admin routes, gives operators precise control over where and how workloads execute.

Under the hood, this release removes repetitive authentication checks across the entire admin API suite. Dozens of manual token verifications are replaced with a single helper that enforces consistent access control for all admin endpoints.

View Original GitHub Description

Extends the admin worker groups endpoint with a GET loader and more fields on POST (type, hidden, workloadType, cloudProvider, location, staticIPs, enableFastPath), and pulls the PAT + admin check that was inlined or locally duplicated across every admin.api route into a shared helper in personalAccessToken.server.ts. The generic authenticateAdminRequest returns a discriminated result; requireAdminApiRequest is the thin Remix loader/action wrapper that throws. The neverthrow-style route (platform-notifications.ts) now composes the generic helper instead of duplicating the check. Verified locally against GET (listing) and POST (new fields, invalid enum, minimal backwards-compat).

© 2026 · via Gitpulse