Android Samples

You can get the Google Fit samples on GitHub.

BasicSensorsApi

This sample demonstrates how to register listeners to read raw sensor data from a data source.
Get it on GitHub

BasicRecordingApi

This sample demonstrates how to request automated storage of sensor data by creating subscriptions.
Get it on GitHub

BasicHistoryApi

This sample demonstartes how to read data from the user's fitness history.
Get it on GitHub

BasicHistorySessions

This sample demonstrates how to use sessions for fitness activities with the fitness history.
Get it on GitHub

StepCounter

This sample demonstrates how to record steps and read them back.
Get it on GitHub