The JSON object you're trying to use is a part of the browser's Document Object model and doesn't directly exist within FiddlerScript. The .NET framework (on which FiddlerScript runs) offers a variety of JSON libraries and one of them may be your best choice.
Having said that, Fiddler does itself have its own JSON objects; they're not optimized for FiddlerScript, however, so you might find them a little cumbersome. At the top of your script, add:
using Fiddler.WebFormats;
In the code, add e.g.
var oResponseBody = oSession.GetResponseBodyAsString();
JSON.JSONParseResult oJSON = JSON.JsonDecode(oResponseBody) as JSON.JSONParseResult;
Hashtable oObj = oJSON.JSONObject as Hashtable;
var oVal = (oObj != null) ? oObj["myObjectValue"] : null;
The JSON object you're trying to use is a part of the browser's Document Object model and doesn't directly exist within FiddlerScript. The .NET framework (on which FiddlerScript runs) offers a variety of JSON libraries and one of them may be your best choice.
Having said that, Fiddler does itself have its own JSON objects; they're not optimized for FiddlerScript, however, so you might find them a little cumbersome. At the top of your script, add: