API des Dokumentations- und Informationssystems für Parlamentsmaterialien
This Python package is automatically generated by the OpenAPI Generator project:
- API version: 1.2
- Package version: 0.1.1
- Build package: org.openapitools.codegen.languages.PythonClientCodegen
Python >= 3.6
pip install deutschland[dip_bundestag]poetry add deutschland -E dip_bundestagInstall via Setuptools.
python setup.py install --user(or sudo python setup.py install to install the package for all users)
Import the package:
from deutschland import dip_bundestagPlease follow the installation procedure and then run the following:
import time
from deutschland import dip_bundestag
from pprint import pprint
from deutschland.dip_bundestag.api import aktivitten_api
from deutschland.dip_bundestag.model.aktivitaet import Aktivitaet
from deutschland.dip_bundestag.model.aktivitaet_list_response import AktivitaetListResponse
from deutschland.dip_bundestag.model.get_vorgang404_response import GetVorgang404Response
from deutschland.dip_bundestag.model.get_vorgang_list400_response import GetVorgangList400Response
from deutschland.dip_bundestag.model.get_vorgang_list401_response import GetVorgangList401Response
from deutschland.dip_bundestag.model.zuordnung import Zuordnung
# Defining the host is optional and defaults to https://search.dip.bundestag.de/api/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = dip_bundestag.Configuration(
host = "https://search.dip.bundestag.de/api/v1"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: ApiKeyHeader
configuration.api_key['ApiKeyHeader'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyHeader'] = 'Bearer'
# Configure API key authorization: ApiKeyQuery
configuration.api_key['ApiKeyQuery'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyQuery'] = 'Bearer'
# Enter a context with an instance of the API client
with dip_bundestag.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = aktivitten_api.AktivittenApi(api_client)
id = 1 # int |
format = "json" # str | Steuert das Datenformat der Antwort, möglich sind JSON (voreingestellt) oder XML. (optional) (default to "json")
try:
# Liefert Metadaten zu einer Aktivität
api_response = api_instance.get_aktivitaet(id, format=format)
pprint(api_response)
except dip_bundestag.ApiException as e:
print("Exception when calling AktivittenApi->get_aktivitaet: %s\n" % e)All URIs are relative to https://search.dip.bundestag.de/api/v1
| Class | Method | HTTP request | Description |
|---|---|---|---|
| AktivittenApi | get_aktivitaet | GET /aktivitaet/{id} | Liefert Metadaten zu einer Aktivität |
| AktivittenApi | get_aktivitaet_list | GET /aktivitaet | Liefert eine Liste von Metadaten zu Aktivitäten |
| DrucksachenApi | get_drucksache | GET /drucksache/{id} | Liefert Metadaten zu einer Drucksache |
| DrucksachenApi | get_drucksache_list | GET /drucksache | Liefert eine Liste von Metadaten zu Drucksachen |
| DrucksachenApi | get_drucksache_text | GET /drucksache-text/{id} | Liefert Volltext und Metadaten zu einer Drucksache |
| DrucksachenApi | get_drucksache_text_list | GET /drucksache-text | Liefert eine Liste von Volltexten und Metadaten zu Drucksachen |
| PersonenstammdatenApi | get_person | GET /person/{id} | Liefert Personenstammdaten zu einer Person |
| PersonenstammdatenApi | get_person_list | GET /person | Liefert eine Liste von Personenstammdaten |
| PlenarprotokolleApi | get_plenarprotokoll | GET /plenarprotokoll/{id} | Liefert Metadaten zu einem Plenarprotokoll |
| PlenarprotokolleApi | get_plenarprotokoll_list | GET /plenarprotokoll | Liefert eine Liste von Metadaten zu Plenarprotokollen |
| PlenarprotokolleApi | get_plenarprotokoll_text | GET /plenarprotokoll-text/{id} | Liefert Volltext und Metadaten zu einem Plenarprotokoll |
| PlenarprotokolleApi | get_plenarprotokoll_text_list | GET /plenarprotokoll-text | Liefert eine Liste von Volltexten und Metadaten zu Plenarprotokollen |
| VorgangspositionenApi | get_vorgangsposition | GET /vorgangsposition/{id} | Liefert Metadaten zu einer Vorgangsposition |
| VorgangspositionenApi | get_vorgangsposition_list | GET /vorgangsposition | Liefert eine Liste von Metadaten zu Vorgangspositionen |
| VorgngeApi | get_vorgang | GET /vorgang/{id} | Liefert Metadaten zu einem Vorgang |
| VorgngeApi | get_vorgang_list | GET /vorgang | Liefert eine Liste von Metadaten zu Vorgängen |
- Aktivitaet
- AktivitaetAnzeige
- AktivitaetListResponse
- AktivitaetListResponseAllOf
- Beschlussfassung
- Bundesland
- Deskriptor
- DokumentTextBase
- Drucksache
- DrucksacheAutorenAnzeigeInner
- DrucksacheListResponse
- DrucksacheListResponseAllOf
- DrucksacheText
- DrucksacheTextListResponse
- DrucksacheTextListResponseAllOf
- Fundstelle
- GetVorgang404Response
- GetVorgangList400Response
- GetVorgangList401Response
- Inkrafttreten
- ListResponseBase
- Person
- PersonListResponse
- PersonListResponseAllOf
- PersonRole
- Plenarprotokoll
- PlenarprotokollListResponse
- PlenarprotokollListResponseAllOf
- PlenarprotokollText
- PlenarprotokollTextListResponse
- PlenarprotokollTextListResponseAllOf
- Quadrant
- Ressort
- Ueberweisung
- Urheber
- Verkuendung
- Vorgang
- VorgangDeskriptor
- VorgangDeskriptorAllOf
- VorgangListResponse
- VorgangListResponseAllOf
- VorgangVerlinkung
- Vorgangsbezug
- Vorgangsposition
- VorgangspositionListResponse
- VorgangspositionListResponseAllOf
- Vorgangspositionbezug
- VorgangspositionbezugAllOf
- Zuordnung
- Type: API key
- API key parameter name: Authorization
- Location: HTTP header
- Type: API key
- API key parameter name: apikey
- Location: URL query string
If the OpenAPI document is large, imports in dip_bundestag.apis and dip_bundestag.models may fail with a RecursionError indicating the maximum recursion limit has been exceeded. In that case, there are a couple of solutions:
Solution 1: Use specific imports for apis and models like:
from deutschland.dip_bundestag.api.default_api import DefaultApifrom deutschland.dip_bundestag.model.pet import Pet
Solution 2: Before importing the package, adjust the maximum recursion limit as shown below:
import sys
sys.setrecursionlimit(1500)
from deutschland import dip_bundestag
from deutschland.dip_bundestag.apis import *
from deutschland.dip_bundestag.models import *