JSON requests in C using libcurl

前端 未结 7 901
孤独总比滥情好
孤独总比滥情好 2020-12-08 12:04

I\'m defining a PUT request with a JSON request body using libcurl in C.

This how I\'m doing it:

    sprintf(jsonObj, \"\\\"name\\\" : \\\"%s\\\", \\         


        
7条回答
  •  天命终不由人
    2020-12-08 12:38

    libcurl will send exactly the bytes you ask it to send. It has no knowledge of JSON at all.

    See @Lukasa's excellent and more elaborate answer for better and more details.

提交回复
热议问题