Пример #1
0
func GetServerStatus() (ServerStatus, error) {
	var status ServerStatus
	result, _, err := apiclient.Get(apiclient.Url("/appstax/hosting/server"))
	if err == nil {
		err = json.Unmarshal(result, &status)
	}
	return status, err
}
Пример #2
0
func GetServerLog(lines int64) (string, error) {
	linesArg := strconv.FormatInt(lines, 10)
	result, _, err := apiclient.Get(apiclient.Url("/appstax/hosting/server/logs?nlines=%s", linesArg))
	return string(result), err
}