bttv

package
v0.4.2 Latest Latest
Warning

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

Go to latest
Published: Aug 17, 2024 License: MIT Imports: 5 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 NewAPI

func NewAPI(client *http.Client) *API

func (API) GetGlobalEmotes

func (a API) GetGlobalEmotes(ctx context.Context) (GlobalEmoteResponse, error)

type APIError

type APIError struct {
	StatusCode int    `json:"-"`
	Status     string `json:"-"`
	Message    string `json:"message"`
}

func (APIError) Error

func (a APIError) Error() string

type Emote

type Emote struct {
	ID        string `json:"id"`
	Code      string `json:"code"`
	ImageType string `json:"imageType"`
	Animated  bool   `json:"animated"`
	UserId    string `json:"userId"`
}

type GlobalEmoteResponse

type GlobalEmoteResponse []Emote

type SharedEmote

type SharedEmote struct {
	ID        string          `json:"id"`
	Code      string          `json:"code"`
	ImageType string          `json:"imageType"`
	Animated  bool            `json:"animated"`
	User      SharedEmoteUser `json:"user"`
}

type SharedEmoteUser

type SharedEmoteUser struct {
	ID          string `json:"id"`
	Name        string `json:"name"`
	DisplayName string `json:"displayName"`
	ProviderId  string `json:"providerId"`
}

type UserResponse

type UserResponse struct {
	ID            string        `json:"id"`
	Bots          []string      `json:"bots"`
	Avatar        string        `json:"avatar"`
	ChannelEmotes []Emote       `json:"channelEmotes"`
	SharedEmotes  []SharedEmote `json:"sharedEmotes"`
}

Jump to

Keyboard shortcuts

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