
import requests
import sys

API_KEY = "d4470516"
SEARCH_TERM = str(sys.argv[1])

url = f"http://omdbapi.com?apikey={API_KEY}&i={SEARCH_TERM}&plot=full"
print(f"{url}")
#http://www.omdbapi.com/?i=tt0462499&plot=full
response = requests.get(url).json()

    # Check if the API returned valid search results
if response.get("Response") == "True":
    search_results = response.get("Search", [])
    print(f"{response}")

