profile
viewpoint
If you are wondering where the data of this site comes from, please visit https://api.github.com/users/marudor/events. GitMemory does not store any data, but only uses NGINX to cache data for a period of time. The idea behind GitMemory is simply to give users a better reading experience.
marudor marudor Karlsruhe, Zug, Germany https://marudor.de Twitter: @marudor

issue commentmarudor/BahnhofsAbfahrten

Link to details page with a HAFAS tripIds

https://docs.marudor.de/#operation/DetailsRedirect example: https://marudor.de/api/hafas/v1/detailsRedirect/1|328979|0|80|25102021

Currently there is no real error handling. Might change that later so an error redirets somewhere that explains what happened. For now it's just a 500.

jeyemwey

comment created time in 18 hours

issue closedmarudor/BahnhofsAbfahrten

Link to details page with a HAFAS tripIds

Is your feature request related to a problem? Please describe. I want to generate hyperlinks to the details page of a trip (e.g. https://marudor.de/details/TGV%209561/2021-10-25T05:08:00.000Z?station=8000105). These links shall then be included in calendar events at https://train-ics.ipv4.rocks (see also https://github.com/jeyemwey/train-ics-converter/issues/4 )

However, hafas-client does not offer a simple way to get to the trainName part of the Details request. While the line model does include a name attribute, bahnhofsabfahrten does not always recognize this. See e.g. regional train RE10 with this information:

{
  "type": "line",
  "id": "nwb-re10",
  "fahrtNr": "28226",
  "name": "NWB RE10",
  "public": true,
  "adminCode": "N2____",
  "productName": "NWB",
  "mode": "train",
  "product": "regional",
  "operator": { "type": "operator", "id": "nordwestbahn", "name": "NordWestBahn" },
  "additionalName": "NWB RE10"
}

but the /details link does not include the line.name but: https://marudor.de/details/NWB%2028226/2021-10-25T09:18:00.000Z?station=8000409

I can only guess that the first parameter identifies the train with line.productName + " " + line.fahrtNr, which feels undocumented and subject to change (described e.g. here).

Describe the solution you'd like

It would be great to have a stable interface to identify travel services, e.g. with the HAFAS tripId (e.g. 1|261094|0|80|25102021) which is common, unique and already includes the date of the service.

My favourite solution would be, if the frontend could read HAFAS tripIds through a query parameter like this: https://marudor.de/details?tripId=1|261094|0|80|25102021

Describe alternatives you've considered Alternatively, a new endpoint is instantiated that converts HAFAS tripIds to a /details link that my users can click on to visit the marudor.de details page.

Additional context Please hit me up if this is already solved in other ways and I'm too stupid.

closed time in 18 hours

jeyemwey

push eventmarudor/BahnhofsAbfahrten

marudor

commit sha d82a106ef4d082c842f04ed69e3d42be4208689c

feat: add route to redirect to details page via hafas Trip Id (#529) * feat: add route to redirect to details page via hafas Trip Id (Journey Id) * feat: percy config

view details

push time in 18 hours

delete branch marudor/BahnhofsAbfahrten

delete branch : feature/528

delete time in 18 hours

push eventmarudor/BahnhofsAbfahrten

marudor

commit sha 79224452db28be189f94b8f13a56e80e55c46dba

feat: percy config

view details

push time in 18 hours

push eventmarudor/BahnhofsAbfahrten

marudor

commit sha 7b2af8509869d926f4372e108d4c55ed8afe26e2

feat: percy config

view details

push time in 18 hours

push eventmarudor/BahnhofsAbfahrten

marudor

commit sha e8eece9b84c52972176437906f68d2a76a165eaa

feat: percy config

view details

push time in 18 hours

push eventmarudor/BahnhofsAbfahrten

marudor

commit sha 59563138810e5a418228ca3d00baa2bf35aeb1ae

feat: add route to redirect to details page via hafas Trip Id (Journey Id)

view details

push time in 18 hours

create barnchmarudor/BahnhofsAbfahrten

branch : feature/528

created branch time in 19 hours

issue commentmarudor/BahnhofsAbfahrten

Link to details page with a HAFAS tripIds

Just as you guessed it is produtName + fahrtNr. I could do something like https://marudor.de/hafasDetails/<tripId> that redirects you to the real details page.

jeyemwey

comment created time in a day

push eventmarudor/BahnhofsAbfahrten

marudor

commit sha acf8e3c38c0425389b5fd5f18c4a3146f32580a4

feat: percy (#527) * feat: percy * feat: more percy snapshots * feat: use dark and light for percy snapshots

view details

push time in a day

delete branch marudor/BahnhofsAbfahrten

delete branch : feature/percy

delete time in a day

PR merged marudor/BahnhofsAbfahrten

feat: percy
+525 -38

1 comment

53 changed files

marudor

pr closed time in a day

push eventmarudor/BahnhofsAbfahrten

marudor

commit sha 6945df17c94d6fabf290e2a642c3db4cfb0944b7

feat: use dark and light for percy snapshots

view details

push time in a day

push eventmarudor/BahnhofsAbfahrten

marudor

commit sha 45d6dd46169a89f934243270af260accd4611b93

feat: more percy snapshots

view details

push time in a day

push eventmarudor/BahnhofsAbfahrten

marudor

commit sha 13f53858fce01022f29fdba960b5b4bb89401867

feat: percy

view details

push time in a day

push eventmarudor/BahnhofsAbfahrten

marudor

commit sha 5a30072436f527a681a450ed3e8a36fe725dd878

feat: percy

view details

push time in a day

PR opened marudor/BahnhofsAbfahrten

feat: percy
+482 -21

0 comment

48 changed files

pr created time in a day

create barnchmarudor/BahnhofsAbfahrten

branch : feature/percy

created branch time in a day

push eventmarudor/BahnhofsAbfahrten

marudor

commit sha 6382ee00f6b42070d72fe5d1115b04ef612e7fff

chore: deps (#526) * chore: deps * chore: remove deprecated stuff * chore: remove SBB experimental API

view details

push time in a day

PR merged marudor/BahnhofsAbfahrten

chore: deps
+2174 -6292

1 comment

399 changed files

marudor

pr closed time in a day

delete branch marudor/BahnhofsAbfahrten

delete branch : chore/deps

delete time in a day

push eventmarudor/BahnhofsAbfahrten

marudor

commit sha 03ddc9eb6c7a3268fd4a177f76b9ecba91ddf49a

chore: remove deprecated stuff

view details

marudor

commit sha 45f47448e1ea776533f34f3884c3d94756969731

chore: remove SBB experimental API

view details

push time in a day

PR opened marudor/BahnhofsAbfahrten

chore: deps
+2174 -5408

0 comment

391 changed files

pr created time in a day

create barnchmarudor/BahnhofsAbfahrten

branch : chore/deps

created branch time in a day

PR merged marudor/randomPictures

chore: deps and stuff
+5226 -44075

0 comment

2086 changed files

marudor

pr closed time in 4 days

push eventmarudor/randomPictures

marudor

commit sha 5a77dc94ab7e7c8e7710e8706d36c2600295d159

chore: deps and stuff (#7) * chore: deps and stuff * fix:: types

view details

push time in 4 days

push eventmarudor/randomPictures

marudor

commit sha af3fe4c36852dcff2399e99eca6e0c2391e5633e

fix:: types

view details

push time in 4 days