Python client for the Baby Tracker sync server, reverse engineered from the Android app (4.53), and a HACS-installable Home Assistant integration built on it. Each baby gets a log calendar and summary sensors, and actions add entries that sync back to the group. Reading has been run against the real server. Uploading and running inside real Home Assistant have not. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
88 lines
1.6 KiB
Python
88 lines
1.6 KiB
Python
"""Unofficial Python client for the Baby Tracker sync server."""
|
|
|
|
from .client import (
|
|
AccountChangedError,
|
|
AccountStateError,
|
|
AuthenticationError,
|
|
BabyTrackerClient,
|
|
BabyTrackerError,
|
|
ConflictError,
|
|
MissingSeedError,
|
|
NotFoundError,
|
|
)
|
|
from .models import (
|
|
Device,
|
|
DiaperAmount,
|
|
DiaperStatus,
|
|
MediaType,
|
|
NursingFinishSide,
|
|
OpCode,
|
|
PumpFinishSide,
|
|
PumpSides,
|
|
Transaction,
|
|
bath,
|
|
decode_object,
|
|
diaper,
|
|
encode_object,
|
|
format_date,
|
|
formula,
|
|
growth,
|
|
journal,
|
|
joy,
|
|
measure,
|
|
new_activity,
|
|
nursing,
|
|
parse_date,
|
|
pumped,
|
|
sleep,
|
|
temperature,
|
|
)
|
|
from .replica import BOTTLE_KINDS, FEED_KINDS, Baby, Entry, Replica
|
|
from .seed import extract_seed_db, open_seed_db, read_babies, read_cursors, read_records
|
|
|
|
__all__ = [
|
|
"AccountChangedError",
|
|
"AccountStateError",
|
|
"AuthenticationError",
|
|
"BOTTLE_KINDS",
|
|
"Baby",
|
|
"BabyTrackerClient",
|
|
"BabyTrackerError",
|
|
"ConflictError",
|
|
"Device",
|
|
"DiaperAmount",
|
|
"DiaperStatus",
|
|
"Entry",
|
|
"FEED_KINDS",
|
|
"MediaType",
|
|
"MissingSeedError",
|
|
"NotFoundError",
|
|
"NursingFinishSide",
|
|
"OpCode",
|
|
"PumpFinishSide",
|
|
"PumpSides",
|
|
"Replica",
|
|
"Transaction",
|
|
"bath",
|
|
"decode_object",
|
|
"diaper",
|
|
"encode_object",
|
|
"extract_seed_db",
|
|
"format_date",
|
|
"formula",
|
|
"growth",
|
|
"journal",
|
|
"joy",
|
|
"measure",
|
|
"new_activity",
|
|
"nursing",
|
|
"open_seed_db",
|
|
"parse_date",
|
|
"pumped",
|
|
"read_babies",
|
|
"read_cursors",
|
|
"read_records",
|
|
"sleep",
|
|
"temperature",
|
|
]
|