Go library to interact with APIs in all the Starr apps.
- Lidarr (view Go ref)
- Prowlarr (view Go ref)
- Radarr (view Go ref)
- Readarr (view Go ref)
- Sonarr (view Go ref)
- Custom Scripts support is also included.
- Check out the types and methods to get that data. For a fuller walkthrough, see starrcmd/README.md.
- Webhook Connect http handlers are available too.
- Check out the types and methods to setup a webhook handler. For a fuller walkthrough, see starrconnect/README.md.
Pretty much all the API methods are available. Plus Connections: Webhooks and Custom Scripts. If you have specific needs this library doesn't currently meet, but should or could, please let us know!
This library is currently in use by:
- Toolbarr (all of it)
- Unpackerr (queue only)
- Notifiarr (a lot of it)
- Checkrr
- telegram-bot (radarr)
- telegram-bot2 (sonarr)
- See Starr Command (README) and Starr Connect (README) for their examples.
- See below for simple Starr API example:
Get it:
go get golift.io/starrUse it:
import "golift.io/starr"package main
import (
"fmt"
"golift.io/starr"
"golift.io/starr/lidarr"
)
func main() {
// Get a starr.Config that can plug into any Starr app.
// starr.New(apiKey, appURL string, timeout time.Duration)
c := starr.New("abc1234ahsuyka123jh12", "http://localhost:8686", 0)
// Lets make a lidarr server with the default starr Config.
l := lidarr.New(c)
// In addition to GetSystemStatus, you have things like:
// * l.GetAlbum(albumID int)
// * l.GetQualityDefinition()
// * l.GetQualityProfiles()
// * l.GetRootFolders()
// * l.GetQueue(maxRecords int)
// * l.GetAlbum(albumUUID string)
// * l.GetArtist(artistUUID string)
status, err := l.GetSystemStatus()
if err != nil {
panic(err)
}
fmt.Println(status)
}