get_author¶
-
s2.api.get_author(authorId, api_key=None, session=None, return_json=False, retries=2, wait=150, **kwargs)¶ Look up information about an author in Semantic Scholar. Returns a
S2Authorobject describing the author.- Parameters
authorId (
str) – Semantic Scholar author identifier.api_key (
str, optional) – A Data Partners API key. Temporarily overwrites API key passed throughsession. Defaults toNonesession (
requests.Session, optional) – Arequests.Sessionobject, can be used to store an API key (see Using an API Key). Note thatapi_keywill overwrite this value temporarily if it is provided. Defaults toNonereturn_json (
bool, optional) – Return original json from get request (e.g. in case of PyS2-breaking changes to the S2 API). Defaults toFalseretries (
int, optional) – Number of retry attempts after rate limit is exceeded. Defaults to2wait (
int, optional) –Number of seconds to wait between retries if rate limit is exceeded (100 per 5 minute window for public API). Defaults to
150. This can be safely lowered with access to the Data Partners API (see Using an API Key)**kwargs (
Dict[str, any], optional) –- Keyword Args for
requests.Session.get(). Defaults to
{}
- Keyword Args for
- Returns
A
S2Authorordictobject describing the author- Return type