daniel
10/20/2023, 4:06 PMedgar_ramirez_mondragon
10/20/2023, 4:20 PMauth=
in the requests library API can be used as an authenticator.daniel
10/20/2023, 4:57 PMrequests-oauthlib
can be used as authenticators for OAuth2? the requests
library documentation mentions OAuth2 but simply links back to requests-oauthlib
which uses its own client for making requests, rather than the native requests
oneedgar_ramirez_mondragon
10/20/2023, 6:57 PMrequests-oauthlib
but it seems OAuth2Session
is a subclass of requests.Session
so you could use that in your stream class
class MyStream(RESTStream):
@property
def requests_session(self):
session = OAuth2Session(...)
return session