2.0.0
What's new
- Carrier-agnostic parcel status (
ParcelStatus) — every parcel now carries a canonicalstatusvalue (registered,in_transit,out_for_delivery,at_pickup_point,delivered,returning,problem,unknown). The original DHL string is preserved on the parcel'sraw_statusattribute. - Parcel events on the HA event bus — the coordinator fires
dhl_nl_parcel_registeredwhen a new barcode appears anddhl_nl_parcel_status_changedwhen a known barcode's normalised status changes. Both events carry the full normalised parcel payload. Events are suppressed on the very first refresh after start-up. - Parcels sorted by delivery date — every bucket is now ordered: active incoming and outgoing ascending on
planned_from, delivered descending ondelivered_at. Parcels without a parseable timestamp always sort to the end. - Translated UI labels — entity names, unit-of-measurement (
parcels→pakkettenin Dutch HA) and icons are sourced fromstrings.json+translations/{en,nl}.json+icons.json. Your HA language drives the labels automatically. - Cleaner device & friendly names — each DHL account becomes a device named
DHL (<your-email>)with entities likeDHL (account@example.com) Incoming parcels. Disambiguates multi-account setups out of the box. examples/folder — ready-to-paste automation YAMLs (e.g. new parcel registered, out for delivery, ready at ServicePoint) and dashboard cards (active-parcels grid, summary glance, next-delivery countdown).
⚠️ Breaking changes & how to fix them
1. Friendly names changed
| Was (≤ 1.4.x) | Is now (2.0.0) |
|---|---|
DHL Incoming Parcels |
DHL (account@example.com) Incoming parcels |
DHL Parcel <barcode> |
DHL (account@example.com) Parcel <barcode> |
DHL Next Delivery |
DHL (account@example.com) Next delivery |
DHL Parcels En Route to ServicePoint |
DHL (account@example.com) En route to ServicePoint |
DHL Parcels Awaiting Pickup |
DHL (account@example.com) Awaiting pickup |
DHL Delivered Parcels |
DHL (account@example.com) Delivered parcels |
DHL Outgoing Parcels |
DHL (account@example.com) Outgoing parcels |
Entity IDs are preserved for existing installs — Home Assistant remembers them in the entity registry. Templates that reference sensor.dhl_incoming_parcels and similar keep working as-is.
What to fix:
- Lovelace cards and Markdown templates that hard-code the friendly name (e.g.
"DHL Incoming Parcels") need to be updated to either the new friendly name pattern or — better — switch to using the entity ID with thefriendly_nameattribute. - If you renamed entities or devices in the HA UI, those custom names stick around; you only see the new defaults for fresh installs.
2. Per-parcel sensor state is the normalised enum, not the raw DHL string
| Was | Is now |
|---|---|
state == "DELIVERED_IN_MAILBOX" |
state == "delivered" |
state == "OUT_FOR_DELIVERY" |
state == "out_for_delivery" |
state == "NOTIFICATION_FOR_PARCELSHOP_COLLECTION_HAS_BEEN_SENT" |
state == "at_pickup_point" |
state == "COLLECTED_AT_PARCELSHOP" |
state == "delivered" |
What to fix:
- Any automation that triggers on the per-parcel sensor state needs to match the new canonical
ParcelStatusvalue. See the parcel-status reference table in the README for the full mapping. - The original raw value is still available on the parcel's
raw_statusattribute; you can keep using that if you prefer.
3. Outgoing summary sensor: shipments attribute → parcels
The outgoing summary sensor's list of shipments now lives on the parcels attribute, matching every other DHL summary sensor.
What to fix:
- If you read
state_attr('sensor.dhl_..._outgoing_parcels', 'shipments'), renameshipmentstoparcels.
4. Custom unit-of-measurement is now translated
The hard-coded parcels unit is replaced by a translated one (parcels in English HA, pakketten in Dutch HA).
What to fix:
- If you have automations matching
state_attr(..., 'unit_of_measurement') == 'parcels', account for the Dutch variant too — or compare against the entity ID instead. - Long-term statistics for the counters may emit a one-time "unit cannot be converted" recorder warning after upgrading on Dutch HA. Open Developer Tools → Statistics, find the sensor and use "Update statistic unit", or ignore the warning until the affected rows roll out of the retention window.