go-twitch/eventsub/webhook/messages/handler.go

14 lines
575 B
Go

package messages
// Handler receives messages from the eventsub transports.
//
// NOTE: When using webooks as the eventsub transport you should make sure
// that you handle the message in a background goroutine and return as soon
// as possible. If you don't, you may receive duplicate messages as twitch
// will consider the processing failed after one or two seconds. If you fail
// to respond quickly enough too many times, the subscription may be revoked
// and you will have to resubscribe to the eventsub events.
type Handler interface {
Handle(msg *Message) error
}