Skip to main content
Glama

Fitness MCP Server

main.py35.8 kB
# generated by fastapi-codegen: # filename: openapi.yaml # timestamp: 2025-06-29T02:09:40+00:00 import argparse import json import os from typing import * from typing import Optional from autogen.mcp.mcp_proxy import MCPProxy from autogen.mcp.mcp_proxy.security import BaseSecurity, UnsuportedSecurityStub from fastapi import Path, Query from models import ( ActivityType, AggregateRequest, AggregateResponse, Alt, Dataset, DataSource, DataTypeName, FieldXgafv, ListDataPointChangesResponse, ListDataSourcesResponse, ListSessionsResponse, Session, ) app = MCPProxy( contact={'name': 'Google', 'url': 'https://google.com', 'x-twitter': 'youtube'}, description="The Fitness API for managing users' fitness tracking data.", license={ 'name': 'Creative Commons Attribution 3.0', 'url': 'http://creativecommons.org/licenses/by/3.0/', }, termsOfService='https://developers.google.com/terms/', title='Fitness API', version='v1', servers=[{'url': 'https://fitness.googleapis.com/fitness/v1/users'}], ) @app.get( '/{userId}/dataSources', description=""" Lists all data sources that are visible to the developer, using the OAuth scopes provided. The list is not exhaustive; the user may have private data sources that are only visible to other developers, or calls using other scopes. """, tags=[ 'fitness_data_sources_management', 'fitness_data_sets_handling', 'fitness_data_aggregation', ], security=[ UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), ], ) def fitness_users_data_sources_list( user_id: str = Path(..., alias='userId'), data_type_name: Optional[DataTypeName] = Query(None, alias='dataTypeName'), field__xgafv: Optional[FieldXgafv] = Query(None, alias='$.xgafv'), access_token: Optional[str] = None, alt: Optional[Alt] = None, callback: Optional[str] = None, fields: Optional[str] = None, key: Optional[str] = None, oauth_token: Optional[str] = None, pretty_print: Optional[bool] = Query(None, alias='prettyPrint'), quota_user: Optional[str] = Query(None, alias='quotaUser'), upload_protocol: Optional[str] = None, upload_type: Optional[str] = Query(None, alias='uploadType'), ): raise RuntimeError("Should be patched by MCPProxy and never executed") @app.post( '/{userId}/dataSources', description=""" Creates a new data source that is unique across all data sources belonging to this user. A data source is a unique source of sensor data. Data sources can expose raw data coming from hardware sensors on local or companion devices. They can also expose derived data, created by transforming or merging other data sources. Multiple data sources can exist for the same data type. Every data point in every dataset inserted into or read from the Fitness API has an associated data source. Each data source produces a unique stream of dataset updates, with a unique data source identifier. Not all changes to data source affect the data stream ID, so that data collected by updated versions of the same application/device can still be considered to belong to the same data source. Data sources are identified using a string generated by the server, based on the contents of the source being created. The dataStreamId field should not be set when invoking this method. It will be automatically generated by the server with the correct format. If a dataStreamId is set, it must match the format that the server would generate. This format is a combination of some fields from the data source, and has a specific order. If it doesn't match, the request will fail with an error. Specifying a DataType which is not a known type (beginning with "com.google.") will create a DataSource with a *custom data type*. Custom data types are only readable by the application that created them. Custom data types are *deprecated*; use standard data types instead. In addition to the data source fields included in the data source ID, the developer project number that is authenticated when creating the data source is included. This developer project number is obfuscated when read by any other developer reading public data types. """, tags=['fitness_data_sources_management'], security=[ UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), ], ) def fitness_users_data_sources_create( user_id: str = Path(..., alias='userId'), field__xgafv: Optional[FieldXgafv] = Query(None, alias='$.xgafv'), access_token: Optional[str] = None, alt: Optional[Alt] = None, callback: Optional[str] = None, fields: Optional[str] = None, key: Optional[str] = None, oauth_token: Optional[str] = None, pretty_print: Optional[bool] = Query(None, alias='prettyPrint'), quota_user: Optional[str] = Query(None, alias='quotaUser'), upload_protocol: Optional[str] = None, upload_type: Optional[str] = Query(None, alias='uploadType'), body: DataSource = None, ): raise RuntimeError("Should be patched by MCPProxy and never executed") @app.delete( '/{userId}/dataSources/{dataSourceId}', description=""" Deletes the specified data source. The request will fail if the data source contains any data points. """, tags=[ 'fitness_data_sources_management', 'fitness_data_sets_handling', 'fitness_data_aggregation', ], security=[ UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), ], ) def fitness_users_data_sources_delete( user_id: str = Path(..., alias='userId'), data_source_id: str = Path(..., alias='dataSourceId'), field__xgafv: Optional[FieldXgafv] = Query(None, alias='$.xgafv'), access_token: Optional[str] = None, alt: Optional[Alt] = None, callback: Optional[str] = None, fields: Optional[str] = None, key: Optional[str] = None, oauth_token: Optional[str] = None, pretty_print: Optional[bool] = Query(None, alias='prettyPrint'), quota_user: Optional[str] = Query(None, alias='quotaUser'), upload_protocol: Optional[str] = None, upload_type: Optional[str] = Query(None, alias='uploadType'), ): raise RuntimeError("Should be patched by MCPProxy and never executed") @app.get( '/{userId}/dataSources/{dataSourceId}', description=""" Returns the specified data source. """, tags=['fitness_data_sources_management', 'fitness_data_sets_handling'], security=[ UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), ], ) def fitness_users_data_sources_get( user_id: str = Path(..., alias='userId'), data_source_id: str = Path(..., alias='dataSourceId'), field__xgafv: Optional[FieldXgafv] = Query(None, alias='$.xgafv'), access_token: Optional[str] = None, alt: Optional[Alt] = None, callback: Optional[str] = None, fields: Optional[str] = None, key: Optional[str] = None, oauth_token: Optional[str] = None, pretty_print: Optional[bool] = Query(None, alias='prettyPrint'), quota_user: Optional[str] = Query(None, alias='quotaUser'), upload_protocol: Optional[str] = None, upload_type: Optional[str] = Query(None, alias='uploadType'), ): raise RuntimeError("Should be patched by MCPProxy and never executed") @app.put( '/{userId}/dataSources/{dataSourceId}', description=""" Updates the specified data source. The dataStreamId, dataType, type, dataStreamName, and device properties with the exception of version, cannot be modified. Data sources are identified by their dataStreamId. """, tags=['fitness_data_sources_management'], security=[ UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), ], ) def fitness_users_data_sources_update( user_id: str = Path(..., alias='userId'), data_source_id: str = Path(..., alias='dataSourceId'), field__xgafv: Optional[FieldXgafv] = Query(None, alias='$.xgafv'), access_token: Optional[str] = None, alt: Optional[Alt] = None, callback: Optional[str] = None, fields: Optional[str] = None, key: Optional[str] = None, oauth_token: Optional[str] = None, pretty_print: Optional[bool] = Query(None, alias='prettyPrint'), quota_user: Optional[str] = Query(None, alias='quotaUser'), upload_protocol: Optional[str] = None, upload_type: Optional[str] = Query(None, alias='uploadType'), body: DataSource = None, ): raise RuntimeError("Should be patched by MCPProxy and never executed") @app.get( '/{userId}/dataSources/{dataSourceId}/dataPointChanges', description=""" Queries for user's data point changes for a particular data source. """, tags=[ 'fitness_data_sources_management', 'fitness_data_sets_handling', 'fitness_data_aggregation', ], security=[ UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), ], ) def fitness_users_data_sources_data_point_changes_list( user_id: str = Path(..., alias='userId'), data_source_id: str = Path(..., alias='dataSourceId'), limit: Optional[int] = None, page_token: Optional[str] = Query(None, alias='pageToken'), field__xgafv: Optional[FieldXgafv] = Query(None, alias='$.xgafv'), access_token: Optional[str] = None, alt: Optional[Alt] = None, callback: Optional[str] = None, fields: Optional[str] = None, key: Optional[str] = None, oauth_token: Optional[str] = None, pretty_print: Optional[bool] = Query(None, alias='prettyPrint'), quota_user: Optional[str] = Query(None, alias='quotaUser'), upload_protocol: Optional[str] = None, upload_type: Optional[str] = Query(None, alias='uploadType'), ): raise RuntimeError("Should be patched by MCPProxy and never executed") @app.delete( '/{userId}/dataSources/{dataSourceId}/datasets/{datasetId}', description=""" Performs an inclusive delete of all data points whose start and end times have any overlap with the time range specified by the dataset ID. For most data types, the entire data point will be deleted. For data types where the time span represents a consistent value (such as com.google.activity.segment), and a data point straddles either end point of the dataset, only the overlapping portion of the data point will be deleted. """, tags=['fitness_data_sources_management', 'fitness_data_sets_handling'], security=[ UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), ], ) def fitness_users_data_sources_datasets_delete( user_id: str = Path(..., alias='userId'), data_source_id: str = Path(..., alias='dataSourceId'), dataset_id: str = Path(..., alias='datasetId'), field__xgafv: Optional[FieldXgafv] = Query(None, alias='$.xgafv'), access_token: Optional[str] = None, alt: Optional[Alt] = None, callback: Optional[str] = None, fields: Optional[str] = None, key: Optional[str] = None, oauth_token: Optional[str] = None, pretty_print: Optional[bool] = Query(None, alias='prettyPrint'), quota_user: Optional[str] = Query(None, alias='quotaUser'), upload_protocol: Optional[str] = None, upload_type: Optional[str] = Query(None, alias='uploadType'), ): raise RuntimeError("Should be patched by MCPProxy and never executed") @app.get( '/{userId}/dataSources/{dataSourceId}/datasets/{datasetId}', description=""" Returns a dataset containing all data points whose start and end times overlap with the specified range of the dataset minimum start time and maximum end time. Specifically, any data point whose start time is less than or equal to the dataset end time and whose end time is greater than or equal to the dataset start time. """, tags=['fitness_data_sets_handling', 'fitness_data_sources_management'], security=[ UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), ], ) def fitness_users_data_sources_datasets_get( user_id: str = Path(..., alias='userId'), data_source_id: str = Path(..., alias='dataSourceId'), dataset_id: str = Path(..., alias='datasetId'), limit: Optional[int] = None, page_token: Optional[str] = Query(None, alias='pageToken'), field__xgafv: Optional[FieldXgafv] = Query(None, alias='$.xgafv'), access_token: Optional[str] = None, alt: Optional[Alt] = None, callback: Optional[str] = None, fields: Optional[str] = None, key: Optional[str] = None, oauth_token: Optional[str] = None, pretty_print: Optional[bool] = Query(None, alias='prettyPrint'), quota_user: Optional[str] = Query(None, alias='quotaUser'), upload_protocol: Optional[str] = None, upload_type: Optional[str] = Query(None, alias='uploadType'), ): raise RuntimeError("Should be patched by MCPProxy and never executed") @app.patch( '/{userId}/dataSources/{dataSourceId}/datasets/{datasetId}', description=""" Adds data points to a dataset. The dataset need not be previously created. All points within the given dataset will be returned with subsquent calls to retrieve this dataset. Data points can belong to more than one dataset. This method does not use patch semantics: the data points provided are merely inserted, with no existing data replaced. """, tags=['fitness_data_sets_handling', 'fitness_data_sources_management'], security=[ UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), ], ) def fitness_users_data_sources_datasets_patch( user_id: str = Path(..., alias='userId'), data_source_id: str = Path(..., alias='dataSourceId'), dataset_id: str = Path(..., alias='datasetId'), field__xgafv: Optional[FieldXgafv] = Query(None, alias='$.xgafv'), access_token: Optional[str] = None, alt: Optional[Alt] = None, callback: Optional[str] = None, fields: Optional[str] = None, key: Optional[str] = None, oauth_token: Optional[str] = None, pretty_print: Optional[bool] = Query(None, alias='prettyPrint'), quota_user: Optional[str] = Query(None, alias='quotaUser'), upload_protocol: Optional[str] = None, upload_type: Optional[str] = Query(None, alias='uploadType'), body: Dataset = None, ): raise RuntimeError("Should be patched by MCPProxy and never executed") @app.post( '/{userId}/dataset:aggregate', description=""" Aggregates data of a certain type or stream into buckets divided by a given type of boundary. Multiple data sets of multiple types and from multiple sources can be aggregated into exactly one bucket type per request. """, tags=['fitness_data_aggregation', 'fitness_data_sources_management'], security=[ UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), ], ) def fitness_users_dataset_aggregate( user_id: str = Path(..., alias='userId'), field__xgafv: Optional[FieldXgafv] = Query(None, alias='$.xgafv'), access_token: Optional[str] = None, alt: Optional[Alt] = None, callback: Optional[str] = None, fields: Optional[str] = None, key: Optional[str] = None, oauth_token: Optional[str] = None, pretty_print: Optional[bool] = Query(None, alias='prettyPrint'), quota_user: Optional[str] = Query(None, alias='quotaUser'), upload_protocol: Optional[str] = None, upload_type: Optional[str] = Query(None, alias='uploadType'), body: AggregateRequest = None, ): raise RuntimeError("Should be patched by MCPProxy and never executed") @app.get( '/{userId}/sessions', description=""" Lists sessions previously created. """, tags=['fitness_session_management'], security=[ UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), ], ) def fitness_users_sessions_list( user_id: str = Path(..., alias='userId'), activity_type: Optional[ActivityType] = Query(None, alias='activityType'), end_time: Optional[str] = Query(None, alias='endTime'), include_deleted: Optional[bool] = Query(None, alias='includeDeleted'), page_token: Optional[str] = Query(None, alias='pageToken'), start_time: Optional[str] = Query(None, alias='startTime'), field__xgafv: Optional[FieldXgafv] = Query(None, alias='$.xgafv'), access_token: Optional[str] = None, alt: Optional[Alt] = None, callback: Optional[str] = None, fields: Optional[str] = None, key: Optional[str] = None, oauth_token: Optional[str] = None, pretty_print: Optional[bool] = Query(None, alias='prettyPrint'), quota_user: Optional[str] = Query(None, alias='quotaUser'), upload_protocol: Optional[str] = None, upload_type: Optional[str] = Query(None, alias='uploadType'), ): raise RuntimeError("Should be patched by MCPProxy and never executed") @app.delete( '/{userId}/sessions/{sessionId}', description=""" Deletes a session specified by the given session ID. """, tags=['fitness_session_management'], security=[ UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), ], ) def fitness_users_sessions_delete( user_id: str = Path(..., alias='userId'), session_id: str = Path(..., alias='sessionId'), field__xgafv: Optional[FieldXgafv] = Query(None, alias='$.xgafv'), access_token: Optional[str] = None, alt: Optional[Alt] = None, callback: Optional[str] = None, fields: Optional[str] = None, key: Optional[str] = None, oauth_token: Optional[str] = None, pretty_print: Optional[bool] = Query(None, alias='prettyPrint'), quota_user: Optional[str] = Query(None, alias='quotaUser'), upload_protocol: Optional[str] = None, upload_type: Optional[str] = Query(None, alias='uploadType'), ): raise RuntimeError("Should be patched by MCPProxy and never executed") @app.put( '/{userId}/sessions/{sessionId}', description=""" Updates or insert a given session. """, tags=['fitness_session_management'], security=[ UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), UnsuportedSecurityStub(name="None"), ], ) def fitness_users_sessions_update( user_id: str = Path(..., alias='userId'), session_id: str = Path(..., alias='sessionId'), field__xgafv: Optional[FieldXgafv] = Query(None, alias='$.xgafv'), access_token: Optional[str] = None, alt: Optional[Alt] = None, callback: Optional[str] = None, fields: Optional[str] = None, key: Optional[str] = None, oauth_token: Optional[str] = None, pretty_print: Optional[bool] = Query(None, alias='prettyPrint'), quota_user: Optional[str] = Query(None, alias='quotaUser'), upload_protocol: Optional[str] = None, upload_type: Optional[str] = Query(None, alias='uploadType'), body: Session = None, ): raise RuntimeError("Should be patched by MCPProxy and never executed") if __name__ == "__main__": parser = argparse.ArgumentParser(description="MCP Server") parser.add_argument( "transport", choices=["stdio", "sse", "streamable-http"], help="Transport mode (stdio, sse or streamable-http)", ) args = parser.parse_args() if "CONFIG_PATH" in os.environ: config_path = os.environ["CONFIG_PATH"] app.load_configuration(config_path) if "CONFIG" in os.environ: config = os.environ["CONFIG"] app.load_configuration_from_string(config) if "SECURITY" in os.environ: security_params = BaseSecurity.parse_security_parameters_from_env( os.environ, ) app.set_security_params(security_params) mcp_settings = json.loads(os.environ.get("MCP_SETTINGS", "{}")) app.get_mcp(**mcp_settings).run(transport=args.transport)

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/ag2-mcp-servers/fitness-api'

If you have feedback or need assistance with the MCP directory API, please join our Discord server