Home > @magiclane/maps-sdk > OverlayItem > getPTStopInfo
OverlayItem.getPTStopInfo() method
Retrieve public-transport stop details when available.
This helper calls getPreviewExtendedData and converts the result to a PTStopInfo when the item belongs to CommonOverlayId.PublicTransport.
Signature:
getPTStopInfo(filter?: PTStopScheduleFilter): Promise<PTStopInfo | null>;Parameters
Parameter | Type | Description |
|---|---|---|
filter | (Optional) Optional departures filter. Narrows only the trips (departures) list - the stops[].routes[] line catalogue is always returned complete. An empty / omitted filter produces the legacy, unfiltered request (see PTStopScheduleFilter). |
Returns:
Promise<PTStopInfo | null>
A PTStopInfo when available, otherwise null.