I am trying to use HTTPUtils2 to POST data to an IoT server which needs to be received in the following format:
"content": {
"temp": "Hello World "
}
When I use my code below, I get the following format which is close but not correct. Any ideas as to what code change is required in order to get the correct format? I tried using the JSONGenerator to see if that worked but the resulting data format was even further from the required format :-(
"content": {
"temp:Hello World": ""
}
Current Code:
msg=nfctag.Text
msg= msg.Replace ( " ","%20")
msg= "temp:"&msg
job1.PostString("https://dweet.io:443/dweet/for/test?key=xxxxxxxxxxxxxxxxxxx",msg)
"content": {
"temp": "Hello World "
}
When I use my code below, I get the following format which is close but not correct. Any ideas as to what code change is required in order to get the correct format? I tried using the JSONGenerator to see if that worked but the resulting data format was even further from the required format :-(
"content": {
"temp:Hello World": ""
}
Current Code:
msg=nfctag.Text
msg= msg.Replace ( " ","%20")
msg= "temp:"&msg
job1.PostString("https://dweet.io:443/dweet/for/test?key=xxxxxxxxxxxxxxxxxxx",msg)