Documentation
¶
Index ¶
- Constants
- Variables
- func NewApiV1(apiClient *ApiClient, userFollowsChan chan<- v1.UserFollows, ...) *apiV1
- func NewApiV2(apiClient *ApiClient, userFollowsChan chan<- v1.UserFollows, ...) *apiV2
- func NewServer(apiClient *ApiClient, userFollowsChan chan<- v1.UserFollows, ...) *server
- type ApiClient
- type ChatBot
- type Manager
- type ReloadMessage
Constants ¶
View Source
const ( EventType_ChannelFollow = "channel.follow" EventType_StreamOnline = "stream.online" EventType_StreamOffline = "stream.offline" )
Event Types
View Source
const ( SUBSCRIPTION_VERSION = "1" EVENT_SUB_URL = "https://api.twitch.tv/helix/eventsub/subscriptions" )
View Source
const (
EventMethod_webhook = "webhook"
)
Event Methods
Variables ¶
View Source
var ( BASE_AUTH_URL = "https://id.twitch.tv" AUTH_VERSION = "oauth2" TOKEN_ENDPOINT = "token" BASE_API_URL = "https://api.twitch.tv" API_VERSION = "helix" USERS_ENDPOINT = "users" FOLLOWS_ENDPOINT = USERS_ENDPOINT + "/follows" GAMES_ENDPOINT = "games" STREAMS_ENDPOINT = "streams" CHANNELS_ENDPOINT = "channels" EVENTSUB_ENDPOINT = "eventsub" SUBSCRIPTIONS_ENDPOINT = "subscriptions" )
View Source
var ( BASE_SELF_API_URL = "https://twitch.aybushbot.com/api" DEFAULT_SELF_API_VER = "v2" CURRENT_TWITCH_API_VER = 2 )
Functions ¶
func NewApiV1 ¶
func NewApiV1(apiClient *ApiClient, userFollowsChan chan<- v1.UserFollows, streamChangedChan chan<- messages.StreamChanged) *apiV1
func NewApiV2 ¶
func NewApiV2(apiClient *ApiClient, userFollowsChan chan<- v1.UserFollows, streamChangedChan chan<- messages.StreamChanged) *apiV2
func NewServer ¶
func NewServer(apiClient *ApiClient, userFollowsChan chan<- v1.UserFollows, streamChanged chan<- messages.StreamChanged, certFile string, keyFile string) *server
Types ¶
type ChatBot ¶
type ChatBot struct {
// contains filtered or unexported fields
}
func NewChatBot ¶
func NewChatBot(username string, token string, streamer payloads.User, client *ApiClient, twitchRepository repository.TwitchRepository) *ChatBot
type Manager ¶
type Manager struct {
// contains filtered or unexported fields
}
func NewManager ¶
func NewManager(streamerUsername string, clientSecret string, clientID string, userRefreshToken string, userFollowsChan chan<- v1.UserFollows, streamChangedChan chan<- messages.StreamChanged, hubSecretP string, twitchRepository repository.TwitchRepository, certFile string, keyFile string) *Manager
Source Files
¶
Click to show internal directories.
Click to hide internal directories.