vimwiki: dth @ dth-MacBookAir
This commit is contained in:
parent
70d2d3b253
commit
e0b6b3d90c
1 changed files with 13 additions and 0 deletions
|
|
@ -11,3 +11,16 @@ def fetch_emojis():
|
||||||
|
|
||||||
def is_in_dict():
|
def is_in_dict():
|
||||||
return True
|
return True
|
||||||
|
|
||||||
|
import json
|
||||||
|
import requests
|
||||||
|
app_id = "<my_app_id>"
|
||||||
|
app_key = "<my_app_key>"
|
||||||
|
endpoint = "entries"
|
||||||
|
language_code = "en-us"
|
||||||
|
word = 'hello'
|
||||||
|
url = f'https://api.dictionaryapi.dev/api/v2/entries/en/{word}'
|
||||||
|
r = requests.get(url)
|
||||||
|
print("code {}\n".format(r.status_code))
|
||||||
|
print("text \n" + r.text)
|
||||||
|
print("json \n" + json.dumps(r.json()))
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue