# How to search a user by its twitter screen\_name? (Since Twitter integration was never fixed)

**URL:** <https://community.auth0.com/t/how-to-search-a-user-by-its-twitter-screen-name-since-twitter-integration-was-never-fixed/136458>\
**Category:** Get Help\
**Tags:** user-search, user-management\
**Created:** [June 16, 2024, 4:58pm UTC](https://community.auth0.com/t/how-to-search-a-user-by-its-twitter-screen-name-since-twitter-integration-was-never-fixed/136458 "2024-06-16T16:58:06Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![claudio.villalobos](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/claudio.villalobos/32/55950_2.png) [@claudio.villalobos](https://community.auth0.com/u/claudio.villalobos)\
**Post date:** [June 16, 2024, 4:58pm UTC](https://community.auth0.com/t/how-to-search-a-user-by-its-twitter-screen-name-since-twitter-integration-was-never-fixed/136458/1 "2024-06-16T16:58:06Z")

</div>

The existing Twitter integration puts the actual ‘username’ into the ‘screen\_name’ field on a user profile. I saw posts reporting this behavior a long time ago but it was never fixed.

How can I search for a user using Lucene syntax by its ‘screen\_name’ property?

The current username search would require me to know the numeric twitter ID for every user which kind of defeats the purpose of searching in the first place.

 ![image](https://global.discourse-cdn.com/auth0/original/3X/1/8/18758fab6adbf769043adde95f3b28c105ecb246.png)

![image](https://global.discourse-cdn.com/auth0/original/3X/a/4/a4e0eade8e3b32b7727e0f7729189029933b8f0c.png)

---

<div class="post-metadata">

**Author:** ![devpaulosouza](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/devpaulosouza/32/73677_2.png) [@devpaulosouza](https://community.auth0.com/u/devpaulosouza)\
**Post date:** [March 16, 2025, 6:30pm UTC](https://community.auth0.com/t/how-to-search-a-user-by-its-twitter-screen-name-since-twitter-integration-was-never-fixed/136458/2 "2025-03-16T18:30:39Z")

</div>

I fixed created an Action Trigger on post-login

```auto
exports.onExecutePostLogin = async (event, api) => {
  const { screen_name } = event.user;

  if (event.authorization) {
    // Set claims 
    api.idToken.setCustomClaim(`screen_name`, screen_name);
  }
};

```

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/auth0/original/3X/b/5/b560f266932fcce5d57f09a6595bd50518cae3f3.jpeg) [@system](https://community.auth0.com/u/system)\
**Post date:** [March 30, 2025, 6:31pm UTC](https://community.auth0.com/t/how-to-search-a-user-by-its-twitter-screen-name-since-twitter-integration-was-never-fixed/136458/3 "2025-03-30T18:31:24Z")

</div>

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