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

Search Jobs

To list all of your jobs or just filtered out part of them you can use this endpoint.

Request URL

https://<baseURL>/traffic/trafficstats/job/search/<versionNumber>?key=<apiKey>

Parameters

The table below describes all of the parameters that can be used in a request. Required parameters must be used or the call will fail. Optional parameters may be used.

Parameter Description Req'd? Type / Values
baseURL Base URL for calling the API. Yes api.tomtom.com
versionNumber Service version number. The current value is 1. Yes 1
apiKey Authorization key for access to the API. Yes API Key
pageIndex Index of page with jobs. Pages counting starts from 0.
When number of jobs matching specified search criteria is greater than perPage then only part of jobs will be returned. To retrieve remaining parts it may be necessary to repeat request with incrementing value of this parameter.
No Integer >=0
perPage Numer of jobs included in page. Last page may have less jobs. No Positive integer
createdAfter Earliest date of requesting jobs (inclusive). No Date in format:
YYYY-MM-DD
Days change according to UTC time zone.
createdBefore Latest date of requesting jobs (inclusive). No Date as above
completedAfter Earliest date of completing jobs (inclusive). No Date as above
completedBefore Latest date of completing jobs (inclusive). No Date as above
name

Name of job(s). By default exact match is done. % is special character which allows for partial matching:

  • %London - search for jobs which name ends with London
  • London% - search for jobs which name starts with London
  • %London% - search for jobs which name contains London
No String
id Id of a job No Integer
type Type of jobs No

Set of comma-separated values from:

  • routeanalysis
  • areaanalysis
  • trafficdensity
state Current state of jobs No

Set of comma-separated values from:

  • NEW
  • MAPMATCHING
  • MAPMATCHED
  • READING_GEOBASE
  • CALCULATIONS
  • NEED_CONFIRMATION
  • DONE
  • ERROR
  • REJECTED
  • EXPIRED

Request URL example

GET https://api.tomtom.com/traffic/trafficstats/job/search/1?key=<apiKey>&createdAfter=2018-01-01&createdBefore=2018-02-01&name=%London%&type=routeanalysis&state=DONE

Response example

{
   "content":[
      {
         "id":123,
         "name":"London A501 weekdays",
         "type":"Route Analysis",
         "createdAt":"2018-01-02T10:22:33Z",
         "completedAt":"2018-01-02T11:28:22Z",
         "state":"DONE"
      },
      {
         "id":127,
         "name":"London A501 weekends",
         "type":"Route Analysis",
         "createdAt":"2018-01-02T10:18:47Z",
         "completedAt":"2018-01-02T11:24:07Z",
         "state":"DONE"
      },
      {
         "id":365,
         "name":"Waterloo Bridge in London City",
         "type":"Route Analysis",
         "createdAt":"2018-01-05T20:18:10Z",
         "completedAt":"2018-01-05T21:24:08Z",
         "state":"DONE"
      }
   ],
   "pageable":{
      "sort":{
         "sorted":true,
         "unsorted":false,
         "empty":false
      },
      "pageSize":20,
      "pageNumber":0,
      "offset":0,
      "paged":true,
      "unpaged":false
   },
   "totalElements":3,
   "last":false,
   "totalPages":1,
   "first":true,
   "sort":{
      "sorted":true,
      "unsorted":false,
      "empty":false
   },
   "numberOfElements":20,
   "size":20,
   "number":0,
   "empty":false
}

JSON result description

Field Description Type / Values
id Job id Integer
name Name of job String
type Type of job
  • Route Analysis
  • Area Analysis
  • Traffic Density
createdAt Job creation time Timestamp in format:
YYYY-MM-DDTHH:mm:ss.SSSZ
completedAt Job completion time Timestamp as above
state Job state
  • NEW
  • MAPMATCHING
  • MAPMATCHED
  • READING_GEOBASE
  • CALCULATIONS
  • NEED_CONFIRMATION
  • DONE
  • ERROR
  • REJECTED
  • EXPIRED