ed-api-client
A Python client for the Ed LMS API, with utilities for analysing student workspace activity.
Installation
pip install ed-api-client
Quick start
from ed_api_client import EdClient
client = EdClient(token="your-api-token")
# Retrieve all students in a course
users = client.get_users(course_id=12345, role="student")
# Retrieve the module/lesson structure
modules = client.get_module_structure(course_id=12345)
for module in modules:
for lesson in module.lessons:
print(lesson.title)
# Fetch and analyse a student's workspace activity
log = client.get_workspace_log(workspace_id="abc123")
files = client.get_scaffold_files(challenge_id=99)
summary = WorkspaceSummary.from_log(files, log)
print(summary.total_active_time)
for file_id, file in summary.file_summaries.items():
print(file.path, file.pasted_proportion, file.cursor_entropy)
Full API reference: https://dmilne.gitlab.io/ed-api-client
Development
Prerequisites
- Python 3.10+
- Poetry
Install Poetry via Homebrew:
brew install poetry
Setup
Clone the repository and install all dependencies (including dev dependencies):
git clone https://gitlab.com/dmilne/ed-api-client.git
cd ed-api-client
poetry install --with dev
Running tests
poetry run pytest tests/ -v
Tests use the responses library to mock HTTP calls — no real Ed credentials are needed.
Viewing the docs locally
poetry run mkdocs serve
Then open http://localhost:8000.
Publishing a new version
-
Bump the version:
poetry version patch # or: minor, major
-
Configure your PyPI token (first time only):
poetry config pypi-token.pypi your-token-here
Get a token at https://pypi.org/manage/account/token/.
-
Build and publish:
poetry publish --build
CI/CD
The GitLab pipeline (.gitlab-ci.yml) runs on every push:
- test — runs
pytestagainst Python 3.11 - pages (main branch only) — builds and deploys the MkDocs site to GitLab Pages at https://dmilne.gitlab.io/ed-api-client
License
MIT
Metadata
Release files for ed-api-client 0.1.9
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| ed_api_client-0.1.9.tar.gz | 24.8 kB | Without provenance | Details for ed_api_client-0.1.9.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| ed_api_client-0.1.9-py3-none-any.whl | Python 3 | none | any | Details for ed_api_client-0.1.9-py3-none-any.whl |
Total release size: 54.3 kB
Release files / ed_api_client-0.1.9.tar.gz
| Download URL | ed_api_client-0.1.9.tar.gz |
|---|---|
| Size | 24.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
4b7f6df5b5f4d485c3104be03df9c20aa33e4ad402405a61d16ec766b454e03b
|
|
BLAKE2b-256 checksum How to use checksums |
55ed9056c72228192ae444c38375d2c52931f2db84d0833a4b6c0943702dc0e2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/2.4.1 CPython/3.14.4 Darwin/24.6.0
|
Release files / ed_api_client-0.1.9-py3-none-any.whl
| Download URL | ed_api_client-0.1.9-py3-none-any.whl |
|---|---|
| Size | 29.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
dd9d35088a31c846c7ce27027b83f35ee212be6c214fb117d9fda0d00266ed83
|
|
BLAKE2b-256 checksum How to use checksums |
3caf228c936917f5ede1cd54324c9fa29055f5368ce6225abfc0618b4c69eac2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/2.4.1 CPython/3.14.4 Darwin/24.6.0
|
Security for ed-api-client 0.1.9
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.