Skip to content

Tracking: explicit connection selection + UPS transport headers#975

Closed
HansDaigle wants to merge 1 commit intokarrioapi:mainfrom
HansDaigle:fix/tracking-carrier-selection-ups-trans-headers
Closed

Tracking: explicit connection selection + UPS transport headers#975
HansDaigle wants to merge 1 commit intokarrioapi:mainfrom
HansDaigle:fix/tracking-carrier-selection-ups-trans-headers

Conversation

@HansDaigle
Copy link
Contributor

@HansDaigle HansDaigle commented Feb 23, 2026

Summary

  • Add carrier_id and test_mode to TrackingData so POST tracking APIs can explicitly select the target connection (consistent with shipping connection resolution behavior).
  • Wire those selectors into both proxy and manager tracking POST endpoints (carrier_filter).
  • Update UPS tracking proxy to auto-populate required transport headers:
    • transId (generated UUID per request)
    • transactionSrc (karrio-test/karrio-prod from test_mode)

Why

  • Tracking requests can target the wrong connection when multiple accounts exist for a carrier.
  • UPS tracking can fail with TV0001/TV0011 when transport headers are missing.

Tests

  • Added proxy tracking test to assert carrier_id/test_mode are forwarded to Shipments.track.
  • Added manager trackers test to assert connection selectors reach Connections.first.
  • Updated UPS tracking test to assert transactionSrc and UUID transId headers are sent.

Notes

  • Validated syntax locally (py_compile) for changed files.
  • Full server test suite was not run in this environment because Karrio server dependencies/runtime are not bootstrapped here.

@vercel
Copy link

vercel bot commented Feb 23, 2026

@HansDaigle is attempting to deploy a commit to the karrio Team on Vercel.

A member of the Team first needs to authorize it.

@HansDaigle
Copy link
Contributor Author

Superseded by split PRs for easier review:\n- #976 (tracking connection selection)\n- #977 (UPS transId/transactionSrc headers)\n\nClosing this combined PR in favor of the two scoped changes.

@HansDaigle
Copy link
Contributor Author

Closing in favor of #976 and #977.

@HansDaigle HansDaigle closed this Feb 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant