• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

supabase / auth / 17260451741

27 Aug 2025 07:39AM UTC coverage: 70.815% (+0.01%) from 70.802%
17260451741

push

github

web-flow
chore: extract token generation logic to its own package (#2135)

## Summary

Extracted common token operations from the existing `/token` endpoint to
a new `internal/tokens` package to enable code reuse for the upcoming
`/oauth/token` endpoint implementation.

## Backward Compatibility
- Type aliases: AccessTokenClaims = tokens.AccessTokenClaims in
`internal/api/token.go` to keep the changes low
- Method preservation: All existing API methods work unchanged
- Feature parity: AsRedirectURL(), hooks, validation - everything
preserved

Note on request object dependency: The service requires the HTTP
`request` object for audit log entries (`models.NewAuditLogEntry`).
While ideally the service would extract only needed context, the current
audit logging implementation requires the full request object.

287 of 382 new or added lines in 6 files covered. (75.13%)

12297 of 17365 relevant lines covered (70.81%)

70.0 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

85.77
/internal/api/api.go


Source Not Available

STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc