pydipapi is a Python package that provides a simple and convenient wrapper around the API of the German Bundestag. This package allows developers to easily access various endpoints of the Bundestag's API to retrieve information about legislative processes, documents, and more.
Note: The author is not affiliated with the German Bundestag or any of its institutions.
For more information on the API and how to obtain an API key, please refer to the official documentation.
This project is licensed under the GPLv3 License.
It is recommended to use a virtual environment. You can install the package using pip:
pip install pydipapi
Here's a quick example of how to use the package:
from pydipapi import DipAnfrage
# Initialize with your API key
dip = DipAnfrage(apikey='your_api_key_here')
# Retrieve a list of persons
persons = dip.get_person(anzahl=10)
print(persons)
# Retrieve a single person by ID
person = dip.get_person_id(id=7355)
print(person)
{'id': '7355', 'nachname': 'Larem', 'vorname': 'Andreas', 'typ': 'Person', 'wahlperiode': 20, 'aktualisiert': '2022-07-26T19:57:10+02:00', 'titel': 'Andreas Larem, MdB, SPD', 'datum': '2024-09-26', 'basisdatum': '2022-01-27'}
Contributions are welcome! Please feel free to submit a pull request or open an issue if you have suggestions for improvements or find any bugs.
For any inquiries, please contact the package author via GitHub.