Core
API v2.x
2

getLastStats #

Deprecated since 2.16.0

Returns the most recent statistics snapshot.


Query Syntax #

HTTP #

Copied to clipboard!
URL: http://kuzzle:7512/_getLastStats
Method: GET

Other protocols #

Copied to clipboard!
{
  "controller": "server",
  "action": "getLastStats"
}

Response #

Returns the last statistic snapshot, with the following properties:

  • completedRequests: completed requests, per network protocol
  • connections: number of active connections, per network protocol
  • failedRequests: failed requests, per network protocol
  • ongoingRequests: requests underway, per network protocol
  • timestamp: snapshot timestamp, in Epoch-millis format
Copied to clipboard!
{
  "status": 200,
  "error": null,
  "action": "getLastStats",
  "controller": "server",
  "requestId": "<unique request identifier>",
  "result": {
    "completedRequests": {
      "websocket": 148,
      "http": 24,
      "mqtt": 78
    },
    "failedRequests": {
      "websocket": 3
    },
    "ongoingRequests": {
      "mqtt": 8,
      "http": 2
    }
    "connections": {
      "websocket": 13
    },
    "timestamp": 1453110641308
  }
}