Newtonsoft.Json
RestSharp
RestSharp
Newtonsoft.Json.Converters
Newtonsoft.Json
System.Dynamic
private string BaseUrl =
//"https://starterset-api.dev.k8s.sdt.local/api/v1/";
"https://localhost:44325/api/v1/";
void Main()
{
RestClient client = new RestClient();
var reports = GetList(client, "Reports");
var rpts = reports
.Where(r => r.Name.StartsWith("TL Fiscal Month Test"))
.OrderBy(r => r.Name)
.ToList()
.Select(rpt => new { rpt.Id, rpt.Name, setup = GetList(client, $"Reports\\{rpt.Id}\\Setup") })
//.Where(x => ((IDictionary)x.setup).ContainsKey("ServiceLines"))
;
rpts.Dump(nameof(rpts),6);
var definitions = GetList(client, "Definitions")
.Where(dd => dd.DimensionId == "e18e27ea-52ec-4793-9209-c6259c78474a"
|| dd.DimensionId == "Fiscan Month");
definitions.Dump();
/*
var setups = rpts.Select(r => r.setup);
setups.Dump(nameof(setups));
var serviceLines = setups.Where(x => ((IDictionary)x).ContainsKey("ServiceLines"))
.SelectMany(s => ((List