C# client

To consume the REST api using C# you can use the standard Client class and use the Get and Post methods. This will use the clients authentication when performing the REST call

var parameters = new NameValueCollection
{
    {"$search","flower"},
    {"$top","10"}
};

var oDataResponse = client.Get<ODataResponse<Asset>>("assets", parameters);
if (oDataResponse?.Value != null)
{
    foreach (var asset in oDataResponse.Value)
    {
        //...
    }
}
comments powered by Disqus
+46 (0)480 - 31 47 95
info@imagevault.se
Swedish website