public object WebJson( [DekiExtParam("source text or source uri (default: none)", true)] string source, [DekiExtParam("caching duration in seconds (range: 300+; default: 300)", true)] double?ttl, [DekiExtParam("return nil if source could not be loaded (default: text with error message)", true)] bool?nilIfMissing, DekiScriptRuntime runtime ) { source = source ?? string.Empty; XUri uri = XUri.TryParse(source); if (uri == null) { return(DekiScriptLibrary.JsonParse(source, runtime)); } // we need to fetch an online document string response = CachedWebGet(uri, ttl, nilIfMissing); return(DekiScriptLibrary.JsonParse(response, runtime)); }