Southern Company API
Control Southern company websites with this api
Supported utilities
| Utility | Class | Auth method |
|---|---|---|
| Georgia Power, Alabama Power, Mississippi Power | SouthernCompanyAPI |
JWT |
| Nicor Gas (LDC=7) | NicorGasAPI |
Cookie session |
Usage
Southern Company electric utilities (Georgia Power, Alabama Power, Mississippi Power)
import asyncio
import aiohttp
from southern_company_api import SouthernCompanyAPI
async def main():
async with aiohttp.ClientSession() as session:
api = SouthernCompanyAPI("username", "password", session)
await api.connect()
for account in await api.accounts:
usage = await account.get_daily_data(start, end, await api.jwt)
print(usage)
asyncio.run(main())
Nicor Gas
import asyncio
import aiohttp
from southern_company_api import NicorGasAPI
async def main():
async with aiohttp.ClientSession() as session:
api = NicorGasAPI("username", "password", session)
await api.connect()
history = await api.get_usage_history()
for period in history.billing_periods:
print(period.date, period.therms, "therms")
for day in history.daily_usage:
print(day.date.date(), day.therms, "therms", day.cost, "cost")
print("Projected bill:", history.projected_bill.low_amount,
"–", history.projected_bill.high_amount)
asyncio.run(main())
Nicor Gas data types
| Type | Fields |
|---|---|
NicorBillingPeriod |
date, meter_reading, reading_details, ccfs, therms, days_used |
NicorDailyUsage |
date, therms, cost, avg_temp, day_of_week, is_weekend, read_type, meter_read, billing_period |
NicorProjectedBill |
usage, low_amount, high_amount |
NicorMeterInfo |
meter_number, meter_status, next_read_date |
All date fields are timezone-aware UTC datetime objects. The parse_aspnet_date helper
converts the ASP.NET /Date(ms)/ format used in the portal.
Installation
Install this via pip (or your favourite package manager):
pip install southern-company-api
Contributors ✨
Thanks goes to these wonderful people (emoji key):
Luke 💻 🤔 📖 |
This project follows the all-contributors specification. Contributions of any kind welcome!
Credits
This package was created with Copier and the browniebroke/pypackage-template project template.
Metadata
Release files for southern-company-api 0.8.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| southern_company_api-0.8.0.tar.gz | 22.3 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| southern_company_api-0.8.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 45.6 kB
Release files / southern_company_api-0.8.0.tar.gz
| Download URL | southern_company_api-0.8.0.tar.gz |
|---|---|
| Size | 22.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
585405b3731776a81c8e7f8f4a4214a016104ed44a810815cb1d5b6a05732865
|
|
BLAKE2b-256 checksum How to use checksums |
cd107ce5e62bf30cad5f1f120ad6ffd49b94b0992ec5d98f6471d8bbf7c78ae0
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / southern_company_api-0.8.0-py3-none-any.whl
| Download URL | southern_company_api-0.8.0-py3-none-any.whl |
|---|---|
| Size | 23.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
50d6795e76c8b47ac2b5982eba24f3a2265ad87344f9e1e055c685719d842caa
|
|
BLAKE2b-256 checksum How to use checksums |
15ce88158e8e28ea9758b3b7cdeaaf3ab9bd9c3e7f7689d61bfb646f3fa5a720
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Security for southern-company-api 0.8.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.