wakatime_api 0.0.1 copy "wakatime_api: ^0.0.1" to clipboard
wakatime_api: ^0.0.1 copied to clipboard

outdated

Api wrapper for Wakatime

Wakatime Api #

This package just wraps wakatime api and provides a simple interface to use it.

Get started #

Before starting, generate the *.freezed.dart and the *.g.dart classes by running

flutter pub run build_runner build --delete-conflicting-outputs

then instantiate the WakatimeApi singleton with your api key

final wakatime = WakatimeApi('your-api-key');

then you can request the heartbeats for a given date just by using

Wakatime().getHeartbeats(DateTime.now())
// Or
Wakatime().getHeartBeatsForRange(
    DateTime(1970, 1, 1),
    DateTime.now(),
)