---
title: "Get Edge Script Statistics"
method: GET
path: "/compute/script/{id}/statistics"
tags: ["Edge Script"]
---

# Get Edge Script Statistics

`GET /compute/script/{id}/statistics`

## Request

- Base URL: `https://api.bunny.net`
- URL: `https://api.bunny.net/compute/script/{id}/statistics`
- Auth: one of:
  - API key in header `AccessKey`
  - API key in header `Authorization`
- TypeScript: <https://skmtc.dev/bunny/apis/bunny-net-compute-api/docs/compute/script/:id/statistics/get.ts> (a function with typed inputs; its response is checked against the schema)

## Path parameters

- `id` integer, required

## Query parameters

- `dateFrom` string, date-time, nullable
- `dateTo` string, date-time, nullable
- `loadLatest` boolean
- `hourly` boolean

## Response `200`

Returns the statistics for the Edge Script with the given ID

- EdgeScriptStatisticsModel
  - `TotalRequestsServed` integer
  - `TotalCpuUsed` number, double
  - `TotalMonthlyCost` number
  - `AverageCpuTimePerExecution` number, double
  - `RequestsServedChart` object, nullable
  - `AverageCpuTimeChart` object, nullable
  - `TotalCpuTimeChart` object, nullable

## Other responses

- `401`: The request authorization failed
- `404`: The Edge Script with the requested ID does not exist
- `500`: Internal Server Error

## Changes

- **2026-08-07** `9b732b27538a`: 2 info
  - the security scope `ScopedApiKey` was added to the endpoint's security scheme `AccessKey`
  - the security scope `ScopedApiKey` was added to the endpoint's security scheme `bearer`

[Operation history](https://skmtc.dev/bunny/apis/bunny-net-compute-api/changes/compute/script/:id/statistics/get.md)

---

[API](https://skmtc.dev/bunny/apis/bunny-net-compute-api.md) - [All operations](https://skmtc.dev/bunny/apis/bunny-net-compute-api/llms.txt) - [OpenAPI document](https://skmtc.dev/bunny/apis/bunny-net-compute-api/revisions/9b167ce43695?raw)
