Cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Will meals imported from MyFitnessPal appear in the Fitbit API?

ANSWERED

I know that if a user links their MyFitnessPal and Fitbit accounts, foods logged in MyFitnessPal show up as meal summaries in Fitbit.

 

My question is: Are these meal summaries then retrievable via the Fitbit API, e.g. via the /foods/log/date endpoint, which includes a summary element?

 

Related question: I've seen many people say the link between MyFitnessPal and Fitbit can be flaky and unreliable. How reliable are these links these days?

Best Answer
0 Votes
1 BEST ANSWER

Accepted Solutions

Hi @diabolus,

 

The summary information is retrievable through the APIs, but it'll appear similarly as shown in your Fitbit account.  For example,

 

{
  "foods": [
    {
      "isFavorite": false,
      "logDate": "2019-01-03",
      "logId": 16510019768,
      "loggedFood": {
        "accessLevel": "PRIVATE",
        "amount": 1,
        "brand": "MyFitnessPal",
        "calories": 370,
        "foodId": 0,
        "mealTypeId": 1,
        "name": "Breakfast Summary",
        "unit": {
          "id": 201,
          "name": "meal",
          "plural": "meals"
        },
        "units": [
          201
        ]
      },
      "nutritionalValues": {
        "calories": 370,
        "carbs": 57,
        "fat": 13,
        "fiber": 8,
        "protein": 10,
        "sodium": 430
      }
    },
Gordon Crenshaw
Senior Technical Solutions Consultant
Fitbit Partner Engineering & Web API Support | Google

View best answer in original post

Best Answer
0 Votes
3 REPLIES 3

Hi @diabolus,

 

The summary information is retrievable through the APIs, but it'll appear similarly as shown in your Fitbit account.  For example,

 

{
  "foods": [
    {
      "isFavorite": false,
      "logDate": "2019-01-03",
      "logId": 16510019768,
      "loggedFood": {
        "accessLevel": "PRIVATE",
        "amount": 1,
        "brand": "MyFitnessPal",
        "calories": 370,
        "foodId": 0,
        "mealTypeId": 1,
        "name": "Breakfast Summary",
        "unit": {
          "id": 201,
          "name": "meal",
          "plural": "meals"
        },
        "units": [
          201
        ]
      },
      "nutritionalValues": {
        "calories": 370,
        "carbs": 57,
        "fat": 13,
        "fiber": 8,
        "protein": 10,
        "sodium": 430
      }
    },
Gordon Crenshaw
Senior Technical Solutions Consultant
Fitbit Partner Engineering & Web API Support | Google
Best Answer
0 Votes

Thanks! This clears up my main question.

 

Other question: Are links between MyFitnessPal and Fitbit accounts reliable currently? Or are API issues between the two services common (e.g. things breaking when MFP makes an update, requiring users to unlink and re-link)?

Best Answer

At Fitbit, we try our best to not make any breaking changes that would affect any of the 3rd party applications that integrate through our APIs.  If we are aware we are making a breaking change, we will make our best effort to contact our partners to let them know.

Gordon Crenshaw
Senior Technical Solutions Consultant
Fitbit Partner Engineering & Web API Support | Google
Best Answer