Skip to content

Latest commit

ย 

History

21 Commits

Folders and files

NameName
Last commit message
Last commit date
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

Posten Bring Parcel Tracker

Release Downloads HACS License

๐Ÿ’ฌ Questions or feedback? Join the discussion on the Home Assistant community.

A custom Home Assistant integration that tracks your Posten or Bring parcels via your own consumer account โ€” both incoming and outgoing. No tracking codes to enter: every parcel on your account shows up automatically. Confirmed working for Norway and Sweden; Denmark is expected to work the same way (same shared account backend) but not yet independently confirmed โ€” see Troubleshooting.

Part of the ha-parcel-integrations family: it publishes the same canonical parcel format, statuses and events as the other carrier integrations, so it plugs straight into the Parcel Aggregator and cross-carrier automations.

Contents

Features

  • Auto-discovers every parcel on your Posten/Bring account โ€” incoming and outgoing, no tracking codes to enter
  • Per-parcel sensor with the canonical status (registered / in_transit / at_pickup_point / delivered / returning / โ€ฆ), the carrier's own raw status, weight, dimensions, the expected delivery window and a public tracking link
  • Summary sensors: incoming parcels, next delivery, delivered parcels, outgoing parcels, outgoing delivered parcels, awaiting pickup
  • Read-only Deliveries calendar with the expected delivery windows
  • Events + device triggers for no-code automations (registered, status changed, delivered, delivery time changed โ€” plus the outgoing pair)
  • Opt-in per-parcel status history
  • Manual refresh button and a diagnostic last-update sensor

Requirements

  • Home Assistant 2024.12 or newer
  • Your own Posten or Bring consumer account (Vipps or phone-number login) โ€” Posten Bring is active in Norway, Sweden and Denmark (confirmed for Norway and Sweden; Denmark is expected but not yet independently confirmed). Not Finland: Bring is no longer active there.
  • A desktop browser with developer tools, to complete the one-time sign-in (see Configuration)

Installation

HACS (recommended)

  1. In HACS, choose the three-dot menu โ†’ Custom repositories.
  2. Add https://github.com/ha-parcel-integrations/ha-posten-bring as an Integration.
  3. Install Posten Bring and restart Home Assistant.

Manual

Copy custom_components/posten_bring into your config/custom_components/ folder and restart Home Assistant.

Configuration

Add the integration via Settings โ†’ Devices & Services โ†’ Add Integration โ†’ Posten Bring.

  1. Pick which brand's login you use โ€” Posten or Bring. Either works for parcels in Norway, Sweden and Denmark alike; this only picks which login page opens. Don't add the integration twice with the other brand for the same account โ€” both read the same inbox, so every parcel would show up twice.
  2. Open the shown authorization URL in a browser and sign in (Vipps or phone number).
  3. Your browser cannot open the address it's redirected to afterwards โ€” that's expected. Copy that complete address from your browser's developer tools (or history) and paste it into the Home Assistant form. See docs/finding-the-redirect-url.md for a step-by-step guide per browser.

Home Assistant only stores the resulting refresh token โ€” never your Vipps/phone credentials, and never the one-time authorization code.

Options

Open Configure on the integration entry:

Section Option Default Description
Delivered parcels Filter by / amount last 7 days How long delivered parcels stay visible on the delivered sensors (incoming and outgoing).
Parcel history Include status history off Adds a history attribute per parcel with each status update.

Polling isn't one of these settings: the integration polls on a dynamic, status-driven schedule with nothing to configure.

Dynamic polling

Polling isn't a setting here โ€” the integration adjusts its own cadence to what your tracked parcels are actually doing:

  • Quiet hours โ€” no polling between 00:00โ€“06:00 local time, aside from one catch-up check at each end of that window (around midnight and around 6 AM), so an overnight update is never missed.
  • Hot (every 15 minutes) โ€” while any tracked parcel is out for delivery today, starting an hour before its delivery window opens (or immediately if no window is known yet โ€” in practice this tier never engages for Posten Bring, whose status vocabulary has no out_for_delivery state at all).
  • Normal (every 45 minutes) โ€” for anything else still on its way.
  • Never fully stops โ€” with nothing hot or in transit, polling keeps running at the normal cadence, since that's also how a new shipment on your account gets discovered.
  • A small, fixed per-hub offset is added on top, so not every Posten Bring hub out there polls at exactly the same second.

Removal

Standard HA removal applies: Settings โ†’ Devices & Services โ†’ Posten Bring โ†’ โ‹ฎ โ†’ Delete. This only removes the local refresh token; nothing is changed on your Posten/Bring account.

Sensors

