Skip to content

v0.2.0 - Weekly Deals

Choose a tag to compare

@dvejsada dvejsada released this 28 Jun 12:03
· 2 commits to main since this release
1c2f7c8

Delivery time-slots now work for accounts whose login doesn't return an
address, plus new bulk product lookups and a weekly-deals helper.

Fixed

  • Delivery slots when login omits an address. The Rohlik login response
    doesn't always include a delivery address (data.address can be null),
    which left address_id unset and made delivery.get_next_slots() return
    None. It now falls back to the saved delivery-address list, prefers the
    address you're currently delivered to (isDeliveredTo), and caches the
    resolved id so later calls stay a single request.

Added

  • delivery.get_addresses() — list the account's saved delivery
    addresses.
  • delivery.get_active_address_id() — resolve the delivery address id
    used for time-slot lookups.
  • products.get_cards(product_ids) — fetch basic data for many products
    in a single request (bulk /products/card endpoint).
  • products.get_week_sales() — this week's deals ("Akce týdne"),
    enriched with product data in one follow-up request.
  • ProductCard model — a trimmed, meaningful product shape: id,
    name, brand, amount, unit, price (sale price when on sale, else
    regular), original_price, unit_price, currency, on_sale,
    sale_valid_till, in_stock. Website display-only fields are omitted.
  • AuthManager.address_id setter — to cache a resolved address.

Compatibility

  • No breaking changes. Public API and existing return types are unchanged;
    all additions are new methods/model.
  • Requires Python 3.13+.

Install: pip install --upgrade rohlik-api