Boilerplate API template includes all the common packages and setup used for API development in this Company

Boilerplate API

Boilerplate API template includes all the common packages and setup used for API development in this Company.

Development

  • Copy .env.example to .env and update according to requirement.
  • Create serviceAccountKey.json file for firebase admin sdk.
  • To run docker-compose up (with default configuration will run at 5000 and adminer runs at 5001)

Run Boilerplate CLI 🖥

  • Run docker-compose exec web sh
  • After running type ./__debug_bin cli you will start cli application.
  • Choose the commands to run afterwards.

Migration Commands 🛳

Command Desc
make migrate-up runs migration up command
make migrate-down runs migration down command
make force Set particular version but don't run migration
make goto Migrate to particular version
make drop Drop everything inside database
make create Create new migration file(up & down)
make crud Create crud template

Implemented Feature

  • Dependency Injection (go-fx)
  • Routing (gin web framework)
  • Environment Files
  • Logging (file saving on production) zap
  • Middlewares (cors)
  • Middleware transaction
  • Database Setup (mysql)
  • Models Setup and Automigrate (gorm)
  • Repositories
  • Implementing Basic CRUD Operation
  • CRUD Scaffold Generator
  • Migration Runner Implementation
  • Live code refresh
  • Firebase basic setup.
  • GCP Cloud Storage bucket setup.
  • Twilio Basic setup.
  • Gmail Api Setup.

For Debugging 🐞 Debugger runs at 5002. Vs code configuration is at .vscode/launch.json which will attach debugger to remote application.

For auto generate of CRUD(Create, ReaD, Update & Delete) api following informations are needed and will be asked in terminal:

  • project-name : The name of the project or the main module name. example: boilerplate-api,watamuki-api etc.
  • resource-name: name of CRUD in upper camelCase. examples:Food,Puppy,ProductCategory etc.
  • resource-table-name: name of CRUD in lower snake case. examples:food,puppy,product_category etc.
  • plural-resource-name: plural name of CRUD in Upper camelCase. examples:Foods,Puppies,ProductCategories etc.
Similar Resources

GoFrame is a modular, powerful, high-performance and enterprise-class application development framework of Golang.

GoFrame is a modular, powerful, high-performance and enterprise-class application development framework of Golang.

GoFrame English | 简体中文 GoFrame is a modular, powerful, high-performance and enterprise-class application development framework of Golang. If you're a

Jan 2, 2023

go-zero is a web and rpc framework written in Go. It's born to ensure the stability of the busy sites with resilient design. Builtin goctl greatly improves the development productivity.

go-zero is a web and rpc framework written in Go. It's born to ensure the stability of the busy sites with resilient design. Builtin goctl greatly improves the development productivity.

go-zero English | 简体中文 0. what is go-zero go-zero is a web and rpc framework that with lots of engineering practices builtin. It’s born to ensure the

Jan 2, 2023

Roche is a Code Generator and Web Framework, makes web development super concise with Go, CleanArch

Roche is a Code Generator and Web Framework, makes web development super concise with Go, CleanArch

It is still under development, so please do not use it. We plan to release v.1.0.0 in the summer. roche is a web framework optimized for microservice

Sep 19, 2022

Rest API Template [GO + Fiber + Mongo]

GoFiber MongoDB Rest API Template Feature: Full CRUD REST API MongoDB native driver; no use of orm/odm How to structure a production ready API (Model/

Jan 6, 2022

A minimal framework to build web apps; with handler chaining, middleware support; and most of all standard library compliant HTTP handlers(i.e. http.HandlerFunc).

A minimal framework to build web apps; with handler chaining, middleware support; and most of all standard library compliant HTTP handlers(i.e. http.HandlerFunc).

WebGo v4.1.3 WebGo is a minimalistic framework for Go to build web applications (server side) with zero 3rd party dependencies. Unlike full-fledged fr

Jan 1, 2023

Flamingo Framework and Core Library. Flamingo is a go based framework for pluggable web projects. It is used to build scalable and maintainable (web)applications.

Flamingo Framework and Core Library. Flamingo is a go based framework for pluggable web projects. It is used to build scalable and maintainable (web)applications.

Flamingo Framework Flamingo is a web framework based on Go. It is designed to build pluggable and maintainable web projects. It is production ready, f

Jan 5, 2023

A simple api server which can be used as backend of a e-bookstore

BookstoreAPIServer A simple api server which can be used as backend of a e-bookstore. User can get list of books and authors. Details of a book can be

Nov 8, 2022

Goal is a toolkit for high productivity web development in Go language in the spirit of Revel Framework that is built around the concept of code generation.

Goal Goal is a set of tools for high productivity web development in Go language. Goal, being mostly inspired by Revel Framework and its discussions,

Sep 27, 2021

Rapid Web Development w/ Go

Buffalo A Go web development eco-system, designed to make your project easier. Buffalo helps you to generate a web project that already has everything

Jan 1, 2023
This library provides a simple framework of microservice, which includes a configurator, a logger, metrics, and of course the handler

Microservice The framework for the creation of microservices, written in Golang. (note: http microservice) Architecture microservice includes: handle

Dec 30, 2022
Simple REST-API implementation using Golang with several packages (Echo, GORM) and Docker

Simple REST-API Boilerplate This is a simple implementation of REST-API using Golang and several packages (Echo and GORM). By default, I use PostgreSQ

Sep 13, 2022
Kubewrap - kubewrap is an kubernetes command line utility with a focus to explore the kubernetes REST API's leveraging the go libraries available along with golang and cobra packages.

Kubewrap kubewrap is an kubernetes cli wrapper with a focus to explore the kubernetes REST API's leveraging the go libraries available along with gola

Nov 20, 2022
REST API boilerplate built with go and clean architecture - Echo Framework

GO Boilerplate Prerequisite Install go-migrate for running migration https://github.com/golang-migrate/migrate App requires 2 database (postgreSQL an

Jan 2, 2023
Opinionated boilerplate Golang HTTP server with CORS, OPA, Prometheus, rate-limiter for API and static website.
Opinionated boilerplate Golang HTTP server with CORS, OPA, Prometheus, rate-limiter for API and static website.

Teal.Finance/Garcon Opinionated boilerplate HTTP server with CORS, OPA, Prometheus, rate-limiter… for API and static website. Origin This library was

Nov 3, 2022
A Golang restful API boilerplate based on Echo framework v4

A Golang restful API boilerplate based on Echo framework v4. Includes tools for module generation, db migration, authorization, authentication and more.

Nov 15, 2022
Go Fiber Boilerplate with Gorm ORM

Go Fiber Boilerplate with Gorm ORM This boilerplate app is using Go version 1.17 because I think for now this is the most updated release. Installatio

Jul 30, 2022
Generate boilerplate + endpoints for Fiber REST APIs.

gomakeme Generate boilerplate + endpoints for Fiber REST APIs. Never spend 6 minutes doing something by hand when you can spend 1 week to automate it

Dec 30, 2022
QOR is a set of libraries written in Go that abstracts common features needed for business applications, CMSs, and E-commerce systems.

QOR English Chat Room: 中文聊天室: For security issues, please send us an email to [email protected] and give us time to respond BEFORE posting as an iss

Jan 2, 2023