Skip to content

Commit

Permalink
Update api.md (#6054)
Browse files Browse the repository at this point in the history
* Update api.md

alternatives_count was missing in this document,

Copied from here:
https://github.com/Project-OSRM/osrm-backend/blob/master/docs/http.md#waypoint-object
  • Loading branch information
omerXfaruq authored Sep 4, 2021
1 parent f1a6056 commit 8e100ea
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions docs/nodejs/api.md
Original file line number Diff line number Diff line change
Expand Up @@ -244,9 +244,16 @@ osrm.match(options, function(err, response) {
Returns **[Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)** containing `tracepoints` and `matchings`.
**`tracepoints`** Array of [`Ẁaypoint`](#waypoint) objects representing all points of the trace in order.
If the trace point was ommited by map matching because it is an outlier, the entry will be null.
Each `Waypoint` object includes two additional properties, 1) `matchings_index`: Index to the
[`Route`](#route) object in matchings the sub-trace was matched to, 2) `waypoint_index`: Index of
Each `Waypoint` object has the following additional properties,

1) `matchings_index`: Index to the
[`Route`](#route) object in matchings the sub-trace was matched to,

2) `waypoint_index`: Index of
the waypoint inside the matched route.

3) `alternatives_count`: Number of probable alternative matchings for this trace point. A value of zero indicate that this point was matched unambiguously. Split the trace at these points for incremental map matching.

**`matchings`** is an array of [`Route`](#route) objects that assemble the trace. Each `Route` object has an additional `confidence` property,
which is the confidence of the matching. float value between `0` and `1`. `1` is very confident that the matching is correct.

Expand Down

0 comments on commit 8e100ea

Please sign in to comment.