Support for the legacy Fitbit Web API ends on September 30, 2026
Important: Support for the legacy Fitbit Web API ends on September 30, 2026. After this date the API will continue to operate, but Google will no longer fix bugs or provide API support. On October 30, 2026, the Fitbit Web API will be turned off and will no longer function or sync data to or from Fitbit users. To continue accessing data for your users after this date, migrate to the Google Health API.
Globals API
chevron down
 

Globals API

cancelAnimationFrame()

This method cancels a previously requested animation frame callback.

cancelAnimationFrame(handle: number)

Parameters

handle: number

The identifier of the request you want to cancel.

requestAnimationFrame()

This method triggers an immediate screen update, and registers a callback to be invoked before painting this update. Note that the request expires after one frame. For continuous animations, another request should be made from within the first callback.

requestAnimationFrame(handler: (timestamp: number) => void)

Parameters

handler: (timestamp: number) => void

A function to be executed before painting. The timestamp parameter indicates the time these callbacks began executing, in milliseconds. Multiple callbacks for the same frame receive the same timestamp value.