go mod tidy
go run main.go
You need to create a .env config file.
DB_CONN="root:*******@/dbName" #DB conf
SECRET_KEY="test_secret_key" #JWT Secret Key
PORT=":8082" #Port to listen
Register
Post localhost:8082/api/register
Login
Post localhost:8082/api/login
Get UserInfo
Cookie JWT is saved.
Logout
Post localhost:8082/api/logout
User information is deleted from the cookie.