ingest: add wire format for incoming messages
This commit is contained in:
13
twitch/eventsub.go
Normal file
13
twitch/eventsub.go
Normal file
@@ -0,0 +1,13 @@
|
||||
package twitch
|
||||
|
||||
// EventSub is the wire format of incoming payloads from Twitch EventSub.
|
||||
type EventSub[Event any] struct {
|
||||
// Subscription is fields relating to the EventSub subscription itself.
|
||||
Subscription Subscription `json:"subscription"`
|
||||
// Event is the event payload.
|
||||
Event Event `json:"event"`
|
||||
}
|
||||
|
||||
// Subscription is the fields of an EventSub subscription
|
||||
// which are relevant to Kaiyan.
|
||||
type Subscription struct{}
|
Reference in New Issue
Block a user