> Markdown versions of all pages of this connector library are available by appending `.md` to the page URL. For the full index of connectors, see [llms.txt](https://connectors.appmixer.com/llms.txt).

# appmixer.strava.core.GetAthleteStats

- Component: `appmixer.strava.core.GetAthleteStats`
- Kind: Action
- Version: 1.0.0
- Visibility: Public
- Connector: [appmixer.strava 1.1.4](https://connectors.appmixer.com/connector/appmixer.strava/1.1.4.md)
- Component page: <https://connectors.appmixer.com/connector/appmixer.strava/1.1.4/component/appmixer.strava.core.GetAthleteStats>

Retrieve aggregated performance statistics for a given athlete.

## Input ports

### Port `in`

| Field | Type | Description |
| --- | --- | --- |
| Athlete ID (`athleteId`) | text | The ID of the athlete whose stats are being requested. |

## Output ports

### Port `out`

| Field | Type | Description |
| --- | --- | --- |
| Recent Run Totals (`recent_run_totals`) | string | - |
| All Run Totals (`all_run_totals`) | string | - |
| Recent Swim Totals (`recent_swim_totals`) | string | - |
| Biggest Ride Distance (`biggest_ride_distance`) | number | - |
| Ytd Swim Totals (`ytd_swim_totals`) | string | - |
| All Swim Totals (`all_swim_totals`) | string | - |
| Recent Ride Totals (`recent_ride_totals`) | object | - |
| Biggest Climb Elevation Gain (`biggest_climb_elevation_gain`) | number | - |
| Ytd Ride Totals (`ytd_ride_totals`) | string | - |
| All Ride Totals (`all_ride_totals`) | string | - |
| Ytd Run Totals (`ytd_run_totals`) | string | - |

## Full metadata (component.json)

```json
{
  "name": "appmixer.strava.core.GetAthleteStats",
  "author": "Appmixer <info@appmixer.com>",
  "description": "Retrieve aggregated performance statistics for a given athlete.",
  "version": "1.0.0",
  "private": false,
  "auth": {
    "service": "appmixer:strava"
  },
  "quota": {
    "manager": "appmixer:strava",
    "resources": "requests"
  },
  "inPorts": [
    {
      "name": "in",
      "schema": {
        "type": "object",
        "properties": {
          "athleteId": {
            "type": "string"
          }
        },
        "required": [
          "athleteId"
        ]
      },
      "inspector": {
        "inputs": {
          "athleteId": {
            "type": "text",
            "tooltip": "The ID of the athlete whose stats are being requested.",
            "label": "Athlete ID",
            "index": 0
          }
        }
      }
    }
  ],
  "outPorts": [
    {
      "name": "out",
      "options": [
        {
          "label": "Recent Run Totals",
          "value": "recent_run_totals",
          "schema": {
            "type": "string",
            "example": "{\"count\":5,\"distance\":32500.0,\"moving_time\":10800,\"elapsed_time\":11200,\"elevation_gain\":450.0,\"achievement_count\":3}"
          }
        },
        {
          "label": "All Run Totals",
          "value": "all_run_totals",
          "schema": {
            "type": "string",
            "example": "{\"count\":120,\"distance\":985000.0,\"moving_time\":320000,\"elapsed_time\":345000,\"elevation_gain\":12500.0}"
          }
        },
        {
          "label": "Recent Swim Totals",
          "value": "recent_swim_totals",
          "schema": {
            "type": "string",
            "example": "{\"count\":2,\"distance\":3000.0,\"moving_time\":3600,\"elapsed_time\":3800,\"elevation_gain\":0.0,\"achievement_count\":0}"
          }
        },
        {
          "label": "Biggest Ride Distance",
          "value": "biggest_ride_distance",
          "schema": {
            "type": "number",
            "example": 128450
          }
        },
        {
          "label": "Ytd Swim Totals",
          "value": "ytd_swim_totals",
          "schema": {
            "type": "string",
            "example": "{\"count\":10,\"distance\":15000.0,\"moving_time\":18000,\"elapsed_time\":19500,\"elevation_gain\":0.0}"
          }
        },
        {
          "label": "All Swim Totals",
          "value": "all_swim_totals",
          "schema": {
            "type": "string",
            "example": "{\"count\":45,\"distance\":67500.0,\"moving_time\":81000,\"elapsed_time\":85000,\"elevation_gain\":0.0}"
          }
        },
        {
          "label": "Recent Ride Totals",
          "value": "recent_ride_totals",
          "schema": {
            "type": "object",
            "example": {
              "distance": 245000,
              "achievement_count": 5,
              "count": 8,
              "elapsed_time": 28800,
              "elevation_gain": 1850,
              "moving_time": 27000
            },
            "properties": {
              "distance": {
                "type": "number",
                "title": "Recent Ride Totals.Distance"
              },
              "achievement_count": {
                "type": "number",
                "title": "Recent Ride Totals.Achievement Count"
              },
              "count": {
                "type": "number",
                "title": "Recent Ride Totals.Count"
              },
              "elapsed_time": {
                "type": "number",
                "title": "Recent Ride Totals.Elapsed Time"
              },
              "elevation_gain": {
                "type": "number",
                "title": "Recent Ride Totals.Elevation Gain"
              },
              "moving_time": {
                "type": "number",
                "title": "Recent Ride Totals.Moving Time"
              }
            }
          }
        },
        {
          "label": "Biggest Climb Elevation Gain",
          "value": "biggest_climb_elevation_gain",
          "schema": {
            "type": "number",
            "example": 1245
          }
        },
        {
          "label": "Ytd Ride Totals",
          "value": "ytd_ride_totals",
          "schema": {
            "type": "string",
            "example": "{\"count\":52,\"distance\":3200000.0,\"moving_time\":360000,\"elapsed_time\":380000,\"elevation_gain\":25000.0}"
          }
        },
        {
          "label": "All Ride Totals",
          "value": "all_ride_totals",
          "schema": {
            "type": "string",
            "example": "{\"count\":310,\"distance\":18500000.0,\"moving_time\":2160000,\"elapsed_time\":2280000,\"elevation_gain\":145000.0}"
          }
        },
        {
          "label": "Ytd Run Totals",
          "value": "ytd_run_totals",
          "schema": {
            "type": "string",
            "example": "{\"count\":35,\"distance\":210000.0,\"moving_time\":72000,\"elapsed_time\":76000,\"elevation_gain\":3200.0}"
          }
        }
      ]
    }
  ],
  "icon": "(data URI omitted)"
}
```
