feat: enable unauthenticated server startup with runtime OAuth and update CI/CD to append Docker pull instructions to release notes
This commit is contained in:
@@ -36,6 +36,9 @@ class StravaClient:
|
||||
|
||||
async def get_valid_token(self) -> str:
|
||||
"""Returns a valid access token, refreshing it if necessary."""
|
||||
if not self.refresh_token:
|
||||
raise ValueError("No Strava refresh token found. Please run the 'get_new_oauth_token' MCP tool to authenticate first.")
|
||||
|
||||
if not self.access_token or time.time() > self.expires_at - 60:
|
||||
await self._refresh_access_token()
|
||||
return self.access_token
|
||||
|
||||
Reference in New Issue
Block a user