originDestinationMatrix
originDestinationMatrix
FunctionoriginDestinationMatrix(requestOptions: IOriginDestinationMatrixOptions): Promise<IOriginDestinationMatrixResponse>
Used to create an origin-destination (OD) cost matrix from multiple origins to multiple destinations. See the REST Documentation for more information.
Parameters
Parameter | Type | Notes |
---|---|---|
request | IOriginDestinationMatrixOptions | Options to pass through to the routing service. |
Returns
Promise<IOriginDestinationMatrixResponse>
A Promise that will resolve with travel time and/or distance for each origin-destination pair. It returns either odLines or odCostMatrix for this information depending on the outputType you specify.