Skip to content

Feature Request: normalize event times in raw shipment data #51

Description

@pkolbus

Thanks for this integration -- it works really well.
In sensor.parcel_raw_shipment_data, the deliveries.event[].date values are strings in different formats per carrier. For example:

  • amzlus: Tuesday, May 13 1:31 PM (or "Wednesday, April 30 ")
  • fedex: May 13, 2025 13:31
  • ups: 05.13.2025 13:31
  • usps: Tuesday, May 13 1:31 pm

It would be helpful for the sensor to provide these as datetime when possible for a consistent presentation. dateutil.parser.parse() can handle at least the above formats, but unfortunately this isn't exposed in HA templates.

I'd be happy to work on a PR for this, but not sure about the following aspects:

  • whether this should be an additional event attribute, or if it can replace the existing date
  • what formats are used by the other 320 carriers

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions