Module pyreddit.services.generic_service
Service for when a suitable specific service is not found.
Classes
class Generic-
Service for when a suitable specific service is not found.
Ancestors
Class variables
var has_external_request : bool-
Inherited from:
Service.has_external_requestTrue if the service needs to reach out to an external http endpoint, False otherwise.
var is_authenticated : bool-
Inherited from:
Service.is_authenticatedTrue if the external request needs to be authenticated (i.e. with an Authorization header), False otherwise …
var access_token : Union[str, NoneType]-
Inherited from:
Service.access_tokenContains the access token for the OAuth authentication if present, None otherwise …
Static methods
def postprocess(response) ‑> Media-
Override of
Service.postprocess()method. def preprocess(url: str, data: Any) ‑> str-
Inherited from:
Service.preprocessPreprocess the media URL coming from Reddit json …
def get(url: str) ‑> Union[requests.models.Response, str]-
Get the media information …
def authenticate() ‑> NoneType-
Inherited from:
Service.authenticateAuthenticate the service on the service provider API …
def get_media(url: str, data: Any) ‑> Media-
Inherited from:
Service.get_mediaEntrypoint of the class …