# Check if it is the streamer viewing

**URL:** <https://discuss.dev.twitch.com/t/check-if-it-is-the-streamer-viewing/33293>\
**Category:** Extensions\
**Created:** [August 30, 2021, 3:28am UTC](https://discuss.dev.twitch.com/t/check-if-it-is-the-streamer-viewing/33293 "2021-08-30T03:28:36Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![dementor](https://d3ovvz0v2ajtpu.cloudfront.net/user_avatar/discuss.dev.twitch.com/dementor/32/13368_2.png) [@dementor](https://discuss.dev.twitch.com/u/dementor)\
**Post date:** [August 30, 2021, 3:28am UTC](https://discuss.dev.twitch.com/t/check-if-it-is-the-streamer-viewing/33293/1 "2021-08-30T03:28:36Z")

</div>

Hello

How can I check if the user viewing my extension is the streamer? Does this require authentication?

---

<div class="post-metadata">

**Author:** ![BarryCarlyon](https://d3ovvz0v2ajtpu.cloudfront.net/user_avatar/discuss.dev.twitch.com/barrycarlyon/32/253_2.png) [@BarryCarlyon](https://discuss.dev.twitch.com/u/BarryCarlyon)\
**Post date:** [August 30, 2021, 8:17am UTC](https://discuss.dev.twitch.com/t/check-if-it-is-the-streamer-viewing/33293/2 "2021-08-30T08:17:36Z")

</div>

> [@dementor](#):
>
> How can I check if the user viewing my extension is the streamer?

See if the userID (is allowing ID sharing) is the JWT matches the channel ID - `window.Twitch.ext.viewer.id:`  
Or the `opaqueId` is `UchannelID`  
Or the JWT role is `broadcaster`  
Or the Helper Role is `broadcaster` as in `window.Twitch.ext.viewer.role`

> **[Extensions Reference](https://dev.twitch.tv/docs/extensions/reference/)**
>
> Extensions Reference

or if they are on the config view, defintely the broadcaster, but still wise to test

---

<div class="post-metadata">

**Author:** ![dementor](https://d3ovvz0v2ajtpu.cloudfront.net/user_avatar/discuss.dev.twitch.com/dementor/32/13368_2.png) [@dementor](https://discuss.dev.twitch.com/u/dementor)\
**Post date:** [September 2, 2021, 1:33am UTC](https://discuss.dev.twitch.com/t/check-if-it-is-the-streamer-viewing/33293/3 "2021-09-02T01:33:22Z")

</div>

Thank you, perfect.
