Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is it possible to make JSON requests using Fiddler's Request Builder?

I keep getting a Request format is invalid.

Here's the raw http that gets sent:

POST http://x.x.x.x/ws/MyWebService.asmx/TestEvent HTTP/1.1 contentType: "application/json; charset=utf-8",   dataType: "json",   data: {"strData":"1"} Host: x.x.x.x Content-Length: 4 

Any help is greatly appreciated.

Thanks!

like image 202
V-Man Avatar asked Apr 07 '10 00:04

V-Man


People also ask

How do I request JSON?

To request JSON from a URL, you need to send an HTTP GET request to the server and provide the Accept: application/json request header with your request. The Accept header tells the server that our client is expecting JSON.

What is the type of requests JSON ()?

json() The json() method of the Request interface reads the request body and returns it as a promise that resolves with the result of parsing the body text as JSON .

How do I create a post request in Fiddler?

To send a new POST request, choose POST for method type, type the URL, enter the body content and click Execute.

Which tab builds raw HTTP request in Fiddler?

The Composer tab enables you to manually create a new HTTP or HTTPS request from scratch and edit an existing captured request, as well as send and test them. This article explains the user interface that creates the Fiddler Everywhere's Composer.


1 Answers

I think it should be more like this:

POST /ws/MyWebService.asmx/TestEvent HTTP/1.1 Host: x.x.x.x Content-Type: application/json; charset=utf-8 Content-Length: 15  {"strData":"1"} 

And it is in the connection that you specify which server to connect to.

like image 77
Alxandr Avatar answered Oct 04 '22 16:10

Alxandr