# Bulk user export: include permissions

**URL:** <https://community.auth0.com/t/bulk-user-export-include-permissions/66197>\
**Category:** Get Help\
**Tags:** export-user\
**Created:** [July 15, 2021, 5:57am UTC](https://community.auth0.com/t/bulk-user-export-include-permissions/66197 "2021-07-15T05:57:20Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![brecht.laitem](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/brecht.laitem/32/12857_2.png) [@brecht.laitem](https://community.auth0.com/u/brecht.laitem)\
**Post date:** [July 15, 2021, 5:57am UTC](https://community.auth0.com/t/bulk-user-export-include-permissions/66197/1 "2021-07-15T05:57:20Z")

</div>

Hi,

I’m using the bulk user export feature of the management API to export the users. Our customer now wants to include the permissions of each user in the export, but I couldn’t find a way to do that.

According to the documentation of what is included in the user profile, permissions are not included.

I thought to maybe using a rule to copy the permissions to the app\_metadata field of the user profile and use that, but this is not good enough for us, since users sometimes not login for several weeks or months and we want the export to be ‘as-is-now’.

Any idea’s on how to achieve this?

---

<div class="post-metadata">

**Author:** ![dan.woda](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/dan.woda/32/18340_2.png) [@dan.woda](https://community.auth0.com/u/dan.woda)\
**Post date:** [July 15, 2021, 5:01pm UTC](https://community.auth0.com/t/bulk-user-export-include-permissions/66197/3 "2021-07-15T17:01:01Z")

</div>

Hi @brecht.laitem,

You will need to export the permissions using the management API. You can get a users permissions via [this endpoint](https://auth0.com/docs/api/management/v2#!/Users/get_permissions).

If you are using roles it may be more efficient to [get a role’s users](https://auth0.com/docs/api/management/v2#!/Roles/get_role_user) then [get the role’s permissions](https://auth0.com/docs/api/management/v2#!/Roles/get_role_permission) and compare against your users.

Just be aware of the [Management API rate limits](https://auth0.com/docs/policies/rate-limit-policy/management-api-endpoint-rate-limits).

---

<div class="post-metadata">

**Author:** ![brecht.laitem](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/brecht.laitem/32/12857_2.png) [@brecht.laitem](https://community.auth0.com/u/brecht.laitem)\
**Post date:** [July 16, 2021, 6:03am UTC](https://community.auth0.com/t/bulk-user-export-include-permissions/66197/4 "2021-07-16T06:03:14Z")

</div>

Hi Dan.

Thank you for the fast response, altough iterating all the users is a no-go because as you mentioned the API rate limits. Just to much users in our database and it would be too slow also.

Using roles might be a better solutions, but requires some rewrite of the current implementation.

I really don’t get why this information isn’t exposed in the bulk export service.

---

<div class="post-metadata">

**Author:** ![dan.woda](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/dan.woda/32/18340_2.png) [@dan.woda](https://community.auth0.com/u/dan.woda)\
**Post date:** [July 16, 2021, 6:07pm UTC](https://community.auth0.com/t/bulk-user-export-include-permissions/66197/5 "2021-07-16T18:07:40Z")

</div>

If you aren’t using roles, exporting them via the first option I mentioned would be the best choice.

The management API rate limits are pretty generous. For example, a Developer subscription in production has a rate limit of 50 requests/second. It should take ~100 seconds to export 5000 users, for example.

If this is something you plan on doing on a consistent basis, you can always submit a [Feature Request](https://community.auth0.com/c/feedback/95).

Hope that helps

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/auth0/original/3X/b/5/b560f266932fcce5d57f09a6595bd50518cae3f3.jpeg) [@system](https://community.auth0.com/u/system)\
**Post date:** [July 31, 2021, 6:08pm UTC](https://community.auth0.com/t/bulk-user-export-include-permissions/66197/6 "2021-07-31T18:08:16Z")

</div>

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.
