Get archived freights list

This method allows you to get a list of archived freights, cre­at­ed both using the API and cre­at­ed by users of the Trans.eu Plat­form under the same cus­tomer (com­pa­ny) account.

It is pos­si­ble to apply fil­ters that allow you to down­load the list accord­ing to the spec­i­fied cri­te­ria. By call­ing the method, it is also pos­si­ble to spec­i­fy fields from the list to be returned as a result of the query.

Those freights ori­gin from Freights sent mod­ule.

Available query modifiers:

  • To spec­i­fy fil­ters when retriev­ing the freight list, send the fil­ter para­me­ter in the request
  • To spec­i­fy the fields returned in the request, the “fields” para­me­ter should be sent

Authorization and access

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.

Url parameters and connection settings

  • URL: https://api.platform.trans.eu
  • End­point: /ex­t/freights-api/v1/archive
  • HTTP Method: GET

Headers

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

Freight information available using a list

List of freights con­sists of:

  • id
  • ref­er­ence num­ber
  • cre­ation date
  • archiviza­tion date
  • pub­li­ca­tion infor­ma­tion
  • freight sta­tus
  • exter­nal iden­ti­fi­ca­tion num­ber
  • ftl/ltl infor­ma­tion
  • array of allowed truck bod­ies
  • vehi­cle size
  • load­ing and unload­ing (first and last spot if freight con­sists of more than two spots)
    • loca­tion
    • oper­a­tions

Available filters

List of avail­able fil­ters

  • truck body type ( ?filter={“truck_body_type”:“cooler”} )
  • load­ing place ( ?filter={“loading_place”:{“country”:“44_netherlands”,“postal_code”:“1012”}} )
  • unload­ing place ( ?filter={“unloading_place”:{“country”:“47_poland”,“postal_code”:“31”}} )
  • load­ing date ( ?filter={“loading_date”:{“start_date”:“2020–03-13”,“end_date”:“2020–03-14”}} )
  • unload­ing date ( ?filter={“unloading_date”:{“start_date”:“2020–03-15”,“end_date”:“2020–03-16”}} )

Sort by

  • sta­tus (?sortBy=status)
  • archiv­ing date (?sortBy=archived_at)
  • load­ing date (?sortBy=loading_date)
  • unload­ing date (?sortBy=unloading_date)
  • cre­ation date (?sortBy=created_at)

Response example

[
  {
    "archived_at": "2021-02-05T11:21:33+01:00",
    "created": "2021-02-05T11:18:22+01:00",
    "ftl": false,
    "id": 593651,
    "loading": {
      "coordinates": {
        "latitude": null,
        "longitude": null
      },
      "place": {
        "country": "pl",
        "locality": "Wroclaw",
        "postal_code": "12345"
      },
      "timespans": {
        "begin": "2021-02-08T11:18:20+01:00",
        "end": "2021-02-08T13:18:20+01:00"
      }
    },
    "publication": {
      "end_reason": "accepted",
      "id": 502505,
      "is_proposal_request_exists": false,
      "is_quick_pay": false,
      "is_recommended": false,
      "price": {
        "currency": "eur",
        "period": {
          "days": 5,
          "payment": "deferred"
        },
        "value": 110
      },
      "publish_date": "2021-02-05T11:18:22+01:00",
      "publish_type": "companies",
      "received_offers": 1,
      "refresh_from": null,
      "sent_offers": 1,
      "smart_match_offers": null,
      "status": "finished",
      "stock_id": null
    },
    "reference_number": "FR/2021/02/05/X7G5",
    "shipment_external_id": null,
    "status": "accepted",
    "truck_bodies": [
      "curtainsider"
    ],
    "unloading": {
      "coordinates": {
        "latitude": null,
        "longitude": null
      },
      "place": {
        "country": "de",
        "locality": "Nürnberg",
        "postal_code": "09876"
      },
      "timespans": {
        "begin": "2021-02-11T11:18:20+01:00",
        "end": "2021-02-11T13:18:20+01:00"
      }
    },
    "vehicle_size": "any_size"
  },
  {
    "next_freight": "next_freight"
  }
]