Features • Dependencies • How To Use
- Get Metadata (title, year, episodes, seasons...) with official Netflix api
- Get medias (videos, audios, audio descriptions, subtitles...)
- Decrypt Widevine DRM protected content
- Automatically mux all your tracks
- Nice pre-made format for file names
- Very fast multi-connection downloads
make sure to add these in the PATH on in your working directory
-
Extract Cookies from Netflix:
- Use an extension like cookie.txt to extract cookies from Netflix.
- Save the extracted cookie file in your working directory.
-
Obtain a Private L3 CDM (Content Decryption Module):
- Option 1: Extract it yourself from an Android device using the tool.
- Option 2: Extract it yourself from an Android emulator. how to
-
Setup the L3 CDM:
- Place the L3 CDM file, named as device_name, inside the devices folder in your working environment.
Working folder example:
│ phantomflix/
│ cookies.txt
│ languages.txt
│ setup.py
│ main.py
└───devices/
└───<device name>/
device_client_id_blob
device_private_key
Now open a terminal on the working dir and run:
py setup.py install
py main.py
where main.py
looks like this:
from phantomflix import NetflixClient
import asyncio
client = NetflixClient(
email="", # Insert your email here
password="", # Insert your password here
device="<device_name>", # Insert your CDM folder name here
quality=1080,
audio_language=["Italian"],
language="it-IT", # Metadata language
video_profile="high",
quiet=False,
)
async def main():
# movie
viewables = client.get_viewables(81500601) # for serie add season=<season_number>, episode=<episode_number>
for viewable in viewables: print(viewable.title)
await viewables[0].download()
asyncio.run(main())
We also accept donations, so we can keep this project up!