Get bucket statistics
A time series over the bucket, one row per hour, day or month (UTC) between start_time and end_time, every period present: size_bytes is the bytes stored at the end of each period (a level), uploaded_bytes and upload_count are what that period's uploads brought (a flow). Downloads and bandwidth are not recorded yet and read 0. Needs the bucket admin role.
Authorization
OAuth2 upl:bucket:analyticsOAuth 2.0 authorization
In: header
Scope: upl:bucket:analytics
Header Parameters
Define the version of the Connect protocol
Define the timeout, in ms
Request Body
application/json
Start of the window. The series begins at the period (hour, day or month, UTC) this falls in. Unset: twelve months before end_time. timestamp.lt_now = true
date-timeEnd of the window, inclusive; must be after start_time. The series ends at the period this falls in. Unset: now. timestamp.lt_now = true
date-timeWidth of one period. Unset: monthly. A window wider than 1000 periods at the chosen granularity is refused with InvalidArgument. enum.defined_only = true
"STATISTICS_GRANULARITY_UNSPECIFIED" | "STATISTICS_GRANULARITY_HOURLY" | "STATISTICS_GRANULARITY_DAILY" | "STATISTICS_GRANULARITY_MONTHLY"Response Body
application/json
application/json
curl -X POST "https://uploads-api.xeonr.io/uplim.api.v1.BucketsService/GetBucketStatistics" \ -H "Connect-Protocol-Version: 1" \ -H "Connect-Timeout-Ms: 1000" \ -H "Content-Type: application/json" \ -d '{}'{
"statistics": [
{
"sizeBytes": "string",
"uploadCount": "string",
"timestamp": "2023-01-15T01:30:15.01Z",
"downloadCount": "string",
"bandwidthBytes": "string",
"uploadedBytes": "string"
}
]
}{
"code": "not_found",
"message": "string",
"details": [
{
"type": "string",
"value": "string",
"debug": {}
}
]
}