简体   繁体   English

如何通过Webhook接收到具有UserId的DropNet Client

[英]How to Use DropNet Client with UserId's received via Webhook

I am using DropBox Webhook to get the notification regarding any changes on DropBox. 我正在使用DropBox Webhook来获取有关DropBox上任何更改的通知。 I'll get user id from webhook. 我将从webhook获取用户ID。 I read there tutorial and they said that after getting user id's i have to call dropbox api on the behalf of that particular userid. 我在那儿读了教程,他们说在获得用户ID后,我必须代表那个特定的用户ID调用dropbox api。

I also use DropNet nuget package for DropBox Communication. 我还使用DropNet nuget包进行DropBox通信。 Now my question is how can i use the user id (that i'll retrieve via Webhook) to get all the changes. 现在我的问题是如何使用用户ID(我将通过Webhook检索)来获取所有更改。 I know that i have to use "GetDelta" Routine but i don't know how can i create DropNet UserLogin on the basis of only "User Id" not on the basis of "User Access Token" and "User Secret Key", so that i can use "GetDelta" Routine. 我知道我必须使用“ GetDelta”例程,但是我不知道如何仅基于“用户ID”而不是基于“用户访问令牌”和“用户密钥”创建DropNet UserLogin,所以我可以使用“ GetDelta”例程。

Any help will be appreciated. 任何帮助将不胜感激。 Thanks. 谢谢。

You should be using a user access token and user secret key. 应该使用用户访问令牌和用户密钥。 On the server, you'll need to keep a mapping of user IDs to access tokens. 在服务器上,您需要保留用户ID的映射才能访问令牌。 When you see a change for a given user, you'll look up that user's access token and make calls via DropNet using that. 当看到给定用户的更改时,您将查找该用户的访问令牌,并使用该令牌通过DropNet进行呼叫。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM