Sorry, you need to enable JavaScript to visit this website.

Analysis Preview

Request

Format

https://api.tomtom.com/origindestination/1/analysis/<id>?key=<apiKey>

Example

https://api.tomtom.com/origindestination/1/analysis/512?key=test-api-key

Parameters

Parameter Description

id

Analysis number id.

apiKey

Authorization key for access to the API.

Response

Response structure

Field Description

analysisInfo

Information about the analysis

analysisInfo.id

Analysis number id.

analysisInfo.name

Job name, given for user’s convenience.

analysisInfo.owner

Email of the analysis' owner

analysisInfo.status

Job status.
One of the following values:

  • WAITING

  • RUNNING

  • ENDED

  • FAILED

  • CANCELLED

  • ACCEPTED

  • REJECTED

analysisInfo.currentProgress

Current value of job progress (0-100)

analysisInfo.creationTime

Job creation time in YYYY-MM-DDTHH:mm:ss.SSSZ format

analysisInfo.timeDefinition

Time definition of the analysis

analysisInfo.tripsCounted

How many trips were counted. Updates when analysis is in progress.

analysisInfo.startAnalysisTime

Date and time start of analysis in format: YYYY-MM-DDTHH:mm:ss.SSSZ

analysisInfo.endAnalysisTime

Date and time end of analysis in format: YYYY-MM-DDTHH:mm:ss.SSSZ

regionsLink

URL to the regions defined in the analysis

results

List of the results available only when analysis has status ACCEPTED

Field Description

tripsWholeResultLink

URL to the whole analysis trips result

tripsPartialResultLink

URL to the partial analysis trips result

durationsHistogramPartialResultLink

URL to the partial analysis trips duration histogram result

lengthsHistogramPartialResultLink

URL to the partial analysis trips lengths histogram result

hoursOfDayHistogramPartialResultLink

URL to the partial analysis trips start hour of day histogram result

tripsResultFileSize

Trips result file size in megabytes. It will help you decide if you want to download whole result or partial

dateRange

Date range of the result

dateRange.startDate

Start date of date range in YYYY-MM-DD format

dateRange.endDate

End date of date range in YYYY-MM-DD format

dateRange

Time range of the result

timeRange.startTime

Start time of time range in HH:mm format

timeRange.endTime

End time of time range in HH:mm format

Trips result structure

Field Description

links

Array of link between regions

Result interpretation example

{
  "links": [[0,0,0,100], [0,1,1,200], ...]
}

Result contains list of 'links'. Each link contains information about trips between regions and looks like this:
[Origin region index (number), Destination region index (number), Via region index (number), Amount of trips (number)]

Errors

If there is an error in the supplied parameters or any other internal problem an error response is generated in the requested format.

HTTP Response Codes
Code Reason

401

Unauthorized

403

Forbidden

404

Not Found

You are here