Skip to main content

Python wrapper client for the Oireachtas public API

Project description

Oireachtas API Wrapper

Python client maintained by Aaron Bowman for the public Oireachtas API. The package exposes thin helper classes that make it easy to call official endpoints for legislation, debates, members, questions, and other parliamentary data.

Features

  • Lightweight wrappers around the official Oireachtas REST endpoints
  • Optional convenience wrapper for resolving endpoint names to URLs
  • Basic error mapping for common HTTP status codes
  • Opt-in helper for file-based logging during local development

Installation

Install from PyPI (or your preferred index):

pip install OireachtasAPIWrapper

Using uv:

uv add OireachtasAPIWrapper

Quick Start

from OireachtasAPI import API

client = API()
response = client.make_request(
    endpoint="https://api.oireachtas.ie/v1/legislation",
    params={"limit": 5},
)

print(response.json())

Enable basic file logging when you need to trace requests:

from OireachtasAPI import configure_logging

configure_logging()

Local Development

Create an isolated environment and install dev dependencies with uv:

uv sync
uv run pytest

If you prefer standard tooling, pip install -e .[test] provides the same dependencies defined in pyproject.toml.

Contributing

Issues and pull requests are welcome on GitHub. Please open an issue before submitting large changes so we can coordinate work.

License

Released under the MIT License. See LICENSE.txt for details.

Project details


Download files

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

Source Distribution

oireachtasapiwrapper-0.0.2.tar.gz (6.4 kB view details)

Uploaded Source

Built Distribution

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

oireachtasapiwrapper-0.0.2-py3-none-any.whl (6.6 kB view details)

Uploaded Python 3

File details

Details for the file oireachtasapiwrapper-0.0.2.tar.gz.

File metadata

File hashes

Hashes for oireachtasapiwrapper-0.0.2.tar.gz
Algorithm Hash digest
SHA256 f9ab42a3a1109542c979241f8295b35a981e18a1eddc5d69d1c89d22f3993027
MD5 806f1eff341f107fabb2da114112ef62
BLAKE2b-256 1f1dfe78c8e4613a7447bf0c333efc6e809dd9fc7ed9d90b97ac925a0bc02bc7

See more details on using hashes here.

File details

Details for the file oireachtasapiwrapper-0.0.2-py3-none-any.whl.

File metadata

File hashes

Hashes for oireachtasapiwrapper-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 6f1603a327c5073b6052884a32bbe6c97c224bc713d04c88f5c1e6bcac7a30f1
MD5 53c1858de6d8106965f20f1253995116
BLAKE2b-256 8689aa81dbed35c972109af17e79ed013e3a41da6a4ea01451b719c075910337

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