Python client library for interacting with the TimeAtlas API.
The Time Atlas is a comprehensive platform for managing and analyzing historical geospatial data. This Python client provides a convenient interface for accessing TimeAtlas API endpoints and working with Research Data Entities (RDEs).
pip install time-atlas-pythonfrom timeatlas import TimeAtlas
# Initialize the client
client = TimeAtlas(api_url='https://your-timeatlas-instance.com/v1')
# Fetch a single RDE object
entity = client.get_single_rde_object('historical-records', 'uuid-here')- RDE Support: Work with multiple Research Data Entity types:
- Historical Records (HR)
- Observations (OBS)
- Points of Interest (POI)
- Geometries (GEOM)
- Datasets
- Maps
- Layers
- Areas
- Type Safety: Comprehensive type hints and dataclass-based models
- Geospatial Integration: Native support for Shapely geometries
- Python 3.12 or higher
- requests >= 2.31.0
- pandas >= 2.0.0
- shapely >= 2.0.0
# Clone the repository
git clone https://github.com/epfl-timemachine/time-atlas-python.git
cd time-atlas-python
# Install in development mode with dev dependencies
pip install -e ".[dev]"python -m pytestRun the complete suite with branch coverage:
python -m pytest \
--cov=timeatlas \
--cov-report=term-missing \
--cov-report=html \
--cov-report=xmlThe project enforces a minimum total coverage of 95%. The HTML report is written to
htmlcov/index.html, and the XML report is written to coverage.xml.
Tests use deterministic fixtures, mocked HTTP responses, temporary files, and representative
RDE samples from test/data; they do not require a running TimeAtlas API.
The test workflow runs the suite with coverage on Python 3.12 and 3.13 for every push and pull request. Coverage XML reports are uploaded as workflow artifacts for each supported Python version.
black timeatlas/Documentation is accessible through epfl-timemachine.github.io/time-atlas-python
This program is provided as open source under the GNU Affero General Public License v3 or later.