This commit is contained in:
2026-11-19 13:39:53 +03:00
parent 470d9d6f1e
commit 1d81159dd3
99 changed files with 10577 additions and 1 deletions
+18
View File
@@ -0,0 +1,18 @@
package sessionstore
import (
"context"
"errors"
"time"
)
var (
ErrNotFound = errors.New("session not found or expired")
ErrUnavailable = errors.New("session store unavailable")
)
type Store interface {
Create(ctx context.Context, token, userID string, ttl time.Duration) (time.Time, error)
GetUserID(ctx context.Context, token string) (string, error)
Delete(ctx context.Context, token string) (bool, error)
}