private static async Task <PortfolioConfigModel> GetConfig(string portfolio) { var url = ConfigurationManager.AppSettings["backendUrl"]; var apiKey = ConfigurationManager.AppSettings["backendApiKey"]; var user = ConfigurationManager.AppSettings["testAdminUser"]; var password = ConfigurationManager.AppSettings["testAdminUserPassword"]; BackendAPIClient backendClient = new BackendAPIClient(url, apiKey, user, password); return(await backendClient.GetAsync <PortfolioConfigModel>($"api/PortfolioConfiguration?portfolio={portfolio}")); }
internal static async Task <T> GetAsync <T>(string uri) { return(await client.GetAsync <T>(uri)); }