1. Home
  2. Private: Container Tracking
  3. Modify a Tracking

Modify a Tracking

In order to modify a tracking of a specific container, a PUT request may be submitted to

https://oceantrack.gatehouse.com/api/container_info/put

This functionality is typically relevant for when a container has been submitted with the wrong SCAC. However, kindly note that if a container has been submitted without a SCAC, and it has yet to be matched, this functionality will be unavailable. While we always recommend submitting SCACs where possible, it is better to let our leased container system match the container(s) in question than modify them after the fact. Indeed, attempting to do this will return an appropriate error.

Note that Basic Authentication in the form of a username and password is necessary to submit a successful request. If you do not have any authentication details, please contact us.

The submitted payload must include the following fields:

{
  "equipmentIdentifier": {
    "type": "CONTAINER_ID",
    "value": "ABCD1234567"
  },
  "carrierSCACCode": "SCAC"
}

Please see our list of supported carriers and list of supported carriers and SCACs.

Including Content-Type: application/json in the headers is necessary. Additionally, we require the value, or container number, to adhere to the ISO 6346:1995 format. Similarly, any submitted SCAC must be valid and of length four. We require SCACs to adhere to the NMFTA standard.

Upon successfully submitting a container for tracking, the following response is returned with status 200:

{
    "success": "true",
    "message": "tracking of ABCD1234567 started successfully"
}

A container will be tracked until its current shipment has completed. In most cases, it is possible to request information on the submitted container within five minutes of initial submission, after which container will be refreshed automatically every 8th hour. Any requests in the interim will thus always yield the same, most recent update.

Errors

Three types of errors can occur:

  1. The container is already being treated as a leased container and is currently being matched,
  2. the container is not owned by the customer submitting the request,
  3. or, an invalid container number or SCAC was submitted.

In all cases, an appropriate error message is returned and the container is not queued for tracking.

Python Example

The following code snippet submits container MSKU1234567 for tracking with an updated SCAC of SUDU.

import requests
from requests.auth import HTTPBasicAuth

payload = {
	"equipmentIdentifier": {
		"type": "CONTAINER_ID",
		"value": "MSKU1234567"},
	"carrierSCACCode": "SUDU"
}

response = requests.put(
    "https://oceantrack.gatehouse.com/api/container_info/track/",
    headers={"Content-Type": "application/json"},
    auth=HTTPBasicAuth("user", "pass"),
    data=payload)
  
print(response)