Entity Description
sensor.posten_bring_<account>_incoming_parcels Number of active incoming parcels, full list under the parcels attribute
sensor.posten_bring_<account>_parcel_<barcode> One per tracked parcel; state is the canonical status, attributes carry the full normalised parcel
sensor.posten_bring_<account>_next_delivery Earliest expected delivery moment across all active incoming parcels
sensor.posten_bring_<account>_delivered_parcels Recently delivered incoming parcels (see the retention option)
sensor.posten_bring_<account>_outgoing_parcels Number of active outgoing parcels (direction: send)
sensor.posten_bring_<account>_outgoing_delivered_parcels Recently delivered outgoing parcels
sensor.posten_bring_<account>_awaiting_pickup Parcels ready for collection at a pickup point
sensor.posten_bring_<account>_last_successful_update Diagnostic: when the account was last polled successfully

A delivered parcel moves from its per-parcel sensor to the delivered sensor automatically.

Parcel status reference

The status field is the carrier-agnostic enum shared by the whole integration family:

Status Meaning
registered Announced, not yet handed to the carrier (notified)
in_transit In the sorting network (underway)
at_pickup_point Waiting for you at a pickup location (collectable)
delivered Delivered โ€” derived from the parcel's event history, since Posten Bring's own item status has no dedicated "delivered" value
returning Going back to the sender (return_underway / return_collectable, or an archived parcel whose latest event is a return)
unknown Not yet scanned, or a status we have not mapped yet

out_for_delivery and problem are part of the shared enum but Posten Bring's own status vocabulary has no mechanism that reaches either โ€” this integration never reports them.

The carrier's own raw status is always available as raw_status.

Events

The integration fires these on the event bus (also available as device triggers on the Posten Bring device):

Event When
posten_bring_parcel_registered A new incoming parcel appears
posten_bring_parcel_status_changed A parcel's canonical status changes (old_status / new_status in the payload), except the final hop to delivered
posten_bring_parcel_delivered A parcel is delivered
posten_bring_parcel_delivery_time_changed The expected delivery window changes
posten_bring_outgoing_parcel_status_changed An outgoing parcel's canonical status changes
posten_bring_outgoing_parcel_delivered An outgoing parcel is delivered

Every payload is the full normalised parcel plus the hub's device_id. Events are suppressed on the first refresh after start-up.

Examples

Ready-to-paste automations live in examples/.

Debugging

logger:
  logs:
    custom_components.posten_bring: debug

Troubleshooting

  • The setup form never shows a working redirect. Make sure you complete the sign-in in a desktop browser with developer tools open and "preserve log" enabled before submitting the login form โ€” see docs/finding-the-redirect-url.md.
  • "That doesn't look like a valid redirect URL". Paste the complete address, including ?code=โ€ฆ&state=โ€ฆ. The code is single-use and short-lived โ€” if it's been a few minutes, redo the sign-in.
  • A status logs "Unrecognised Posten Bring status" โ€” please open an issue with the logged line so the mapping can be extended.
  • Using a Danish account. Posten Bring's shared inbox has been confirmed to return Norwegian and Swedish accounts' own parcels; Danish coverage hasn't been independently tested yet. If it doesn't show your parcels, please open an issue โ€” that's exactly the report this needs.

Related integrations

This integration is part of ha-parcel-integrations โ€” a family of parcel-carrier integrations that all publish the same canonical parcel format, statuses and events.

Disclaimer

This is an independent, community-built project. It is not affiliated with, endorsed by, sponsored by, or supported by Posten Bring, Home Assistant, or any other third party referenced in this project. Please don't contact Posten Bring for support with this integration.

All third-party trademarks, trade names, product names, logos, and other brand assets are the property of their respective owners. References to them are solely to identify the relevant carrier or service and do not imply affiliation, sponsorship, or endorsement. Nothing in this project grants or implies any licence or right to use third-party brand assets.

This integration may rely on public, unofficial, or undocumented carrier interfaces, accessed with your own account or API key where required. These may change or be withdrawn without notice and may be subject to Posten Bring's terms. Data is sent only to Posten Bring's own services or those of its group; this project operates no servers of its own. You are responsible for ensuring that your use complies with applicable law and those terms. Use is at your own risk; see the licence for warranty limitations.

This integration uses the official Posten/Bring native-app OAuth client to read your own account's parcel inbox โ€” the same credential pair the official Android app itself uses, embedded here with the project maintainer's explicit approval.

Contributing

Pull requests and issues are welcome. Please open an issue before submitting a large change.

License

MIT

Releases

Sponsor this project

Packages

Used by

Contributors

Languages