Get info about a track using its 6 letters/numbers code. This can be used by external software like lap timers to get the length/pieces of the track without entering them manually.

NOTE: ONLY WORKS FOR 3-LANE TRACKS AT THE MOMENT.

Request example

/api/track/FWCQGR

Response example

{"code":"FWCQGR","created_at":"2017-02-27T18:46:43.000Z","url":"http://0.0.0.0:3000/FWCQGR","view_url":"http://0.0.0.0:3000/view/FWCQGR","pieces":[{"type":"45_CORNER","count":48},{"type":"STRAIGHT","count":41},{"type":"RAINBOW_CHANGER","count":1},{"type":"LANE_CHANGER","count":3},{"type":"BANK","count":2}],"length":153.09,"changers":4,"order":[1,2,3]}

Response fields

  • code: the track code.

  • created_at: the track save time.

  • url: the track url for editing.

  • view_url: the track url for printing.

  • pieces: array of objects with the count of each piece type. Eg. {"type":"STRAIGHT","count":10}

  • length: track length in meters.

  • changers: number of lane changers.

  • order: lane order that a car will pass. Can be [1,2,3] or [1,3,2] depending on the number of changers.

Pieces types

  • STRAIGHT

  • 45_CORNER

  • LANE_CHANGER

  • RAINBOW_CHANGER

  • WAVE

  • SLOPE

  • JUMP

  • BANK

Params

Param name Description
code
required

The 6 letters/numbers track code.

Validations:

  • Must be a String