List another user's contact/mailing lists | XM Community
Skip to main content

Hey there community. Riddle me this. I am a brand admin. I am wanting to use the API to retrieve the IDs of the contact/mailing lists in another user's account. Everyone in my organization is under the same directory / pool ID. I can't seem to find a way get mailinglistID's for any lists outside those in my own account - that's all the current "list mailing lists" command seems to do. (https://api.qualtrics.com/dd83f1535056c-list-mailing-lists) All I see is my own stuff.
Does anyone know how I can use the API to get the mailinglistIDs for lists in accounts other than my own? Or is this a hole in the API functionality?
When I asked support, all the techs would suggest was to "use the List Users API and then get the API token for each of those users and list through the lists of all of those users." ... I don't follow. If I have an account's API token, how can I get "the (contact/mailing) lists" of that user?

I don't think you can. I would classify it as a security feature rather than a hole.
Ideally, the mailing lists should have been created in a shared folder so both you and user would have API access using your own API tokens.
Support's answer was for you to use the user's API token. From a security perspective, that isn't ideal. However, as a Brand Admin you can login as the user through the user admin panel then look-up their API token. Once you have the user's token there is an API to list the mailing lists they have access to.


Appreciate the response, sir.
You mention "Once you have the user's token there is an API to list the mailing lists they have access to"... Can you link or reference this precisely? I can't see how having a user's API token allows me to grab their mailing lists. Not in any of the calls I can see in the documentation at least.


https://community.qualtrics.com/XMcommunity/discussion/comment/48508#Comment_48508https://api.qualtrics.com/dd83f1535056c-list-mailing-lists


I was just about to write back that I'd been there and there was no place to put the API token... Then it clicked... If I have their token I can use it in the call - the "X-API-TOKEN" parameter in the header - and that indeed does give me that user's unique mailing lists. Thanks for helping me put two and two together, sir!


Oh. Hmm. New problem. Only a few people have access to the API, and I'm not wanting to manually click into everyone's account and give them OAuth2 access... Whenever I get someone's API token and run the list call, I get "403: This user does not have access to this API endpoint." Even when I make a user a Brand Admin they don't get access, seemingly. Any ideas how I can actually run/loop through these calls without giving each and every person scoped OAuth access? (Also, is there a way to do that in an automated / API way?)


Leave a Reply