import requests
day = 1
month = 1
text = 'russia'
api_key = 'api key'
api_url = f'https://api.api-ninjas.com/v1/historicalevents?text={text}&day={day}&month={month}'
response = requests.get(api_url, headers={'X-Api-Key': api_key})
if response.status_code == requests.codes.ok:
print(response.text)
else:
print("Error:", response.status_code, response.text)