Your workflow is unique 👨‍💻 -  tell us how you use Dropbox here.

Forum Discussion

Federico B.4's avatar
Federico B.4
New member | Level 1
9 years ago

Business API notifications for activity

Hello. I'm trying to get a notification when a team's user logs in, but so far I haven't found a reasonable way to do this.

Since logins don't seem to trigger the webhooks, what I'm doing is:

1. Wait for any webhook notification (the user did something so he must have logged in recently).

2. Once received, take the list of users and get the events from the `team/log/get_events` v1 API (I was not able to find login/logout information in v2). Save cursor for future requests. 

It kinda works, but I'd like to know if there's a more appropriate way to achieve this for auditing purposes.

3 Replies

Replies have been turned off for this discussion
  • Alexandra F.1's avatar
    Alexandra F.1
    New member | Level 1
    9 years ago

    Yes, the /team/log/get_events (aka the audit log) for API v1 is what you want. Unfortunately, the API does not support webhooks for login events, but I'll be sure to pass this along as a feature request.

    Also, you may find API v2's /devices/list_members_devices endpoint useful (documentation here: https://www.dropbox.com/developers/documentation/http/teams#team-devices-list_members_devices ). You can get a list of all the devices and web sessions to which all team members are currently signed-in (sorted by member). It's not real-time notifications, but you could use this in a similar way to how your webhook+audit log workflow, replacing /devices/ calls with the audit log.

  • Federico B.4's avatar
    Federico B.4
    New member | Level 1
    9 years ago

    Thanks for the prompt response Alexandra! We'll use `list_members_devices` since the format fits our situation much better.

    To clarify our needs going forward for the feature request: we want to receive a webhook when a user does a login/logout action for auditing processes on business accounts. 

    Thanks again!

About Dropbox API Support and Feedback

Node avatar for Dropbox API Support and Feedback
Get help with the Dropbox API from fellow developers and experts.

The Dropbox Community team is active from Monday to Friday. We try to respond to you as soon as we can, usually within 2 hours.

If you need more help you can view your support options (expected response time for an email or ticket is 24 hours), or contact us on X, Facebook or Instagram.

For more info on available support options for your Dropbox plan, see this article.

If you found the answer to your question in this Community thread, please 'like' the post to say thanks and to let us know it was useful!