server

package
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 10, 2023 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type API

type API struct {
	// contains filtered or unexported fields
}

func New

func New(logger zerolog.Logger, config Config, client *http.Client, ttvAPI *twitch.API) *API

func (*API) Launch

func (a *API) Launch(ctx context.Context) error

type Client

type Client struct {
	// contains filtered or unexported fields
}

func NewClient

func NewClient(baseURL string, httpClient *http.Client) *Client

func (*Client) GetChannelEmotes

func (c *Client) GetChannelEmotes(ctx context.Context, broadcaster string) (twitch.EmoteResponse, error)

func (*Client) GetChatSettings

func (c *Client) GetChatSettings(ctx context.Context, broadcasterID string, moderatorID string) (twitch.GetChatSettingsResponse, error)

func (*Client) GetGlobalEmotes

func (c *Client) GetGlobalEmotes(ctx context.Context) (twitch.EmoteResponse, error)

func (*Client) GetStreamInfo

func (c *Client) GetStreamInfo(ctx context.Context, broadcastID []string) (twitch.GetStreamsResponse, error)

func (*Client) GetUsers

func (c *Client) GetUsers(ctx context.Context, logins []string, ids []string) (twitch.UserResponse, error)

func (*Client) RefreshToken

func (c *Client) RefreshToken(ctx context.Context, refreshToken string) (string, string, error)

type Config

type Config struct {
	ClientID     string
	ClientSecret string
	HostAndPort  string
	RedirectURL  string
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL