我目前正在使用 oAuth 通过
Calendars.ReadWrite
范围获取令牌,但它适用于用户拥有的所有日历。这是我的代码:
const PCA = new PublicClientApplication({
auth: {
clientId: "***",
authority: "https://login.microsoftonline.com/common",
redirectUri: "http://localhost:8080/"
}
});
PCA.loginPopup({ scopes: ["User.Read", "Calendars.ReadWrite"] })
.then((response) => {
console.log(response.accessToken)
})
.catch(function (error) {
console.log(error);
});
我在想,有没有办法根据特定的日历获取令牌?我想要一个令牌,它只适用于用户选择的同一日历,不适用于用户拥有的其他日历。