PlutoAuth
PlutoAuth is a Python SDK for interacting with the Pluto Authentication API. It provides a simple and pythonic way to use the API's functionality.
This library was made by the Official Pluto Authentication Team.
Installation
Use the package manager pip to install PlutoAuth.
pip install PlutoAuth
or
python3 -m pip install PlutoAuth
Example Usage
from PlutoAuth import PlutoAPI
db_uuid = "DBUUID - Get from dashboard"
db_user = {"username": "username", "password": "password"}
# Read database/userbase
api = PlutoAPI(db_uuid, db_user)
print(api.read_database()) # Should return the database as JSON
# Get the user who is currently signed in on the web
me = api.me(db_user.get('username'), db_user.get('password'))
print(me) # Should return the user object
print("Credits: " + me.credits)
API Methods
The PlutoAPI class provides the following methods:
me(username: str, password: str): Get the user who is currently signed in on the web.read_database(): Read database/userbase.add_db_user(new_user, permissions): Add a new access user to the database.remove_db_user(username): Remove a DB user from the database.update_db_user_permissions(username, permissions): Update a DB user's permissions.add_userbase_user(new_user, extra_fields=None): Add a new auth user to the database.remove_userbase_user(username): Remove an auth user from the database.update_userbase_user(update_user): Update an auth user's extra fields.authenticate_user(auth_user): Check the credentials of an auth user.
For more details on these methods and the data they require, refer to the Pluto API documentation. (Must be signed in to view)
Contributing
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
Please make sure to update tests as appropriate.
License
Release files for PlutoAuth 1.0.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| PlutoAuth-1.0.2.tar.gz | 4.3 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| PlutoAuth-1.0.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 9.1 kB
Release files / PlutoAuth-1.0.2.tar.gz
| Download URL | PlutoAuth-1.0.2.tar.gz |
|---|---|
| Size | 4.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
cf991afb77aa4aa7fc15619aec5188aaf69dad0429779a5b1b67a65c8e59635e
|
|
BLAKE2b-256 checksum How to use checksums |
e9bcd7dc0151a93cf0f5bd8da2026b1df12af27e870bb07f222d8b0784a69c40
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.0.0 CPython/3.11.5
|
Release files / PlutoAuth-1.0.2-py3-none-any.whl
| Download URL | PlutoAuth-1.0.2-py3-none-any.whl |
|---|---|
| Size | 4.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
5061a699319e459409e3f754873c804e4dce63cfef2a6b9e58ed723a02721a9a
|
|
BLAKE2b-256 checksum How to use checksums |
d01b2271ca4829757ddab5ba542fa2b1baba180175c44ad2b5914b2e75751c82
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.0.0 CPython/3.11.5
|