I am trying to receive a JWT token for the management API.
I copied the code directly from the management API UI that is provided.
var client = new RestClient("https://dev-bqynboke.us.auth0.com/oauth/token");
var request = new RestRequest("https://dev-bqynboke.us.auth0.com/oauth/token",Method.Post);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\"client_id\":\"zzzzzzzzz\",\"client_secret\":\"zzzzzzz\",\"audience\":\"https://dev-bqynboke.us.auth0.com/api/v2/\",\"grant_type\":\"client_credentials\"}", ParameterType.RequestBody);
var response = await client.ExecuteAsync(request);
I keep getting a bad request response, and the content is Invalid Json.
Any thoughts?
Thank you,
Marty