Skip to main content

Python API for downloading Melon charts

Project description

melon-chart.py

melon

melon-chart.py is a Python API that retrieves the TOP 100 information from the Melon.

Installation

pip install melon-chart.py

Quickstart

The main usage of melon-chart.py is similar to billboard.py.

>>> from melon import *
>>> chart = ChartData(image_size=500)
>>> print(chart[0].json())
{
    "artist": "IVE (아이브)",
    "image": "https://cdnimg.melon.co.kr/cm2/album/images/112/11/297/11211297_20230327114349_500.jpg?7d9408105554f2f425c3d1d43ddd3d9f/melon/resize/500/optimize/90",
    "isNew": false,
    "lastPos": 1,
    "rank": 1,
    "title": "Kitsch"
}
>>> print(chart.name)
멜론차트_TOP100NOW
>>> print(chart.date)
2023-04-09 20:00:00

ChartData Arguments

  • imageSize – The size of cover image for the track. (default: 256)
  • fetch – A boolean value that indicates whether to retrieve the chart data immediately. If set to False, you can fetch the data later using the fetchEntries() method.

Chart entry attributes

ChartEntry can be accessed using the ChartData[index] syntax. A ChartEntry instance has the following attributes:

  • title – The title of the track
  • artist – The name of the artist
  • image – The URL of the cover image for the track
  • lastPos - The track's last position on the previous period.
  • rank – The track's current rank position on the chart.
  • isNew – Whether the track is new to the chart.

Dependencies

License

This project is licensed under the MIT License.

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

melon-chart.py-1.0.0.tar.gz (4.1 kB view details)

Uploaded Source

Built Distribution

melon_chart.py-1.0.0-py3-none-any.whl (4.5 kB view details)

Uploaded Python 3

File details

Details for the file melon-chart.py-1.0.0.tar.gz.

File metadata

  • Download URL: melon-chart.py-1.0.0.tar.gz
  • Upload date:
  • Size: 4.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.6

File hashes

Hashes for melon-chart.py-1.0.0.tar.gz
Algorithm Hash digest
SHA256 fd8339461980434c478910140c523b7bcf218e4caa7dbfa00d5d2ee82d6e0e03
MD5 07d840ca6da0ba1edd64a0a1b018da84
BLAKE2b-256 22143282372b81def243cc7313e429e385d937442d9c47c113b7ee75d256b4a6

See more details on using hashes here.

File details

Details for the file melon_chart.py-1.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for melon_chart.py-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 f28b846a4d037228d5e372ec175f1d542a07406c0dad565aa32aad80ce4612f7
MD5 c90d11649aa8b3c41344a4078a667828
BLAKE2b-256 032ad65215ef9cfd727dca5b6c1ace9e68eb808225b7285dcbe22e83a3aa769b

See more details on using hashes here.

Supported by

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