Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ```
- website: https://www.semanticscholar.org/search?q=machine%20learning&sort=relevance
- I'm trying to calling the API of that website but it's keep replying back with
- {'error': 'Sorry, an unexpected error occured. Please try again soon.'}
- But it's works fine from browser !
- ```
- import requests
- from bs4 import BeautifulSoup
- data = {
- "queryString": "machine learning",
- "page": 1,
- "pageSize": 10,
- "sort": "relevance",
- "authors": [],
- "coAuthors": [],
- "venues": [],
- "yearFilter": 'null',
- "requireViewablePdf": 'false',
- "publicationTypes": [],
- "externalContentTypes": []
- }
- r = requests.post(
- 'https://www.semanticscholar.org/api/1/search', json=data).json()
- print(r)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement