Description of monitoring tasks usage, scope and allowed methods.
Available methods
What is the scope of monitoring tasks:
- create new monitoring task
- get list of monitoring tasks
- get details of single monitoring task by id
- get location of single monitoring task
- accept monitoring task
Creating new monitoring task
With the use of Trans.eu API it is possible for shipper and forwarder to create new monitoring task, displayed in Trans.eu Platform in Monitoring module. After the monitoring task is created, it will be automatically sent to carrier assigned for acceptance.
Diagram
Standard and recommended process for using monitoring tasks
Components of single monitoring task
Each monitoring task consists of:
- places
- operations
- carrier’s id
Monitoring task statuses:
- new
- waiting_for_carrier_acceptance
- waiting for shipper acceptance
- pending_monitoring_data
- ready
- en_route
- alert
- aborted
- finished
- missed
- rejected_by_carrier
- rejected_by_shipper
Description and example values
Structure of posting new monitoring task
Json | Is required | Example | Type | Description |
office_id | Yes | 11111 | String | Identification number of company assigned to monitoring task |
spots | Yes | Object | — | Collection of freights’ spots – at least one loading and one unloading is required |
spots.place | Yes | Object | — | Collection of locations of monitored route |
spots.place.address | Yes | Object | — | Address |
spots.place.address.country | Yes | DE | String | ISO value for country of loading or unloading spot |
spots.place.address.postcode | Yes | D1234 | String | Postal code |
spots.place.address.locality | Yes | Hamburg | String | Town |
spots.place.address.street | Yes | Strasse | String | Street |
spots.place.address.number | Yes | 11 | String | Number |
spots.place.coordinates | Yes | Object | — | Longitude and latitude for selected point |
spots.place.coordinates.longitude | Yes | 49.1231 | Float | Longitude of the point along monitored route |
spots.place.coordinates.latitude | Yes | 11.123 | Float | Latitude of the point along monitored route |
spots.operations | Yes | Object | — | Array of operations to be completed in given spot |
spots.operations.type | Yes | Loading | String | Could be either loading or unloading, at least one of each is required |
spots.operations.time_frame | Yes | Object | — | Timeframe of operation |
spots.operations.time_frame.date_from | Yes | 2021–02-16T15:00:00 | Timestamp | Date from |
spots.operations.time_frame.date_to | Yes | 2021–02-16T16:00:00 | Timestamp | Date to |
info | Yes | Example | String | Additional information or route description |
Structure of confirmation for posting new monitoring task
Json | Is required | Example | Type | Description |
date_created
| No |
2021–02-17T13:19:30.173Z
| Timestamp | Monitoring task creation date |
id
| No |
e4d753f4-b629-4c73-97e0-5dd15648b918
| String | Monitoring task ID |
info
| No | Example | String | Additional information or route description |
reference_number
| No |
2021/02/Q957
| String | Monitoring task reference number |
role
| No |
Shipper
| String | When you add monitoring task, you role is shipper |
spots | No | Object | — | Collection of locations of monitored route |
spots.operations | No | Object | — | Array of operations to be completed in given spot |
spots.operations.completed_at | No | Null | Timestamp | This field has value null after adding monitoring task |
spots.operations.is_completed | No | False | Boolean | This field has value false after adding monitoring task |
spots.operations.time_frame | No | Object | — | Timeframe of operation |
spots.operations.time_frame.date_from | No | 2021–02-16T15:00:00.000Z | Timestamp | Date from |
spots.operations.time_frame.date_to | No | 2021–02-16T16:00:00.000Z | Timestamp | Date to |
spots.operations.type | No | Loading | String | Could be either loading or unloading, at least one of each is required |
spots.place | No | Object | — | Collection of locations of monitored route |
spots.place.address | No | Object | — | Address |
spots.place.address.country | No | DE | String | ISO value for country of loading or unloading spot |
spots.place.address.postcode | No | D1234 | String | Postal code |
spots.place.address.locality | No | Hamburg | String | Town |
spots.place.address.street | No | Strasse | String | Street |
spots.place.address.number | No | 11 | String | Number |
spots.place.coordinates | No | Object | — | Longitude and latitude for selected point |
place.coordinates.longitude | No | 49.1231 | Float | Longitude of the point along monitored route |
place.coordinates.latitude | No | 11.123 | Float | Latitude of the point along monitored route |
status | No |
waiting_for_carrier_acceptance
| String | Monitoring task status |
time_frame | No | Object | — | Timeframe of monitoring task |
time_frame.date_from | No | 2021–02-16T13:30:00.000Z | Timestamp | Date from |
time_frame.date_to | No |
2021–02-18T23:00:00.000Z
| Timestamp | Date to |
Structure of getting single monitoring task and list of tasks
Json | Is required | Example | Type | Description |
date_created
| No |
2021–02-17T13:19:30.173Z
| Timestamp | Monitoring task creation date |
devices
| No | Object | — | A list of devices with their description (such as kind, manufacturer, registration plate number) and also driver details |
finished_at
| No | 2021–02-18T23:00:00.000Z | Timestamp | Monitoring finish time |
id
| No |
e4d753f4-b629-4c73-97e0-5dd15648b918
| String | Monitoring task ID |
info
| No | Example | String | Additional information or route description |
reference_number
| No |
2021/02/Q957
| String | Monitoring task reference number |
role
| No |
Carrier
| String | Your company role in monitoring task (for added monitorings it will be shipper, for received it will be carrier) |
spots | No | Object | — | Collection of locations of monitored route |
spots.operations | No | Object | — | Array of operations to be completed in given spot |
spots.operations.completed_at | No | 2021–02-18T23:38:00.000Z | Timestamp | Completion time |
spots.operations.is_completed | No | True | Boolean | It may be true or false |
spots.operations.time_frame | No | Object | — | Timeframe of operation |
spots.operations.time_frame.date_from | No | 2021–02-16T15:00:00.000Z | Timestamp | Date from |
spots.operations.time_frame.date_to | No | 2021–02-16T16:00:00.000Z | Timestamp | Date to |
spots.operations.type | No | Loading | String | Could be either loading or unloading, at least one of each is required |
spots.place | No | Object | — | Collection of locations of monitored route |
spots.place.address | No | Object | — | Address |
spots.place.address.country | No | DE | String | ISO value for country of loading or unloading spot |
spots.place.address.postcode | No | D1234 | String | Postal code |
spots.place.address.locality | No | Hamburg | String | Town |
spots.place.address.street | No | Strasse | String | Street |
spots.place.address.number | No | 11 | String | Number |
spots.place.coordinates | No | Object | — | Longitude and latitude for selected point |
place.coordinates.longitude | No | 49.1231 | Float | Longitude of the point along monitored route |
place.coordinates.latitude | No | 11.123 | Float | Latitude of the point along monitored route |
status | No |
Finished
| String | Monitoring task status |
time_frame | No | Object | — | Timeframe of monitoring task |
time_frame.date_from | No | 2021–02-16T13:30:00.000Z | Timestamp | Date from |
time_frame.date_to | No |
2021–02-18T23:00:00.000Z
| Timestamp | Date to |