has_connect_plus
Check if a Garmin account has a Connect+ subscription before calling food search, custom food, or food logging methods, which require it and otherwise throw an error.
Instructions
whether the account has a Garmin Connect+ subscription, read from the cached user profile (/userprofile-service/socialProfile, so usually no extra request): true when hasPremiumSocialIcon is true or userRoles holds any ROLE_SP_FEATURE_n entry. The methods in CONNECT_PLUS_METHODS (searchFoods, getCustomFoods, getCustomFoodServingUnits, createCustomFood, updateCustomFood, deleteCustomFood, logFood, quickAddFood, deleteFoodLogs) need it; without it they throw GarminConnectPlusRequiredError instead of the bare 403 Garmin sends
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||