Outlook API身份验证

时间:2020-04-08 18:25:11

标签: azure

我正在尝试使用Outlook API v2。但是,当尝试获取oauth2令牌时,我仅收到400错误的请求。

根据此Access Token Request

这是请求:

RestClient.post“ https://login.microsoftonline.com/common/oauth2/v2.0/token”,“ code = code&client_id = f9411ec1-b3e3-4468-b627-23368b98d22b&client_secret = CLIENT_SECRET&redirect_uri = http%3A%2F%2Flocalhost%3A8080%2Fprofile%2Fcalendar-sync&grant_type = “ Accept” =>“ / ”,“ Accept-Encoding” =>“ gzip,deflate”,“ Content-Length” =>“ 247”,“ Content-Type” =>“ application / x-www-form-urlencoded“,” User-Agent“ =>” rest-client / 2.0.2(linux-gnu x86_64)ruby / 2.6.5p114“

代码来自用户登录到Microsoft服务。

0 个答案:

没有答案