
Audio DB API
MusicWith the Audio DB API, you can get albums, artist, specific tracks data, youtube music videos, popularity of an artist and images for 1000s of musicians. For example, on free plan, you can fetch the artist's entire biography. Such as year of birth, style & genre of music, mood of the star, his social media websites, thumbnail, logo, gender, complete description in nearly 6 languages.
π Documentation & Examples
Everything you need to integrate with Audio DB API
π Quick Start Examples
// Audio DB API API Example
const response = await fetch('https://www.theaudiodb.com/api_guide.php', {
method: 'GET',
headers: {
'Content-Type': 'application/json'
}
});
const data = await response.json();
console.log(data);Public API Docs for TheAudioDB
If you are a music lover and want to get access to a lot of information about your favourite artists and their music, then TheAudioDB website is a perfect place to start. TheAudioDB has a massive collection of data related to music, including artist names, album titles, track listings, and more.
The good news is that TheAudioDB also provides a public API that developers can use to get access to this information programmatically. In this article, we will explore the steps required to use TheAudioDB API to retrieve artist data and album information.
Requirements
To get started, you should have a basic understanding of JavaScript and Node.js installed on your machine.
How to Get a TheAudioDB API Key
TheAudioDB does not issue keys through a normal signup form. Instead:
- Free testing: use the shared public test key
123. It works immediately on the V1 JSON API and is limited to 30 requests per minute β fine for development and low-volume use. - Personal key: for your own key with higher limits (and access to the V2 API, livescores, and video links), join TheAudioDB Patreon (the $8 tier). After subscribing you receive a private API key by email. See https://www.theaudiodb.com/api_apply.php.
The key sits in the URL path, as https://www.theaudiodb.com/api/v1/json/{KEY}/:
const apiKey = '123'; // free public test key
const artist = 'Coldplay';
const url = `https://www.theaudiodb.com/api/v1/json/${apiKey}/search.php?s=${encodeURIComponent(artist)}`;
fetch(url)
.then(res => res.json())
.then(data => console.log(data.artists));
The old advice to "register at register.php to receive a key" is outdated β use 123 for testing, or Patreon for a personal key.
Conclusion
In this article, we have explored TheAudioDB API and looked at examples of how to retrieve artist and album data programmatically using JavaScript. With this knowledge, you can start building your own music applications, leveraging the wealth of data available on the TheAudioDB website.









