Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/adhityaramadhanus/userland

userland api
https://github.com/adhityaramadhanus/userland

Last synced: 22 days ago
JSON representation

userland api

Awesome Lists containing this project

README

        

# userland

[![Go Report Card](https://goreportcard.com/badge/github.com/AdhityaRamadhanus/userland)](https://goreportcard.com/report/github.com/AdhityaRamadhanus/userland) [![Build Status](https://travis-ci.org/AdhityaRamadhanus/userland.svg?branch=master)](https://travis-ci.org/AdhityaRamadhanus/userland)

User Management API, based on https://userland.docs.apiary.io

Entities:
User
Event
Session

Database: postgres, redis
Authentication: JWS


Installation |
Usage |
License




Userland is account self-management, imaginary APIs that will include following near-real-world features:

  • Registration

  • Activation

  • Authentication (with optional 2FA)

  • Forgot and Reset Password

  • Self Data ManagementManage Basic Info

    • Manage Profile Picture

    • Change Email

    • Change Password

    • Configure 2FA



  • Self Session Management

    • Manage Session

    • Manage Refresh Token

    • Manage Access Token

    • Event Logging

    • Self Delete



Installation (For Development)
-----------
* git clone
* set environtment variables in .env see (.env.sample)
* create database "userland" on postgres
* create database "userland_test" on postgres
* download migration cli
``` bash
(linux)
curl -L https://github.com/golang-migrate/migrate/releases/download/v4.1.0/migrate.linux-amd64.tar.gz | tar xvz
(mac Os)
curl -L https://github.com/golang-migrate/migrate/releases/download/v4.1.0/migrate.darwin-amd64.tar.gz | tar xvz
```
* run migration
``` bash
(linux)
./migrate.linux-amd64 -path storage/postgres/migration/ -database postgres://[user]:[pass]@localhost:5432?sslmode=disable up 2
(linux)
./migrate.darwin-amd64 -path storage/postgres/migration/ -database postgres://[user]:[pass]@localhost:5432?sslmode=disable up 2
```
* run build
```bash
make build-api
make build-mail
```
* run api and mail

Usage
-----
* You can find postman collection in docs folder

License
----

MIT © [Adhitya Ramadhanus]