Best way to get (via API) a list of users from a group, and their bios

I would like to make an API call that would return a list of users in a given user group, along with their bio. I don’t want to be in a position of having to make a new API call for every user to then get their bio.

Is there any way to do this?

Use the data explorer plugin and then Run Data Explorer queries with the Discourse API.

1 Like

Is there any way to do this using the publicly available APIs? We want to be able to access this data from a public site, but it looks like the bio might not be available unless you provide an API key.

I don’t think there’s an endpoint that will give you all group members with their bio. You’ll need to loop through the users to get their bio. You can get group users from something like https://meta.discourse.org/groups/support-experts/members.json?offset=0&order=&asc=true&filter=

Profile - pfaffman - Discourse Meta shows my bio in an incognito window, so the bio might be available on your site to anonymous users, so you wouldn’t need an API key.

Maybe you want to look at Reverse engineer the Discourse API

I was once an academic. My wife does discourse analysis with tools like ATLAS.ti and I’ve spent some time pulling data from various sources to be analzed with various tools. Good luck to you!

3 Likes

I think you’d need to have hide user profiles from public toggled off for them to be available for non-users, so that may be worth a check.

4 Likes

Thank you, I didn’t realize this was an option, but changing that allows me to access the details of the users now!

3 Likes

So you ARE an admin but you want to pull the data without using an API key?

So you’re trying to embed these data from a site that you manage onto some other site?

2 Likes

Yes, and it has been successful thanks to your help :slight_smile:

2 Likes

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