Closed chandrasekar-vlsi closed 6 years ago
Method: POST URL: http://10.91.16.76:8005/data
{ "d":"device1", "f":"daimler", "t":1520424248897, "l":"LOCATION", "s":{ "bluetooth":{ "20:25:64:b7:91:42":-72, "20:25:64:b8:06:38":-81, }, "wifi":{ "20:25:64:b7:91:40":-73, "70:4d:7b:11:3a:c8":-81, "88:d7:f6:a7:2a:4c":-39, "8c:0f:6f:e7:2b:78":-42, "8c:0f:6f:e7:2b:80":-43, "92:0f:6f:e7:2b:80":-43, "96:0f:6f:e7:2b:78":-39, "9e:0f:6f:e7:2b:80":-43, "ac:9e:17:7f:38:a4":-55, "dc:fe:07:79:aa:c0":-90, "dc:fe:07:79:aa:c3":-89 } }, "gps":{ "lat":12.1, "lon":10.1, "alt":54 } }
RESPONSE:
tatus Code: 400 Bad Request Access-Control-Allow-Credentials: true Access-Control-Allow-Headers: Content-Type, Content-Length, Accept-Encoding, X-CSRF-Token, Authorization, X-Max Access-Control-Allow-Methods: GET Access-Control-Allow-Origin: * Access-Control-Max-Age: 86400 Content-Length: 120 Content-Type: application/x-gzip Date: Tue, 17 Apr 2018 10:51:02 GMT Vary: Accept-Encoding
Yes, its because you're trying to submit bad JSON: https://jsonformatter.org/9241ba
The last comma on "bluetooth" should be removed
Method: POST URL: http://10.91.16.76:8005/data
{
"d":"device1", "f":"daimler", "t":1520424248897, "l":"LOCATION", "s":{
"bluetooth":{
"20:25:64:b7:91:42":-72, "20:25:64:b8:06:38":-81,
}, "wifi":{
"20:25:64:b7:91:40":-73, "70:4d:7b:11:3a:c8":-81, "88:d7:f6:a7:2a:4c":-39, "8c:0f:6f:e7:2b:78":-42, "8c:0f:6f:e7:2b:80":-43, "92:0f:6f:e7:2b:80":-43, "96:0f:6f:e7:2b:78":-39, "9e:0f:6f:e7:2b:80":-43, "ac:9e:17:7f:38:a4":-55, "dc:fe:07:79:aa:c0":-90, "dc:fe:07:79:aa:c3":-89 } }, "gps":{ "lat":12.1, "lon":10.1, "alt":54 } }
RESPONSE:
tatus Code: 400 Bad Request Access-Control-Allow-Credentials: true Access-Control-Allow-Headers: Content-Type, Content-Length, Accept-Encoding, X-CSRF-Token, Authorization, X-Max Access-Control-Allow-Methods: GET Access-Control-Allow-Origin: * Access-Control-Max-Age: 86400 Content-Length: 120 Content-Type: application/x-gzip Date: Tue, 17 Apr 2018 10:51:02 GMT Vary: Accept-Encoding