What would be the best way to make a JSON get requests like this?

I have no experience with posting json data via a web get on the homey. What app would be most suitable to make calls like this? Currently I use CURL from the command line for it;

curl
-H “X-Vestaboard-Api-Key: $key”
-H “X-Vestaboard-Api-Secret: $secret”
-d ‘{“text”: “Hello test message”}’ https://platform.vestaboard.com/subscriptions/$subscriptions/message

You can use this flow action card:

I’m nut sure if header field must be set as JSON object like this:
grafik

You have to set the $key and $secret in then flow card field. Or you can use global tags (variables) to fill them dynamically.

It should not, you have to add headers as plain text, one per line:

X-Vestaboard-Api-Key: $key
X-Vestaboard-Api-Secret: $secret

And not use “smart quotes” in the body data, just regular ones (")

1 Like

Hi Robert,
Somehow it’s throwing me a 404. I used the one header per line (i saw you write on this forum about it before).
What do you mean by smart quotes? Single quotes?
This is what I got right now;

Url:
https://platform.vestaboard.com/subscriptions/SUBKEY/message
Headers;

X-Vestaboard-Api-Key: APIKEY
X-Vestaboard-Api-Secret: APISECRET

Body;
{"text": "Hello"}

(cant upload a screenshot for some reason but this is what I copied from the flow).
What am I missing?

Update: did some more testing and I think the problem is the body… when I just request my vestaboards installation information it doesnt need a body and that seems to work.

Thanks, Robert.
I just copied the examples above. But yes, standard quotes "..." must be used.

Edit: just inserted standard quotes and the forum software converts to Unicode :expressionless:

Make it a POST request.

Ah… silly of me… of course…
Works like a charm… thanks!