Scans
import scan data/Api/FreightScan
The scan API method allows HTTP Put actions and requires the consignment to already exist in the system.
HTTP Put
Allows you to update a consignment status in your TransVirtual database.
Request Properties
| Property Name | Required | Description |
|---|---|---|
| ConsignmentNumber | Consignment number (also the tracking number).[Required if UniqueId or Id not provided] Max length: 100 | |
| Id | A unique TransVirtual key value that our system returned on consignment creation.[Required if ConsignmentNumber or UniqueId not provided] Max length: 20 | |
| UniqueId | A unique key value that your system will identify with the consignment.[Required if ConsignmentNumber or Id not provided] Max length: 200 | |
| DateTime | Yes | The date of the scan. Format: yyyy-MM-dd HH:mm (for UTC) or yyyy-MM-ddTHH:mm+Z (for local Ex: 2016-05-10T10:30+10:00) |
| ScannedValue | Yes | The name of the status |
| ScanType | Yes | The scan type [Damaged, DepotIn, HeldOver, LinehaulOut, Misdirected, Short, PickedUP, OnDelivery, Floor, AtLocation] |
| ScanLocation | The scan location | |
| CreatedBy | The driver/staff member that triggered this scan | |
| UniqueIdScan | Your unique ID of this scan | |
| ScanDestLocation | The destination location (used for linehaul scans) | |
| ScanVehicleName | The vehicle name associated with this scan | |
| ScanVehicleRego | The vehicle rego associated with this scan | |
| ScanTag | A general tag against this scan | |
| Comment | Any notes or comments against this scan | |
| ApiImportTag | A tag that can be used to assist with generating advanced export rules. Max length: 50 | |
| ScanEventWeightCheckLength | Import updated length value from scan check/weight/cube. Decimal | |
| ScanEventWeightCheckWidth | Import updated width value from scan check/weight/cube. Decimal | |
| ScanEventWeightCheckHeight | Import updated height value from scan check/weight/cube. Decimal | |
| ScanEventWeight | Import updated weight value from scan check/weight/cube. Decimal |
Response Properties
The response properties for the HTTP Put found within the Data field of the reponse
| Property Name | Description |
|---|---|
| Id | The TransVirtual Id of the scan created |
Example Put
Request (json)
Response (json)
Error Codes
| Error Code | Description |
|---|---|
| 2150 | BarcodeMissing |
| 2151 | ScanTypeMissing |