"Asset is not valid" in HTTP API Agent Asset

Hi, I have recently pulled the latest manager docker image, and found that when I edit anything of my HTTP Agent, a “Asset is not valid” error will be shown and prohibit me to save the changes.

Attributes in the asset:
agentStatus: CONNECTED
baseURL: https://api.openweathermap.org/data/2.5/
requestHeader:
{
“q”: [
“Rotterdam,nl”
],
“appid”: [
“{MY_API_ID}”
],
“units”: [
“metric”
]
}

The error started when I tried to add a Custom Attribute “testAttri1” with type “Number”, then the error keeps persisting even after I deleted the custom attribute.

I have tried to install a fresh copy of OpenRemote docker container but the problem is still there. In the above screenshot I was following the tutorial for connecting the OpenWeather API. Is there any change in the compulsory attribute in HTTP agents? Also, I tried to check the JS console and the manager console in terminal but no error message is prompted, so I am not sure how to find the problem.

Please help to point me a direction, thanks!

Jeffrey

Hi Jeffrey,

Frontend validation for assets was only recently added and there are some outstanding issues that need to be resolved; for now I will prevent the save button from being disabled at least until we iron out these problems.

If you mouse over the Asset is not valid message at the top you will get a popup with the list of errors but sounds like a bug in your case.

Just pushed an update so look for a manager:latest docker image with a timestamp > this message

Hi @Rich , that will be great, thanks!

Just out of curiosity, I was creating an agent to call an API at my local network node-red

Base URL: http://192.168.3.50:1880/testapi

I moused over the Asset is not valid message and saw

  • Invalid attribute value for requestHeaders
  • Invalid attribute value for requestQueryParameters
  • Invalid attribute value for base URL

For the first two, I managed to resolve them by providing an empty JSON {}, for the third one, how should I go about to resolve the error?

Thanks for the great work in OR!
Jeffrey

Looks like a limitation with our HTTP URL regex, I’ve just pushed an update which should prevent this

1 Like