Implementing Social Login #440
Unanswered
fugacityengr
asked this question in
Q&A
Replies: 1 comment 3 replies
-
@fugacityengr I've integrated with things like Google Sign-In with some of my own apps. There isn't really anything explicitly built into Piccolo to support it. If you're trying to make the admin work with third party login, you could override the piccolo/piccolo/apps/user/tables.py Line 153 in 503bf24 For example: from piccolo.apps.user.tables import BaseUser
class CustomBaseUser(BaseUser):
@classmethod
async def login(cls, username: str, password: str) -> t.Optional[int]:
# Call a third party endpoint, if valid return user ID Then with Piccolo admin you can do: create_admin(tables=[Table1, Table2], auth_table=CustomBaseUser) Is that the kind of thing you're looking for? |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello, I very much like the batteries-included approach by this ORM compared to other ORMs that can be used with FastAPI.
However, I cannot seem to find discussions nor documentation for how to implement social logins (OAuth2) using Piccolo ORM.
Could anyone point me to an example or a discussion that I could follow to implement social login with Piccolo ORM?
Beta Was this translation helpful? Give feedback.
All reactions