I have the same issueā¦ starting from few days ā¦ just after the token is expiredā¦ (it was working for over 3 months)
Now I am no longer able to add the SmartThings integration because of this generic errorā¦ (tried many times to uninstall and reinstall the integration and to generate new tokenā¦ always with the same errorā¦ )
In the log I see the followingā¦
Logger: homeassistant.components.smartthings.config_flow
Source: components/smartthings/smartapp.py:176
Integration: smartthings (documentation, issues)
First occurred: 13:23:50 (3 occurrences)
Last logged: 17:46:13
API error setting up the SmartApp: {ārequestIdā: ā160A574A-E27A-4BF5-9FF1-DFFEAB699145ā, āerrorā: {ācodeā: āConstraintViolationErrorā, āmessageā: āThe request is malformed.ā, ādetailsā: [{ācodeā: āPatternErrorā, ātargetā: ātargetUrlā, āmessageā: ātargetUrl is malformed.ā, ādetailsā: []}]}}
API error setting up the SmartApp: {ārequestIdā: ā42420777-D6B9-44C9-AFC8-3C9801416702ā, āerrorā: {ācodeā: āConstraintViolationErrorā, āmessageā: āThe request is malformed.ā, ādetailsā: [{ācodeā: āPatternErrorā, ātargetā: ātargetUrlā, āmessageā: ātargetUrl is malformed.ā, ādetailsā: []}]}}
API error setting up the SmartApp: {ārequestIdā: āAA3F565B-728D-4C95-A07A-2DB85A758162ā, āerrorā: {ācodeā: āConstraintViolationErrorā, āmessageā: āThe request is malformed.ā, ādetailsā: [{ācodeā: āPatternErrorā, ātargetā: ātargetUrlā, āmessageā: ātargetUrl is malformed.ā, ādetailsā: []}]}}
Traceback (most recent call last):
File ā/usr/src/homeassistant/homeassistant/components/smartthings/config_flow.pyā, line 104, in async_step_pat
await update_app(self.hass, app)
File ā/usr/src/homeassistant/homeassistant/components/smartthings/smartapp.pyā, line 176, in update_app
await app.save()
File ā/usr/local/lib/python3.10/site-packages/pysmartthings/app.pyā, line 349, in save
response = await self._api.update_app(self._app_id, self.to_data())
File ā/usr/local/lib/python3.10/site-packages/pysmartthings/api.pyā, line 179, in update_app
return await self.put(API_APP.format(app_id=app_id), data)
File ā/usr/local/lib/python3.10/site-packages/pysmartthings/api.pyā, line 399, in put
return await self.request(āputā, self._api_base + resource, data=data)
File ā/usr/local/lib/python3.10/site-packages/pysmartthings/api.pyā, line 368, in request
raise APIResponseError(
pysmartthings.errors.APIResponseError: Unprocessable Entity (422): {ārequestIdā: ā160A574A-E27A-4BF5-9FF1-DFFEAB699145ā, āerrorā: {ācodeā: āConstraintViolationErrorā, āmessageā: āThe request is malformed.ā, ādetailsā: [{ācodeā: āPatternErrorā, ātargetā: ātargetUrlā, āmessageā: ātargetUrl is malformed.ā, ādetailsā: []}]}}
Any idea how to fix it?