diff options
| author | Jules Laplace <julescarbon@gmail.com> | 2019-05-03 19:11:07 +0200 |
|---|---|---|
| committer | Jules Laplace <julescarbon@gmail.com> | 2019-05-03 19:11:07 +0200 |
| commit | 4f823ca49a01becafdcd38c4d342080c1f29ce87 (patch) | |
| tree | e9cb3da884e9101561e6ad74adbbc908b58ba808 /scraper/s2.py | |
| parent | a53909352266a2258ddfa287508f979da59a9d1d (diff) | |
final report stuph
Diffstat (limited to 'scraper/s2.py')
| -rw-r--r-- | scraper/s2.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/scraper/s2.py b/scraper/s2.py index 26334de8..62fd9a94 100644 --- a/scraper/s2.py +++ b/scraper/s2.py @@ -178,7 +178,7 @@ class SemanticScholarAPI(object): @staticmethod def search(q, page=1, pageSize=10, yearFilter=None): - resp = requests.post(SemanticScholarAPI.SEARCH_ENDPOINT, json={ + query = { 'authors': [], 'coAuthors': [], 'facets': {}, @@ -190,6 +190,7 @@ class SemanticScholarAPI(object): 'sort': "relevance", 'venues': [], 'yearFilter': yearFilter, - }, headers=SemanticScholarAPI.headers) + } + resp = requests.post(SemanticScholarAPI.SEARCH_ENDPOINT, json=query, headers=SemanticScholarAPI.headers) # print(resp.status_code) return None if resp.status_code != 200 else resp.json() |
