I have this API response, I want to take some values and store them as variables for a python BOT for example 'floor_price' (I want the integer after it ofc) but for some reason, it's not working it keeps giving me errors but when I try it with 'stats' it works and gives everything.
The API https://api.opensea.io/api/v1/collection/ogcats-harvest-galaxy/stats
url = "https://api.opensea.io/api/v1/collection/ogcats-harvest-galaxy/stats"
headers = {"Accept": "application/json"}
response = requests.request("GET", url)
json_response = response.json()
floor= json_response['floor_price']
pls help :)
url = "https://api.opensea.io/api/v1/collection/ogcats-harvest-galaxy/stats"
headers = {"Accept": "application/json"}
response = requests.request("GET", url)
json_response = response.json()
floor= json_response['stats']['floor_price']
credits: @kindall