# Problem with PubSub and WebHooks

**URL:** <https://staging-discuss.dev.twitch.com/t/problem-with-pubsub-and-webhooks/28591>\
**Category:** API\
**Created:** [October 12, 2020, 7:36pm UTC](https://staging-discuss.dev.twitch.com/t/problem-with-pubsub-and-webhooks/28591 "2020-10-12T19:36:39Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Chimo](https://avatars.discourse-cdn.com/v4/letter/c/a9a28c/32.png) [@Chimo](https://staging-discuss.dev.twitch.com/u/Chimo)\
**Post date:** [October 12, 2020, 7:36pm UTC](https://staging-discuss.dev.twitch.com/t/problem-with-pubsub-and-webhooks/28591/1 "2020-10-12T19:36:39Z")

</div>

Hello, how are you?  
I have 2 problems:

1. I’m using pubsub with the follow topics without problems “channel-points-channel-v1” and “channel-subscribe-events-v1” but I have an error on auth when I try add topic “channel-bits-events-v1” or “channel-bits-events-v2”, I added the scope “bits:read” but get the auth error.

2. I’m trying to use webhooks with the topic “[https://api.twitch.tv/helix/streams?user\_id=](https://api.twitch.tv/helix/streams?user_id=)…”, the auth is correct and the hook make a request GET to my callback and I send the “hub.challenge” value, but when change the title or game never call the POST of my callback. I’m trying when I not live, this is a problem?

Thank you!

---

<div class="post-metadata">

**Author:** ![BarryCarlyon](https://d1d6mrmdu7ztse.cloudfront.net/user_avatar/staging-discuss.dev.twitch.com/barrycarlyon/32/253_2.png) [@BarryCarlyon](https://staging-discuss.dev.twitch.com/u/BarryCarlyon)\
**Post date:** [October 12, 2020, 7:40pm UTC](https://staging-discuss.dev.twitch.com/t/problem-with-pubsub-and-webhooks/28591/2 "2020-10-12T19:40:08Z")

</div>

> [@Chimo](#):
>
> I’m using pubsub with the follow topics without problems “channel-points-channel-v1” and “channel-subscribe-events-v1” but I have an error on auth when I try add topic “channel-bits-events-v1” or “channel-bits-events-v2”, I added the scope “bits:read” but get the auth error.

You did generate a user access token and not an app access token?

> **[Getting OAuth Access Tokens](https://dev.twitch.tv/docs/authentication/getting-tokens-oauth/)**
>
> Getting OAuth Access Tokens

Also you are trying to listen on `channel-bits-events-v1.<channel ID>` where `<channel ID>` is the channel ID of the user in the token?

> [@Chimo](#):
>
> I’m trying to use webhooks with the topic “[https://api.twitch.tv/helix/streams?user\_id=…”](https://api.twitch.tv/helix/streams?user_id=%E2%80%A6%E2%80%9D), the auth is correct and the hook make a request GET to my callback and I send the “hub.challenge” value, but when change the title or game never call the POST of my callback. I’m trying when I not live, this is a problem?

The hook only fires when you are live or going live

It fires for stream up, stream down, and game/title changes whilst live

---

<div class="post-metadata">

**Author:** ![Chimo](https://avatars.discourse-cdn.com/v4/letter/c/a9a28c/32.png) [@Chimo](https://staging-discuss.dev.twitch.com/u/Chimo)\
**Post date:** [October 12, 2020, 8:09pm UTC](https://staging-discuss.dev.twitch.com/t/problem-with-pubsub-and-webhooks/28591/3 "2020-10-12T20:09:28Z")

</div>

Thank for reply, so, I should test second problem when I’m live, regarding with the first error you are right, I generated the access token with an refresh token who no haven’t the right permises

Thanks!

---

<div class="post-metadata">

**Author:** ![system](https://d2spem0quai2ol.cloudfront.net/original/2X/0/05909729875cce3b53e59d5561c4d23bb14948fc.png) [@system](https://staging-discuss.dev.twitch.com/u/system)\
**Post date:** [November 11, 2020, 8:09pm UTC](https://staging-discuss.dev.twitch.com/t/problem-with-pubsub-and-webhooks/28591/4 "2020-11-11T20:09:33Z")

</div>

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