MarcelRobitaille / bbyen

Bring Back YouTube Email Notifications! YouTube upload email notification replacement
MIT License
10 stars 0 forks source link

Getting Emails for Personalized & All #6

Closed ghost closed 3 years ago

ghost commented 3 years ago

I am getting emails for subscriptions I have saved as 'personalized' notifications for. Anyway to only send emails for those subscriptions I have set as 'all' ?

image

MarcelRobitaille commented 3 years ago

Thanks for the report. That is how it's supposed to work, yes. It looks like I misunderstood the entry in the docs that's supposed to do that. I'll see if I can find a way.

MarcelRobitaille commented 3 years ago

As of right now, I don't think there is any way to do that unfortunately. I have opened an issue here. Let's see if we get any reply. I would also really like this functionality. Unfortunately, Google apis are notoriously bad. If you really really wanted that feature, I guess we could have the program scrape the HTML, but then it would need to be authenticated as your user...

ghost commented 3 years ago

That's possible, for the time being I could make an easy work around by making an alt YT account that is only subbed to the channels I want to receive emails from

MarcelRobitaille commented 3 years ago

Yeah I thought of that too. That or a blacklist / whitelist in the config.

ghost commented 3 years ago

If that's possible for you to implement that would be the best

MarcelRobitaille commented 3 years ago

I added a blacklist. Try the latest commit. Just add a key blacklistedChannelIds in config.json. The value should be an array of channel ids to blacklist (ids rather than names because people like to rename their channel).

ghost commented 3 years ago

Not too familiar with all of this, could you show me what you mean by that? Thanks. And by the Channel Ids would you mean the actual channel ids or the integer values of them in database.sqlite ?

MarcelRobitaille commented 3 years ago

I mean the unique ID that YouTube gives this channel. You can see it in the logs of BBYEN, or by putting the url to the channel into this website.

For the config, it should not look like this:

{
    "email": {
        "host": "smtp.example.com",
        "port": 465,
        "secure": true,
        "auth": {
            "user": "your-automated-email@example.com",
            "pass": "your-automated-email-password"
        },
        "sendingContact": "\"BBYEN\" <your-automated-email@example.com>",
        "destination": "your-personal-email@example.com"
    },
    "database": {
        "filename": "database.sqlite"
    },
    "timers": {
        "subscriptions": "3 days",
        "videos": "6 hours"
    },
    "kickoff": {
        "subscriptions": true,
        "videos": true
    },
    "logging": {
        "level": "info"
    },
        "blacklistedChannelIds": [ "UC5NO8MgTQKHAWXp6z8Xl7yQ" ]
}
ghost commented 3 years ago

Could you add whitelisting as an option as well if possible? Would be easier than blacklisting most of my 200 subs. And just to confirm would adding a second channel just be [ "xxxx" "yyyy" ] ? Correct?

MarcelRobitaille commented 3 years ago

You need a comma in there: [ "xxxx", "yyyy" ]. I will add whitelisting.

MarcelRobitaille commented 3 years ago

See if latest commit works for you. Same thing, whitelistedChannelIds in config.

ghost commented 3 years ago

New clone with whitelistedChannelIds seems to not be working; unless it would have to go through the entire sub list to cache it, but that wouldn't make sense.

MarcelRobitaille commented 3 years ago

No, it shouldn't have to. Could you please post your config.json?

ghost commented 3 years ago

`{

"email": {
    "host": "smtp.gmail.com",
    "port": 465,
    "secure": true,
    "auth": {
        "user": "----@gmail.com",
        "pass": "----"
    },
    "sendingContact": "\"BBYEN\" <----@gmail.com>",
    "destination": "-----@gmail.com"

},
"database": {
    "filename": "database.sqlite"

},
"timers": {
    "subscriptions": "3 days",
    "videos": "1 hours"

},
"kickoff": {
    "subscriptions": true,
    "videos": true

},
"logging": {
    "level": "info"

},
"whitelistChannelIds": [ "UCmu9PVIZBk-ZCi-Sk2F2utA", "UC3IBRaFnWgy28FbS8y_hvQg", "UCwP3cAr798B69rULA_w_SdA", "UCov_51F0betb6hJ6Gumxg3Q", "UCQ9STd0zeHrrQGJQEuvhuTw", "UCFXc5nAao6554AIXlN9KgwQ", "UCq5SRFSlGthDYtLsbksZfMQ", "UCY3A_5R_m3PXCn5XDhvBBsg", "UCdJt4ZOl3ZvHs4FGt_yttKw", "UChRHXZj9ri-mmieJRKGa-3w", "UCTkXRDQl0luXxVQrRQvWS6w", "UCIyZiiHXIH7KkqfaDvBmG-Q", "UCA2tt9GSU2sl8rAqjlLR3mQ", "UC-kOXc3gBwksVfmndSEz7jg", "UCVlnbFbokOoklTRa65QnTNA", "UCUNoEsSfUcyNlaJbieYkMvg", "UCopd7DDjaIjzp8JXMKFvL8w", "UC3ltptWa0xfrDweghW94Acg", "UC3XTzVzaHQEd30rQbuvCtTQ", "UCRcgy6GzDeccI7dkbbBna3Q", "UCXuqSBlHAE6Xw-yeJA0Tunw", "UChrYe70o7NmDioL02PRVWVg", "UCS-WzPVpAAli-1IfEG2lN8A", "UCjFaPUcJU1vwk193mnW_w1w", "UCzbKyK3YQwJGwp4hrydFKig", "UCjzofrZsvck42FHW5LAI0DA", "UCZz9SVPgBpG_pTPHCc3GleA", "UC42NgAW2U0ZF_HTUw4mE_gQ", "UCGXoHUekWaWozDnYb9Y7hUQ", "UCNUzWfHUP_iXZ1GMHz8gBgw", "UClY084mbGLK_SLlOfgizjow", "UCwhWV4r7e6J5TjvYjA4ccng", "UCDRmGMSgrtZkOsh_NQl4_xw", "UC9Y0uUKJ5y78QbhHbntAyFQ", "UCtUbO6rBht0daVIOGML3c8w", "UCpGCuiAOFIDurA-hU_p2E0w", "UCy0tKL1T7wFoYcxCe0xjN6Q", "UC0vBXGSyV14uvJ4hECDOl0Q", "UCKGe7fZ_S788Jaspxg-_5Sg", "UCRHXUZ0BxbkU2MYZgsuFgkQ", "UC2gkQ4VVQftkUAqTHiXmvaA", "UCTqvhfqR9mDf1z6sDkLgSuw", "UCiSVflez5qi1cLwh6rg5Kyw" ]

} `

MarcelRobitaille commented 3 years ago

Ok, that looks right. What is actually happening? Is everything getting through the filter, or nothing?

ghost commented 3 years ago

All subscriptions are going through the whitelist

MarcelRobitaille commented 3 years ago

Actually there is a problem with your config. It should be whitelistedChannelIds.

ghost commented 3 years ago

Ah, seems to be working now! Thank you, I appreciate it

MarcelRobitaille commented 3 years ago

I'm closing this as I can't do anything about it for now.