Skip to main content
Solved

Regarding api

  • November 29, 2024
  • 6 replies
  • 82 views

Forum|alt.badge.img+1

How to list all users thorugh api.
 

 

Best answer by chloe.strange

Hi ​@deependra123,

The ajax calls can only be made in the context of a logged-in browser session, not the API. 

With that said, I have submitted a feature request for “get all users” on your behalf. 

~Chloe

6 replies

Forum|alt.badge.img+7
  • Klaviyo Employee
  • November 29, 2024

Hi, currently you can’t fetch admin users through the API.

What’s the use case, what are you trying to do to automate getting an account’s users (and possibly their roles)?


Forum|alt.badge.img+1
  • Author
  • Contributor I
  • December 4, 2024

In klavyo we can invite or add member in same account. In krispcall integration with klaviyo, we have the ability to integrate with different member of klaviyo. While integrating klaviyo from our platform, we want to save the user_id of logged in member of klaviyo in our database . since there is not api regarding getting current user api or to list the user api , we are not able to save it in our database. There is only account api which return account id which is same for all user.


Forum|alt.badge.img+7
  • Klaviyo Employee
  • December 4, 2024

Hi, even if the API could fetch a list of account users, there’d still be no concept of “the current/logged in user”. API calls happen outside of a browser session and aren’t tied to a specific account (rather, each key has a set of access scopes).


Forum|alt.badge.img+1
  • Author
  • Contributor I
  • December 6, 2024

After inspecting in browser tab , there is api to list all users which is 

https://www.klaviyo.com/ajax/account/users/get, but this api is not accessible . We want api which give us the logged in user deatail after perfroming oAuth with klaviyo.


chloe.strange
Community Manager
Forum|alt.badge.img+43
  • Community Manager
  • Answer
  • December 19, 2024

Hi ​@deependra123,

The ajax calls can only be made in the context of a logged-in browser session, not the API. 

With that said, I have submitted a feature request for “get all users” on your behalf. 

~Chloe


talhahussain
Expert Problem Solver I
Forum|alt.badge.img+9
  • Expert Problem Solver I
  • December 20, 2024

This discussion on API integration is super helpful! APIs play such a critical role in streamlining data and enhancing workflows in Klaviyo. Thanks for sharing these insights it's always great to learn more about optimizing API usage. Looking forward to more discussions like this!