GymMaster: KPI, Reporting and Dashboard API V2 (v1560)

Download OpenAPI specification:

KPI

KPI summary statistics. Equivalent to data in Report & Till -> Key Performance Indicators

KPI Categories List

All the available categories that are used to group together KPI fields

Authorizations:
api_key_header

Responses

Response samples

Content type
application/json
{
  • "result": [
    ],
  • "error": null
}

KPI - Filter By Category

Uses an array of categories to grab values. These values may be grouped by category or left in one large array.

Authorizations:
api_key_header
Request Body schema: application/json

api_request

required
object (DateFilter)
selected_categories
required
Array of strings (Selected Categories)
grouped_categories
boolean (Grouped Categories)
Default: true
Company Id (integer) or Company Id (null) (Company Id)
Default: null

Responses

Request samples

Content type
application/json
{
  • "date": {
    },
  • "selected_categories": [
    ],
  • "grouped_categories": true,
  • "company_id": null
}

Response samples

Content type
application/json
Example
{
  • "result": {
    },
  • "error": [ ]
}

KPI Fields List

All the available Categories that are used to group together KPI fields.

Authorizations:
api_key_header

Responses

Response samples

Content type
application/json
{
  • "result": [
    ],
  • "error": null
}

KPI - Filter By Fields

Get individual kpi fields for a given date. These fields may return single set of values, as is found in the Members Statistics group, or return an array of values - (Sales Made Group)

Authorizations:
api_key_header
Request Body schema: application/json

filter

required
object (DateFilter)
selected_fields
required
Array of strings (Selected Fields)
Company Id (integer) or Company Id (null) (Company Id)
Default: null

Responses

Request samples

Content type
application/json
{
  • "date": {
    },
  • "selected_fields": [
    ],
  • "company_id": null
}

Response samples

Content type
application/json
{
  • "result": {
    },
  • "error": [ ]
}

Report

API equivalents to Report & Till -> Standard Report page

Available Reports

List of all the available report names and their ID's

Authorizations:
api_key_header
query Parameters
predefined_only
boolean

Exclude copies of reports generated by the user. Defaults to true. Query parameter value if supplied will be coerced to a boolean

Responses

Response samples

Content type
application/json
{
  • "result": [
    ],
  • "error": null
}

Run Report

Generate the same data as if running a report through Report and Till -> Standard Report

Authorizations:
api_key_header
Request Body schema: application/json

api_request

start_date
required
string (Start Date)

ISO date string

end_date
required
string (End Date)

ISO date string

report_id
required
integer (Report Id)
Company Id (integer) or Company Id (null) (Company Id)
Default: null
displaymode
string (Displaymode)
Default: "CURRENT"
Enum: "CURRENT" "ALL" "HIDDEN"

Affects some member-based reports. Controls whether "casual"/"hidden" memberships are included in the returned data

required_columns
Array of strings (Required Columns)

List of field names that should be added to the report

Responses

Request samples

Content type
application/json
{
  • "start_date": "2024-06-01",
  • "end_date": "2024-07-01",
  • "report_id": 0,
  • "company_id": null,
  • "displaymode": "CURRENT",
  • "required_columns": [
    ]
}

Response samples

Content type
application/json
{
  • "result": [
    ],
  • "error": null,
  • "cached_result": false
}

Dashboard

Endpoints for showing data used on the home page dashboard

Dashboard List

List of all dashboard endpoints

Authorizations:
api_key_header

Responses

Response samples

Content type
application/json
{
  • "result": [
    ],
  • "error": null
}

Run Dashboard Endpoint

Takes a single dashboard endpoint name. The dashboard fields are calculated based off the current date. There is no passing in of dates for this endpoint.

Authorizations:
api_key_header
query Parameters
endpoint
string

An endpoint returned by /dashboard/list

string or null

ISO date string to override the default date the dashboard widget is run as of

string or null
    ISO date string to override the default date the dashboard widget is run as of.
    Note that if both a start and end date is provided, this will completely override any logic the widget uses to determine what dates to fetch data from.
    

Responses

Response samples

Content type
application/json
{
  • "result": { },
  • "error": "string"
}