cURL POST command line on WINDOWS RESTful service
|
My problem: Running windows 7 and using the executable command line tool to curl my localhost server api for POST data was returning me an error that seems to be really common. The request was being sent properly with the exception that the data was not reaching the server as it should causing my REST service to insert data with null values. What seems to be causing the error: imagine something like this
Result of the returning data
After some searching i figured out that problem couldn't be the sintax used for the request since it works on UNIX shells.
I tried to work around with those " escaping it \" but it still didn't work 2.
3.
So i gave up. Windows seems to messing up with the JSON object sent on POST |
|||||||||
|
|
I ran into the same issue on my win7 x64 laptop and was able to get it working using the curl release that is labeled Win64 - Generic w SSL by using the very similar command line format:
Which only differs from your 2nd escape version by using double-quotes around the escaped ones and the header parameter value. Definitely prefer the linux shell syntax more. |
cURL POST command line on WINDOWS RESTful service的更多相关文章
- Cookies with curl the command line tool
w https://curl.haxx.se/docs/http-cookies.html curl has a full cookie "engine" built in. If ...
- [转]How do I run msbuild from the command line using Windows SDK 7.1?
本文转自:http://stackoverflow.com/questions/6319274/how-do-i-run-msbuild-from-the-command-line-using-win ...
- How to install IIS 7.5 on Windows 7 using the Command Line
原文 How to install IIS 7.5 on Windows 7 using the Command Line On Windows Vista, to install IIS 7.0 f ...
- Create Windows Server 2008 cluster from the command line
How to create a Windows Server 2008 cluster from the command line? Creating a cluster in Server 2008 ...
- [Windows]远程管理服务WinRM远程管理Windows服务器 Invalid use of command line. Type "winrm -?" for help.
运行环境 Windows 2012 R2 1. Windows需要打开WinRM服务,Server系统默认打开,默认端口5985 # WinRM服务查看 PS C:\Users\Administrat ...
- MySQL 5.7 Command Line Client输入密码后闪退和windows下mysql忘记root密码的解决办法
MySQL 5.7 Command Line Client输入密码后闪退的问题: 问题分析: 1.查看mysql command line client默认执行的一些参数.方法:开始->所有程序 ...
- windows 8 安装 oracle 11g 报错:command line option syntax error,type command/? for help
windows 8 安装 oracle 11g 报错:command line option syntax error,type command/? for help 在windows8操作系统上安装 ...
- [RabbitMQ]Windows环境下rabbitmqclt(Command Line Tools)出现Erlang distribution failed错误的解决方法
摘要 当使用rabbitmqctl时出现Erlang distribution failed,把%SystemRoot%Windows\System32\config\systemprofile下的. ...
- 如何在Windows下开发Python:在cmd下运行Python脚本+如何使用Python Shell(command line模式和GUI模式)+如何使用Python IDE
http://www.crifan.com/how_to_do_python_development_under_windows_environment/ 本文目的 希望对于,如何在Windows下, ...
随机推荐
- IIS兼容模式设置
X-UA-Compatible IE=EmulateIE7 来自为知笔记(Wiz)
- ViewPager中使用PhotoView时出现pointerIndex out of range异常
问题描述: 当PhotoView 和 ViewPager 组合时 ,用双指进行放大时 是没有问题的,但是用双指进行缩小的时候,程序就会崩掉,并且抛出java.lang.IllegalArgumentE ...
- 使用wireshark抓取wcf生成的soap消息
在使用wcf的时候想看下生成的soap的格式是怎样的,就想到了抓包. 平时用惯的抓包工具是需要破解,另外有时会不太好用. 于是就想起来用wireshark. 首先遇到几个问题: 1.wireshart ...
- 搬家至个人独立博客virson.cn
最近正在将博客园的文章搬到自己的独立博客,以后基本上不会在博客园更新文章了,欢迎光临我的新博客:www.virson.cn,博客内容持续更新中……
- C#使用ICSharpCode.SharpZipLib.dll压缩文件夹和文件
大家可以到http://www.icsharpcode.net/opensource/sharpziplib/ 下载SharpZiplib的最新版本,本文使用的版本为0.86.0.518,支持Zip, ...
- UNIX环境高级编程笔记之标准I/O库
一.总结 文件I/O一章讲了不带缓冲的I/O,本章讲的是带缓冲的I/O.不带缓冲针对的是内核的系统调用,而带缓冲针对的是用户空间的标准库函数,是基于带缓冲的I/O实现的.不带缓冲的I/O通过文件描述符 ...
- java之源码路径及api
jav源码地址:D:\Program Files\jdk1.7\src.zip class类地址:D:\Program Files\jdk1.7\jre\lib\rt.jar 在线api底地址:htt ...
- 视觉SLAM中的数学基础 第四篇 李群与李代数(2)
前言 理解李群与李代数,是理解许多SLAM中关键问题的基础.本讲我们继续介绍李群李代数的相关知识,重点放在李群李代数的微积分上,这对解决姿态估计问题具有重要意义. 回顾 为了描述三维空间里的运动,我们 ...
- 用Razor語法寫範本-RazorEngine組件介紹【转——非常好,可以用它来代替NVelocity】
RazorEngine 官網網址:http://razorengine.codeplex.com 在找到RazorEngine之前曾經想過其他的方案,如T4與V8 Engine載jquery.temp ...
- mingW与cygwin
转自:http://hi.baidu.com/ooxxer/item/d25dccc072846a50ac00ef7e# 首先MingW和cygwin都可以用来跨平台开发. MinGW是Minima ...