I have an application with messenger integration and using the list_integrations method, returns the next exception because de page_access_token is None en the API response.
example code with get:
with sc.ApiClient(configuration) as api_client: api_instance = sc.IntegrationsApi(api_client) api_response = api_instance.get_integration(app_id, integration_id)
example code with list:
with sc.ApiClient(configuration) as api_client: api_instance = sc.IntegrationsApi(api_client) api_response = api_instance.list_integrations(app_id=app_id)
Error:
Traceback (most recent call last): File "/Users/dfalcon/Code/smooch/poc_sunshine_conversations_v2/src/smooch/integrations/get.py", line 26, in <module> get() File "/Users/dfalcon/Code/smooch/poc_sunshine_conversations_v2/shared/exception_handler.py", line 7, in handler return func(*args, **kwargs) File "/Users/dfalcon/Code/smooch/poc_sunshine_conversations_v2/src/smooch/integrations/get.py", line 18, in get api_response = api_instance.get_integration(app_id, integration_id, _return_http_data_only=False) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api/integrations_api.py", line 311, in get_integration return self.get_integration_with_http_info(app_id, integration_id, **kwargs) # noqa: E501 File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api/integrations_api.py", line 394, in get_integration_with_http_info return self.api_client.call_api( File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 362, in call_api return self.__call_api(resource_path, method, File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 206, in __call_api return_data = self.deserialize(response_data, response_type) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 278, in deserialize return self.__deserialize(data, response_type) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 317, in __deserialize return self.__deserialize_model(data, klass, parent_data) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 660, in __deserialize_model kwargs[attr] = self.__deserialize(value, attr_type) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 317, in __deserialize return self.__deserialize_model(data, klass, parent_data) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 670, in __deserialize_model instance = self.__deserialize(data, klass_name, all_args) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 317, in __deserialize return self.__deserialize_model(data, klass, parent_data) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 665, in __deserialize_model instance = klass(**all_args) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/model/messenger.py", line 87, in __init__ self.page_access_token = page_access_token File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/model/messenger.py", line 140, in page_access_token raise ValueError("Invalid value forpage_access_token, must not beNone") # noqa: E501 ValueError: Invalid value forpage_access_token, must not beNone
The same happens with an application with Whatsapp Sandbox Integration and deployment_id:
Traceback (most recent call last): File "/Users/dfalcon/Code/smooch/poc_sunshine_conversations_v2/src/smooch/integrations/get.py", line 26, in <module> get() File "/Users/dfalcon/Code/smooch/poc_sunshine_conversations_v2/shared/exception_handler.py", line 7, in handler return func(*args, **kwargs) File "/Users/dfalcon/Code/smooch/poc_sunshine_conversations_v2/src/smooch/integrations/get.py", line 18, in get api_response = api_instance.get_integration(app_id, integration_id) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api/integrations_api.py", line 311, in get_integration return self.get_integration_with_http_info(app_id, integration_id, **kwargs) # noqa: E501 File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api/integrations_api.py", line 394, in get_integration_with_http_info return self.api_client.call_api( File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 362, in call_api return self.__call_api(resource_path, method, File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 206, in __call_api return_data = self.deserialize(response_data, response_type) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 278, in deserialize return self.__deserialize(data, response_type) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 317, in __deserialize return self.__deserialize_model(data, klass, parent_data) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 660, in __deserialize_model kwargs[attr] = self.__deserialize(value, attr_type) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 317, in __deserialize return self.__deserialize_model(data, klass, parent_data) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 670, in __deserialize_model instance = self.__deserialize(data, klass_name, all_args) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 317, in __deserialize return self.__deserialize_model(data, klass, parent_data) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 665, in __deserialize_model instance = klass(**all_args) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/model/whatsapp.py", line 87, in __init__ self.deployment_id = deployment_id File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/model/whatsapp.py", line 137, in deployment_id raise ValueError("Invalid value fordeployment_id, must not beNone") # noqa: E501 ValueError: Invalid value fordeployment_id, must not beNone
I have an application with messenger integration and using the list_integrations method, returns the next exception because de page_access_token is None en the API response.
example code with get:
with sc.ApiClient(configuration) as api_client: api_instance = sc.IntegrationsApi(api_client) api_response = api_instance.get_integration(app_id, integration_id)
example code with list:
with sc.ApiClient(configuration) as api_client: api_instance = sc.IntegrationsApi(api_client) api_response = api_instance.list_integrations(app_id=app_id)
Error:
Traceback (most recent call last): File "/Users/dfalcon/Code/smooch/poc_sunshine_conversations_v2/src/smooch/integrations/get.py", line 26, in <module> get() File "/Users/dfalcon/Code/smooch/poc_sunshine_conversations_v2/shared/exception_handler.py", line 7, in handler return func(*args, **kwargs) File "/Users/dfalcon/Code/smooch/poc_sunshine_conversations_v2/src/smooch/integrations/get.py", line 18, in get api_response = api_instance.get_integration(app_id, integration_id, _return_http_data_only=False) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api/integrations_api.py", line 311, in get_integration return self.get_integration_with_http_info(app_id, integration_id, **kwargs) # noqa: E501 File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api/integrations_api.py", line 394, in get_integration_with_http_info return self.api_client.call_api( File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 362, in call_api return self.__call_api(resource_path, method, File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 206, in __call_api return_data = self.deserialize(response_data, response_type) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 278, in deserialize return self.__deserialize(data, response_type) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 317, in __deserialize return self.__deserialize_model(data, klass, parent_data) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 660, in __deserialize_model kwargs[attr] = self.__deserialize(value, attr_type) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 317, in __deserialize return self.__deserialize_model(data, klass, parent_data) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 670, in __deserialize_model instance = self.__deserialize(data, klass_name, all_args) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 317, in __deserialize return self.__deserialize_model(data, klass, parent_data) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 665, in __deserialize_model instance = klass(**all_args) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/model/messenger.py", line 87, in __init__ self.page_access_token = page_access_token File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/model/messenger.py", line 140, in page_access_token raise ValueError("Invalid value for
page_access_token, must not be
None") # noqa: E501 ValueError: Invalid value for
page_access_token, must not be
NoneThe same happens with an application with Whatsapp Sandbox Integration and deployment_id:
Traceback (most recent call last): File "/Users/dfalcon/Code/smooch/poc_sunshine_conversations_v2/src/smooch/integrations/get.py", line 26, in <module> get() File "/Users/dfalcon/Code/smooch/poc_sunshine_conversations_v2/shared/exception_handler.py", line 7, in handler return func(*args, **kwargs) File "/Users/dfalcon/Code/smooch/poc_sunshine_conversations_v2/src/smooch/integrations/get.py", line 18, in get api_response = api_instance.get_integration(app_id, integration_id) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api/integrations_api.py", line 311, in get_integration return self.get_integration_with_http_info(app_id, integration_id, **kwargs) # noqa: E501 File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api/integrations_api.py", line 394, in get_integration_with_http_info return self.api_client.call_api( File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 362, in call_api return self.__call_api(resource_path, method, File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 206, in __call_api return_data = self.deserialize(response_data, response_type) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 278, in deserialize return self.__deserialize(data, response_type) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 317, in __deserialize return self.__deserialize_model(data, klass, parent_data) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 660, in __deserialize_model kwargs[attr] = self.__deserialize(value, attr_type) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 317, in __deserialize return self.__deserialize_model(data, klass, parent_data) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 670, in __deserialize_model instance = self.__deserialize(data, klass_name, all_args) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 317, in __deserialize return self.__deserialize_model(data, klass, parent_data) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/api_client.py", line 665, in __deserialize_model instance = klass(**all_args) File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/model/whatsapp.py", line 87, in __init__ self.deployment_id = deployment_id File "/Users/dfalcon/Code/venvs/sunco/lib/python3.8/site-packages/sunshine_conversations_client/model/whatsapp.py", line 137, in deployment_id raise ValueError("Invalid value for
deployment_id, must not be
None") # noqa: E501 ValueError: Invalid value for
deployment_id, must not be
None