def list(self): url = util._base_url() + constants.CUSTOMER_URL _response = util._get(url) object_list = ListType(type=Customer) for item in _response: object_list.append(Customer(**item)) return object_list
def list(self): url = util._base_url() + constants.NOTIFICATION_URL _response = util._get(url) object_list = ListType(type=Notification) for item in _response: object_list.append(Notification(**item)) return object_list
def get(self, id:str): url = util._base_url() + constants.ORDER_GET_URL.format(ORDER_ID = id) self.__reponse__(**util._get(url)) return self
def get(self, id: str): url = util._base_url() + constants.NOTIFICATION_GET_URL.format( NOTIFICATION_ID=id) self.__reponse__(**util._get(url)) return self
def get(self, id=None): url = util._base_url() + (constants.WEBHOOK_GET_URL.format(RESOURCE_ID = id) if id else constants.WEBHOOK_URL) self.__reponse__(**util._get(url)) return self