Installation

python-social-auth is a very modular library looking to provide the basic tools to implement social authentication / authorization in Python projects. For that reason, the project is split in smaller components that focus on providing a simpler functionality. Some components are:

Dependencies

Dependencies are defined in each component’s package metadata (pyproject.toml for the core and Django integration). There are some extras defined to install the corresponding dependencies since they are required to build extensions that, unless used, are undesired.

There’s also the all extra that will install all the extra options.

Several backends demand application registration on their corresponding sites and other dependencies like SQLAlchemy on Flask and Webpy.

Get a copy

From PyPI:

$ pip install social-auth-<component>

Or, clone the relevant repository from GitHub and install it in a virtual environment. For example, to install the core library from source:

$ git clone https://github.com/python-social-auth/social-core.git
$ cd social-core
$ python -m venv .venv
$ . .venv/bin/activate
$ python -m pip install .

On Windows, activate the environment with .venv\Scripts\activate instead. For editable installations and working on multiple components together, see Development setup.

Using the extras options

To enable any of the extras options to bring the dependencies for SAML, or all:

$ pip install "social-auth-core[saml]"
$ pip install "social-auth-core[all]"