There's a very old very extensive USB HID spec for a ton of battery & charger telemetry things, that for no good reason was never implemented. I'm not sure if USB-PD has overlapping way of sharing data like "is the other side also running on battery?" but we have had the technical possibility of answering that (and how much charge is left what the battery voltage is, but getting low power alarms, more) for literally decades & shame on us for never having implemented it.