getSiteListLoad
Description:
Method returns information about the average load on user websites within the last month.


Call example:


// correct call example
https://api.beget.de/api/stat/getSitesListLoad?
login=user&passwd=password&output_format=json



Response example:


[
    {
        "name": "sitename.de",
        "id": "299163",
        "cp": "195.257188"
    },
    {
        "name": "sitename2.de",
        "id": "299176",
        "cp": "97.168125"
    },
    {
        "name": "sitename3.de",
        "id": "307286",
        "cp": "93.905937"
    }
]



Returns website list and average load thereof (in descending order)
ID - the website id is unique within one user.


getDbListLoad
Description:
Method returns information about the average load on the user's databases for the past month.


Call example:


// correct call example
https://api.beget.de/api/stat/getDbListLoad?
login=user&passwd=password&output_format=json



Response example:


[
    {
        "name": "base_name",
        "cp": "2895.257188"
    },
    {
        "name": "base_name2",
        "cp": "1500.168125"
    },
    {
        "name": "base_name3",
        "cp": "856.905937"
    }
]



Returns list of database names and the average load thereof (in descending order)
name - the database name is unique within one user.


getSiteLoad
Description:
Method returns detailed information about the load on the given webiste (load per day and hour)




Additional parameters
site_id - идентификатор сайта;


Call example:


// for illustration purposes input_data is presented in uncoded form<
https://api.beget.de/api/stat/getSiteLoad?
login=user&passwd=password&output_format=json&
input_format=json&input_data={"site_id":296164}

// correct call example, input_data is coded with urlencode
https://api.beget.de/api/stat/getSiteLoad?
login=user&passwd=password&output_format=json&
input_format=json&input_data={%22site_id%22:296164}



Response example:


{
    "days": [
        {
            "value": "0.35",
            "date": "2014-05-04"
        },
        {
            "value": "0.47",
            "date": "2014-05-05"
        },
        {
            "value": "0.14",
            "date": "2014-05-06"
        },
        {
            "value": "0.09",
            "date": "2014-05-07"
        }
        ...
    ],
    "hours": [
        {
            "value": "0.02",
            "date": "2014-06-02 18:00:00"
        },
        {
            "value": "0.00",
            "date": "2014-06-02 19:00:00"
        },
        {
            "value": "0.00",
            "date": "2014-06-02 20:00:00"
        },
        {
            "value": "0.00",
            "date": "2014-06-02 21:00:00"
        }
        ...
    ]
}



Returns load list for the past 30 days (per day)
As well as load list for the past 24 hours (per hour)


getDbLoad
Description:
Method returns detailed information about load on the given MySQL database.




Additional parameters
db_name - database name;


Call example:


// for illustration purposes input_data is presented in uncoded form<
https://api.beget.de/api/stat/getDbLoad?
login=user&passwd=password&output_format=json&
input_format=json&input_data={"db_name":"login_dbname"}

// correct call example, input_data is coded with urlencode
https://api.beget.de/api/stat/getDbLoad?
login=user&passwd=password&output_format=json&
input_format=json&input_data=%7B%22db_name%22%3A%22login_dbname%22%7D



Response example:


{
    "hours": [
        {
            "cpu_time": "0",
            "date": "2014-06-02 20:00:00"
        },
        {
            "cpu_time": "0",
            "date": "2014-06-02 21:00:00"
        },
        {
            "cpu_time": "0",
            "date": "2014-06-02 22:00:00"
        },
        {
            "cpu_time": "0",
            "date": "2014-06-03 15:00:00"
        },
        {
            "cpu_time": "0",
            "date": "2014-06-03 16:00:00"
        },
        {
            "cpu_time": "0",
            "date": "2014-06-03 17:00:00"
        },
        {
            "cpu_time": "0",
            "date": "2014-06-03 18:00:00"
        },
        {
            "cpu_time": "0",
            "date": "2014-06-03 19:00:00"
        }
        ...
    ],
    "days": [
        {
            "cpu_time": "0",
            "date": "2014-05-04"
        },
        {
            "cpu_time": "0",
            "date": "2014-05-13"
        },
        {
            "cpu_time": "0",
            "date": "2014-05-20"
        },
        {
            "cpu_time": "0",
            "date": "2014-05-21"
        },
        {
            "cpu_time": "31",
            "date": "2014-05-22"
        },
        {
            "cpu_time": "1",
            "date": "2014-05-23"
        },
        {
            "cpu_time": "0",
            "date": "2014-05-24"
        },
        {
            "cpu_time": "0",
            "date": "2014-05-25"
        },
        {
            "cpu_time": "0",
            "date": "2014-06-03"
        }
        ...
    ],
    "size_days": [
        {
            "date": "2014-05-04",
            "size": "229512"
        },
        {
            "date": "2014-05-05",
            "size": "229512"
        },
        {
            "date": "2014-05-06",
            "size": "229512"
        },
        {
            "date": "2014-05-07",
            "size": "229512"
        },
        {
            "date": "2014-05-08",
            "size": "229512"
        },
        {
            "date": "2014-05-09",
            "size": "229512"
        },
        {
            "date": "2014-05-10",
            "size": "229512"
        },
        {
            "date": "2014-05-11",
            "size": "229512"
        },
        {
            "date": "2014-05-23",
            "size": "229512"
        },
        {
            "date": "2014-05-24",
            "size": "229512"
        },
        {
            "date": "2014-05-25",
            "size": "229512"
        },
        {
            "date": "2014-05-26",
            "size": "229512"
        }
        ...
    ],
    "total_day": {
        "commit_transactions": "525",
        "rollback_transactions": "0",
        "cpu_time": "0",
        "connected_time": "40",
        "lost_connections": "0",
        "table_rows_read": "25366",
        "denied_connections": "0",
        "update_commands": "1714",
        "total_connections": "515",
        "access_denied": "0",
        "select_commands": "5479",
        "empty_queries": "1107",
        "rows_updated": "152",
        "concurrent_connections": "0",
        "other_commands": "1545",
        "rows_fetched": "6601",
        "busy_time": "18"
    },
    "total_month": {
        "commit_transactions": "14729",
        "rollback_transactions": "0",
        "cpu_time": "33",
        "connected_time": "3176",
        "lost_connections": "0",
        "table_rows_read": "710595",
        "denied_connections": "0",
        "update_commands": "58046",
        "total_connections": "18285",
        "access_denied": "0",
        "select_commands": "167591",
        "empty_queries": "32697",
        "rows_updated": "19127",
        "concurrent_connections": "0",
        "other_commands": "54855",
        "rows_fetched": "191127",
        "busy_time": "1621"
    }
}



Returns load list for the past 30 days (per date)
Load list for the past 24 hours (per hour)
List with database size (in bytes) for the past 30 days (per date)
total_day, total_month - total load metrics for day and month respectively