@tmlmobilidade/external 20260624.53.12 → 20260624.1142.37

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.
@@ -1,5 +1,5 @@
1
1
  import { type GtfsRtFeedMessage, ServiceAlertResponse } from '@tmlmobilidade/types';
2
- import { BaseResponse, EstadoLinha, InfoEstacao, TempoEspera } from './types.js';
2
+ import { BaseResponse, EstadoLinha, InfoEstacao, TempoEsperaRawItem } from './types.js';
3
3
  export declare const MlClient: Readonly<{
4
4
  /**
5
5
  * Gets the status of a specific Metro Lisboa line.
@@ -31,20 +31,20 @@ export declare const MlClient: Readonly<{
31
31
  /**
32
32
  * Gets the current waiting time estimates for a specific station.
33
33
  * @param estacao Station identifier as string.
34
- * @returns TempoEspera object with estimated waiting times for the station.
34
+ * @returns An array of TempoEsperaRawItem objects, one for each platform in the station.
35
35
  */
36
- tempoEsperaEstacao: (estacao: string) => Promise<BaseResponse<TempoEspera>>;
36
+ tempoEsperaEstacao: (estacao: string) => Promise<BaseResponse<TempoEsperaRawItem[]>>;
37
37
  /**
38
38
  * Gets the current waiting time estimates for a specific line.
39
39
  * @param linha Line identifier as string.
40
- * @returns An array of TempoEspera objects, one for each station in the line.
40
+ * @returns An array of TempoEsperaRawItem objects, one for each platform in the line.
41
41
  */
42
- tempoEsperaLinha: (linha: string) => Promise<BaseResponse<TempoEspera[]>>;
42
+ tempoEsperaLinha: (linha: string) => Promise<BaseResponse<TempoEsperaRawItem[]>>;
43
43
  /**
44
44
  * Gets the current waiting time estimates for all stations.
45
- * @returns An array of TempoEspera objects, one for each station.
45
+ * @returns An array of TempoEsperaRawItem objects, one for each platform in all stations.
46
46
  */
47
- tempoEsperaTodasEstacoes: () => Promise<BaseResponse<TempoEspera[]>>;
47
+ tempoEsperaTodasEstacoes: () => Promise<BaseResponse<TempoEsperaRawItem[]>>;
48
48
  /**
49
49
  * Fetches waiting time estimates for a line and transforms them into a GTFS-RT TripUpdates feed.
50
50
  * @param linha Line identifier as string.
@@ -98,7 +98,7 @@ export const MlClient = Object.freeze({
98
98
  /**
99
99
  * Gets the current waiting time estimates for a specific station.
100
100
  * @param estacao Station identifier as string.
101
- * @returns TempoEspera object with estimated waiting times for the station.
101
+ * @returns An array of TempoEsperaRawItem objects, one for each platform in the station.
102
102
  */
103
103
  tempoEsperaEstacao: async (estacao) => {
104
104
  return await fetcher(endpoints.tempoEsperaEstacao(estacao));
@@ -106,14 +106,14 @@ export const MlClient = Object.freeze({
106
106
  /**
107
107
  * Gets the current waiting time estimates for a specific line.
108
108
  * @param linha Line identifier as string.
109
- * @returns An array of TempoEspera objects, one for each station in the line.
109
+ * @returns An array of TempoEsperaRawItem objects, one for each platform in the line.
110
110
  */
111
111
  tempoEsperaLinha: async (linha) => {
112
112
  return await fetcher(endpoints.tempoEsperaLinha(linha));
113
113
  },
114
114
  /**
115
115
  * Gets the current waiting time estimates for all stations.
116
- * @returns An array of TempoEspera objects, one for each station.
116
+ * @returns An array of TempoEsperaRawItem objects, one for each platform in all stations.
117
117
  */
118
118
  tempoEsperaTodasEstacoes: async () => {
119
119
  return await fetcher(endpoints.tempoEsperaTodasEstacoes);
package/dist/index.d.ts CHANGED
@@ -37,9 +37,9 @@ export declare const externalClients: Readonly<{
37
37
  infoEstacao: (estacao: string) => Promise<import("./clients/ml/types.js").BaseResponse<import("./clients/ml/types.js").InfoEstacao>>;
38
38
  infoEstacaoTodas: () => Promise<import("./clients/ml/types.js").BaseResponse<import("./clients/ml/types.js").InfoEstacao[]>>;
39
39
  serviceAlerts: () => Promise<import("./clients/ml/types.js").BaseResponse<import("@tmlmobilidade/types").ServiceAlertResponse>>;
40
- tempoEsperaEstacao: (estacao: string) => Promise<import("./clients/ml/types.js").BaseResponse<import("./clients/ml/types.js").TempoEspera>>;
41
- tempoEsperaLinha: (linha: string) => Promise<import("./clients/ml/types.js").BaseResponse<import("./clients/ml/types.js").TempoEspera[]>>;
42
- tempoEsperaTodasEstacoes: () => Promise<import("./clients/ml/types.js").BaseResponse<import("./clients/ml/types.js").TempoEspera[]>>;
40
+ tempoEsperaEstacao: (estacao: string) => Promise<import("./clients/ml/types.js").BaseResponse<import("./clients/ml/types.js").TempoEsperaRawItem[]>>;
41
+ tempoEsperaLinha: (linha: string) => Promise<import("./clients/ml/types.js").BaseResponse<import("./clients/ml/types.js").TempoEsperaRawItem[]>>;
42
+ tempoEsperaTodasEstacoes: () => Promise<import("./clients/ml/types.js").BaseResponse<import("./clients/ml/types.js").TempoEsperaRawItem[]>>;
43
43
  tripUpdates: () => Promise<import("@tmlmobilidade/types").GtfsRtFeedMessage>;
44
44
  }>;
45
45
  mobi: Readonly<{
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tmlmobilidade/external",
3
- "version": "20260624.53.12",
3
+ "version": "20260624.1142.37",
4
4
  "author": {
5
5
  "email": "iso@tmlmobilidade.pt",
6
6
  "name": "TML-ISO"