Pradeep Rawat

Pradeep Rawat

  • NA
  • 286
  • 8.5k

how to add APPsetting keys and value in other layer(DAL).

Dec 30 2020 1:29 PM
using (var client = new HttpClient())
{
//client.BaseAddress = new Uri("https://cou-wrapper-api.setu.co");
client.DefaultRequestHeaders.Accept.Clear();
client.DefaultRequestHeaders.Accept.Add(new MediaTypeWithQualityHeaderValue("application/json"));
client.DefaultRequestHeaders.Add("axxsx-channel-id", "Prghfdhgfh");
client.DefaultRequestHeaders.Add("axxxs-client-id", "fgfhdgfdhe-dc6b60e99403");
 
///app setting //
 
<appSettings>
<add key="axxsx-channel-id" value="dsfadsafdsaf"/>
<add key="axxxs-client-id" value="f85ede94-1fcb-42d7-ac5e-dc6b60e99403"/>
</appSettings>
 

Answers (1)