
Tempus Metronome and GetSongBPM API
What BPM really means and how I integrated the GetSongBPM API into Tempus Metronome using Flutter to let users look up song tempos instantly.
Key takeaways
- GetSongBPM API returns tempo data in one call with no OAuth, allowing 3,000 requests per hour.
- BPM data can be unreliable for live recordings, tempo changes, and double-time patterns.
- Tempus Metronome auto-sets the beat from a song search, bridging BPM lookup and practice.
Understanding tempo is one of the fundamentals of music performance, practice, and DJing. In Tempus Metronome, I integrate directly with the GetSongBPM API, allowing users to look up a song, check its tempo, and instantly set the metronome to match. This article explains what BPM actually is, why it matters, where tempo data comes from, and how to integrate GetSongBPM into Flutter — all in one place.
What Is BPM?
BPM (Beats Per Minute) describes the tempo of a piece of music — how many beats occur in one minute. A slow ballad might be 60 BPM, a pop track 120 BPM, and fast electronic music can reach 150–180 BPM or more.
Keep a steady beat during practice and performance.
Match tempos between tracks for seamless transitions.
Design workouts and running playlists by energy level.
Practice specific rhythmic patterns at precise tempos.
Analyze energy and intensity in any track.
What BPM Can Tell You
Higher BPM generally means higher energy.
Most genres cluster around specific BPM ranges.
Faster tempos demand more from the performer.
Plan warm-ups, drills, and cool-downs by tempo.
What to Watch Out For
BPM data is not always reliable. Watch out for tempo changes within a track, live recordings with natural drift, different remixes at different speeds, double-time / half-time feel that confuses detection, and incorrect crowd-sourced data.
Where Can You Search for BPM Data?
Dedicated BPM database with a simple REST API. Used by Tempus Metronome.
Rich audio analysis including tempo, key, and danceability via Spotify's API.
Audio recognition services that identify songs and return metadata including BPM.
Tap along to the beat and calculate BPM manually — the most reliable fallback.
Tempus Metronome uses GetSongBPM for its simplicity and speed. One API call returns the tempo — no OAuth, no complex setup.
Getting Started with the GetSongBPM API
Sign up at getsongbpm.com/api to get your API key. Free tier available.
The API terms require a backlink to GetSongBPM in your app or website.
3,000 requests per hour — more than enough for a metronome app.
Store your key in environment variables, never hardcode it in source code.
Environment Configuration
GETSONGBPM_API_KEY=your_api_key_here
For Flutter Web, pass the key at build time:
flutter build web --dart-define=GETSONGBPM_API_KEY=your_api_key_here
Flutter Integration Example
API Service
class GetSongBpmApi {
final String baseUrl = "https://api.getsongbpm.com";
final String apiKey = dotenv.env['GETSONGBPM_API_KEY']!;
Future<List<dynamic>> searchSongs(String query) async {
final url = Uri.parse(
"$baseUrl/search/?api_key=$apiKey&type=multi&lookup=$query"
);
final response = await http.get(url);
if (response.statusCode == 200) {
final jsonResponse = jsonDecode(response.body);
return jsonResponse['search'] ?? [];
} else {
throw Exception("Failed to load data");
}
}
}
Testing
Links
Integrating SignNow E-Signatures into Your Django Application
A practical guide to adding e-signatures to your Django app with the SignNow REST API: OAuth2 auth, document uploads, Celery signing workflows, and webhooks.
Learning Embedded Rust: A C/Python Developer's Rosetta Stone
A practical guide for C and Python developers transitioning to embedded Rust. Side-by-side comparisons of ownership, error handling, pattern matching, and more — mapped to concepts you already know.