Assign truck and driver to received order

Description

This method allows you to assign truck and driver to received order.
You  can get driver_id (which is the trans_id that is assigned to the driver) using method described here.
Values ​​such as semi_trailer_id and vehicle_id can be found in the fleet.


Url parameters and connection settings

  • URL: https://api.platform.trans.eu
  • Endpoint: /ext/orders-api/v1/orders/{orderId}/assignee
  • Method: POST

Headers

  • Content-type: application/json
  • Accept: application/json
  • Authorization: Bearer {access_token}
  • Api-key: {unique_app_api-key}

Authorization and access

Authorization process is described here.  Each API request must also consist of unique Api-key obtained during application registration together with client_id and client_secret.


Request

Example of request for truck and driver assignment.

{
  "driver_id": "4321-1",
  "semi_trailer_id": 1017334,
  "vehicle_id": 1012335
}

Response

Confirmation of properly sent request.

{
  "driver": {
  "account_id": 10127335,
  "email": "example@trans.eu",
  "employee_id": 862902,
  "family_name": "Kowalski",
  "full_name": "Jan Kowalski",
  "given_name": "Jan",
  "identity_document_number": null,
  "phone": "0048 11111111",
  "phone_visible_to_contractor": true
}
}