Skip to main content

Basic wrapper around the https://registry.o2a-data.de/api/ powered by pydantic.

Project description

O2A Registry API Wrapper

pipeline status coverage report Latest Release Ruff Documentation

Basic wrapper around the registry API powered by pydantic.

Note: Currently, rate limited to 100 requests/sec

Example Usage

from o2a_registry.api import ProductionAPI  # registry.o2a-data.de
from o2a_registry.api import SandboxAPI     # registry.sandbox.o2a-data.de 

event_types = await ProductionAPI.get_vocables(where="vocableGroup.id==8")

await ProductionAPI.close()

Custom endpoint:

from o2a_registry.api import RegistryApi

api = RegistryApi("example.com", ssl=True)

Further examples can be found in examples

Install

Currently, only available from the gitlab repository:

pip install o2a.registry.python.lib

Setting up the project locally

This project uses the package manager uv

git clone git@gitlab.awi.de:o2a/registry/o2a.registry.python.lib.git
cd o2a.registry.python.lib

uv sync

This creates a virtual environment in o2a.registry.python.lib/.venv/.

The code formatter Ruff is used to ensure proper code formatting. Use uv tool install ruff to install and uvx ruff format . to run.

Before pushing changes, please ensure that your code works and is well formated. You can do this with:

uvx ruff check --fix
uvx ruff format

uv run mypy o2a_registry
uv run pytest ./tests/unit

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

o2a_registry_python_lib-0.1.1-py3-none-any.whl (24.3 kB view details)

Uploaded Python 3

File details

Details for the file o2a_registry_python_lib-0.1.1-py3-none-any.whl.

File metadata

File hashes

Hashes for o2a_registry_python_lib-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 26022e8c884519ccb3b125a8515f8c5e09ec63e5fefc9a1265c33282f0d7cb45
MD5 40ef3d057561f4ffd4526ce2c5f25779
BLAKE2b-256 3c4a14cee5a403db1f87ca7294e249076e842843dd68491b4012ca92d356faad

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page