# Searching data via role

**URL:** <https://forum.opensearch.org/t/searching-data-via-role/3436>\
**Category:** Security\
**Created:** [August 3, 2020, 12:21pm UTC](https://forum.opensearch.org/t/searching-data-via-role/3436 "2020-08-03T12:21:00Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![luj\_ogluszacz](https://avatars.discourse-cdn.com/v4/letter/l/bbce88/32.png) [@luj\_ogluszacz](https://forum.opensearch.org/u/luj_ogluszacz)\
**Post date:** [August 3, 2020, 12:21pm UTC](https://forum.opensearch.org/t/searching-data-via-role/3436/1 "2020-08-03T12:21:00Z")

</div>

Hi, everyone. My problem is that I get JSON from different App where I don’t get information about the user just about the role. Can I search for data only having a role? Or if I create only one user can I search and exclude/include data that have this particular role that is assigned to a particular document or index?

---

<div class="post-metadata">

**Author:** ![Anthony](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.opensearch.org/anthony/32/9939_2.png) [@Anthony](https://forum.opensearch.org/u/Anthony)\
**Post date:** [March 12, 2021, 2:23pm UTC](https://forum.opensearch.org/t/searching-data-via-role/3436/2 "2021-03-12T14:23:21Z")

</div>

@luj_ogluszacz can you confirm if you are getting JSON in a form of JWT?
