Categorygithub.com/anurag-rajawat/rest-api
module
0.0.0-20230911172031-f37d44866dcc
Repository: https://github.com/anurag-rajawat/rest-api.git
Documentation: pkg.go.dev

# README

REST API

Build CI tests codecov License Go Version Go Report Card

This REST API was built with Golang and the Gin web framework. It is backed by a PostgreSQL database and uses unit tests to ensure its quality.

I built this REST API as a learning project to learn Golang and backend development. I am currently learning Golang and wanted to build something to solidify my understanding of the language.

Prerequisites

  1. Docker
  2. Go

Local Development

Start API server (locally)

$ docker run --rm -d -p 5432:5432 --name=api-db -e POSTGRES_PASSWORD=test postgres:15 
$ make run

Alternatively, using docker compose

$ make docker-run

Run tests

$ make test

API Resources

  • GET /v1
  • GET /v1/users
  • GET /v1/users/{id}
  • PUT v1/users/{id}
  • DELETE v1/users/{id}
  • POST /v1/signup
  • POST /v1/signin

# Packages

No description provided by the author
No description provided by the author