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

How to get all of the activities by date?

Hi all

 

Can someone please help me to figure out how to get all of the activities just on a specific day, I need the ID of these please?

 

 

Best Answer
0 Votes
3 REPLIES 3

Hi @mrf0200,

 

Welcome to the forums!

 

You can use the Get Activity Logs List endpoint to return all activities before or after a certain date. Each activity log will return the 'activityId' for the recorded exercise.

Best Answer

Hi @JohnFitbit, I have question regarding this fetching of activities. 
So, in the webhook it is not possible to receive Datetime of the Activity, we just get the Date ?

In this case, when fetching the detailed activities, we can only use BeforeDate or AfterDate, not both. This is causing us to get up to 100 activities (for that Date, and probably for a few days after/before the said Date) for each webhook we receive. 
Is there a better approach for fetching that 1 activity for which the webhook was actually sent. 

Best Answer
0 Votes

The notifications are sent when the data is added, deleted or updated.   At this time, the notification doesn't state which has happened.   So, you'll probably want to pull all of the activities for that date to reconcile against what you have already recorded.   There isn't a way to pull recorded activities during a specific date and time.

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