ParentZone holds your photos and videos, but offers no clear export path for your own data. I disagree with that — these are your family's memories, and without a way to get them out there's a real risk of losing them (for example if your account or the service goes away). This tool exists to let you download and keep your own copy.
This project is a Python command-line script to fetch and download media items and gallery content from the ParentZone API (parentzone.me).
- Fetch posts and gallery items from the API.
- Download media files to a local directory.
- Automatically handles API key retrieval from environment variables or a local file.
- Updates the creation date on the downloaded files based on the metadata.
Pre-built, standalone executables are published automatically for Windows, macOS, and Linux on every release — you don't need Python installed to use them.
- Go to the Releases page.
- Download the zip for your operating system from the latest release:
release-media-downloader-windows-latest.zip— Windowsrelease-media-downloader-macos-latest.zip— macOSrelease-media-downloader-ubuntu-latest.zip— Linux
- Unzip it. Inside you'll find the executable (
media-downloaderon macOS/Linux,media-downloader.exeon Windows). - Run it. On first launch it will prompt you for your API key (see Extracting the API Key) and save it alongside the binary in
config.ini. Media is downloaded into anout/folder next to the executable.
macOS/Windows note: because these binaries aren't code-signed, the OS may warn that the app is from an unidentified developer. On macOS, right-click the binary → Open to allow it; on Windows, choose More info → Run anyway on the SmartScreen prompt.
If you'd rather run from source or build the binary yourself, see the sections below.
- Python 3.7 or higher
requestslibrary (version 2.25.1 or higher)python-dateutillibrary (version 2.9.0 or higher)
-
Clone the Repository:
git clone https://github.com/skycubeuk/media-downloader.git cd media-downloader -
Install Dependencies: Install the required Python libraries:
pip install -r requirements.txt
-
Set Up the API Key: Copy the example config and add your key:
cp config.ini.example config.ini
Then edit
config.iniand setapi_key.config.iniis gitignored so your key is never committed. If you don't create it, the script will prompt you for the key on first run and save it toconfig.ini.Alternatively, you can set the
API_KEYenvironment variable (this takes precedence overconfig.ini):export API_KEY=your_api_keyIf you don't know how to extract the API key, refer to the Extracting the API Key section below.
You can package the script so it runs without installing Python by using the bundled PyInstaller helper. Run the build on the operating system you want to target:
python build.pyThe resulting binary is placed in dist/ (e.g., dist/media-downloader).
The script uses a config.ini file to store configuration settings, including the API key and directory paths. If the API key is not set in the environment or the config.ini file, the script will prompt you to enter it and save it automatically.
[Credentials]
api_key=your_api_key
[Paths]
log_dir=./log
out_dir=./out[Credentials]: Stores the API key.[Paths]: Specifies the directories for logs and output files.
Run the script using:
python main.pyThe script will:
- Fetch posts and gallery items from the API.
- Download media files to the
./outdirectory.
You can override paths and the posts query without editing the source:
python main.py --out ./out --log ./log --query 'typeIDs[]=14&typeIDs[]=12' --api-key YOUR_KEYTo extract the API key from the web application, follow these steps:
-
Open the Web Application:
- Navigate to the web application where the API is being used.
-
Open Developer Tools:
- Press
F12orCtrl+Shift+I(Windows/Linux) orCmd+Option+I(Mac) to open the browser's developer tools.
- Press
-
Go to the Network Tab:
- Click on the "Network" tab in the developer tools.
-
Filter Requests:
- Reload the page and look for network requests. Use the filter box to search for requests to the API endpoint (e.g.,
https://api.parentzone.me).
- Reload the page and look for network requests. Use the filter box to search for requests to the API endpoint (e.g.,
-
Inspect Headers:
- Click on one of the requests to the API. In the "Headers" section, look for the
x-api-keyheader under "Request Headers".
- Click on one of the requests to the API. In the "Headers" section, look for the
-
Copy the API Key:
- Copy the value of the
x-api-keyheader.
- Copy the value of the
-
Save the API Key:
- Paste the API key into the
config.inifile or set it as an environment variable.
- Paste the API key into the
This project is licensed under the MIT License.