v0.3.2
Changed
- API keys — corrected the public API (the feature shipped in v0.3.1). Self-service methods now take identity from the auth context, admin methods take a user
sub, every method uses request/response DTOs with runtime validation, and generated keys are a plain server-generated secret (no prefix). See the API Keys guide.
If you started using API keys in v0.3.1:
-
Self-service: drop the
userIdargument — identity comes from the session.await apiKeys.createKey(dto); // was: createKey({ userId, ...dto }) -
Admin: use the
admin*methods onApiKeyService(keyed bysub):await apiKeys.adminCreateKey({ sub, expiresInDays: 90 }); -
Remove
apiKeys.keyPrefixfrom config. Thenauth_api_keysschema change ships as an automatic follow-up migration — no manual step.