cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
New Member

Microsoft Online OAuth2 Token cannot handle Content-Type with given Charset

Hello,

i am trying to get the oauth token via post to https://login.microsoftonline.de/common/oauth2/token.

[{"key":"Content-Type","name":"Content-Type","value":"application/x-www-form-urlencoded","description":"","type":"text"}] 

If i try to post with given charset, does not matter what charset, i always get an error and cannot get the token!

This should be fixed! Microsoft should be able to handle given charset inside the header. 

 

curl --request POST \ --url https://login.microsoftonline.de/common/oauth2/token \ --header 'Accept: */*' \ --header 'Content-Type: application/x-www-form-urlencoded;charset="UTF-8"' \ --header 'Postman-Token: 99b8afdb-b4fc-4cfc-812e-059a256ef6d2' \ --header 'cache-control: no-cache' \ --data 'grant_type=password&client_id=abc&resource=abc&scope=openid&username=abc&password=abc'

 

A post like this should work! But it does not! I get invalid_request! So please fix this issue, so that given charset parameter are excepted when posting to get microsoft token.

0 REPLIES 0

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

Power Platform ISV Studio

Power Platform ISV Studio

ISV Studio is designed to become the go-to Power Platform destination for ISV’s to monitor & manage published applications.

Top Solution Authors
Users online (12,882)