For anyone trying to work with Xibo and C#… tis may help
private async void button4_Click(object sender, EventArgs e)
{
string clientId = "your_clientId";
string clientSecret = "your_clientSecret";
string uri = "http://srv1.youservername:8080/api/authorize/access_token";
var formContent = new FormUrlEncodedContent(new[]
{
new KeyValuePair<string, string>("client_id", clientId),
new KeyValuePair<string, string>("client_secret", clientSecret),
new KeyValuePair<string, string>("grant_type", "client_credentials")
});
var myHttpClient = new HttpClient();
myHttpClient.DefaultRequestHeaders.Accept.Add(new MediaTypeWithQualityHeaderValue("application/json"));
var response = await myHttpClient.PostAsync(uri.ToString(), formContent);//GivesValue ok Request
var stringContent = await response.Content.ReadAsStringAsync();//Gives Better Erro and Data
statustextBox1.Text = stringContent;
}