and i'm not using "Dropbox Business API" , i'm using "Dropbox API" . and according to instruction mentioned in webhook section we need to use
Note that only the user IDs and accounts with file changes are provided. Your app is expected to call /files/list_folder/continue to find out what files changed using the latest cursor your app previously stored for that account. If your app is still using v1, you can call /delta.
But when i'm using api call /list_folder i got all files and folders , and when i use "Dropbox-Api-Select-Admin" in Header than i got "Error in call to API function "files/list_folder": Unexpected select user header. Your app does not have permission to use this feature" , so i need to use business api for access files ?
Need solution for this problem how i get changed files by user , please provide me perfect solution for access this
First, to clarify, if you're only using a Dropbox API app, not a Dropbox Business API app, you should not use the "Dropbox-API-Select-Admin". You can access the Dropbox API endpoints, such as the list_folder endpoints, without that header.
The basic flow for using webhooks with list_folder would go like this:
the user connects to the app for the first time
the app stores the access token for that user, identified by the Dropbox account ID
the app starts listing the files and folders for the user using /2/files/list_folder and /2/files/list_folder/continue as necessary
the app stores the last returned cursor for that user, identified by the Dropbox account ID
the user leaves and some time passes
the user makes changes elsewhere
Dropbox sends the webhook notification for that user with the relevant account ID to the app's webhook URI
the app receives the webhook notification for that user and looks like up the access token and last received cursor for that account ID
the app calls /2/files/list_folder/continue with that access token and cursor to get the latest changes
The webhook notification includes the account ID of the user who had changes in their account. You can use that account ID to look up the user in your app so you know which one to update. This means you do need to record the Dropbox account IDs originally, but exactly how you manage your app's user model and database is up to you of course.