Admin Usage
Get usage statistics by user
Changed onReturns paginated user usage statistics with search, sorting, and filtering capabilities. Includes activity status. Dates are optional - if not provided, shows all usage.
get/usage/users
Request
- The document declares no server URL.
- Auth: none declared
Query parameters
startDatestring
Example:2024-01-01T00:00:00.000Z
Start date in ISO format
endDatestring
Example:2024-01-31T23:59:59.999Z
End date in ISO format
limitnumber
Example:50
Number of users per page (1-1000). Defaults to 50.
offsetnumber
Number of users to skip for pagination. Defaults to 0.
searchstring
Example:john.doe
Search term to filter users by name or email
sortBy'credits' | 'requests' | 'lastActivity' | 'userName'
Field to sort users by. Defaults to credits.
sortOrder'asc' | 'desc'
Sort order (ascending or descending). Defaults to desc.
Response
User usage statistics retrieved successfully. Includes pagination metadata.
Example response
{
"pagination": {
"limit": 50,
"total": 150
}
}Changes
- info
added the non-success response with the status
- info