"""
    Eco-Counter: Eco-Visio-API

    API zum [Eco-Visio-Dashboard](https://data.eco-counter.com/ParcPublic/?id=4586) von Eco-Counter. Eco-Counter ist ein Technologieunternehmen mit Hauptsitz in Lannion, in der Bretagne. Zum Unternehmen zählen Filialen in Montreal (Kanada) und in Köln. Das Untenehmen betreibt u.a. Fahrrad- und Fußgängerzähler in unterschiedlichen Ländern, die in zahlreichen deutschen Städten z.B. Angaben wie \"Radfahrende heute\" oder \"Radfahrende dieses Jahr\" ausweisen. Teilweise sind die Zähler auch vollständig unterirdisch verlegt worden (z.B. zahlreiche Fahrradzählstellen in Hessen, vgl. https://data.eco-counter.com/ParcPublic/?id=8080).   Generell findet man in Deutschland überwiegend Fahrradzähler. In Rostock gibt es daneben auch Fußgängerzähler (https://data.eco-counter.com/ParcPublic/?id=888), ebenso in Schwerin (https://data.eco-counter.com/ParcPublic/?id=6116), in Greifswald (https://data.eco-counter.com/ParcPublic/?id=6997) oder in Böblingen (https://data.eco-counter.com/ParcPublic/?id=6811). In Ludwigsburg gibt es sogar separat ausgewiesene Autozähler von Eco-Counter (https://data.eco-counter.com/ParcPublic/?id=6011).   Eco-Visio ist ein Analysetool zur Auswertung der Daten. Auf dem Dashboard können die Zahlen unterschiedlicher Zähler eingesehen und verglichen werden.   # noqa: E501

    The version of the OpenAPI document: 1.0.0
    Contact: kontakt@bund.dev
    Generated by: https://openapi-generator.tech
"""


import re  # noqa: F401
import sys  # noqa: F401

from deutschland.EcoVisio.api_client import ApiClient
from deutschland.EcoVisio.api_client import Endpoint as _Endpoint
from deutschland.EcoVisio.model.all_counter import AllCounter
from deutschland.EcoVisio.model_utils import (  # noqa: F401
    check_allowed_values,
    check_validations,
    date,
    datetime,
    file_type,
    none_type,
    validate_and_convert_types,
)


