Skip to main content

A light weight Python library that acts as an API for the website albumoftheyear.org

Project description

AlbumOfTheYearWrapper

A light weight python library that acts as an API for https://www.albumoftheyear.org/
Tests PyPI

Description

Gets data from https://www.albumoftheyear.org/. The website doesn't currently provide API support so web parsing is required to obtain data. Because of this, and according to https://www.albumoftheyear.org/robots.txt, searching and POST requests are not allowed.

Installation

pip install album-of-the-year-api

or upgrade

pip install album-of-the-year-api --upgrade

Usage

Examples

Here's a quick example of getting a specific users follower count

from albumoftheyearapi import AOTY

client = AOTY()
print(client.user_follower_count('jahsias'))

>> 0

If you don't need the full functionality, you can also import only the neccesary files

from albumoftheyearapi.artist import ArtistMethods

client = ArtistMethods()
print(client.artist_albums('183-kanye-west'))

>> ['Donda 2', 'Donda', 'JESUS IS KING', 'ye', 'The Life of Pablo', 'Yeezus', 'Watch the Throne', 'My Beautiful Dark Twisted Fantasy', '808s & Heartbreak', 'Graduation', 'Late Registration', 'The College Dropout']

Notice artists also need their unique id along with their name

Each function also is able to return the data in JSON format

from albumoftheyearapi import AOTY

client = AOTY()
print(client.artist_critic_score_json('183-kanye-west'))

>> {"critic_score": "73"}

For detailed information, refer to the Full API Documentation.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

album-of-the-year-api-0.2.10.tar.gz (6.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

album_of_the_year_api-0.2.10-py3-none-any.whl (8.2 kB view details)

Uploaded Python 3

File details

Details for the file album-of-the-year-api-0.2.10.tar.gz.

File metadata

  • Download URL: album-of-the-year-api-0.2.10.tar.gz
  • Upload date:
  • Size: 6.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.18

File hashes

Hashes for album-of-the-year-api-0.2.10.tar.gz
Algorithm Hash digest
SHA256 19707d5fead592113fa0d01b05dd80392e467294cc208e6f4203f43596e519c9
MD5 d0e2bb43082d15b450f2255159818bda
BLAKE2b-256 c4a94e423d77df8af0968bc4fa76dd86cb8d6430aca8aa9021e46851c42a834e

See more details on using hashes here.

File details

Details for the file album_of_the_year_api-0.2.10-py3-none-any.whl.

File metadata

File hashes

Hashes for album_of_the_year_api-0.2.10-py3-none-any.whl
Algorithm Hash digest
SHA256 989a5f041ea7c200ba39084c6f448d83730c07882e1173839b5c1830bd8d9bd3
MD5 a7736f2749fbd385f261284b60d1bd7f
BLAKE2b-256 64f5f83555951246ea146a75ae71cf7ccb2e709628d1b880501cd00aca3e2dec

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page