The service has 5 endpoints:
localhost:8080/api/v1/efishery/user
HTTP POST endpoint for user to register.localhost:8080/api/v1/efishery/login
HTTP POST endpoint to get token.localhost:8080/api/v1/efishery/validate
HTTP POST endpoint to validate token.localhost:8080/api/v1/efishery/storages
HTTP GET endpoint to get data from storage with converted currency.localhost:8080/api/v1/efishery/aggregate
HTTP GET endpoint to get aggregated data from storage.
To start using the app first:
git clone https://github.com/nurroy/efishery.git
cd efishery
You can set environtment in .env
file.
or you can directly run the app
For running the app type
# run
go run main.go
You can use eFishery.postman_collection.json
to try
- register your account using
register endpoint
and you will get password for login. - Use password from register to
login endpoint
for get jwt token. - You can validate token using
validate endpoint
endpoint - use your token to access
storages endpoint
, can be accessed by any role. - You can also access
aggregate endpoint
if you have admin role.