Skip to content

Take control over your wallets, built with Golang and Echo framework

Notifications You must be signed in to change notification settings

bruno-lombardi/wallett

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Wallett

Simple HTTP REST API that helps you take control of your money, manage multiple resources, like: users, wallets and transactions.

Currently supported database is SQLite. Any SQL database should work.

Endpoints

All endpoints are available below.

POST /api/v1/users

Creates an user with email and password. Example:

curl --request POST \
  --url http://localhost:3333/api/v1/users \
  --header 'Content-Type: application/json' \
  --data '{
	"email": "bruno.vbl@hotmail.com",
	"name": "Bruno Lombardi",
	"password": "123456",
	"password_confirmation": "123456"
}'

201 CREATED:

{
	"id": "u_uZpAwRNITM",
	"email": "bruno.vbl@hotmail.com",
	"name": "Bruno Lombardi"
}
GET /api/v1/users

List all users. Example:

curl --request GET \
  --url 'http://localhost:3333/api/v1/users?Page=1&Limit=10'

200 OK:

{
  "total_pages": 1,
  "count": 1,
  "per_page": 10,
  "page": 1,
  "data": [
    {
      "id": "u_uZpAwRNITM",
      "email": "bruno.vbl@hotmail.com",
      "name": "Bruno Lombardi"
    }
  ]
}
GET /api/v1/users/{user_id}

Fetch user by id. Example:

curl --request GET \
  --url http://localhost:3333/api/v1/users/u_uZpAwRNITM

200 OK:

{
  "id": "u_uZpAwRNITM",
  "email": "bruno.vbl@hotmail.com",
  "name": "Bruno Lombardi"
}

Install dependencies

➜ go mod download

Run

➜ go run main.go

Build

➜ go build

About

Take control over your wallets, built with Golang and Echo framework

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages