feature/oauth #54
@ -11,7 +11,7 @@ from ..models import users, token
|
||||
from ..dependencies import database, cookie
|
||||
|
||||
from authlib.integrations.starlette_client import OAuth
|
||||
import httpx
|
||||
import httpx, os
|
||||
|
||||
SECRET_KEY = "09d25e094faa6ca2556c818166b7a9563b93f7099f6f0f4caa6cf63b88e8d3e7"
|
||||
ALGORITHM = "HS256"
|
||||
@ -22,8 +22,8 @@ pwd_context = CryptContext(schemes=["bcrypt"], deprecated="auto")
|
||||
oauth = OAuth()
|
||||
oauth.register(
|
||||
name="google",
|
||||
client_id="GOOGLE_CLIENT_ID",
|
||||
client_secret="GOOGLE_CLIENT_SECRET",
|
||||
client_id=os.environ["GOOGLE_CLIENT_ID"],
|
||||
client_secret=os.environ["GOOGLE_CLIENT_SECRET"],
|
||||
authorize_url="https://accounts.google.com/o/oauth2/auth",
|
||||
access_token_url="https://oauth2.googleapis.com/token",
|
||||
client_kwargs={"scope": "openid email profile"},
|
||||
|
@ -6,4 +6,5 @@ passlib[bcrypt]
|
||||
python-multipart
|
||||
fastapi-mail
|
||||
redis
|
||||
authlib
|
||||
authlib
|
||||
httpx
|
Loading…
x
Reference in New Issue
Block a user