package config

import "time"

type AuthConfig struct {
	jwtTokenExpiresTTL int
	jwtTokenSecret     string
}

type JWT struct {
	secret    string
	expireTTL int
}

func (c *AuthConfig) AccessTokenSecret() string {
	return c.jwtTokenSecret
}

func (c *AuthConfig) AccessTokenExpiresDate() time.Time {
	duration := time.Duration(c.jwtTokenExpiresTTL)
	return time.Now().UTC().Add(time.Minute * duration)
}
