The official Dart package for the WorkoutX API. Ship cross-platform fitness apps from one codebase — 1,400+ exercises with GIF animations, the AI Workout Generator, supplements, and the Body Scan API. Runs on Flutter for iOS, Android, web, and desktop.
📦 Publishing to pub.dev shortly — not yet installable. Get your key now and you'll be ready the moment it lands.
One client covers both products — the Exercise API (API-key auth) and the Body Scan API (user JWT). The SDK attaches the right credential automatically.
iOS, Android, web, and desktop from a single Dart package. Display GIFs directly with Image.network(wx.gifUrl(id)).
Automatic retries with backoff on 429 and 5xx, honoring Retry-After. Structured WorkoutXError with status, code and tips.
Exercises, GIFs, workouts, supplements and Body Scan — all under wx.*. Auth handled transparently per product.
Exercise IDs are not sequential, so passing a human name to get() returns a 404. The find() helper tries an ID first, then falls back to a name search.
Run flutter pub add workoutx_sdk (or dart pub add workoutx_sdk for a Dart-only project), then import package:workoutx_sdk/workoutx_sdk.dart.
All Flutter targets: iOS, Android, web, macOS, Windows, and Linux. It also works in plain Dart projects.
Pass wx.gifUrl('0001') straight to Image.network(...), or fetch raw bytes with wx.gifs.get('0001').
Body Scan uses a logged-in user's JWT. Pass scan: ScanAuth.token('...'), or ScanAuth.credentials(email:, password:) to let the SDK log in automatically.
Keys compiled into a mobile or web build can be extracted. For production, proxy requests through your own backend or use a restricted, rotatable key rather than a full-access one.
gifUrl() puts the key in the query string so Image.network can load it. Since URLs can leak via logs and referrers, use a separate, restricted key for GIFs where possible.
For Body Scan, fetch a short-lived JWT from your backend and pass ScanAuth.token(...). Avoid shipping the email/password login flow inside the app.
Free tier included. 1,400+ exercises, GIFs, workouts, and Body Scan in one package.
Get your free API key