Librería para añadir autenticación con Google en aplicaciones web con el framework de Streamlit.
Project description
Author: @valantoni
☕ Apoya al desarrollador aquí / Support me here
Installation
pip install google-auth-st
🔐 google-auth-st
A python package for adding google auth to your streamlit apps!
Documentation
Once you configure the authentication on st.secrets
, you can use the the library methods to conditionally render the content of the page:
from google_auth_st import add_auth
add_auth()
#after authentication, the email is stored in session state
st.write(st.session_state.email)
This package expects that you have a .streamlit/secrets.toml
file which you will have to create. Inside it, you will need to add Google API information that runs the authentication parts of the package. If you already have all of your information for authentication providers, here is how the package expects your secrets file to look.
redirect_uris = "http://localhost:8501/"
testing_mode = true
client_id = ''
client_secret = ''
redirect_url_test = 'http://localhost:8501/'
redirect_url = "https://your_app_url..."
Feedback:
If you have feedback about this package, please reach out to me on instagram.
Shotout
Shotout to @tylerjrichards for creating the st-paywall package and inspiring me to create this new version without the payment method.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file google-auth-st-1.3.tar.gz
.
File metadata
- Download URL: google-auth-st-1.3.tar.gz
- Upload date:
- Size: 4.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.9.18
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | ef1cd8f349afa33aa503d5f2c4ff979b3b044a5abb536db0dd0e250fb3537bae |
|
MD5 | a3dcdc9f7a8c515654ac1670eb1c113c |
|
BLAKE2b-256 | 2fdfb916176ee998af28b32389ca9d239b6c36232ede5114c18c1c83f27cd708 |
File details
Details for the file google_auth_st-1.3-py3-none-any.whl
.
File metadata
- Download URL: google_auth_st-1.3-py3-none-any.whl
- Upload date:
- Size: 4.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.9.18
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5bb0267b27b73963b3c11d684abf37f7f98410aebda691dc4f76cb9f0b0dbdda |
|
MD5 | d116cbd2335a899aabf6cf7cbadd0e32 |
|
BLAKE2b-256 | eaf4cccfad56fbfd4759c0a64ef1d350092a59d390e5b84d4a98c05e33c09221 |