@autobusal/providers 1.44.0 → 1.44.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/types/routes.ts +18 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@autobusal/providers",
3
- "version": "1.44.0",
3
+ "version": "1.44.1",
4
4
  "author": "Ferjolt Ozuni",
5
5
  "type": "module",
6
6
  "main": "index.ts",
package/types/routes.ts CHANGED
@@ -148,6 +148,24 @@ export interface FoundData extends Omit<RouteData, 'locations' | 'id'> {
148
148
  // must read "missing" as unknown, never as direct.
149
149
  stops_count?: number
150
150
 
151
+ /**
152
+ * How many seats are still on sale on this departure.
153
+ *
154
+ * Edited: Claude - Date: 2026-09-16
155
+ *
156
+ * NOT `trip.available_seats`, which is the coach's CAPACITY - the search
157
+ * subtracts what every brand has sold and what the operator holds back
158
+ * before deciding whether to offer the departure at all, and this is that
159
+ * answer (Routes\Search\Buses::removeOccupied). Reading the capacity
160
+ * instead announced 49 free seats on a coach with 49 sold, which is the
161
+ * one number on a result card nobody would think to doubt.
162
+ *
163
+ * Optional: an external-provider offer has no seat count of ours, and an
164
+ * older API does not send this at all - in both cases the card shows
165
+ * nothing rather than guessing.
166
+ */
167
+ seats_left?: number
168
+
151
169
  /**
152
170
  * Claude - 2026-08-29 (audit A3-02h)
153
171
  *