Export List of Users in a Group

Comments

4 comments

  • Avatar
    Katie Garrison

    Hi Jessica,

    Using the REST API you can pretty quickly get this info in JSON document format.

    The GET /users API supports group ID - 

    You could run GET /groups with the group name to get it's ID

    Then use that group ID in the GET /users call which will provide users who are members of that group.
    You can even use the 'fields' parameter to include or exclude fields.

    Hope that helps,
    Katie

    0
    Comment actions Permalink
  • Avatar
    Jessica Orlando

    Thanks Katie, I think it worked, is this the expected formatting result? It's very tough to dig through.

    0
    Comment actions Permalink
  • Avatar
    Moti Granovsky (Edited )

    Hi Jessica,

    If you use the "v1" API instead, which is at /api/v1/users, you could simplify the results from this API by specifying which fields should be returned, via the "fields" parameter:

    or as it would be in the URL:

    http://10.50.12.161:30845/api/v1/users?fields=userName%2Cemail

    (This is in addition to specifying the group ID to filter by)

    This should make the results easier to work with - and you can also find various tools online that will convert this format (JSON) to something more convenient for manual editing such as CSV.

    0
    Comment actions Permalink
  • Avatar
    Michael Becker

    Hi Jessica,

    other solution is to connect to Sisense MongoDB through Mongo Connector https://documentation.sisense.com/latest/managing-data/connectors/mongodb_online.htm#gsc.tab=0 , before that you need to setup read user on your mongo for Sisense via this API

    it is in REST V 1.0 under admin section. After you setup this user and connect using it to Mongo on Sisense you will be able to select connecting to some databases and you should select this one:

    The in Collections look for Users and Groups tables. Due to JSON structure mongo connector can generate multiple tables for Users and Gropus depending on how many nested JSON structures are within it. That should be realtievely easy to go through, and then you should have a full structure of Users per Group. What is more, this can be refreshed as any ECube so it will be up to date with a need to call API everytime. Hope that helps.

    Regards,

    Michał

    0
    Comment actions Permalink

Please sign in to leave a comment.