cURL / Mailing Lists / curl-library / Single Mail


Help required on data option usage with DELETE - curl -X DELETE -d data='{"name":"test"}'

From: Prasanna Viswakumar <>
Date: Fri, 20 Sep 2013 11:45:07 -0700 (PDT)

HI Team

I am Prasanna from India.

I am working on a Java Application where I would want to send a DELETE with more information
than present with the URI.

I learnt that the CURL library achieves this with this form curl -X DELETE -d data='{"name":"test"}'..

Captured the packets and did observe the name/value pair being sent with the packet.

0000: DELETE /restapi/15/123/vlan/0 HTTP/1.1
0028: User-Agent: curl/7.15.5 (i686-redhat-linux-gnu) libcurl/7.15.5 O
0068: penSSL/0.9.8b zlib/1.2.3 libidn/0.6.5
008f: Host:
00a4: Accept: application/json
00be: Content-Length: 24
00d2: Content-Type: application/x-www-form-urlencoded
0105: data={"name":"test"} <<<<

How does CURL manage to achieve this ?

Is it possible to get this ported to Java with the use of any of the Apache HTTP client libraries ?

Appreciate your help in this regard.

Prasanna, V
List admin:
Received on 2013-09-20