aboutsummaryrefslogtreecommitdiff
path: root/phpipam/__init__.py
blob: 89d828047ca2c791d96189d868407ca0df616e56 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
from .backend import phpipamBackend
from .resources import phpipamResource

class phpipam:
    """
    phpIPAM API Implementation
    ReadOnly because I don't need the writing bit

    https://phpipam.net/api-documentation/
    """

    def __init__(self, api_url, app_id, api_user, api_password):
        self._backend = phpipamBackend(api_url, app_id, api_user, api_password)

    def __getattr__(self, item):
        return phpipamResource(self._backend, item)