package torrent type TorrentInfo struct { Hash string Name string Size int64 Progress float64 DlSpeed int64 UpSpeed int64 NumSeeds int32 NumLeechs int32 State string ETA int64 Ratio float64 Category string Tags string AddedOn int64 CompletionOn int64 SavePath string ContentPath string Downloaded int64 Uploaded int64 Tracker string SeedingTime int64 AmountLeft int64 Availability float64 } type TorrentFile struct { Filename string Data []byte } type FindOptions struct { Hash string Name string Category string Tag string State string } type TorrentClient interface { Login(username string, password string) (string, error) List() ([]TorrentInfo, error) Find(opts FindOptions) ([]TorrentInfo, error) AddTorrent(file TorrentFile, savePath string) error AddMagnet(magnetURI string, savePath string) error DefaultSavePath() (string, error) }