import requests

# Many APIs use ?key=value to filter results
base = "https://api.datamuse.com/words"
params = {"rel_rhy": "wand", "max": 3}   # words that rhyme with “wand”
response = requests.get(base, params=params)

if response.status_code == 200:
    words = response.json()   # list of dicts
    for entry in words:
        print(entry["word"])
