Skip to content

avios-cli v0.5.0 — BA reward search fixed + Avios prices

Choose a tag to compare

@alexechoi alexechoi released this 11 Aug 12:19
· 3 commits to main since this release
2ffdd2f

British Airways replaced the reward-flight finder with a new Next.js app, which
broke reward search. This release follows the new protocol, cuts the request
volume that was getting IPs blocked, and picks up the Avios pricing the new
searcher exposes.

uvx avios-cli flights LON HKG --date 2027-01-06

Fixed

  • Reward search returned nothing. Each day's flights moved one level deeper
    (departureJourneys.<date>.journeys[].flights[] instead of
    departureJourneys.<date>.flights[]), so every day parsed as empty.
  • Business always reported 0 seats. BA's availability rows use cabin code J;
    we only looked for C. Both are now recognised.
  • Fewer requests, far less chance of being blocked. Every leg used to launch
    its own Chrome, navigate to the finder and drive the search form — that
    page-load traffic is what earns an IP a site-wide 403 from Akamai. A search now
    warms one navigation and issues in-page fetch() calls for everything after it,
    paced. A two-leg return trip costs one navigation and two fetches.
  • Akamai denials are told apart from an expired session: you get "wait a few
    minutes and switch network" instead of being sent to log in again, and the
    remaining legs are abandoned rather than hammering a blocked endpoint.
  • The request contract is reproduced byte for byte against a live capture,
    including both next-router-state-tree variants. The default user-agent claimed
    Chrome/126 while the sec-ch-ua client hints claimed 148 — a disagreement that
    is itself a bot signal — and now matches.

Added

  • Avios prices. Searching an exact --date shows the Avios cost per cabin for
    your party, in both the CLI and the TUI. Calendar (month) searches stay
    seats-only, which keeps them to one request per leg.

    │ BA0031 │ LHR→HKG │ 18:55 │ 15:50 │ 12h 55m │ 9 · 38,500 │ 7 · 55,000 │ — │ — │ no │
    
  • Exact-date searches re-read that date the way clicking a day does, so seat
    counts are fresh rather than served from the month cache.

  • Seats that only sell against a BA companion voucher are marked † instead of
    being counted as general availability.

  • Dates beyond BA's rolling booking horizon are recognised and no longer render as
    "no reward seats"; an out-of-range month now reports the window BA actually
    offers.

  • AviosClient.search_reward_legs() searches every leg of a trip over one browser
    session and reports failures per leg.

Breaking

avios flights --json reports days as journeys[].flights[], following the
upstream shape, and includes the price attached to each cabin.

Full changelog: https://github.com/alexechoi/avios-cli/blob/main/CHANGELOG.md