freestuff

package
v0.0.0-...-a027125 Latest Latest
Warning

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

Go to latest
Published: Jan 29, 2022 License: GPL-3.0 Imports: 11 Imported by: 0

README

Freestuff

Get notified about free apps in Discord

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Config config

Functions

func Price

func Price(title string) (float64, error)

func ResponseOk

func ResponseOk(statusCode int) bool

Types

type AppstoreInfo

type AppstoreInfo struct {
	Score    float64
	Ratings  float64
	Category string
}

func (AppstoreInfo) GetLabels

func (a AppstoreInfo) GetLabels() []Label

type ExtraInfo

type ExtraInfo interface {
	GetLabels() []Label
}

func GetAppstoreInfo

func GetAppstoreInfo(link string) (ExtraInfo, error)

func GetExtraInfo

func GetExtraInfo(link string) (ExtraInfo, error)

func GetGogInfo

func GetGogInfo(link string) (ExtraInfo, error)

type GogInfo

type GogInfo struct {
	Score float64
}

func (GogInfo) GetLabels

func (g GogInfo) GetLabels() []Label

type Label

type Label struct {
	Key   string
	Value string
}

type LinkCache

type LinkCache interface {
	IsKnown(title string) bool
	SetKnown(title string) error
}
type RedditLink struct {
	Title      string
	Link       string
	RedditLink string
	Image      string
}

func GetLinksFromSubreddit

func GetLinksFromSubreddit(subreddit Subreddit) ([]RedditLink, error)

type RedisCache

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

func NewRedisCache

func NewRedisCache() RedisCache

func (*RedisCache) IsKnown

func (r *RedisCache) IsKnown(title string) (bool, error)

func (*RedisCache) SetKnown

func (r *RedisCache) SetKnown(title string) error

type Subreddit

type Subreddit string

Jump to

Keyboard shortcuts

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