ECPAuthSessionMixin¶
- class requests_ecp.ECPAuthSessionMixin(idp=None, kerberos=False, username=None, password=None, **kwargs)[source]¶
Bases:
objectA mixin for
requests.Sessionto add default ECP Auth.This creates a default
authattribute on createdSessionobjects as an instance of theHTTPECPAuthauthorisation plugin:from requests import Session from requests_ecp import ECPAuthSessionMixin class MySession(ECPAuthSessionMixin, Session): pass
This can be mixed with any other
Sessionmixins, but beware of the inheritance order that may impact which mixin preserves the finalauthattribute.See also
requests_ecp.SessionFor a ready-made wrapped
Session.