HelmHelm UniversityTrack 4 › Lesson 4.3

Lesson 4.3

How delivery is recorded

A carrier can say so, or a person can press a button, and the one that gets there first wins.

2 min readTrack 4, Fulfil It ProperlyFree, no account needed
Helm University track 4, Fulfil It Properly

Prefer to listen? This is the same lesson, word for word. The text below is the transcript.

This lesson prepares you to: Explain both routes to a delivered order and why the timestamp matters more than the status.

Two routes, either one is enough

The carrier. When the tracking service reports the parcel delivered, Helm records it automatically. This happens two ways: a webhook that arrives the moment it changes, and a poll that checks every five minutes in case the webhook never comes.

Both exist on purpose. The reasoning in the code is worth quoting because it is the right way to think about it: a webhook that quietly stops arriving looks exactly like a parcel that has not moved, and the difference is a seller's money. If the webhook never works at all, delivery is still detected, just minutes later.

A person. The buyer, the seller or an admin can mark an order delivered directly. This is the only route available when there is no tracking number.

The timestamp is the carrier's, not Helm's

When a carrier reports a delivery, Helm records the moment the carrier says it landed, not the moment Helm found out. It walks the carrier's own event history to find it.

That matters because the delivery timestamp is what your payout hold counts from. Using the moment Helm heard about it would quietly cost you hours every time.

Recorded once

The automatic path will not overwrite a delivery time that is already set. If a person pressed the button first, the carrier confirming later does not push your timestamp forward.

The manual button does not have that protection, so pressing delivered twice re-stamps the time and moves your payout later. Press it once.

An order that already ended stays ended

An order that was refunded or cancelled while the parcel was in transit does not flip to delivered when it lands. The automatic path only moves an order that is still in the shipped state, which keeps a refunded order from quietly looking like a completed one.

Unsigned delivery events are refused

Every carrier webhook must be correctly signed or it is rejected outright. There is no fallback to trusting the payload, and the reason is direct: trusting it would let anyone who guessed a tracking code mark an order delivered, and delivered is what starts the payout clock.

If signature checking ever breaks, the five minute poll still finds the delivery. The cost of refusing is minutes. The cost of trusting would be money.