This documentation describes how to fetch your data from CC Athletics database through REST API endpoints.
In short, the steps are:
1. Get an API key from your Cloud dashboard – and insert it in the header when using the following endpoints:
2. Use getTeams endpoint (see below) to retrieve a list of all teams
3. Use getAthletes endpoint (see below) to retrieve a list of all athletes
Authentication
API Key
- Each API request requires a valid API key
- Include the API key in the
X-API-Key
header - API keys can be generated and managed in your ForceMate Cloud dashboard Account -> API Keys
Example Authentication
curl https://us-central1-forcemate-desktop.cloudfunctions.net/get_athletes \
-H "X-API-Key: fm_your_api_key_here"
Endpoints
Get Teams
- Endpoint:
GET https://us-central1-forcemate-desktop.cloudfunctions.net/get_teams
- Description: Retrieve all teams for your organization
- Response Format:
{
"teams": [
{
"id": "team_123",
"name": "Team Alpha",
"creation_date": 1623456789
}
]
}
Get Athletes
- Endpoint:
GET
https://us-central1-forcemate-desktop.cloudfunctions.net/get_athletes - Description: Retrieve athletes including all recordings (optionally filtered by team)
- Query Parameters:
team_id
(optional): Filter athletes by specific teammin_birth_year
(integer, optional)- Filter athletes born on or after this year
- Example:
min_birth_year=1990
max_birth_year
(integer, optional)- Filter athletes born on or before this year
- Example:
max_birth_year=2005
tests_date_from
(string, optional)- Filter tests recorded on or after this date
- Format: YYYY-MM-DD
- Example:
tests_date_from=2024-01-01
tests_date_to
(string, optional)- Filter tests recorded on or before this date
- Format: YYYY-MM-DD
- Example:
tests_date_to=2024-12-31
analysis_type
(string, optional)- Filter by type of analysis
- Valid values: “jump”, “isometric”
- Example:
analysis_type=jump
isometric_exercise_names
(string, optional)- Comma-separated list of isometric exercise names to include
- Only applies when analysis_type is “isometric”
- Example:
isometric_exercise_names=Mid-thigh pull,Squat
- Response Format:
{
"athletes": [
{
"id": "athlete_456",
"name": "John Doe",
"team_id": "team_123",
"player_info": {},
"recordings": []
}
],
"total": 1
}
Error Handling
401 Unauthorized
: Invalid or missing API key500 Internal Server Error
: Unexpected server-side issue
Rate Limits
- Rate limits apply to prevent abuse
- Contact support for specific rate limit details
Support
- For help: info@ccathletics.dk
Best Practices
- Keep your API key confidential
- Use HTTPS for all API requests
- Implement proper error handling in your client