Commit graph

63 commits

Author SHA1 Message Date
0e4a963bc7
[eventsub] Fix: Twitch renamed field in adbreak_begin
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2024-03-25 22:23:31 +01:00
c3085ea7f9
[eventsub] Suppress error on abnormal closure and reconnect
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2024-03-23 12:03:39 +01:00
031ad331e4
[eventsub] Fix: Do not retry subscription on collision
resolves #TWITCH-BOT-7

Signed-off-by: Knut Ahlers <knut@ahlers.me>
2024-03-22 21:29:07 +01:00
f2ac1acb17
[core] Add support for Hype-Train events
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2024-03-04 00:13:37 +01:00
673ed1e29a
Lint: Resolve linter issues
occurred with new Go / golangci-lint version

Signed-off-by: Knut Ahlers <knut@ahlers.me>
2024-02-18 13:42:00 +01:00
c78356f68f
Lint: Update linter config, improve code quality
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2024-01-01 17:52:39 +01:00
61bab3c984
[eventsub] Fix: Log error when giving up subscription retries
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-12-22 15:18:52 +01:00
8b3d3bdc98
[eventsub] Fix: Stop subscription-retries when client is closed
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-12-16 12:52:54 +01:00
eec4966b82
[eventsub] Fix: Clean IPs from eventsub-socket read errors
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-12-14 00:19:29 +01:00
1515536746
[twitch] Fix: Log correct error when wiping token fails
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-12-13 23:31:06 +01:00
e1f11a6c98
[eventsub] Make topic subscriptions more dynamic
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-12-13 23:14:50 +01:00
091dac235b
[eventsub] Update field naming for ad-break, use V1 event
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-12-12 16:00:08 +01:00
ee5e7359a2
[core] Add auth-cache for token auth
to speed up frontend and reduce CPU/MEM consumption on consecutive API
requests

Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-12-06 21:57:02 +01:00
0d10b5165f
[core] Add retries for database access methods
to compensate for database temporarily not being available. This is not
suitable for longer database outages as 5 retries with a 1.5 multiplier
will not give much time to recover but should cover for cluster changes
and short network hickups.

Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-12-04 16:19:36 +01:00
a1fa9972a8
[core] Fix: Do not retry requests with status 429
which for example can happen when doing two shoutouts within the 120s
cooldown period enforced by Twitch

Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-11-27 23:18:53 +01:00
e7a493cafe
[CLI] Add database migration tooling
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-11-26 16:55:05 +01:00
9ebdaa8a71
[templating] Add scheduleSegments function
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-11-05 13:44:16 +01:00
cb68b029ec
[core] Add timeout to eventsub connection dialer
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-11-05 11:50:56 +01:00
932e6907da
[eventsub] Replace keepalive timer
as `time.Timer` wasn't really suited for how it was used

Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-10-30 11:36:03 +01:00
a9e4931271
Add support for beta Ad-Break event
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-10-22 16:20:58 +02:00
ac4312ffc4
[core] Expose method to retrieve AppAccessToken
in order for libraries to for example instantiate an IGDB client easily

Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-10-10 14:42:32 +02:00
40dc38d9ac
[core] Fix: New followers endpoint requires user-token
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-10-08 12:26:43 +02:00
fbc76761b4
[core] Fix: Replace deprecated follow API
- add `moderator:read:followers` scope to bot-defaults
- document requirement of bot to be mod to read followers
- adjust `GetFollowDate` method to use new channel followers endpoint

Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-09-29 14:58:59 +02:00
1ac20921a1
[core] Add user:manage:whispers extended scope
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-09-13 22:41:46 +02:00
bcc5b4eba7
[core] Update go-irc to v4.0.0
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-09-11 19:51:38 +02:00
fb57cb9304
[templating] Add usernameForID function
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-09-03 12:09:33 +02:00
253379e507
[clip] Add clip actor
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-08-14 16:09:55 +02:00
8a40f105e3
[core] Fix: Clean usernames when querying user information
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-08-14 15:53:51 +02:00
c263c72f9b
[core] Improve GetCurrentStreamInfo lib function
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-07-30 14:03:55 +02:00
76e72e8148
[core] Use app-access-tokens for stream info
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-07-27 12:42:58 +02:00
3f64d60c43
[core] Add support for stream schedule to twitch lib
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-07-27 12:42:58 +02:00
7afea3ea30
[twitchclient] Reduce retries and errors when banning banned user
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-07-21 20:37:20 +02:00
a58b72c268
[#16] Implement Raffle module (#47) 2023-07-14 16:15:58 +02:00
a4a3a7f81e
[eventsub] Replace IsMature tag in channel updates
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-07-04 00:05:04 +02:00
fc93c6e63b
[core] Export Twitch client Request
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-07-01 16:48:21 +02:00
49aba55cfe
[core] Clean IPs from socket errors
in order not to log IPs (GDPR) and also to prevent spread of errors in
Sentry logging as IP/Port combinations are unique per connection and
therefore will spam with many unique errors. By removing the unique
information from the error the errors should be groupable again.

Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-06-24 14:59:36 +02:00
a136902d58
[eventsub] Add debug logging for subscribed topics
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-05-21 16:01:22 +02:00
79fb09469c
[template] Add lastPoll function
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-05-21 15:28:10 +02:00
04648a22e0
[eventsub] Add poll_begin, poll_end, poll_progress events
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-05-21 14:59:06 +02:00
0e7af1cfc8
[eventsub] Switch to Websocket transport (#46)
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-05-18 15:09:25 +02:00
63685ff5f2
[core] Allow case insensitive category matches
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-05-11 14:42:32 +02:00
f9c6be800b
[template] Add subCount, subPoints template functions
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-04-22 22:23:35 +02:00
d92a451ebc
[linkprotect] Add Link-, Clip-Detector and Link-Protection actor (#42) 2023-04-08 00:41:00 +02:00
0dc648d02a
[core] Add connection tuning for MySQL databases
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-04-01 15:40:54 +02:00
3213f4ac37
[core] Add validation and reset of encrypted values
in order to detect change of encryption pass

Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-03-24 20:41:02 +01:00
7126f6d7b7
[eventsub] Switch to v2 follows topic
as Twitch changed the policy which applications can use the v1 endpoint

> Update (2023-02-23): The deprecated “Get Users Follows” API
> endpoint and channel.follow (v1) EventSub subscription type now
> have limited access to minimize usage in new development leading up
> to the August 3 decommission date. The API endpoint is accessible
> to client IDs that have made requests on or before February 17,
> 2023. The v1 EventSub subscription type is accessible to client IDs
> that had an active subscription on February 17, 2023.
> (https://discuss.dev.twitch.tv/t/follows-endpoints-and-eventsub-subscription-type-are-now-available-in-open-beta/43322)

Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-03-22 00:24:07 +01:00
f066b3fd2a
[eventsub] Add shoutout_created event
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-03-21 10:51:34 +01:00
990060ce41
[commercial] Add commercial actor
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-03-17 17:08:56 +01:00
8eaf676b13
[eventsub] Add shoutout_received event
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-02-11 23:10:16 +01:00
75991fdb87
[core] Rewrite bot token storage logic
- Do not store bot-token as core-kv entry
- Hold the bot username in core-kv
- Take bot client from extended channel permissions
- Store (updated) bot tokens into extended permissions

Signed-off-by: Knut Ahlers <knut@ahlers.me>
2023-02-06 19:55:46 +01:00