adding rest-api

This commit is contained in:
2026-07-08 06:59:16 -05:00
parent 0ef9b90bcd
commit 60c2f20fea
20 changed files with 524 additions and 0 deletions

8
rest-api/utils/hash.go Normal file
View File

@@ -0,0 +1,8 @@
package utils
import "golang.org/x/crypto/bcrypt"
func HashPassword(password string) (string, error) {
bytes, err := bcrypt.GenerateFromPassword([]byte(password), 14)
return string(bytes), err
}