utils

package
v0.0.0-...-0090429 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 25, 2024 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenerateJWT

func GenerateJWT(email string) (string, error)

GenerateJWT generates a new JWT token for a user

func GenerateOTP

func GenerateOTP() string

GenerateOTP generates a 6-digit OTP

func SendOTPEmail

func SendOTPEmail(to string, otp string)

SendOTPEmail sends an OTP to the provided email address

func ValidateJWT

func ValidateJWT(tokenString string) (*jwt.StandardClaims, error)

ValidateJWT validates a JWT token and returns the claims

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL