<div dir="ltr">Hi,<div><br></div><div>I am just trying out the new and shiny JMAP implementation using cyrus-imapd master. But when i made the request using postman (chrome app). It gave me error:</div><div>







<p class="">







</p><p class=""><font face="monospace, monospace">Mar 18 20:16:33 gaby http[2543]: <a href="http://ipv4-x-x-x.as55666.net">ipv4-x-x-x.as55666.net</a> [111.x.x.x] as "diaz" with "Mozilla/5.0 (Chrome/49.0.2623.87 Safari/537.36"; "POST /jmap/authentication HTTP/1.1" (origin=chrome-extension://aicmkgpgakddgnaphhhpliifpcfhicfo) => "400 Bad Request" (error=Unable to parse JSON request body#015#012)</font></p><p class="">And when i change the code in http_jmap.c to output the RAW json: it displayed:</p><p class="">







</p><p class=""><font face="monospace, monospace">Mar 18 19:15:41 gaby http[28360]: JSON {#012#011"username": "diaz@localhost",#012#011"clientName": "CLIENT",#012#011"clientVersion": "0.1",#012#011"deviceName": "api"#012}</font></p><p class="">I don't know how the "#012#11" characters came from, it should have been "{"</p><p class=""><br></p><p class="">But when using cURL, the RAW json data is correct:</p><p class="">







</p><p class=""><font face="monospace, monospace">Mar 18 19:19:10 gaby http[28616]: JSON {    "username": "diaz@localhost",    "clientName": "CLIENT",    "clientVersion": "0.1",    "deviceName": "api"}</font></p><p class="">but still give error "400 Bad Request"</p><p class="">Then i upgrade jansson to 2.7.3, but the error persist.</p><p class="">Then i compare the json_loads implementation from http_jmap.c and jcal.c, and then remove the <font face="monospace, monospace">`json_is_array`</font> condition, so it looked like:</p><p class=""><font face="monospace, monospace">    req = json_loads(buf_cstring(&txn->req_body.payload), 0, &jerr);<br></font><span style="font-family:monospace,monospace">    if (!req) {<br></span></p><p class="">Now i get HTTP 200 OK.  But i got empty JSON reply "[]" where it should have been "continuationToken" if i read the from <a href="http://jmap.io">jmap.io</a> spec.<br></p><p class=""><br></p><p class="">Any clue how to get the "continuationToken" from the server ?</p><p class=""><br></p><p class="">Thanks!</p></div></div>