Querying Identities
We have hundreds of thousands of customers in our system, and of those customers, I'd like to know what customers have secondary email addresses.
It looks like those are stored as an identity with a type of "email".
Right now, the only way that I can see to do this is to list users and side-load identities. "/users.json?include=identities"
I will then have to go through all the identities and filter by: type: "email", primary: false, and then group by "user_id" to find users that have secondary emails.
It wouldn't be so bad if I didn't have to load all the user data when trying to just retrieve all the identities, but I understand why it behaves this way. I wish there was an endpoint just for identities, even better if I could query against it.
Does anyone know of a better way to do this? I'd be fine if it was doable through the admin console as well but I don't see a way to filter based on secondary emails.
-
Hey Kevin,
Thanks for reaching out!
Unfortunately there isn’t a specific endpoint that allows you to search at scale directly for users with secondary email addresses - your workflow is probably how I would go about this as well.
I’d encourage you to make a post in our feedback channels outlining your use case and requirements. Here's a link to the product feedback template to get you started:
Product feedback post template
Thanks!
Tipene
Please sign in to leave a comment.
1 Comments