oauth-client-nestjs
This package includes client oauth authentication module based upon nest.
This package includes vcita authentication, and can also interact with additional providers.
Installation
install this package using npm in nest app.
You should add these env variables (you can add then on .env file):
- VCITA_CLIENT_ID
- VCITA_CLIENT_SECRET
- VCITA_AUTHORIZATION_CLIENT: client authorization url
- VCITA_APP_SERVER: vcita api server
- APPLICATION_URL
Usage
This is a dynamic module. To use it you should call register method:
OauthModule.register({ })
register configuration (all of then are optional)
- useApplicationConnection: boolean, use existing db connection or not.
- databaseConfig: if not using database connection, db connection settings.
- applicationConfig: to implement oauth flow with another provider, add a json config file.
- logger: a logger for the app.