I have a WebClient like this:
WebClient
WebClient _webClient = new WebClient { UseDefaultCredentials = true, Encoding = System.Text.Encoding.UTF8,
I think you can also do it like this (without the : in the header):
:
private static WebClient _doClient = new WebClient { BaseAddress = "https://api.digitalocean.com/v2/domains/example.com/", Headers = new WebHeaderCollection { { "Authorization", "Bearer " + _digitalOceanApiKey } } };