Skip to main content

Python library for Amapche XML-API

Project description

AMPACHE LIBRARY FOR PYTHON3

Upload to PyPI
https://github.com/ampache/python3-ampache/workflows/Upload%20Python%20Package/badge.svg

INFO

A python3 library for interaction with your Ampache server using the XML API https://github.com/ampache/ampache/wiki/API

If you run a develop server you now have access to JSON as well!

Code examples and scripts are available from github

INSTALL

You can now install from pip directly:

pip3 install -U ampache

EXAMPLES

Practical example:

import time
import ampache

# user variables
ampache_url = 'https://music.server'
my_api_key  = 'mysuperapikey'
user        = 'myusername'

# processed details
encrypted_key = ampache.encrypt_string(my_api_key, user)
ampache_api   = ampache.handshake(ampache_url, encrypted_key)

if ampache_api:
    # Scrobble a music track to your ampache server
    Process(target=ampache.scrobble,
            args=(ampache_url, ampache_api, 'Hear.Life.Spoken', 'Sub Atari Knives', 'Unearthed',
            '', '', int(time.time()))).start()

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

ampache-4.4.1.tar.gz (24.6 kB view details)

Uploaded Source

Built Distribution

ampache-4.4.1-py3-none-any.whl (24.6 kB view details)

Uploaded Python 3

File details

Details for the file ampache-4.4.1.tar.gz.

File metadata

  • Download URL: ampache-4.4.1.tar.gz
  • Upload date:
  • Size: 24.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.10.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.10.2

File hashes

Hashes for ampache-4.4.1.tar.gz
Algorithm Hash digest
SHA256 a231cef1401814c08d689a8b6d012c98754baea4a1bd0a17e2705c05f7acd8ec
MD5 92df2394a31323109c2bb42f42a509e0
BLAKE2b-256 14eb58e62cc9a19fdaba833c937ed15f0e0d78073d95848de22a24db01a3f19a

See more details on using hashes here.

File details

Details for the file ampache-4.4.1-py3-none-any.whl.

File metadata

  • Download URL: ampache-4.4.1-py3-none-any.whl
  • Upload date:
  • Size: 24.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.10.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.10.2

File hashes

Hashes for ampache-4.4.1-py3-none-any.whl
Algorithm Hash digest
SHA256 99d92a4afce99c5200279ca14e3d0236f2ed37837d01887b89187d21f63216c4
MD5 bca2ebfe4283b8537b16620bb136e61f
BLAKE2b-256 11f4f964f9108e0263e35a87786149c9f1772c304c634e6f392afc96f7d470b6

See more details on using hashes here.

Supported by

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