This project is a product management API built using Go and SQLite. It provides endpoints to create, retrieve, update, and delete products.
curl -X POST http://localhost:8000/login -H "Content-Type: application/json" -d '{"username": "username", "password": "password"}'
curl -X GET http://localhost:8000/products -H "Authorization: Bearer JWT_TOKEN"
curl -X POST http://localhost:8000/products \
-H "Authorization: Bearer JWT_TOKEN" \
-H "Content-Type: application/json" \
-d '{"name": "GO Book", "price": 19.99, "description": "Go Programming Language"}'
curl -X GET http://localhost:8000/products/1 -H "Authorization: Bearer JWT_TOKEN"
curl -X PUT http://localhost:8000/products/1 \
-H "Authorization: Bearer JWT_TOKEN" \
-H "Content-Type: application/json" \
-d '{"name": "GO Book 2", "price": 29.99}'
curl -X DELETE http://localhost:8000/products/1 -H "Authorization: Bearer JWT_TOKEN"
docker build -t store-app .
docker run -p 8000:8000 store-app