kuzzle-plugin-auth-github v1.0.3
Plugin Github Authentication
This plugin provides a authentication with passportjs github strategy.
Manifest
This plugin doesn't need any right.
Configuration
You can override the configuration in your config/customPlugins.json
file in Kuzzle:
Name | Default value | Type | Description |
---|---|---|---|
persist | {} | Object | Attributes you want to persist if the user doesn't exist |
scope | [] | Array | List of attributes which requires rights to get |
profile | default | Array | Profile of the new persisted user |
clientID | String | Github clientID | |
clientSecret | String | Github secret | |
callbackUrl | String | Github callback url |
Here is an example of a configuration:
"kuzzle-plugin-auth-github": {
"version": "1.0.0",
"activated": true,
"name": "kuzzle-plugin-auth-github",
"defaultConfig": {
"persist": {}
},
"customConfig": {
"persist": [
"login",
"avatar_url",
"name",
"email"
],
"scope": [
"user:email",
"user:avatar_url"
],
"defaultProfile": "default",
"clientID": "<your-client-id>",
"clientSecret": "<your-client-secret>",
"callbackUrl": "http://host:7511/api/1.0/_login/github"
}
}
Usage
Just send following data to the auth controller:
{"body":{
"strategy": "github",
"username": "<username>"
}}
See Kuzzle API Documentation for more details about Kuzzle authentication mechanism.
How to create a plugin
See Kuzzle documentation about plugin for more information about how to create your own plugin.
About Kuzzle
For UI and linked objects developers, Kuzzle is an open-source solution that handles all the data management (CRUD, real-time storage, search, high-level features, etc).
Kuzzle features are accessible through a secured API. It can be used through a large choice of protocols such as REST, Websocket or Message Queuing protocols.