Add new monitoring task

Allows to cre­ate new mon­i­tor­ing task with cho­sen car­ri­er.

Mon­i­tor­ing of ship­ment on the route between load­ing and unload­ing points with­out the need to spec­i­fy the type and dimen­sions of the load trans­port­ed. Allows to receive loca­tion updates dur­ing ship­ment.

Url parameters and connection settings

  • URL: https://api.platform.trans.eu
  • End­point:/ex­t/loads-mon­i­tor­ing-api/v1/­mon­i­tor­ings
  • Http Method: POST

Headers

  • Accept: application/json
  • Con­tent-type: application/json
  • Autho­riza­tion: Bear­er {access_token}
  • Api-key: {unique_ap­p_api-key}

Authorization

Autho­riza­tion process is described here. Each API request must also con­sist of unique Api-key obtained dur­ing appli­ca­tion reg­is­tra­tion togeth­er with client_id and client_secret.

Description and example values

JsonIs requiredExam­pleTypeDescrip­tion
office_idYes11111StringIden­ti­fi­ca­tion num­ber of com­pa­ny assigned to mon­i­tor­ing task
spotsYesObjectCol­lec­tion of freights’ spots – at least one load­ing and one unload­ing is required
spots.placeYesObjectCol­lec­tion of loca­tions of mon­i­tored route
spots.place.addressYesObjectAddress
spots.place.address.countryYesDEStringISO val­ue for coun­try of load­ing or unload­ing spot
spots.place.address.postcodeYesD1234StringPostal code
spots.place.address.localityYesHam­burgStringTown
spots.place.address.streetYesStrasseStringStreet
spots.place.address.numberYes11StringNum­ber
spots.place.coordinatesYesObjectLon­gi­tude and lat­i­tude for select­ed point
spots.place.coordinates.longitudeYes49.1231FloatLon­gi­tude of the point along mon­i­tored route
spots.place.coordinates.latitudeYes11.123FloatLat­i­tude of the point along mon­i­tored route
spots.operationsYesObjectArray of oper­a­tions to be com­plet­ed in giv­en spot
spots.operations.typeYesLoad­ingStringCould be either load­ing or unload­ing, at least one of each is required
spots.operations.time_frameYesObjectTime­frame of oper­a­tion
spots.operations.time_frame.date_fromYes2021–02-16T15:00:00Time­stampDate from
spots.operations.time_frame.date_toYes2021–02-16T16:00:00Time­stampDate to
infoYesExam­pleStringAddi­tion­al infor­ma­tion or route descrip­tion

Request body example

{
  "office_id": 123,
  "spots": [
    {
      "place": {
        "address": {
          "locality": "Hamburg",
          "postcode": "D1234",
          "country": "DE",
          "street": "Example street",
          "number": "17"
        },
         "coordinates": {
          "latitude": 54.3705784,
          "longitude": 18.652582
        }
      },
      "operations": [
        {
          "type": "loading",
          "time_frame": {
            "date_from": "2020-03-23T11:27:39.000Z",
            "date_to": "2020-03-24T12:22:39.000Z"
          }
        }
      ]
    },
    {
      "place": {
        "address": {
          "locality": "Gdansk",
          "postcode": "87-800",
          "country": "PL",
          "street": "Example street",
          "number": "11"
        }
      },
      "coordinates": {
        "latitude": 54.3705784,
        "longitude": 18.652582
      },
      "operations": [
        {
          "type": "unloading",
          "time_frame": {
            "date_from": "2020-03-25T11:27:39.000Z",
            "date_to": "2020-03-25T12:22:39.000Z"
          }
        }
      ]
    }
  ],
  "info": "Example monitoring info"
}