Docs : API : List Database Users
The List Database Users API lets you retrieve all the users who have access to a database. Database ID's can be obtained from the getDatabases function in the SDK. This endpoint is paginated.
curl 'https://v1.userbase.com/v1/admin/databases/$DATABASE_ID/users?nextPageToken=$NEXT_PAGE_TOKEN' \
-XGET \
-H 'Authorization: Bearer $ACCESS_TOKEN'
Parameters
-
DATABASE_ID - The database ID to retrieve.
-
NEXT_PAGE_TOKEN - The next page of users to retrieve.
-
ACCESS_TOKEN - Your access token.
Result
- nextPageToken [string] - Each response has a max limit of around 1mb of users. If this limit is reached, this token is provided in the response, and must be provided in the next request to get the next page of users.
- users [array]
- userId [string] - The user's unique identifier.
- isOwner [boolean] - Whether or not the user owns the database.
- readOnly [boolean] - Whether or not the user has read only permissions to the database.
- resharingAllowed [boolean] - Whether or not the user has permission to reshare the database.