Skip to main content
GET
/
compute
/
script
/
{id}
/
statistics
Get Edge Script Statistics
curl --request GET \
  --url https://api.bunny.net/compute/script/{id}/statistics \
  --header 'AccessKey: <api-key>'
{
  "TotalRequestsServed": 123,
  "TotalCpuUsed": 123,
  "TotalMonthlyCost": 123,
  "AverageCpuTimePerExecution": 123,
  "RequestsServedChart": {},
  "AverageCpuTimeChart": {},
  "TotalCpuTimeChart": {}
}

Authorizations

AccessKey
string
header
required

API Access Key authorization header

Path Parameters

id
integer<int64>
required

The ID of the Edge Script for which the statistics will be returned

Query Parameters

dateFrom
string<date-time>

(Optional) The start date of the statistics. If no value is passed, the last 30 days will be returned

dateTo
string<date-time>

(Optional) The end date of the statistics. If no value is passed, the last 30 days will be returned

loadLatest
boolean
default:false

(Optional) Load most recent data as soon as it's available

hourly
boolean
default:false

(Optional) If true, the statistics data will be returned in hourly groupping.

Response

Returns the statistics for the Edge Script with the given ID

TotalRequestsServed
integer<int64>
required
TotalCpuUsed
number<double>
required
TotalMonthlyCost
number<decimal>
required
AverageCpuTimePerExecution
number<double>
required
RequestsServedChart
object
AverageCpuTimeChart
object
TotalCpuTimeChart
object