minimal example
This commit is contained in:
parent
5d18be471c
commit
483c2bef68
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
|||||||
|
.idea
|
17
main.py
Normal file
17
main.py
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
import requests
|
||||||
|
|
||||||
|
|
||||||
|
def fetch_list(list_url, page):
|
||||||
|
headers = {"accept": "application/ld+json"}
|
||||||
|
url = list_url + "?page={}".format(page)
|
||||||
|
result = requests.get(url, headers=headers)
|
||||||
|
return result
|
||||||
|
|
||||||
|
|
||||||
|
if __name__ == '__main__':
|
||||||
|
list_url = "https://wyrms.de/user/j12i/books/reading"
|
||||||
|
list = fetch_list(list_url, page=1)
|
||||||
|
list_dict = list.json()
|
||||||
|
for key, val in list_dict.items():
|
||||||
|
print("{}: {}".format(key, val))
|
||||||
|
|
Loading…
x
Reference in New Issue
Block a user