The nymea-cli does not provide a python library ready to be used at this point. Instead it should be seen as an example of how to interact with nymea using python.
If you’re a python developer, we’d happily accept any patches that transform nymea-cli into a library and a frontend part.
The code can be obtained from github.
git clone https://github.com/nymea/nymea-cli