OneDrive Webservice - 不同的用户可以访问我的 OneDrive 吗?

OneDrive Webservice - Can different users access my OneDrive?

我想在我的 wordpress 博客中实现 REST 网络服务。访客或其他用户可以从我的 OneDrive 帐户中 select 图片并订购它们。

我的问题是当我获得身份验证时 code 我必须输入我的 OneDrive 密码。之后我得到 access_tokenaccess_token 只有 1 小时的运行时间。

当我订购新的 access_token 时,code 已过期,我必须使用我的用户密码获取新的验证码。

如何在不每次都输入自己的密码的情况下为 OneDrive 实现网络服务?

感谢您的帮助。

当您通过 code flow when authing you should also see a refresh_token come back (provided you requested the wl.offline_access scope). You should be able to use that to get a new access_token by using the this process 获得 access_token 而无需用户交互时。