https://github.com/shubhambansal1997/go-api-starter-kit
A starting point to start writing API in the golang
https://github.com/shubhambansal1997/go-api-starter-kit
Last synced: 3 months ago
JSON representation
A starting point to start writing API in the golang
- Host: GitHub
- URL: https://github.com/shubhambansal1997/go-api-starter-kit
- Owner: ShubhamBansal1997
- Created: 2018-02-24T18:16:43.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2018-02-25T20:57:54.000Z (over 7 years ago)
- Last Synced: 2025-01-04T20:46:20.140Z (5 months ago)
- Language: Go
- Size: 12.7 KB
- Stars: 2
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README

[](https://travis-ci.org/ShubhamBansal1997/go-api-starter-kit)
Welcome to **Go API Starter KIT**!
The fastest way to deploy a restful api's with [Gin Framework](https://gin-gonic.github.io/gin/) with a structured project that defaults to **PostgreSQL** database and **Redis** as the session storage.
## Configured with
* [go-gorp](https://github.com/go-gorp/gorp): Go Relational Persistence
* [RedisStore](https://github.com/gin-gonic/contrib/tree/master/sessions): Gin middleware for session management with multi-backend support (currently cookie, Redis).
* Built-in **CORS Middleware**
* Feature **PostgreSQL 9.6** JSON queries
* Unit test### Installation
```
$ go get github.com/ShubhamBansal1997/go-api-starter-kit
``````
$ cd $GOPATH/src/github.com/ShubhamBansal1997/go-api-starter-kit
``````
$ go get -t -v ./...
```> Sometimes you need to get this package manually
```
$ go get github.com/bmizerany/assert
```You will find the **database.sql** in `db/database.sql`
And you can import the postgres database using this command:
```
$ psql -U postgres -h localhost < ./db/database.sql
```## Running Your Application
```
$ go run *.go
```## Building Your Application
```
$ go build -v
``````
$ ./gin-boilerplate
```## Testing Your Application
```
$ go test -v ./tests/*
```## License
(The MIT License)