SetProperty http api


I am trying to use SetProperty through the http api on blynk cloud. I saw that this feature was implemented in anoucemnents last month.

I couldn’t find any documentation, but after poking around on GitHub it looks like the http Put should look something like{token}/pin/{pin}/{property}. I’ve been trying{token}/pin/v77/label but I’m just getting a 404.
Is this the correct format?

Has SetProperty been implemented on the blynk cloud server, or is it only available on a local server?

Btw I’m loving the blynk app!

1 Like

Hello. Updated doc -

Thanks Dmitriy,

For some reason I’m getting “400 project is not active” when using http get with /update/v77?label=mylabel

However no issues updating pin with /update/v77?value=7, so my project is definitely active.

Any ideas on what I’m doing wrong?

Doesn’t this message explain what problem is?

@greggius do you get the full project details with the following line?

Note your_token is replaced with the 32 character token.

Yes I get full project details using{my_token}/project

I can also update pin values using{my_token}/update/{my_pin}?value={my_value}

But I get “400 project is not active” when I use{my_token}/update/{my_pin}?label={my_label}
I’m using the same auth token for all requests.

So maybe you need to activate your project?

Ok yes I have it working now. I thought the project was active once I had an auth token for it, but by active you mean that the project must be open and running in the Android app for the property update to work.
Sorry for the the misunderstanding.
I must have pressed stop on my project before submitting the http property update request.

Is there any reason why the project and the widget for a pin have to be active for a property update to work? Would it be possible to store the pin property on the sever, in the same way that a pin value is stored on the server?

This would make it easier to label pins from the hardware side.

No, it don’t. Just activated.

It is already done. Active doesn’t mean opened.