feat: impl bearer auth middleware

This commit is contained in:
2025-11-26 01:09:42 +00:00
parent 81e3f7af75
commit 389fe35a0a
9 changed files with 161 additions and 25 deletions

View File

@@ -0,0 +1,19 @@
package user
import (
"fmt"
"github.com/google/uuid"
)
type NotFoundError struct {
id uuid.UUID
}
func newNotFoundError(id uuid.UUID) *NotFoundError {
return &NotFoundError{id}
}
func (e *NotFoundError) Error() string {
return fmt.Sprintf("user not found: %v", e.id)
}