Hi . while working with kavenegar API , i encountered with an issue :
from kavenegar import *
def send_otp_code(phone_number , code):
try:
api = KavenegarAPI('my_api_key', timeout=20)
params = {
'sender': '2000660110', # optional
'receptor': phone_number, # multiple mobile number, split by comma
'message': f'{code} کد تایید شما '
}
response = api.sms_send(params)
print(response)
except APIException as e:
print(e)
except HTTPException as e:
print(e)
The error : TypeError: KavenegarAPI.__init__() got an unexpected keyword argument 'timeout'