# Get tour by ID Endpoint: GET /v1/tours/{tourId} Version: 1.0.0 Security: ApiKeyAuth ## Path parameters: - `tourId` (string, required) Unique tour identifier (generated by Better Route backend) ## Response 200 fields (application/json): - `data` (object) Full information about an individual tour, excluding the sequence information - `data.tourId` (string) Tour identifier generated by the backend - `data.date` (string) Date on which the tour is / will be driven - `data.assignment` (string) Vehicle / route / driver identifier. - `data.depot` (string) Depot identifier - `data.created` (string) - `data.jobs` (array) All jobs for tour's assignment. Jobs not referenced in waypoints have no or insufficient address data. - `data.jobs.jobId` (string) A unique identifier used within Bettermile. The API will only accept / use this id to identify jobs in requests. - `data.jobs.externalId` (string,null) The job id provided to Bettermile Data Gateway. Can't be used to reference this job when communicating with the API. Example: "E00013222111" - `data.jobs.type` (string) Types of a job Enum: "DELIVERY", "PICKUP", "COLLECTION", "CUSTOM", "UNKNOWN" - `data.jobs.originalAddress` (any) Only present, if also provided via the connector data. - `data.jobs.redirectOriginalAddress` (any) Only present, if also provided via the connector data. - `data.jobs.navigationAddress` (any) Filled by Bettermile during tour creation. A job provided without a navigationAddress will be not included in any waypoint. - `data.jobs.state` (any) Example: "UNPROCESSED" - `data.jobs.outcome` (any) - `data.jobs.timeFrames` (array) - `data.jobs.timeFrames.earliest` (string) Example: "14:00:00" - `data.jobs.timeFrames.latest` (string) Example: "16:00:00" - `data.jobs.timeFrames.timezone` (string) Example: "Europe/Berlin" - `data.waypoints` (array) Tour waypoints in no particular order - `data.waypoints.waypointId` (string) A unique identifier of this waypoint - `data.waypoints.jobIdentifiers` (array) List of job IDs (internal and external) - `data.waypoints.jobIdentifiers.internalId` (string) Internal Job ID reference as UUID - `data.waypoints.jobIdentifiers.externalId` (string,null) External Job ID reference as string - `data.waypoints.address` (object) An address - `data.waypoints.address.street` (string,null) Street - `data.waypoints.address.streetNumber` (string,null) Street number - `data.waypoints.address.locality` (string,null) City, town, village etc - `data.waypoints.address.postalCode` (string,null) Postal/zip code - `data.waypoints.address.country` (string,null) Country as "alpha-2 code" of ISO 3166 (https://en.wikipedia.org/wiki/List_of_ISO_3166_country_codes) - `data.waypoints.address.streetCoordinates` (any) - `data.waypoints.address.rooftopCoordinates` (any) - `data.waypoints.status` (string) State of the waypoint Enum: "UNPROCESSED", "PROCESSED", "CONFIRMED" - `data.waypoints.closedAtTimestamp` (string,null) Time at which this waypoint was closed - `data.waypoints.stopTimeInSeconds` (number) How much time is planned for stopping at the waypoint and delivering / picking up parcels - `data.waypoints.timeFrame` (object,null) Time window with earliest and latest possible time - `data.waypoints.type` (object) - `data.waypoints.jobIds` (array) List of job references as UUIDs. Deprecated use jobIdentifiers instead - `data.rttCategory` (string) Category assigned by Real Time Tracking Enum: "GOOD", "MEDIUM", "BLOCKED" - `data.destination` (object,null) Destination for a tour / sequence - `data.destination.eta` (string,null) Arrival time to the destination - `data.unassignedJobIdentifiers` (array) Identifiers of jobs that couldn't be assigned to any waypoint (e.g. due to lacking coordinates). ## Response 400 fields (application/json): - `error` (object) Error response - `error.status` (integer) HTTP error status Example: 400 - `error.message` (string) Human readable error message Example: "'depot' field can't be null" - `error.errorCode` (string) Machine-friendly error message containing only alphanumeric characters and '.' Example: "tour.list.fetch.failed.bad.request" - `error.details` (array) ## Response 401 fields (application/json): - `error` (object) Error response - `error.status` (integer) HTTP error status Example: 400 - `error.message` (string) Human readable error message Example: "'depot' field can't be null" - `error.errorCode` (string) Machine-friendly error message containing only alphanumeric characters and '.' Example: "tour.list.fetch.failed.bad.request" - `error.details` (array) ## Response 404 fields (application/json): - `error` (object) Error response - `error.status` (integer) HTTP error status Example: 400 - `error.message` (string) Human readable error message Example: "'depot' field can't be null" - `error.errorCode` (string) Machine-friendly error message containing only alphanumeric characters and '.' Example: "tour.list.fetch.failed.bad.request" - `error.details` (array) ## Response 500 fields (application/json): - `error` (object) Error response - `error.status` (integer) HTTP error status Example: 400 - `error.message` (string) Human readable error message Example: "'depot' field can't be null" - `error.errorCode` (string) Machine-friendly error message containing only alphanumeric characters and '.' Example: "tour.list.fetch.failed.bad.request" - `error.details` (array)