How To Get Dealer Stats
In this section you will learn how to make an request to our Dealer Stats API with our /data
endpoint.
- Parameters Used:
{{startDate}}
- Start date of data. (MM/dd/yyy){{endDate}}
- End date of data. (MM/dd/yyy){{dealerUUIDs}}
- List of DealerUUIDs to fetch data for, comma separated.{{columns}}
- List of columns/metrics to fetch, comma separated.{{groupbys}}
- List of groupby values to use, comma separated. Use with SUM columns which have a name that starts with sum_. Leave blank if you are not sure.{{orderbys}}
- List of orderbys to use, comma separated.{{columnFilters}}
- List of predefined data filters to use, comma separated.{{departmentFilter}}
- List of department categories to filter, comma separated.{{orderTypeFilter}}
- List of order type categories to filter, comma separated.{{brandNameFilter}}
- List of brand categories to filter, comma separated.{{cpValueFilter}}
- List of customer pay range categories to filter, comma separated.{{payTypeFilter}}
- List of pay type categories to filter, comma separated.{{apptCreateCategory}}
- This is used to filter appointments data by their created source, comma separated.{{userFilter}}
- This is used to filter out predefined dealerAssocaites/users that shouldn't show up in the data.{{basic_auth_token}}
- Authorization: Basic "generate using username password".
Scope: The service subscriber needs to have the following scope for the department in the request -
report.api.query
Endpoint
curl --request POST 'https://api.mykaarma.com/reporting/v2/data' \
--header 'Authorization: Basic {{basic_auth_token}}' \
--form 'startDate=""' \
--form 'endDate=""' \
--form 'dealerUUIDs=""' \
--form 'columns=""' \
--form 'groupbys=""' \
--form 'columnFilters=""' \
--form 'departmentFilter=""' \
--form 'orderTypeFilter=""' \
--form 'brandNameFilter=""' \
--form 'payTypeFilter=""' \
--form 'cpValueFilter=""' \
--form 'userFilter=""' \
--form 'apptCreateCategory=""'
- Response
{
"data": [
{
"column1": {},
"column2": {},
"column3": {}
}
],
"errorCode": "string",
"errorDescription": "string"
}