Versions in this module Expand all Collapse all v0 v0.1.1 Jul 19, 2020 Changes in this version + const KILL + const OFF + const ON + const RESTART + type Allocation struct + Alias string + IP string + Port int + Primary bool + type ApplicationCredentials Credentials + func NewApplication(url, apiToken string) *ApplicationCredentials + func (c *ApplicationCredentials) CreateDatabase(sid int, db *Database) (err error) + func (c *ApplicationCredentials) CreateLocation(shortName, longName string) (loc *Location, err error) + func (c *ApplicationCredentials) CreateServer(sv *ApplicationServer) (err error) + func (c *ApplicationCredentials) CreateUser(u *User, password ...string) (err error) + func (c *ApplicationCredentials) DeleteDatabase(sid int, dbid int) (err error) + func (c *ApplicationCredentials) DeleteLocation(lid int) (err error) + func (c *ApplicationCredentials) DeleteServer(sid int) (err error) + func (c *ApplicationCredentials) DeleteUser(id int) (err error) + func (c *ApplicationCredentials) ForceDeleteServer(sid int) (err error) + func (c *ApplicationCredentials) GetDatabase(sid int, dbid int) (db *Database, err error) + func (c *ApplicationCredentials) GetDatabases(sid int) (dbs []*Database, err error) + func (c *ApplicationCredentials) GetEgg(nestID int, eggID int) (egg *Egg, err error) + func (c *ApplicationCredentials) GetEggs(nestID int) (eggs []*Egg, err error) + func (c *ApplicationCredentials) GetLocation(id int) (loc *Location, err error) + func (c *ApplicationCredentials) GetLocations() (locations []*Location, err error) + func (c *ApplicationCredentials) GetNest(id int) (nest *Nest, err error) + func (c *ApplicationCredentials) GetNests() (nests []*Nest, err error) + func (c *ApplicationCredentials) GetServer(internalID int) (sv *ApplicationServer, err error) + func (c *ApplicationCredentials) GetServerExternal(externalID string) (sv *ApplicationServer, err error) + func (c *ApplicationCredentials) GetServers() (svs []*ApplicationServer, err error) + func (c *ApplicationCredentials) GetUser(id int) (user *User, err error) + func (c *ApplicationCredentials) GetUserExternal(eid string) (user *User, err error) + func (c *ApplicationCredentials) GetUsers() (users []*User, err error) + func (c *ApplicationCredentials) RebuildServer(sid int) (err error) + func (c *ApplicationCredentials) ReinstallServer(sid int) (err error) + func (c *ApplicationCredentials) ResetDatabasePassword(sid int, dbid int) (err error) + func (c *ApplicationCredentials) SuspendServer(sid int) (err error) + func (c *ApplicationCredentials) UnsuspendServer(sid int) (err error) + func (c *ApplicationCredentials) UpdateBuild(sv *ApplicationServer, addAlloc []int, removeAlloc []int) (err error) + func (c *ApplicationCredentials) UpdateDetails(sv *ApplicationServer) (err error) + func (c *ApplicationCredentials) UpdateLocationName(loc *Location) (err error) + func (c *ApplicationCredentials) UpdateStartup(sv *ApplicationServer) (err error) + func (c *ApplicationCredentials) UpdateUser(u *User, password ...string) (err error) + type ApplicationServer struct + Allocation int + AllocationsDetails []Allocation + Container Container + Created time.Time + Description string + Egg int + ExternalID string + ID int + Limits Limits + Name string + Nest int + Node int + Pack int + Suspended bool + UUID string + Updated time.Time + User int + func (s *ApplicationServer) String() string + type CPU struct + Cores []float32 + Current float32 + Limit uint64 + type ClientCredentials Credentials + func NewClient(url, clientToken string) *ClientCredentials + func (c *ClientCredentials) ExecuteCommand(id string, cmd string) (err error) + func (c *ClientCredentials) GetServer(id string) (sv *ClientServer, err error) + func (c *ClientCredentials) GetServerStatus(id string) (ss *ServerStatus, err error) + func (c *ClientCredentials) GetServers() (svs []*ClientServer, err error) + func (c *ClientCredentials) SetPowerState(id string, state string) (err error) + type ClientServer struct + AllocationDetails []Allocation + Description string + ID string + IsOwner bool + Limits Limits + Name string + func (s *ClientServer) String() string + type Container struct + Environment map[string]string + Image string + Installed bool + StartupCommand string + type Credentials struct + Token string + URL string + type Database struct + CreatedAt time.Time + Database string + Host int + ID int + Remote string + Server int + UpdatedAt time.Time + Username string + type Disk struct + Limit uint64 + Used uint64 + type Egg struct + Author string + Config EggConfig + CreatedAt time.Time + Description string + DockerImage string + ID int + Nest int + Script EggScript + Startup string + UUID string + UpdatedAt time.Time + type EggConfig struct + CustomConfig []string + Extends string + Startup EggStartup + Stop string + type EggScript struct + Container string + Entry string + Extends string + Install string + Privileged bool + type EggStartup struct + Done string + UserInteraction []string + type Limits struct + Allocations int + CPU int + Databases int + Disk int + IO int + Memory int + Swap int + type Location struct + CreatedAt time.Time + ID int + LongName string + ShortName string + UpdatedAt time.Time + type Memory struct + Limit uint64 + Used uint64 + type Meta struct + Pagination struct{ ... } + type Nest struct + Author string + CreatedAt time.Time + Description string + ID int + Name string + UUID string + UpdatedAt time.Time + type Players struct + Current uint64 + Limit uint64 + type ServerStatus struct + CPU CPU + Disk Disk + Memory Memory + Players Players + State string + type User struct + CreatedAt time.Time + Email string + ExternalID string + FirstName string + ID int + Language string + LastName string + RootAdmin bool + TwoFactorAuthentication bool + UUID string + UpdatedAt time.Time + Username string