/, so they cannot encode canonical Unkey
resource paths. The WorkOS permission model is intentionally much smaller than
Unkey’s resource permission model.
The exact list of supported WorkOS permissions and their Unkey translations is
defined in
pkg/auth/workos/permissions.go.
That Go file is the source of truth.
Permission shape
WorkOS recommends clear, concise permission slugs with a resource and action delimiter. Unkey follows that shape and keeps WorkOS permissions broad:Translation
The WorkOS resolver wraps the generic JWT JWKS resolver. The generic resolver verifies issuer, audience, signature, and time claims, and builds the initial JWT principal. The WorkOS wrapper then replaces the raw WorkOS permission strings with canonical permissions in this format:Unknown permissions
Unknown WorkOS permission strings are ignored during translation. They don’t grant access, and they don’t fall back to legacy wildcard permissions. This makes WorkOS safe to contain permissions that are not yet understood by the API. Adding a new permission requires updating the mapping table inpkg/auth/workos/permissions.go and adding tests for the resulting Unkey
resource permission.
Ownership boundaries
The generic JWT package must stay provider-neutral. It verifies JWTs and returns claims as-is. WorkOS-specific behavior belongs inpkg/auth/workos:
- the WorkOS issuer constant,
- the WorkOS JWKS resolver wrapper,
- the WorkOS permission mapping table, and
- tests for WorkOS permission translation.

