Skip to content

[P1][Sprint 1][Growth] Add typed LTL and parcel fuel-surcharge clients #101

Closed

Description

@karlwaldman

Why

The published API exposes six LTL/parcel fuel-surcharge routes, but no first-class Python resource. This is a customer workflow already shipped by the API.

Acceptance criteria

  • Cover list, latest, and history routes for LTL and parcel carriers.
  • Type carrier, service level, mode, date, pagination, and response models.
  • Preserve effective dates and source provenance.
  • Test unknown carrier, no-data, entitlement, malformed 200, 429, and timeout paths.
  • Add examples, docs, live smoke, capabilities metadata, and a minor release.

Delivery

Independent Python release.

Activity

  1. karlwaldman commented on Sep 13, 2026

    @karlwaldman
    MemberAuthor

    Premise check, 2026-09-13, against oilpriceapi-api origin/main and production:

    • Routes: confirmed. All six exist: config/routes.rb, scope fuel-surcharge -> V1::FuelSurchargeController. All six returned 200 in production with the test key.
    • "Entitlement" path: premise is wrong. No fuel-surcharge route has a plan gate. The routes comment and controller header record a 2026-07-17 decision: available on every tier including free, and not matched in BaseController#determine_required_feature. Only 401 (no key), 429 and 404/400 are real outcomes. 402/403 are tested as generic status mapping only.
    • "Machine-readable capabilities metadata": does not exist in this repo. The only machine-readable artifact is the snippet manifest (examples/snippets/manifest-source.json). tests/test_snippet_manifest.py executes every entry against a prices-only fixture server, so a fuel-surcharge snippet was not added. No new capabilities file was invented.
    • "Type carrier, service level, mode, date, pagination": confirmed with shape notes.
      • service_level is sent only on parcel rows.
      • doe_diesel_price and diesel_band are nullable and are null for several LTL carriers and all parcel rows.
      • Parcel latest returns a carrier object without service_level and a single rate with it.
      • The server silently clamps page/per_page: per_page=500&page=0 -> meta {page:1, per_page:100}.
    • "Minor release": not cut in the PR, per instruction; entries are under ## [Unreleased].
  2. added 2 commits that reference this issue on Sep 13, 2026
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

    featureNew featurepriority: highShould be fixed soonqaQuality assurance and testing

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions