Skip to main content
Join the official 2019 Python Developers SurveyStart the survey!

stats.tenet.ua account manager

Project description

TenetAPI

Description

This is a Python module for the ISP TeNeT API.

Usage:

>>> from tenet import TenetAccount
>>> from tenet.utils import sizeof_fmt
>>> TenetAccount()
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "tenet/__init__.py", line 34, in __init__
    "Usage: TenetAccount(username='user', password='pass')"
tenet.exceptions.TenetBaseException: Usage: TenetAccount(username='user', password='pass') or TenetAccount(username='user', md5password='hash')
>>> account = TenetAccount(
...     username='user-00000',
...     md5password='8b46a9e3095d350b2faeb1c503239b5e'
... )
>>> account.update()
>>> print account.id
00000
>>> print account.state
Normal
>>> print account.enabled
True
>>> print account.tariff_plan
Сверхскоростной Интернет и Wi-Fi
>>> print account.saldo
374.60
>>> print account.good_day
False
>>> print account.bonus_state
Enabled
>>> account.toggle_bonus()
>>> print account.bonus_state
Disabled
>>> print sizeof_fmt(account.bonus_rest)
10.0 GiB

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for tenet, version 0.6
Filename, size File type Python version Upload date Hashes
Filename, size tenet-0.6-py2-none-any.whl (16.9 kB) File type Wheel Python version py2 Upload date Hashes View hashes
Filename, size tenet-0.6.tar.gz (4.0 kB) File type Source Python version None Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page