v1

latestOpenAPI 3.0.3Apache-2.02026-07-179814.8 KB
Debug

Get database statistics

Retrieve database storage statistics and estimated logical table sizes. Only available when DEBUG environment variable is set to true.

get/api/stats

Response

Database statistics

row_countinteger

Total number of rows in the database

storage_usage_kbstring

Storage usage in kilobytes

storage_usage_mbstring

Storage usage in megabytes

Example response

{
  "row_count": 10000,
  "storage_usage_kb": "1024.50",
  "storage_usage_mb": "1.00",
  "memory_usage": {
    "time": "1700000000000",
    "total": 16000000000,
    "available": 8000000000,
    "used": 8000000000,
    "usedPercent": 50,
    "free": 8000000000
  },
  "table_sizes": [
    {
      "table_name": "cpu_usage",
      "row_count": 600,
      "size_mb": "0.50",
      "size_kb": "512.00"
    }
  ]
}