A simple example of a self hosted OAuth2 password provider. It can be used to authenticate users in own applications with password flow.
- create a Python virtual environment
python -m venv venv
- install dependencies
pip install -r requirements.txt
- run the dev server
python server.py
- look at example.http to find at the example requests
/api/register
- register a new user/api/token
- get a new access token/api/refresh
- refresh an access token/api/revoke
- revoke an access token/api/anonymous
- get a resource without authentication/api/protected
- get a resource with authentication