henryz2004
custom handler
8ca8e46
raw
history blame contribute delete
400 Bytes
from handler import EndpointHandler
handler = EndpointHandler(".")
non_holiday_payload = {"inputs": "I am so sad", "date": "2022-01-04"}
holiday_payload = {"inputs": "I am so sad", "date": "2022-07-04"}
non_holiday_response = handler(non_holiday_payload)
holiday_response = handler(holiday_payload)
print("non_holiday_response:", non_holiday_response)
print("holiday_response:", holiday_response)