Skip to content

advanced-server-architecture/centralized-user-management-service

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Introduction

API

Application API

All request must be signed (see util/signRequest.js for detail).

Sign Up

POST /signup

--

Request

{
	method: String,  // username/phone
	account: String, // username/phone number
	secret: String   // password
}

Response

[{
	_id: String
}]

Sign in

POST /authorize

--

Request

{
	method: String,  // username/phone
	account: String, // username/phone number
	secret: String   // password
}

Response

[
	{
		token: String,
      	expireAt: Number,
      	scope: {
 			scopeId: String,
 			scopeName: String     
      	},  // only presents when user is owner of an application.
		roles: [{
			_id: String,
			scopeId: String,
			scope: String,
			scopeName: String,
			name: String,
		}],
		permissions: [{
			_id: String,
			scopeId: String,
			scope: String,
			scopeName: String,
			name: String,
		}],
		profiles: [{
			application: String
		}]
    }
  ]

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published