Tuesday, August 5, 2014

Fiddler - Replay altered requests multiple times


If you want to replay a certain request in Fiddler, you can select it and press R
If you want to replay a request multiple number of times , you can select the request, press Shift + R and specify the count.
However, if you want to alter the request every time you replay it, you can do that by adding a custom rule in fiddler.

Go to Rules->Customize Rules. In the method OnBeforeRequest(oSession: Session), add the below:

 if(oSession.uriContains("yourUrl"))
 {
  oSession.utilReplaceInRequest('searchText',Guid.NewGuid());
 }

Now press Shift + R on your request and replay the altered request multiple times. Sweet!

1 comment:

  1. Its good but need to know more how we can extract( cookie/ response body value) from previous request and pass to next request

    ReplyDelete