Sending a web request to blynk-cloud using Android API

Hi, I would like to send a web request to the blynk cloud server from an Android app.

The following command works as expected:
curl --include --request PUT --header “Content-Type: application/json” --data-binary “[“255”]” ‘[MyToken]/update/V0

putUrl(“[MyToken]/update/V0”) produces logcat message: “response:500”.

void putUrl(String urlString){
HttpClient httpclient = new DefaultHttpClient();
HttpPut httpPut = new HttpPut(urlString);
httpPut.setHeader(“Content-Type”, “application/json”);
httpPut.setHeader(“data-binary”, “255”);
HttpResponse response = httpclient.execute(httpPut);
Log.v(TAG, “response:”+response.getStatusLine().getStatusCode());
catch (IOException e)
Log.v(TAG,“Failed to execute httpput:”+e.getMessage());

Could I get some help? Thank you for your help in advance.

Hello. Please try new API. it is much simpler - blynkapi · Apiary

Your error is here

It is not header.

Works like a charm! Thank you!