config

package
v0.3.2 Latest Latest
Warning

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

Go to latest
Published: Sep 23, 2022 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ENV_TYPE_STRING envType = iota
	ENV_TYPE_BOOL
)

Variables

This section is empty.

Functions

func ParseBool

func ParseBool(toParse string) (bool, error)

func VerifySnowflake

func VerifySnowflake(id string) (string, bool)

Types

type Config

type Config struct {
	Token               string
	IdType              IdType
	Ids                 []string
	ExportType          ExportType
	DownloadMedia       bool
	ExportLocation      string
	ExportHtmlThemeName string
	ExportJsonMeta      bool
	ExportTextFormat    string
	IgnoreNsfw          bool
	IgnoreSystemMsgs    bool
	UseLimit50          bool
	Filter              MsgFilter
	HeadersMask         HeadersMask
}

func Load

func Load() Config

type ExportType

type ExportType int8
const (
	EXPORT_TYPE_TEXT ExportType = iota
	EXPORT_TYPE_JSON
	EXPORT_TYPE_HTML
)

type HeadersMask

type HeadersMask struct {
	UseCanary       bool
	UserAgent       string
	Locale          string
	SuperProperties string
	DomainPrefix    string
	DiscordVersion  string
}

func (*HeadersMask) Auto

func (mask *HeadersMask) Auto()

func (*HeadersMask) EncodeSuperProps

func (mask *HeadersMask) EncodeSuperProps()

func (*HeadersMask) PullDiscordVers

func (mask *HeadersMask) PullDiscordVers(discordPath string)

type IdType

type IdType int8
const (
	ID_TYPE_USER IdType = iota
	ID_TYPE_CHANNEL
	ID_TYPE_GUILD
)

type MsgFilter

type MsgFilter struct {
	NumMax  int
	MinId   string
	MaxId   string
	MinTime int
	MaxTime int
}

Jump to

Keyboard shortcuts

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