Get company members report
curl --request GET \
--url https://api.lighton.ai/api/v2/reporting/users/ \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.lighton.ai/api/v2/reporting/users/"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.lighton.ai/api/v2/reporting/users/', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"reporting": [
{
"company": {
"id": 123,
"name": "<string>"
},
"total_historical_members": 123,
"current_active_members": 123
}
],
"metadata": {
"total_historical_members": {
"description": "<string>",
"unit": "<string>"
},
"current_active_members": {
"description": "<string>",
"unit": "<string>"
}
}
}Reporting
Get company members report
This endpoint allows you to retrieve a company’s members report.
The start date is required, but the end date is by default today.
It is restricted to admin and company admin users.
Admin users can optionally filter by company.
GET
/
api
/
v2
/
reporting
/
users
/
Get company members report
curl --request GET \
--url https://api.lighton.ai/api/v2/reporting/users/ \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.lighton.ai/api/v2/reporting/users/"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.lighton.ai/api/v2/reporting/users/', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"reporting": [
{
"company": {
"id": 123,
"name": "<string>"
},
"total_historical_members": 123,
"current_active_members": 123
}
],
"metadata": {
"total_historical_members": {
"description": "<string>",
"unit": "<string>"
},
"current_active_members": {
"description": "<string>",
"unit": "<string>"
}
}
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Query Parameters
The unique identifier of the company (for admin users only).
The end date for the report (defaults to today).
The start date for the report.