# Extension: TheAudioDB
Retrieve images and information about artists, releases, and recordings from [TheAudioDB.com](http://www.theaudiodb.com/).
This extension uses its own cache, separate from the MusicBrainz loader cache.
## Configuration
This extension can be configured using environment variables:
* **`THEAUDIODB_API_KEY`**: TheAudioDB API key to use. This is required for any
fields added by the extension to successfully resolve.
* **`THEAUDIODB_BASE_URL`**: The base URL at which to access TheAudioDB API.
Defaults to `http://www.theaudiodb.com/api/v1/json/`.
* **`THEAUDIODB_CACHE_SIZE`**: The number of items to keep in the cache.
Defaults to `GRAPHBRAINZ_CACHE_SIZE` if defined, or `8192`.
* **`THEAUDIODB_CACHE_TTL`**: The number of seconds to keep items in the
cache. Defaults to `GRAPHBRAINZ_CACHE_TTL` if defined, or `86400000` (one day).
Table of Contents
* [Objects](#objects)
* [Artist](#artist)
* [Recording](#recording)
* [ReleaseGroup](#releasegroup)
* [TheAudioDBAlbum](#theaudiodbalbum)
* [TheAudioDBArtist](#theaudiodbartist)
* [TheAudioDBMusicVideo](#theaudiodbmusicvideo)
* [TheAudioDBTrack](#theaudiodbtrack)
* [Enums](#enums)
* [TheAudioDBImageSize](#theaudiodbimagesize)
| Field | Argument | Type | Description |
|---|---|---|---|
| theAudioDB | TheAudioDBArtist | Data about the artist from [TheAudioDB](http://www.theaudiodb.com/), a good source of biographical information and images. This field is provided by TheAudioDB extension. | |
| Field | Argument | Type | Description |
|---|---|---|---|
| theAudioDB | TheAudioDBTrack | Data about the recording from [TheAudioDB](http://www.theaudiodb.com/). This field is provided by TheAudioDB extension. | |
| Field | Argument | Type | Description |
|---|---|---|---|
| theAudioDB | TheAudioDBAlbum | Data about the release group from [TheAudioDB](http://www.theaudiodb.com/), a good source of descriptive information, reviews, and images. This field is provided by TheAudioDB extension. | |
| Field | Argument | Type | Description |
|---|---|---|---|
| albumID | ID | TheAudioDB ID of the album. | |
| artistID | ID | TheAudioDB ID of the artist who released the album. | |
| description | String | A description of the album, often available in several languages. | |
| lang | String | The two-letter code for the language in which to retrieve the biography. | |
| review | String | A review of the album. | |
| salesCount | Int | The worldwide sales figure. | |
| score | Float | The album’s rating as determined by user votes, out of 10. | |
| scoreVotes | Int | The number of users who voted to determine the album’s score. | |
| discImage | URLString | An image of the physical disc media for the album. | |
| size | TheAudioDBImageSize | The size of the image to retrieve. | |
| spineImage | URLString | An image of the spine of the album packaging. | |
| size | TheAudioDBImageSize | The size of the image to retrieve. | |
| frontImage | URLString | An image of the front of the album packaging. | |
| size | TheAudioDBImageSize | The size of the image to retrieve. | |
| backImage | URLString | An image of the back of the album packaging. | |
| size | TheAudioDBImageSize | The size of the image to retrieve. | |
| genre | String | The primary musical genre of the album (e.g. “Alternative Rock”). | |
| mood | String | The primary musical mood of the album (e.g. “Sad”). | |
| style | String | The primary musical style of the album (e.g. “Rock/Pop”). | |
| speed | String | A rough description of the primary musical speed of the album (e.g. “Medium”). | |
| theme | String | The primary musical theme of the album (e.g. “In Love”). | |
| Field | Argument | Type | Description |
|---|---|---|---|
| artistID | ID | TheAudioDB ID of the artist. | |
| biography | String | A biography of the artist, often available in several languages. | |
| lang | String | The two-letter code for the language in which to retrieve the biography. | |
| memberCount | Int | The number of members in the musical group, if applicable. | |
| banner | URLString | A 1000x185 JPG banner image containing the artist and their logo or name. | |
| size | TheAudioDBImageSize | The size of the image to retrieve. | |
| fanArt | [URLString]! | A list of 1280x720 or 1920x1080 JPG images depicting the artist. | |
| size | TheAudioDBImageSize | The size of the images to retrieve. | |
| logo | URLString | A 400x155 PNG image containing the artist’s logo or name, with a transparent background. | |
| size | TheAudioDBImageSize | The size of the image to retrieve. | |
| thumbnail | URLString | A 1000x1000 JPG thumbnail image picturing the artist (usually containing every member of a band). | |
| size | TheAudioDBImageSize | The size of the image to retrieve. | |
| genre | String | The primary musical genre of the artist (e.g. “Alternative Rock”). | |
| mood | String | The primary musical mood of the artist (e.g. “Sad”). | |
| style | String | The primary musical style of the artist (e.g. “Rock/Pop”). | |
| Field | Argument | Type | Description |
|---|---|---|---|
| url | URLString | The URL where the music video can be found. | |
| companyName | String | The video production company of the music video. | |
| directorName | String | The director of the music video. | |
| screenshots | [URLString]! | A list of still images from the music video. | |
| size | TheAudioDBImageSize | The size of the images to retrieve. | |
| viewCount | Int | The number of views the video has received at the given URL. This will rarely be up to date, so use cautiously. | |
| likeCount | Int | The number of likes the video has received at the given URL. This will rarely be up to date, so use cautiously. | |
| dislikeCount | Int | The number of dislikes the video has received at the given URL. This will rarely be up to date, so use cautiously. | |
| commentCount | Int | The number of comments the video has received at the given URL. This will rarely be up to date, so use cautiously. | |
| Field | Argument | Type | Description |
|---|---|---|---|
| trackID | ID | TheAudioDB ID of the track. | |
| albumID | ID | TheAudioDB ID of the album on which the track appears. | |
| artistID | ID | TheAudioDB ID of the artist who released the track. | |
| description | String | A description of the track. | |
| lang | String | ||
| thumbnail | URLString | A thumbnail image for the track. | |
| size | TheAudioDBImageSize | The size of the image to retrieve. | |
| score | Float | The track’s rating as determined by user votes, out of 10. | |
| scoreVotes | Int | The number of users who voted to determine the album’s score. | |
| trackNumber | Int | The track number of the song on the album. | |
| musicVideo | TheAudioDBMusicVideo | The official music video for the track. | |
| genre | String | The primary musical genre of the track (e.g. “Alternative Rock”). | |
| mood | String | The primary musical mood of the track (e.g. “Sad”). | |
| style | String | The primary musical style of the track (e.g. “Rock/Pop”). | |
| theme | String | The primary musical theme of the track (e.g. “In Love”). | |
| Value | Description |
|---|---|
| FULL | The image’s full original dimensions. |
| PREVIEW | A maximum dimension of 200px. |