split api settings

This commit is contained in:
Ryan Peters 2023-03-18 15:38:35 +00:00
parent 47d34eb4d1
commit 9add92c170
2 changed files with 6 additions and 4 deletions

View File

@ -13,8 +13,8 @@ namespace WeatherDashboard.Web.Services
{
this.configuration = configuration;
apiBaseUrl = configuration["ApiBaseUrl"];
apiKey = configuration["ApiKey"];
apiBaseUrl = configuration["Api:BaseUrl"];
apiKey = configuration["Api:Key"];
httpClient = httpClientFactory.CreateClient();
}

View File

@ -6,6 +6,8 @@
}
},
"AllowedHosts": "*",
"ApiBaseUrl": "https://api.weatherapi.com",
"ApiKey": "829fbbe5beb2424aa1021928230702"
"Api": {
"BaseUrl": "https://api.weatherapi.com",
"Key": "829fbbe5beb2424aa1021928230702"
}
}