go-mux-jwt-boilerplate - Golang REST API using MUX, GORM, and JWT for authentication

  •        17

The purpose of this web app is for me to learn Go REST API Development using Mux (router), Gorm (ORM), JSON Web Tokens (JWT), and Golang development in general. The application is optimized for Heroku deployment using the Go Build Kit and Godep for dependency management. Several routes are protected and require JWT tokens, which can be generated using the login route. You will need to create a user by sending a post request to the createUser route.

https://github.com/hellojebus/go-mux-jwt-boilerplate

Tags
Implementation
License
Platform

   




Related Projects

golang-gin-realworld-example-app - Exemplary real world application built with Golang + Gin

  •    Go

This codebase was created to demonstrate a fully fledged fullstack application built with Golang/Gin including CRUD operations, authentication, routing, pagination, and more.

laravel-adminpanel - A Laravel 5 Admin Panel (version : 5.7)

  •    PHP

Give your project a Head Start by using laravel-adminpanel. It gives you the ability to create a module using a sweet GUI, where you put in the Module Name and it will generate all the necessary files for you, like Model, Traits, Relationship, Migration, Controllers, Views and routes. So when you are done creating a module, you can directly go to the route generated and see your new module. Since, this does not have the ability to generate table fields for now, so you have to write the migration file that is generated and run a manual php artisan migrate command, and you are good to go.

mux - A powerful URL router and dispatcher for golang.

  •    Go

Package gorilla/mux implements a request router and dispatcher for matching incoming requests to their respective handler. The name mux stands for "HTTP request multiplexer". Like the standard http.ServeMux, mux.Router matches incoming requests against a list of registered routes and calls a handler for the route that matches the URL or other conditions.

go-base - Go RESTful API Boilerplate with JWT Authentication backed by PostgreSQL

  •    Go

Easily extendible RESTful API boilerplate aiming to follow idiomatic go and best practice. The goal of this boiler is to have a solid and structured foundation to build upon on.

laravel-api-boilerplate-jwt - An API Boilerplate to create a ready-to-use REST API in seconds.

  •    PHP

What I made is really simple: an integration of these three packages and a setup of some authentication and credentials recovery methods. Once the project creation procedure will be completed, run the php artisan migrate command to install the required tables.


jwt-go - Golang implementation of JSON Web Tokens (JWT)

  •    Go

BREAKING CHANGES:* Version 3.0.0 is here. It includes a lot of changes including a few that break the API. We've tried to break as few things as possible, so there should just be a few type signature changes. A full list of breaking changes is available in VERSION_HISTORY.md. See MIGRATION_GUIDE.md for more information on updating your code.NOTICE: It's important that you validate the alg presented is what you expect. This library attempts to make it easy to do the right thing by requiring key types match the expected alg, but you should take the extra step to verify it in your usage. See the examples provided.

mux - mux is a lightweight HTTP request router

  •    Go

mux is a lightweight fast HTTP request router (also called multiplexer or just mux for short) for Go 1.7. The difference between the default mux of Go's net/http package and this mux is, it's supports variables and regex in the routing pattern and matches against the request method. It also scales better.

Bebop - Simple discussion board / forum web application.

  •    Go

Bebop is a simple discussion board / forum web application.Create a new empty database (MySQL оr PostgreSQL) that will be used as a data store and a database user with all privileges granted on this database.

go-jwt-middleware - A Middleware for Go Programming Language to check for JWTs on HTTP requests

  •    Go

A middleware that will check that a JWT is sent on the Authorization header and will then set the content of the JWT into the user variable of the request.This module lets you authenticate HTTP requests using JWT tokens in your Go Programming Language applications. JWTs are typically used to protect API endpoints, and are often issued using OpenID Connect.

angular-sailsjs-boilerplate - 'Boilerplate' for AngularJS + Sails.js

  •    Javascript

Modern web applications has separated front- and backend sides to use. This 'boilerplate' present one way to make your application which have fully separated back- and frontend sides. And really this is more than just a boilerplate, proper term would be 'example application'. First of all you have to install npm and node.js to your box. Installation instructions can be found here.

httprouter - A high performance HTTP request router that scales well

  •    Go

HttpRouter is a lightweight high performance HTTP request router (also called multiplexer or just mux for short) for Go.In contrast to the default mux of Go's net/http package, this router supports variables in the routing pattern and matches against the request method. It also scales better.

feature-flags - Feature flags API written in Go

  •    Go

This package uses boltdb/bolt, a key-value store for storage. You do not need to connect another database! The HTTP routing is done by gorilla/mux. Feature flags let you enable or disable some features of your application, for example when you're under unexpected traffic or when you want to let some users try a new feature you've been working on. They decouple feature release and code deployment, so that you can release features whenever you want, instead of whenever the code happens to ship.

go-jose - An implementation of JOSE standards (JWE, JWS, JWT) in Go

  •    Go

Package jose aims to provide an implementation of the Javascript Object Signing and Encryption set of standards. This includes support for JSON Web Encryption, JSON Web Signature, and JSON Web Token standards.Disclaimer: This library contains encryption software that is subject to the U.S. Export Administration Regulations. You may not export, re-export, transfer or download this code or any part of it in violation of any United States law, directive or regulation. In particular this software may not be exported or re-exported in any form or on any media to Iran, North Sudan, Syria, Cuba, or North Korea, or to denied persons or entities mentioned on any US maintained blocked list.

APNS/2- ⚡ HTTP/2 Apple Push Notification Service (APNs) push provider for Go

  •    Go

APNS/2 is a go package designed for simple, flexible and fast Apple Push Notifications on iOS, tvOS, OSX and Safari using the new HTTP/2 Push provider API.

jose - A comprehensive set of JWT, JWS, and JWE libraries.

  •    Go

JOSE is a comprehensive set of JWT, JWS, and JWE libraries.The only other JWS/JWE/JWT implementations are specific to JWT, and none were particularly pleasant to work with.

traffic - Sinatra inspired regexp/pattern mux and web framework for Go

  •    Go

Package traffic - a Sinatra inspired regexp/pattern mux for Go.development is the default environment. The above middlewares are loaded only in development.

traffic - Sinatra inspired regexp/pattern mux and web framework for Go [NOT MAINTAINED]

  •    Go

Package traffic - a Sinatra inspired regexp/pattern mux for Go. development is the default environment. The above middlewares are loaded only in development.

mux - A high performance and powerful trie based url path router for Go.

  •    Go

A high performance and powerful trie based url path router for Go. This router supports fixed and regex rules in routing pattern, and matches request method. It's optimized by trie structure for faster matching and large scale rules.

jwt-auth-guard - JWT Auth Guard for Laravel and Lumen Frameworks.

  •    PHP

JWT Auth Guard is a Laravel & Lumen Package that lets you use jwt as your driver for authentication guard in your application. The Guard uses tymon/jwt-auth package for authentication and token handling.

jwtproxy - An HTTP-Proxy that adds AuthN through JWTs

  •    Go

The JWT proxy is intended to be used as a complementary service for authenticating, and possibly authorizing requests made between services. There is a forward proxy component, which can be configured to sign outgoing requests to another service, and a reverse proxy component, which can be used to authenticate incoming requests from another service.The JWT forward proxy is used to sign outgoing requests with a JWT using a private key.