Skip to content

Commit

Permalink
API call
Browse files Browse the repository at this point in the history
Making an API call, getting hold of the data, and getting to know what the data looks like.
  • Loading branch information
Uma2197 authored Apr 21, 2024
1 parent d955399 commit 151ee53
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions main.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import requests

api_endpoint = "https://uk.api.just-eat.io/discovery/uk/restaurants/enriched/bypostcode/EC4M7RF"
headers = {
'User-Agent': 'Mozilla/5.0'
}
response = requests.get(url=api_endpoint, headers=headers)
api_data = response.json()
print(api_data)

0 comments on commit 151ee53

Please sign in to comment.