Questions tagged [flask-oauthlib]

77 questions
1
vote
1 answer

How to get gmail messages with the Flask OAuthlib?

I'm building a website using flask, in which people can authorize my website for their gmail account using the Flask-OAuthlib. The initial authorization works fine and after that I can get the userinfo like this: userinfo =…
kramer65
  • 50,427
  • 120
  • 308
  • 488
0
votes
0 answers

flask_oauthlib invalid response from discord

I am currently writing a discord dashboard for my discord bot and using flask oauth library to deal with the oauth from discord. This is the code that is handling the oauth. @app.route('/login') def login(): return…
Knife worm
  • 67
  • 6
0
votes
0 answers

Is there an example-oauth2-server repo for jwt access token instead of opaque?

This repo https://github.com/authlib/example-oauth2-server is amazing. But there is very little flexibility. Is there any repo existing that creates an OAuth Authorization Server to deliver a JWT access token instead of opaque token?
Safdar Mirza
  • 89
  • 3
  • 11
0
votes
1 answer

Flask Facebook Login using Oauthlib - redirect problem

I would like to implement Facebook login using Flask. Here is the function which is called to request service from Facebook @users_view.route('/facebook/') def facebook(): credentials = current_app.config['OAUTH_CREDENTIALS']['facebook'] …
0
votes
1 answer

TypeError: 'ResourceProtector' object is not callable

According to the Authlib documentation, there is a built-in approach to use introspection endpoint to validate the given token when resource server has no access to token database: import requests from authlib.oauth2.rfc7662 import…
Alex
  • 1
0
votes
0 answers

Python requests-oauthlib - adding parameters to authorization header for Oauth1 request

In my Flask App, I'm using the Python requests-oauthlib library to make OAuth1 requests (https://requests-oauthlib.readthedocs.io/en/latest/oauth1_workflow.html#). One of the API calls that I need to make require passing the…
Vee
  • 1,821
  • 3
  • 36
  • 60
0
votes
1 answer

Spotify API create playlist - error parsing JSON

I have a Flask app where I want to create playlists using Spotify API. My issue is similar to this Stackoverflow question. The difference is that I am using OAuthlib instead of requests and the solution posted there didn't work in my case. The…
Ewelina Luczak
  • 379
  • 4
  • 13
0
votes
1 answer

How can I send Authlib requests through a proxy?

With requests I can make a request through a proxy: import requests proxies = { "http": "http://proxy.yourorg.com:80", "https": "http://proxy.yourorg.com:80" } url = 'http://myorg.com/example' response = requests.post(url,…
Justin Oroz
  • 614
  • 8
  • 14
0
votes
1 answer

Automatic sso login

I want to implement sso for multiple providers in my app. Currently I am using flask-oauthlib for the authentication. For google authentication sso login works like a charm. Since I will have multiple sso providers, I was wondering if I could…
baconStrips
  • 101
  • 9
0
votes
1 answer

Flask Dance oauth on different domains

I am implementing a Oauth for different services and I am using "OAuth2ConsumerBlueprint" (using flask-dance). I was thinking about Flask-OAuth but I think I would end up with the same issues I am facing with Flask-Dance. What I am planning to do…
Rob
  • 89
  • 6
0
votes
1 answer

How can I use oauth.create_client in different file than the one I called the constructor, in Authlib?

I need to connect to a website using Authlib. I am a newbie at this, so I studied some tutorials: one., two, three All of them gave the following structure: create the app instance; create the oauth instance, passing app to the OAuth…
Bogdan Doicin
  • 2,342
  • 5
  • 25
  • 34
0
votes
1 answer

Airflow GitHub Authentication Failing

I have a working instance of Airflow already. I am now trying to set up Airflow with GitHub Enterprise Authentication. There is not much available as far as documentation and I did not find any good examples online so I am having some trouble. …
mattc-7
  • 432
  • 1
  • 10
  • 24
0
votes
1 answer

github.GithubException.GithubException: 401 on Heroku when want to create a repo on user's public repo- Github API

I am making this app using python, Flask_OAuthlib, and heroku to get access to the public repo of user's Github and create a repo and copy the required files over there. The app gets connected and also receives the following permissions as an…
BobbyF
  • 431
  • 1
  • 7
  • 19
0
votes
1 answer

Flask-OAuth TypeError: Unicode-objects must be encoded before hashing

I'm trying to use Flask-OAuth with Facebook following this example. I have define APP_ID and APP_SECRET according to mine. I can login with facebook account now, but when it redirects after login, I got this error: TypeError: Unicode-objects must be…
Tri
  • 2,722
  • 5
  • 36
  • 65
0
votes
1 answer

Trusted clients

I need to add trusted clients in SSO using Authlib. These clients are parts of my system and I don't need to the user confirmed it. Now, I use the next code for authorization: @bp.route("/oauth/authorize", methods=['GET', 'POST']) def…
Denis Sologub
  • 7,277
  • 11
  • 56
  • 123