https://github.com/khofesh/go-api
Rest API
https://github.com/khofesh/go-api
backend gin-gonic golang mongo rest-api
Last synced: about 1 month ago
JSON representation
Rest API
- Host: GitHub
- URL: https://github.com/khofesh/go-api
- Owner: khofesh
- License: mpl-2.0
- Created: 2020-03-25T15:56:09.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2022-01-11T14:41:26.000Z (over 4 years ago)
- Last Synced: 2026-04-21T04:34:25.550Z (about 2 months ago)
- Topics: backend, gin-gonic, golang, mongo, rest-api
- Language: Go
- Homepage:
- Size: 186 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# simple-go-api
Example of Rest API built with gin-gonic, gorm, and mongo-go-driver
For Fun
# Table of contents:
- [Requirements](#requirements)
- [Getting started](#getting-started)
- [References](#references)
# Requirements
- Golang (duh)
- MongoDB
# Getting started
0. start docker
```shell
sudo systemctl start docker.service
```
1. mongodb
```
docker run --name fdm-mongo -p 27017:27017 -d mongo
```
if you already set it up
```
docker start fdm-mongo
```
2. redis
```
docker run -d -p 6379:6379 --name fdm-redis redis
```
# References
1. https://github.com/wangzitian0/golang-gin-starter-kit
2. https://github.com/Massad/gin-boilerplate
3. https://www.nexmo.com/blog/2020/03/13/using-jwt-for-authentication-in-a-golang-application-dr