Register shipment for future tracking.
Arguments
Argument | Type | Description |
---|---|---|
shipments | [TrackedShipmentInput!]! | The shipments' identification credentials and the data to update. |
TrackedShipmentInput Fields
Field | Type | Description |
---|---|---|
bol | BOL | The Bill of Lading of the shipment to be tracked. |
carrierBookingReference | [carrierBookingReference] | A unique number assigned to a scheduled transportation movement which allocates assets, space needed and a transport plan. |
containerNumber | ContainerNumber | The container of the shipment to be tracked. |
customer | CustomerInput | The details of the customer of the shipment to be tracked. |
masterShipment | MasterShipmentInput | The details of the master shipment of the shipment to be tracked. |
metadata | TrackedShipmentMetadataInput | The metadata of the shipment to be tracked. |
scac | SCAC | The shipment Standard Carrier Alpha Code of the shipment to be tracked. |
shipmentId | ObjectId | The shipment ID of the shipment to be tracked. |
shipmentsUploadId | ObjectId | The shipment upload ID of the shipment to be tracked. |
Return
Name | Description |
---|---|
[TrackedShipment!]! | The registered shipment's data and metadata. |
TrackedShipment Fields
Field | Type | Description |
---|---|---|
createdAt | DateTime! | Shipment's tracking start timestamp. |
id | ObjectId! | Unique Windward assigned shipment ID. |
metadata | TrackedShipmentMetadata | Additional metadata updated by the user. |
shipment | Shipment | Contains all the information on the shipment. |
updatedAt | DateTime! | Shipment's last update timestamp. |
Example Code
Sample Mutation
mutation UpsertTrackedShipments($shipments: [TrackedShipmentInput!]!) {
upsertTrackedShipments(shipments: $shipments) {
id
shipment {
id
carrierBookingReference
containerNumber
bol
scac
carrier {
code
shortName
longName
codeAliases
}
container {
id
number
isoCode
}
status {
id
events {
timestamps {
datetime
code
}
voyage
utcOffset
vessel {
name
imo
flag
class
mmsi
}
port {
properties {
name
country
locode
}
}
}
estimatedArrivalAt
estimatedDepartureAt
actualArrivalAt
actualDepartureAt
currentEvent {
timestamps {
datetime
code
}
voyage
utcOffset
vessel {
name
imo
flag
class
mmsi
}
port {
properties {
name
country
locode
}
}
}
milestones {
type
port {
properties {
name
country
locode
}
}
utcOffset
arrival {
vessel {
name
imo
flag
class
mmsi
}
voyage
timestamps {
carrier {
datetime
code
}
predicted {
datetime
code
}
}
}
departure {
vessel {
name
imo
flag
class
mmsi
}
voyage
timestamps {
carrier {
datetime
code
}
predicted {
datetime
code
}
}
}
}
pod {
properties {
name
country
locode
}
}
pol {
properties {
name
country
locode
}
}
postPod {
properties {
name
country
locode
}
}
}
}
createdAt
updatedAt
metadata {
businessData {
key
value
}
eta
etd
jobNumber
pod
pol
}
}
}
Variables
{
"shipments": [
{
"containerNumber": "TRHU8251254"
},
{
"containerNumber": "CSNU7092694",
"bol":"COSU6321888720",
"scac":"COSU"
},
{
"containerNumber": "FCIU5898000",
"scac":"COSU"
},
{
"bol": "HLCUDE12112BFHX0",
"scac":"HLCU"
},
{
"carrierBookingReference": "HLCUDE12112BFHX0",
"scac":"HLCU",
"metadata":
{
"businessData":[
{ "key":"shipper", "value":"shipper_a"},
{ "key":"username", "value":"user_a"},
{ "key":"department", "value":"export"}
]
}
}
]
}
Response
{
"data": {
"upsertTrackedShipments": [
{
"id": "671faec9e48c9b3e300eddc2",
"shipment": {
"id": "671faec95c72176ef1cba796",
"carrierBookingReference": "HLCUDE12112BFHX0",
"containerNumber": null,
"bol": null,
"scac": "HLCU",
"carrier": {
"code": "HLCU",
"shortName": "Hapag Lloyd",
"longName": "Hapag-Lloyd",
"codeAliases": [
"HLCU",
"HLXU",
"HPGC",
"HLUS"
]
},
"container": null,
"status": null
},
"createdAt": "2024-10-28T15:33:29.643Z",
"updatedAt": "2024-10-28T15:33:29.643Z",
"metadata": {
"businessData": [
{
"key": "shipper",
"value": "shipper_a"
},
{
"key": "username",
"value": "user_a"
},
{
"key": "department",
"value": "export"
}
],
"eta": null,
"etd": null,
"jobNumber": null,
"pod": null,
"pol": null
}
},
{
"id": "671faec9e48c9b3e300eddc5",
"shipment": {
"id": "671faec95c72176ef1cba798",
"carrierBookingReference": null,
"containerNumber": "CSNU7092694",
"bol": "COSU6321888720",
"scac": "COSU",
"carrier": {
"code": "COSU",
"shortName": "COSCO",
"longName": "COSCO",
"codeAliases": [
"COSU",
"CQGD",
"CQSQ",
"CSHI",
"CSNG",
"CSZH",
"CXMN",
"COAU"
]
},
"container": {
"id": "671faeca04b372d3a834a1b2",
"number": "CSNU7092694",
"isoCode": null
},
"status": null
},
"createdAt": "2024-10-28T15:33:29.643Z",
"updatedAt": "2024-10-28T15:33:29.643Z",
"metadata": null
},
{
"id": "671faec9e48c9b3e300eddc8",
"shipment": {
"id": "671faec95c72176ef1cba797",
"carrierBookingReference": null,
"containerNumber": "FCIU5898000",
"bol": null,
"scac": "COSU",
"carrier": {
"code": "COSU",
"shortName": "COSCO",
"longName": "COSCO",
"codeAliases": [
"COSU",
"CQGD",
"CQSQ",
"CSHI",
"CSNG",
"CSZH",
"CXMN",
"COAU"
]
},
"container": {
"id": "671faeca04b372d3a834a1b1",
"number": "FCIU5898000",
"isoCode": null
},
"status": null
},
"createdAt": "2024-10-28T15:33:29.643Z",
"updatedAt": "2024-10-28T15:33:29.643Z",
"metadata": null
},
{
"id": "671faec9e48c9b3e300eddcb",
"shipment": {
"id": "671faec95c72176ef1cba799",
"carrierBookingReference": null,
"containerNumber": "TRHU8251254",
"bol": null,
"scac": null,
"carrier": null,
"container": {
"id": "671faeca04b372d3a834a1b3",
"number": "TRHU8251254",
"isoCode": null
},
"status": null
},
"createdAt": "2024-10-28T15:33:29.643Z",
"updatedAt": "2024-10-28T15:33:29.643Z",
"metadata": null
}
]
}
}