Skip to content

Installation

python-moodle requires Python 3.9+ and can be installed in several ways.

Package name vs. command name

The package is published as python-moodle (that's what you pip install and import py_moodle), and the CLI is available under two equivalent command names: python-moodle (used throughout these docs) and the shorter alias py-moodle. Use whichever you prefer.

pip install python-moodle

Method 2: From Source

Clone the repository and install:

git clone https://github.com/erseco/python-moodle.git
cd python-moodle
pip install .

This makes the python-moodle command (and its py-moodle alias) available system-wide.

Method 3: Development Installation

For development or to get the latest features:

git clone https://github.com/erseco/python-moodle.git
cd python-moodle
pip install -e .

The -e flag installs in "editable" mode, so changes to the source code are immediately available.

Verify Installation

Test that the CLI is properly installed (either command works):

python-moodle --help
# or, equivalently, the shorter alias:
py-moodle --help

You should see the main help screen with available commands.

Next Steps