View upload metrics
GET https://{{host}}/datastream-config-api/v2/log/streams/metrics?start={{start}}&end={{end}}
Returns aggregated metrics for log file uploads, including success or failure upload counts, upload latency, and the volume of data uploaded in the stream. Set the start
and end
dates to get metrics from a specific time range, and aggregationInterval
to group data by time intervals.
Body
PARAM
Key | Datatype | Required | Description |
start
|
string | (Required) Specifies the beginning of the time range for the metrics in the ISO 8601 format. Set this no more than seven days before the `end` date. | |
end
|
string | (Required) Specifies the end of the time range for the metrics in the ISO 8601 format. Set this no more than seven days after the `start` date. | |
streamId
|
string | (Optional) Uniquely identifies the stream. Set the `streamId` to get metrics for a specific stream, or `groupId` for all streams belonging to that group. If both are omitted, this operation returns metrics for all streams that belong to your contract. | |
groupId
|
string | (Optional) Set the `groupId` to get metrics for all streams belonging to that group, or `streamId` for a specific stream. If both are omitted, this operation returns metrics for all streams that belong to your contract. | |
aggregationInterval
|
string | (Optional) __Enum__ Specifies the time interval for metrics aggregation, either 5 minutes, an hour, or 24 hours. If omitted, this operation returns the metrics grouped in hourly intervals. | |
includeDetails
|
string | (Optional) Set to `true` or omit to get detailed metrics. If set to `false`, this operation returns only the `timestamp`, `streamId`, `successAttemptResponseCount`, and `failAttemptResponseCount` values. |
HEADERS
Key | Datatype | Required | Description |
Accept
|
string |
RESPONSES
status OK
{
"fileUploadMetrics": [
{
"aggregationTime": "2022-03-14T22:00:00",
"failedUploadAttempts": [
{
"errorCode": "400",
"errorCount": 100
},
{
"errorCode": "500",
"errorCount": 30
}
],
"latencyBuckets": [
{
"latencyInSeconds": 0,
"recordsCount": 500
},
{
"latencyInSeconds": 30,
"recordsCount": 5000
},
{
"latencyInSeconds": 60,
"recordsCount": 2000
},
{
"latencyInSeconds": 120,
"recordsCount": 500
},
{
"latencyInSeconds": 300,
"recordsCount": 1000
}
],
"recordsAttemptedUpload": 10000,
"recordsFailedUpload": 1000,
"streamId": 30000,
"successUploadsCount": 1000,
"uploadBuckets": [
{
"recordsCount": 100,
"uploadTimeInMilliseconds": 0
},
{
"recordsCount": 3000,
"uploadTimeInMilliseconds": 30
},
{
"recordsCount": 3000,
"uploadTimeInMilliseconds": 60
},
{
"recordsCount": 1000,
"uploadTimeInMilliseconds": 120
},
{
"recordsCount": 0,
"uploadTimeInMilliseconds": 300
},
{
"recordsCount": 1000,
"uploadTimeInMilliseconds": 600
},
{
"recordsCount": 900,
"uploadTimeInMilliseconds": 1800
}
],
"uploadedBytes": 150000
},
{
"aggregationTime": "2022-03-14T22:00:00",
"failedUploadAttempts": [
{
"errorCode": "404",
"errorCount": 59
},
{
"errorCode": "503",
"errorCount": 3
}
],
"latencyBuckets": [
{
"latencyInSeconds": 0,
"recordsCount": 0
},
{
"latencyInSeconds": 30,
"recordsCount": 2000
},
{
"latencyInSeconds": 60,
"recordsCount": 1000
},
{
"latencyInSeconds": 120,
"recordsCount": 1000
},
{
"latencyInSeconds": 300,
"recordsCount": 1000
}
],
"recordsAttemptedUpload": 7000,
"recordsFailedUpload": 2000,
"streamId": 40000,
"successUploadsCount": 800,
"uploadBuckets": [
{
"recordsCount": 1000,
"uploadTimeInMilliseconds": 0
},
{
"recordsCount": 1000,
"uploadTimeInMilliseconds": 30
},
{
"recordsCount": 1000,
"uploadTimeInMilliseconds": 60
},
{
"recordsCount": 1000,
"uploadTimeInMilliseconds": 120
},
{
"recordsCount": 0,
"uploadTimeInMilliseconds": 300
},
{
"recordsCount": 500,
"uploadTimeInMilliseconds": 600
},
{
"recordsCount": 500,
"uploadTimeInMilliseconds": 1800
}
],
"uploadedBytes": 7000
}
],
"totalErrorCount": 192,
"totalSuccessCount": 1800,
"totalUploadCount": 1992
} |
ENDPOINTS