Skip to content

Commit 37224d0

Browse files
committed
TSV2: add paced trains documentation
Signed-off-by: Youness CHRIFI ALAOUI <[email protected]>
1 parent 7a6cf59 commit 37224d0

File tree

1 file changed

+39
-16
lines changed
  • content/docs/reference/design-docs/timetable

1 file changed

+39
-16
lines changed

content/docs/reference/design-docs/timetable/index.en.md

+39-16
Original file line numberDiff line numberDiff line change
@@ -246,49 +246,72 @@ Other errors can happen at runtime:
246246

247247
During simulation, **if a target arrival time cannot be achieved, the rest of the schedule still stands**.
248248

249+
The mission model in OSRD is represented almost like a Train Schedule with the addition of 2 fields:
250+
- `step: Duration (ISO 8601)` corresponds to the delay between each train
251+
- `duration: Duration (ISO 8601)` which corresponds to the total duration of the mission.
252+
253+
## Example
254+
255+
A mission with a step of 15 min and a duration of 2 hours will see 8 trains running from the departure time.
249256

250257
## Endpoints
251258

252259
### Timetable
253260

254261
```
255-
POST /v2/timetable
256-
GET /v2/timetable/ # Paginated list timetable
257-
PUT /v2/timetable/ID
258-
DELETE /v2/timetable/ID
259-
GET /v2/timetable/ID # Timetable with list of train schedule ids attached to it
262+
POST /timetable
263+
GET /timetable/ # Paginated list timetable
264+
PUT /timetable/ID
265+
DELETE /timetable/ID
266+
GET /timetable/ID/train_schedules # Paginated list of train schedules
267+
GET /timetable/ID/paced_trains # Paginated list of paced_trains
260268
```
261269
262270
### Train Schedule
263271
264272
```
265-
POST /v2/timetable/ID/train_schedule # A batch creation
266-
GET /v2/train_schedule/ID
267-
PUT /v2/train_schedule/ID # Update a specific train schedule
268-
DELETE /v2/train_schedule # A batch deletion
273+
POST /timetable/ID/train_schedules # A batch creation
274+
GET /train_schedule/ID
275+
PUT /train_schedule/ID # Update a specific train schedule
276+
DELETE /train_schedule # A batch deletion
277+
```
278+
279+
### Paced Train
280+
281+
POST /timetable/ID/paced_trains # A batch creation
282+
GET /paced_train/ID
283+
PUT /paced_train/ID # Update a specific paced train
284+
DELETE /paced_trains # A batch deletion
269285
```
270286

271287
### Path
272288

273289
```
274-
POST /v2/infra/ID/pathfinding/topo # Not required now can be move later
275-
POST /v2/infra/ID/pathfinding/blocks
290+
POST /infra/ID/pathfinding/topo # Not required now can be move later
291+
POST /infra/ID/pathfinding/blocks
276292
# takes a pathfinding result and a list of properties to extract
277-
POST /v2/infra/ID/path_properties?props[]=slopes&props[]=gradients&props[]=electrifications&props[]=geometry&props[]=operational_points
278-
GET /v2/train_schedule/ID/path?infra_id=42 # Retrieve the path from a train schedule
293+
POST /infra/ID/path_properties?props[]=slopes&props[]=gradients&props[]=electrifications&props[]=geometry&props[]=operational_points
294+
GET /train_schedule/ID/path?infra_id=42 # Retrieve the path from a train schedule
295+
GET /paced_train/ID/path?infra_id=42 # Retrieve the path from a paced_train
279296
```
280297

281298
### Simulation results
282299

283300
```
284301
# Retrieve the list of conflict of the timetable (invalid trains are ignored)
285-
GET /v2/timetable/ID/conflicts?infra=N
302+
GET /timetable/ID/conflicts?infra=N
286303
# Retrieve the space, speed and time curve of a given train
287-
GET /v2/train_schedule/ID/simulation?infra=N
304+
GET /train_schedule/ID/simulation?infa=N
305+
# Retrieve the space, speed and time curve of a given paced train
306+
GET /paced_train/ID/simulation?infa=N
288307
# Retrieves simulation information for a given train list. Useful for finding out whether pathfinding/simulation was successful.
289-
GET /v2/train_schedule/simulations_summary?infra=N&ids[]=X&ids[]=Y
308+
GET /train_schedule/simulations_sumary?infa=N&ids[]=X&ids[]=Y
309+
# Retrieves simulation information for a given paced train list. Useful for finding out whether pathfinding/simulation was successful.
310+
GET /paced_train/simulations_sumary?infa=N&ids[]=X&ids[]=Y
290311
# Projects the space time curves and paths of a number of train schedules onto a given path
291312
POST /v2/train_schedule/project_path?infra=N&ids[]=X&ids[]=Y
313+
# Projects the space time curves and paths of a number of paced trains onto a given path
314+
POST /paced_train/project_path?infra=N&ids[]=X&ids[]=Y
292315
```
293316

294317
## Frontend workflow

0 commit comments

Comments
 (0)