Skip to main content API client

Project description

# TenetAPI

## Description
This is a Python module for work with ISP TeNeT API.

## Usage:
>>> from tenet import TenetAPI
>>> from tenet.utils import sizeof_fmt
>>> TenetAPI()
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "tenet/", line 34, in __init__
"Usage: TenetAPI(username='user', passcode='pass')"
tenet.exceptions.TenetBaseException: Usage: TenetAPI(username='user', passcode='pass') or TenetAPI(username='user', md5passcode='hash')
>>> api = TenetAPI(
... username='user-00000',
... md5passcode='8b46a9e3095d350b2faeb1c503239b5e'
... )
>>> api.update()
>>> print api.api.account_id
>>> print api.account_state
>>> print api.account_enabled
>>> print api.service_name
Сверхскоростной Интернет и Wi-Fi
>>> print api.saldo
>>> print api.good_day
>>> print api.bonus_state
>>> api.toggle_bonus()
>>> print api.bonus_state
>>> print sizeof_fmt(api.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.4
Filename, size File type Python version Upload date Hashes
Filename, size tenet-0.4-py2-none-any.whl (16.9 kB) File type Wheel Python version py2 Upload date Hashes View hashes
Filename, size tenet-0.4.tar.gz (3.8 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