Hizo
1
Hello,
I have an issue with HTML requests.
I want to send myself an SMS via Free’s API, which does this very well and for free.
You just need to do:
https://smsapi.free-mobile.fr/sendmsg?user=XXXXXX&pass=XXXXXXX&msg=Super Texte de la mort
But when I put this command in the HTML requests block, whether as POST or GET, it tells me:
An error occurred during the request. Are you sure you filled out the form correctly?
However, the SMS messages do arrive.
I tried treating the key/value pairs as headers; no more error message but also no more SMS.
This prevents saving the scene:
An error occurred while saving your scene. Please check that all actions/triggers are filled in and correct.
Any idea?
Thanks
That seems fine to me
Have you managed to resolve your issue since?
Hizo
3
I’m bypassing it via MQTT, but it’s not exactly practical…
Did you have a quick look at Gladys’ logs when you got the error?
Hizo
5
Not at all, can you remind me how to do it please?
On the machine where you’re running Gladys:
docker logs gladys
Hizo
7
There is no related message…
Would you mind sending me the URL privately so I can test on my side?
Hi @Hizo! I ran a test on my side this morning, and I didn’t see anything, everything is working.
You should have received an SMS « Test » ^^
Are you sure about what you’re doing?
Hizo
11
Yes I received it last night 
I know I’m not always lightning-fast but this…
I do receive an email…
For the test I only added this action and I tested on Firefox and Opera.
Ok, I wasn’t doing the same thing — I created a scene, saved it, and ran it.
I’ll re-test with the same scenario as you.
Ok this time I can reproduce it:
When making an API call via the « Try » button, the front-end doesn’t handle the API response missing the « Content-Type » header.
It’s just a display bug, but it doesn’t prevent using the scene.
If you create the scene, don’t click « try », just save it and click « Run » the scene to test. It should work without problems 
Edit: I created a GitHub issue for the front-end bug:
Hizo
14
OK, thanks.
I can no longer reproduce it, but testing prevented me from saving the scene as indicated in the first message.
1 Like
Sorry I just did one last test to check that my fix was good (it was literally 5 characters to change), now I’ll stop bothering you 
It will be included in the next version of Gladys, but you don’t need to wait, don’t use the « Try » button in the meantime!
1 Like