class DefaultApi(object):
    """NOTE: This class is auto generated by OpenAPI Generator
    Ref: https://openapi-generator.tech

    Do not edit the class manually.
    """

    def __init__(self, api_client=None):
        if api_client is None:
            api_client = ApiClient()
        self.api_client = api_client
        self.zaehler_endpoint = _Endpoint(
            settings={
                "response_type": (AllCounter,),
                "auth": [],
                "endpoint_path": "/pbl/publicwebpageplus/{idOrganisme}",
                "operation_id": "zaehler",
                "http_method": "GET",
                "servers": None,
            },
            params_map={
                "all": [
                    "id_organisme",
                    "with_null",
                    "end",
                    "begin",
                    "pratique",
                ],
                "required": [
                    "id_organisme",
                ],
                "nullable": [],
                "enum": [
                    "id_organisme",
                ],
                "validation": [],
            },
            root_map={
                "validations": {},
                "allowed_values": {
                    ("id_organisme",): {
                        "4586": 4586,
                        "5024": 5024,
                        "8080": 8080,
                        "6365": 6365,
                        "4728": 4728,
                        "677": 677,
                        "4701": 4701,
                        "6011": 6011,
                        "4206": 4206,
                        "607": 607,
                        "4702": 4702,
                        "857": 857,
                        "888": 888,
                        "5417": 5417,
                        "5972": 5972,
                        "7119": 7119,
                        "4197": 4197,
                        "7581": 7581,
                        "7224": 7224,
                        "4729": 4729,
                        "7241": 7241,
                        "751": 751,
                        "6109": 6109,
                        "4699": 4699,
                        "6076": 6076,
                        "6116": 6116,
                        "7642": 7642,
                        "6135": 6135,
                        "6997": 6997,
                        "6471": 6471,
                        "7058": 7058,
                        "4626": 4626,
                        "6603": 6603,
                        "6481": 6481,
                        "6811": 6811,
                        "6150": 6150,
                    },
                },
                "openapi_types": {
                    "id_organisme": (int,),
                    "with_null": (bool,),
                    "end": (str,),
                    "begin": (str,),
                    "pratique": (int,),
                },
                "attribute_map": {
                    "id_organisme": "idOrganisme",
                    "with_null": "withNull",
                    "end": "end",
                    "begin": "begin",
                    "pratique": "pratique",
                },
                "location_map": {
                    "id_organisme": "path",
                    "with_null": "query",
                    "end": "query",
                    "begin": "query",
                    "pratique": "query",
                },
                "collection_format_map": {},
            },
            headers_map={
                "accept": ["application/json"],
                "content_type": [],
            },
            api_client=api_client,
        )
        self.zaehlerdaten_endpoint = _Endpoint(
            settings={
                "response_type": ([str],),
                "auth": [],
                "endpoint_path": "/pbl/publicwebpageplus/data/1",
                "operation_id": "zaehlerdaten",
                "http_method": "GET",
                "servers": None,
            },
            params_map={
                "all": [
                    "id_organisme",
                    "id_pdc",
                    "interval",
                    "flow_ids",
                    "fin",
                    "debut",
                ],
                "required": [
                    "id_organisme",
                    "id_pdc",
                    "interval",
                    "flow_ids",
                ],
                "nullable": [],
                "enum": [
                    "id_organisme",
                    "interval",
                ],
                "validation": [
                    "fin",
                    "debut",
                ],
            },
            root_map={
                "validations": {
                    ("fin",): {
                        "regex": {
                            "pattern": r"^(0[1-9]|[12][0-9]|3[01])\/(0[1-9]|1[012])\/(\d{4})$",  # noqa: E501
                        },
                    },
                    ("debut",): {
                        "regex": {
                            "pattern": r"^(0[1-9]|[12][0-9]|3[01])\/(0[1-9]|1[012])\/(\d{4})$",  # noqa: E501
                        },
                    },
                },
                "allowed_values": {
                    ("id_organisme",): {
                        "4586": 4586,
                        "5024": 5024,
                        "8080": 8080,
                        "6365": 6365,
                        "4728": 4728,
                        "677": 677,
                        "4701": 4701,
                        "6011": 6011,
                        "4206": 4206,
                        "607": 607,
                        "4702": 4702,
                        "857": 857,
                        "888": 888,
                        "5417": 5417,
                        "5972": 5972,
                        "7119": 7119,
                        "4197": 4197,
                        "7581": 7581,
                        "7224": 7224,
                        "4729": 4729,
                        "7241": 7241,
                        "751": 751,
                        "6109": 6109,
                        "4699": 4699,
                        "6076": 6076,
                        "6116": 6116,
                        "7642": 7642,
                        "6135": 6135,
                        "6997": 6997,
                        "6471": 6471,
                        "7058": 7058,
                        "4626": 4626,
                        "6603": 6603,
                        "6481": 6481,
                        "6811": 6811,
                        "6150": 6150,
                    },
                    ("interval",): {"1": 1, "2": 2, "3": 3, "4": 4, "5": 5, "6": 6},
                },
                "openapi_types": {
                    "id_organisme": (int,),
                    "id_pdc": (int,),
                    "interval": (int,),
                    "flow_ids": (str,),
                    "fin": (str,),
                    "debut": (str,),
                },
                "attribute_map": {
                    "id_organisme": "idOrganisme",
                    "id_pdc": "idPdc",
                    "interval": "interval",
                    "flow_ids": "flowIds",
                    "fin": "fin",
                    "debut": "debut",
                },
                "location_map": {
                    "id_organisme": "query",
                    "id_pdc": "query",
                    "interval": "query",
                    "flow_ids": "query",
                    "fin": "query",
                    "debut": "query",
                },
                "collection_format_map": {},
            },
            headers_map={
                "accept": ["application/json"],
                "content_type": [],
            },
            api_client=api_client,
        )

    def zaehler(self, id_organisme=4586, **kwargs):
        """Zähler  # noqa: E501

        Alle Zähler eines Trägers mit ID idOrganisme (z.B. 4586, 20 oder 8080). Eine Übersicht über gültige Ausprägungen des Parameters idOrganisme und deren Bedeutung gibt die Tabelle unter https://github.com/bundesAPI/eco-visio-api/blob/main/eco-visio-api_2022-06-13.csv (Stand 13.06.2022). Einige idOrganisme sind deutschen Bundesländern und Städten zugeordnet: 8080=Hessen, 6365=Mecklenburg-Vorpommern, 4728=Berlin, 677=Köln, 4701=Bonn, 6011=Ludwigsburg, 4206=Heidelberg, 607=Stuttgart, 4702=Rhein-Sieg-Kreis, 857=Düsseldorf, 888=Rostock, 5417=Augsburg, 5972=Leipzig, 7119=Bielefeld, 4197=Mannheim, 7581=Reutlingen, 7224=Hürth, 4729=Würzburg, 7241=Norderstedt, 751=Freiburg, 6109=Oberbergischer Kreis und Rheinisch-Bergischer Kreis, 4699=Rheinisch-Bergischer Kreis und Oberbergischer Kreis, 6076=Oberhausen, 6116=Schwerin, 7642=Leverkusen, 6135=Goslar, 6997=Greifswald, 6471=Ludwigshafen, 7058=Siegen, 4626=Essen, 6603=Bochum, 6481=Aschaffenburg, 6811=Böblingen, 6150=Dortmund.   Außerdem sind Zähler in deutschen Städten ausgewiesen unter idOrganisme 4586 (='Bike Count Display Interactive Map') und 5024 (='National Database Demo').   # noqa: E501
        This method makes a synchronous HTTP request by default. To make an
        asynchronous HTTP request, please pass async_req=True

        >>> thread = api.zaehler(id_organisme=4586, async_req=True)
        >>> result = thread.get()

        Args:
            id_organisme (int): Träger ID. defaults to 4586, must be one of [4586]

        Keyword Args:
            with_null (bool): Parameter ohne bekannten/dokumentierten Effekt.. [optional]
            end (str): Spätestes interessierendes Datum (z.B. 26/05/2022).. [optional]
            begin (str): Frühestes interessierendes Datum (z.B. 01/01/2021).. [optional]
            pratique (int): pratique i.S.v. interessierende Zählerart (z.B. 1=Fußgänger,2=Fahrräder, oder 12=Sternchen). [optional]
            _return_http_data_only (bool): response data without head status
                code and headers. Default is True.
            _preload_content (bool): if False, the urllib3.HTTPResponse object
                will be returned without reading/decoding response data.
                Default is True.
            _request_timeout (int/float/tuple): timeout setting for this request. If
                one number provided, it will be total request timeout. It can also
                be a pair (tuple) of (connection, read) timeouts.
                Default is None.
            _check_input_type (bool): specifies if type checking
                should be done one the data sent to the server.
                Default is True.
            _check_return_type (bool): specifies if type checking
                should be done one the data received from the server.
                Default is True.
            _spec_property_naming (bool): True if the variable names in the input data
                are serialized names, as specified in the OpenAPI document.
                False if the variable names in the input data
                are pythonic names, e.g. snake case (default)
            _content_type (str/None): force body content-type.
                Default is None and content-type will be predicted by allowed
                content-types and body.
            _host_index (int/None): specifies the index of the server
                that we want to use.
                Default is read from the configuration.
            _request_auths (list): set to override the auth_settings for an a single
                request; this effectively ignores the authentication
                in the spec for a single request.
                Default is None
            async_req (bool): execute request asynchronously

        Returns:
            AllCounter
                If the method is called asynchronously, returns the request
                thread.
        """
        kwargs["async_req"] = kwargs.get("async_req", False)
        kwargs["_return_http_data_only"] = kwargs.get("_return_http_data_only", True)
        kwargs["_preload_content"] = kwargs.get("_preload_content", True)
        kwargs["_request_timeout"] = kwargs.get("_request_timeout", None)
        kwargs["_check_input_type"] = kwargs.get("_check_input_type", True)
        kwargs["_check_return_type"] = kwargs.get("_check_return_type", True)
        kwargs["_spec_property_naming"] = kwargs.get("_spec_property_naming", False)
        kwargs["_content_type"] = kwargs.get("_content_type")
        kwargs["_host_index"] = kwargs.get("_host_index")
        kwargs["_request_auths"] = kwargs.get("_request_auths", None)
        kwargs["id_organisme"] = id_organisme
        return self.zaehler_endpoint.call_with_http_info(**kwargs)

    def zaehlerdaten(self, id_pdc, interval, flow_ids, id_organisme=4586, **kwargs):
        """Zählerdaten  # noqa: E501

        Werte für einen spezifischen Fahrradzählers mit ID idPdc (z.B. 100125116) der als GET-Parameter zu spezifizieren ist (optional auch ergänzend als Pfad-Parameter statt der 1).  # noqa: E501
        This method makes a synchronous HTTP request by default. To make an
        asynchronous HTTP request, please pass async_req=True

        >>> thread = api.zaehlerdaten(id_pdc, interval, flow_ids, id_organisme=4586, async_req=True)
        >>> result = thread.get()

        Args:
            id_pdc (int): ID des Fahrradzählers
            interval (int): Aggregationsintervall (6=Monate, 5=Wochen, 4=Tage, ...).
            flow_ids (str): pratique-ID mit Semikolon getrennt
            id_organisme (int): Träger ID. defaults to 4586, must be one of [4586]

        Keyword Args:
            fin (str): Spätestes interessierendes Datum (z.B. '26/05/2022').. [optional]
            debut (str): Frühestes interessierendes Datum (z.B. '01/01/2021').. [optional]
            _return_http_data_only (bool): response data without head status
                code and headers. Default is True.
            _preload_content (bool): if False, the urllib3.HTTPResponse object
                will be returned without reading/decoding response data.
                Default is True.
            _request_timeout (int/float/tuple): timeout setting for this request. If
                one number provided, it will be total request timeout. It can also
                be a pair (tuple) of (connection, read) timeouts.
                Default is None.
            _check_input_type (bool): specifies if type checking
                should be done one the data sent to the server.
                Default is True.
            _check_return_type (bool): specifies if type checking
                should be done one the data received from the server.
                Default is True.
            _spec_property_naming (bool): True if the variable names in the input data
                are serialized names, as specified in the OpenAPI document.
                False if the variable names in the input data
                are pythonic names, e.g. snake case (default)
            _content_type (str/None): force body content-type.
                Default is None and content-type will be predicted by allowed
                content-types and body.
            _host_index (int/None): specifies the index of the server
                that we want to use.
                Default is read from the configuration.
            _request_auths (list): set to override the auth_settings for an a single
                request; this effectively ignores the authentication
                in the spec for a single request.
                Default is None
            async_req (bool): execute request asynchronously

        Returns:
            [str]
                If the method is called asynchronously, returns the request
                thread.
        """
        kwargs["async_req"] = kwargs.get("async_req", False)
        kwargs["_return_http_data_only"] = kwargs.get("_return_http_data_only", True)
        kwargs["_preload_content"] = kwargs.get("_preload_content", True)
        kwargs["_request_timeout"] = kwargs.get("_request_timeout", None)
        kwargs["_check_input_type"] = kwargs.get("_check_input_type", True)
        kwargs["_check_return_type"] = kwargs.get("_check_return_type", True)
        kwargs["_spec_property_naming"] = kwargs.get("_spec_property_naming", False)
        kwargs["_content_type"] = kwargs.get("_content_type")
        kwargs["_host_index"] = kwargs.get("_host_index")
        kwargs["_request_auths"] = kwargs.get("_request_auths", None)
        kwargs["id_organisme"] = id_organisme
        kwargs["id_pdc"] = id_pdc
        kwargs["interval"] = interval
        kwargs["flow_ids"] = flow_ids
        return self.zaehlerdaten_endpoint.call_with_http_info(**kwargs)
