Aggregate log counts by level and source for a time window.
GET
/logs/stats
const url = 'https://api.siteqwality.com/logs/stats';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://api.siteqwality.com/logs/stats \ --header 'Authorization: Bearer <token>'Authorizations
Section titled “Authorizations ”Responses
Section titled “ Responses ”Log statistics
Media type application/json
object
total_count
required
integer format: int64
by_level
required
Array<object>
object
level
required
string
count
required
integer format: int64
by_source
required
Array<object>
object
source
required
string
count
required
integer format: int64
Example generated
{ "total_count": 1, "by_level": [ { "level": "example", "count": 1 } ], "by_source": [ { "source": "example", "count": 1 } ]}Missing or invalid authentication
Internal server error