ZapAPI Docs
Get StartedConceptsAI GatewayGuidesPayment GatewaySDKAPI ReferenceResources
ApiUsers

Get user statistics (Admin/Moderator)

GET
/api/v1/users/statistics

Retrieves user statistics including total, active, inactive, and today registered counts. Requires Admin or Moderator role.

Authorization

bearer

Header Parameters

X-API-Version?string

API version for header-based versioning

Default"1"
Value in"1""2"

Response Body

User statistics retrieved successfully.

response?unknownapplication/json
Example Request
curl -X GET 'http://localhost:3001/api/v1/users/statistics'
Example Response
{  "status": "success",  "statusCode": 200,  "message": "Statistics fetched successfully",  "data": {    "total": 125,    "active": 98,    "inactive": 27,    "pending": 0,    "todayRegistered": 5  },  "meta": {    "cached": false,    "timestamp": "2026-01-31T10:00:00.000Z"  },  "timestamp": "2026-01-31T10:00:00.015Z",  "path": "/api/v1/users/statistics"}