Skip to main content

Anisette.py

An anisette data provider, but in a Python package! Based on pyprovision-uc.

Documentation

Usage

Anisette.py has a very simple API. You, the developer, are responsible for initializing, loading and saving the state of the Anisette engine, either to memory or to disk. If you want to keep your provisioning session, you MUST save and load the state properly. If you don't, you WILL run into errors. See the docs for information on how to do this.

Initialization

The Anisette provider must be initialized with libraries from the Apple Music APK. To save you some effort, a Cloudflare Worker has been set up to provide easy access to these libraries. By default, the Anisette.py will download this library bundle (~3 megabytes) when initializing a new session, but you can also provide an APK file or downloaded bundle yourself.

from anisette import Anisette

# First use: download from Cloudflare
ani = Anisette.init()

# After download, save library bundle to disk
ani.save_libs("libs.bin")

# For future use, initialize from disk:
ani2 = Anisette.init("libs.bin")

Getting Anisette data

The first time you call this method will probably take a few seconds since the virtual device needs to be provisioned first. After provisioning, getting Anisette data should be quite fast.

ani.get_data()

# Returns:
# {
#   'X-Apple-I-MD': '...',
#   'X-Apple-I-MD-M': '...',
#   ...
# }

Credits

A huuuge portion of the work has been done by @JayFoxRox in their pyprovision-uc project. I just rewrote most of their code :-)

Release files for Anisette 1.2.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for Anisette 1.2.4
File Size Uploaded
anisette-1.2.4.tar.gz 92.4 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for Anisette 1.2.4
File Interpreter ABI Platform
anisette-1.2.4-py3-none-any.whl Python 3 none any Details

Total release size: 124.6 kB

Release files / anisette-1.2.4.tar.gz

Download URL anisette-1.2.4.tar.gz
Size 92.4 kB
Tags Source
SHA-256 checksum
How to use checksums
061866f05fdbde2990d2e2617457264a20ca12679217941bb38b5fefef492e62
BLAKE2b-256 checksum
How to use checksums
3e1b5e110b7243fc695459e52888548cac693d25da97ab05640003f401994ad4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.8.19

Release files / anisette-1.2.4-py3-none-any.whl

Download URL anisette-1.2.4-py3-none-any.whl
Size 32.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f61e620aa736f0cac0ca102dd44a02cc2caea1a072eab0f1ef7f2d8b534e03dc
BLAKE2b-256 checksum
How to use checksums
c4382f8b4c7d97d3eca76c1794348ea142bba393da11950ed836e741692d133e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.8.19

Release history Release notifications | RSS feed

This release

1.2.4 This release

2 release files

1.2.3

2 release files

1.2.2

2 release files

1.2.1

2 release files

1.2.0

2 release files

1.1.1

2 release files

1.1.0

2 release files

1.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page