feat(auth): Add /token endpoint to request a access token

This commit is contained in:
Björn Benouarets
2026-01-27 11:19:52 +01:00
parent 346100feb6
commit d8241a2491
19 changed files with 418 additions and 14 deletions

View File

@@ -33,7 +33,7 @@ func (authorization *Authorization) BeforeCreate(tx *gorm.DB) (err error) {
}
authorization.Code = codeHash
if authorization.ExpiresAt == nil {
expiresAt := time.Now().Add(time.Minute * 10)
expiresAt := time.Now().Add(time.Minute * 2)
authorization.ExpiresAt = &expiresAt
}
return nil