Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Request for AIOHTTP client #26

Open
rishabhpoddar opened this issue Oct 9, 2021 · 2 comments
Open

Request for AIOHTTP client #26

rishabhpoddar opened this issue Oct 9, 2021 · 2 comments

Comments

@rishabhpoddar
Copy link
Contributor

supertokens/supertokens-core#53

@divyanshudimri
Copy link

Hello @rishabhpoddar Can i try to help on this? Let me know your feedback.

@rishabhpoddar
Copy link
Contributor Author

hey @divyanshudimri sure! We are happy that you would like to help out.

On a high level, the way the python SDK is built is that it exposes a few APIs based on what the user wants to use. These APIs are written in a web framework agnostic manner. This means that the same API logic is shared across different web frameworks (django, flask, fastpi at the moment). This is achieved by the API logic using a base request and response class, which are implemented by the various web frameworks.

There is also a middleware function that needs to be implemented for each of these frameworks which is responsible for intercepting all API calls and calling the internal middleware function that actually handles the call if needed. An example of this for flask is here.

Finally, you would need to implement the verify_session middleware which can be used by the user for session verification. This would call the internal verify_session function. An example of this for flask is here

The contributing guide for python is empty at the moment, so feel free to join our discord community and I can help you setup the dev env fairly quickly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants