Created
March 19, 2020 22:58
-
-
Save imvladikon/3bfb39f4f0c844581c3b457022482594 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pprint | |
import requests | |
import json | |
QUERY = 'meaning' | |
DICTIONARY_API = 'https://dictionary.yandex.net/api/v1/dicservice.json/lookup' | |
YNDX_TMP_KEY = 'dict.1.1.20171114T131015Z.59d0570f825aeb6d.aa00fdbd5ee643a6cb790c0963c0946115ceef55' | |
params = {'key' : YNDX_TMP_KEY, 'lang' : 'en-ru', 'text' : QUERY} | |
req =requests.get(DICTIONARY_API, params = params) | |
pprint.pprint(json.loads(req.text)['def']) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment