# Container Tracking API, Sinay Vessel ETA, Port Congestion, CO2 (`nabeelbaghoor/container-vessel-eta-port-congestion-api`) Actor

Track containers, bills of lading and bookings across 170+ shipping lines with the Sinay API: status, POL, POD, ETA, events, vessel and AIS position. Plus port congestion, berth occupation, vessels in port, vessel ETA prediction, voyage CO2 per TEU and underwater noise. Bring your own key.

- **URL**: https://apify.com/nabeelbaghoor/container-vessel-eta-port-congestion-api.md
- **Developed by:** [Nabeel Hassan](https://apify.com/nabeelbaghoor) (community)
- **Categories:** Developer tools, Business, Travel
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $15.00 / 1,000 tracked shipment returneds

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Container Tracking API with Sinay: Vessel ETA, Port Congestion and CO2

Track containers, bills of lading and bookings across 170+ shipping lines, and read port congestion, berth occupation, vessel ETA predictions, voyage CO2 per TEU and underwater noise, all through the Sinay APIs with your own API key, as clean dataset rows.

Sinay is a French maritime data company (the maker of the Safecube container tracking platform). Its API family on api.sinay.ai covers container tracking from one endpoint for over 170 global carriers, port intelligence, port congestion, an AI vessel ETA calculator, CO2 emission per TEU and underwater radiated noise. This actor wraps the read only and compute only parts of those documented APIs, so you can pull container ETAs, milestones and port congestion into Google Sheets, BI dashboards, ERP or TMS systems, demurrage alerts or AI agents without writing an API client. Bring your own API key.

BYOK, not live tested: every route, parameter and field comes from Sinay's published OpenAPI definitions on documentation.safecube.ai (documentation.sinay.ai redirects there), checked on 2026-10-26. The service prefixes were probed with an invalid key on the same day. The actor has not been run against a live Sinay key.

### What it does

- **Container shipments**: one row per container number, bill of lading or booking with carrier SCAC and name, shipping status (planned, in transit, delivered), port of loading and port of discharge (UN/LOCODE, name and date, actual or estimated), Sinay's predictive ETA near arrival, container count, the current vessel (name, IMO, MMSI) and its latest AIS position. The full answer, with every container, facility, route segment and AIS block, is kept in `data`.
- **Container events**: one row per container milestone (gate out, loaded, departed, transshipment, arrived, discharged, gate in and more) with DCSA event code, description, actual or estimated date, location, facility, vessel and voyage.
- **Supported shipping lines**: every carrier Sinay tracks, with SCAC codes, container number prefixes, which number types work and whether it is under maintenance.
- **Port search**: find ports by name or UN/LOCODE with coordinates and country.
- **Port berth occupation**: the current berth occupation level of a port and its gap with the average.
- **Vessels in port**: the vessels currently in a port with IMO, MMSI and ship type.
- **Port congestion**: occupation rate by vessel type (commercial, cargo, tanker, ro-ro), time in port statistics and vessels in port counts for 720+ major ports.
- **Vessel ETA prediction**: Sinay's machine learning ETA for any cargo or tanker vessel to a port, from its live AIS position or from a departure port and time, with a confidence score from 1 to 5, remaining hours and distance.
- **Voyage CO2 emissions**: voyage length and tons of CO2 per TEU between two ports, by the GLEC trade lane method (well to tank, tank to wheel, well to wheel) and Sinay's vessel model method.
- **Underwater radiated noise**: sound exposure level of a vessel's voyage between two ports and whether it is above the Lloyd's transit and Bureau Veritas standard recommended thresholds.
- **Pay only for results**: unknown numbers, carrier errors, ports without data and refused lookups are recorded as a free row that says why, never charged.

### How to use it

1. Get your API key from your Sinay or Safecube account at app.safecube.ai/api/credentials. A free account works with the sandbox test shipments; congestion, ETA, CO2 and noise need the matching Sinay product on your plan.
2. Paste the key into the API key field (or set the DATA_API_KEY secret). It is sent only to api.sinay.ai in the `API_KEY` header and is removed from everything the actor logs.
3. Pick a mode, add numbers, ports or vessels, and start the run. The prefilled sandbox shipment `ZZZZ0000000` costs nothing on the Sinay side. Download the rows as JSON, CSV or Excel, or call the actor from your own code or a schedule.

This actor never creates webhook endpoints, subscribes shipments to them, or creates or deletes Safecube shipments, because those start billable tracking on your Sinay plan. A missing or rejected key, or a used up credit quota, ends the run cleanly with a status message that says what to change.

### Input

| Field | Modes | Description |
| --- | --- | --- |
| `mode` | all | `shipments` (default), `containerEvents`, `sealines`, `portSearch`, `portOccupation`, `vesselsInPort`, `portCongestion`, `vesselEta`, `co2Emissions` or `underwaterNoise` |
| `shipmentNumbers` | Container shipments, Container events | Container, bill of lading or booking numbers, one per line |
| `sealine` | Container shipments, Container events | Optional carrier SCAC such as MAEU; detected automatically when empty |
| `shipmentType` | Container shipments, Container events | Optional: CT (container), BL (bill of lading) or BK (booking) |
| `includeRoute`, `includeAis` | Container shipments, Container events | Route segments and AIS vessel data (both on by default) |
| `portQueries` | Port search | Port names or UN/LOCODEs |
| `portCodes` | Port berth occupation, Vessels in port, Port congestion | Port UN/LOCODEs such as FRLEH |
| `vesselImos`, `vesselMmsis` | ETA, CO2, noise | Vessels by 7 digit IMO or 9 digit MMSI |
| `departurePort`, `arrivalPort` | ETA, CO2, noise | UN/LOCODEs; departure is optional for the ETA |
| `departureDate` | Vessel ETA prediction | ISO 8601 departure time, only with a departure port |
| `speedKnots` | ETA, CO2 | Optional custom average speed, at most 25 knots |
| `maxResults` | all | Most rows to return and charge for |
| `requestsPerMinute` | all | Pacing; Sinay allows 10 requests per 10 seconds per key |
| `apiKey` | all | Your Sinay API key (secret) |

### Output

Every row has flat columns that are easy to filter: `shipmentNumber`, `shipmentType`, `sealine`, `sealineName`, `shippingStatus`, `containerNumber`, `containerType`, `containerCount`, `polLocode`, `polName`, `polDate`, `podLocode`, `podName`, `podDate`, `podDateActual`, `predictiveEta`, `vesselName`, `vesselImo`, `vesselMmsi`, `event`, `eventCode`, `eventDate`, `eventActual`, `locationLocode`, `locationName`, `facilityName`, `latitude`, `longitude`, `portCode`, `portName`, `countryCode`, `occupationPercent`, `occupationGapWithMean`, `vesselsInPortCount`, `timeInPortMedian`, `departurePort`, `arrivalPort`, `arrivalTime`, `confidence`, `remainingHours`, `remainingDistanceNm`, `voyageLengthNm`, `co2TradeLaneWtwTonsPerTeu`, `co2VesselTtwTonsPerTeu`, `soundExposureLevel`, `name` and `code`. The full Sinay answer is kept in `data`. A refused or empty lookup has `found` set to false and a `note` with Sinay's own words.

Example container shipment row (values from the Sinay API reference sample):

```json
{
    "mode": "shipments",
    "modeLabel": "Container shipments",
    "recordType": "shipment",
    "query": "MSKU0496560",
    "found": true,
    "shipmentNumber": "MSKU0496560",
    "shipmentType": "CT",
    "sealine": "MAEU",
    "sealineName": "Maersk",
    "shippingStatus": "IN_TRANSIT",
    "containerNumber": "MSKU0496560",
    "containerType": "40' High Cube Dry",
    "containerCount": 1,
    "polLocode": "USHOU",
    "polName": "Houston",
    "polDate": "2023-11-07T12:46:00Z",
    "podLocode": "DEBRV",
    "podName": "Bremerhaven",
    "podDate": "2023-12-01T22:00:00Z",
    "podDateActual": false,
    "predictiveEta": null,
    "vesselName": "MAERSK OHIO",
    "vesselImo": 9298698,
    "vesselMmsi": 367775000,
    "data": { "metadata": { "updatedAt": "2023-11-28T11:24:59Z" }, "containers": [{ "number": "MSKU0496560", "isoCode": "45G1", "events": [] }] },
    "retrievedAt": "2026-10-26T12:00:00.000Z",
    "note": null
}
```

Example port congestion row (from the Congestion API sample):

```json
{
    "mode": "portCongestion",
    "recordType": "congestion",
    "query": "FRLEH",
    "found": true,
    "portCode": "FRLEH",
    "occupationPercent": 28.57,
    "occupationGapWithMean": -25,
    "timeInPortMedian": 56.39,
    "vesselsInPortCount": 8,
    "data": { "rateOccupation": { "cargo": { "rateOccupationPercentage": 32.92, "rateOccupationGapWithMean": -1.69 } }, "time": { "timeInPortStatistics": { "max": 89.02, "median": 56.39, "min": 23.76 } } }
}
```

ETA rows carry `arrivalTime`, `confidence`, `remainingHours` and `remainingDistanceNm`; CO2 rows carry `voyageLengthNm` and tons of CO2 per TEU; noise rows carry `soundExposureLevel` with the threshold checks in `data.isAboveRecommendedThresholds`.

### Pricing

| Event | Price | Charged for |
| --- | --- | --- |
| `shipment-tracking` | 0.015 USD | Each container, bill of lading or booking with tracking data |
| `container-event` | 0.005 USD | Each container milestone |
| `reference-record` | 0.005 USD | Each shipping line, port found or vessel in port |
| `port-intelligence` | 0.01 USD | Each port berth occupation or congestion reading |
| `voyage-computation` | 0.01 USD | Each vessel ETA, CO2 or noise computation |

Unknown numbers, carrier errors, ports without data and refused lookups are never charged. Your Sinay plan and credits are billed separately by Sinay.

### FAQ

#### What is the Sinay container tracking API?

Sinay is a French maritime data company and the maker of Safecube. Its Container Tracking API v2 (api.sinay.ai/container-tracking/api/v2) returns status, locations, dates, events, vessels and AIS positions for a container number, bill of lading or booking number from one endpoint covering over 170 ocean carriers such as Maersk, MSC, CMA CGM, COSCO, Hapag-Lloyd and ONE.

#### Do I need my own Sinay API key?

Yes. This is a bring your own key actor: it calls Sinay with your key, under your plan, credits and terms. Find the key in your Safecube account under API credentials. Container tracking and the other products (congestion, ETA, CO2, noise) are billed per product by Sinay.

#### Can I test it for free?

Yes. Sinay's sandbox shipments cost nothing: `ZZZZ0000000` is a complete healthy shipment from Le Havre to Rotterdam, `ZZZZ100000` follows a full lifecycle that changes by day of week, and `ZZZZ300000` includes a transshipment. The input is prefilled with the first one.

#### How do I get the ETA of a container or bill of lading?

Use Container shipments with the number (and the carrier SCAC if you know it). The row's `podDate` is the carrier's arrival date at the port of discharge with `podDateActual` saying whether it has happened, and `predictiveEta` is Sinay's own prediction when the shipment is within 3 days of arrival.

#### How do I predict when a vessel will arrive at a port?

Use Vessel ETA prediction with the IMO or MMSI and the arrival UN/LOCODE. Without a departure port Sinay starts from the vessel's latest AIS position; with a departure port and time it computes port to port. Sinay covers cargo and tanker vessels on maritime routes that sent AIS in the last few days.

#### How is port congestion measured?

The Congestion API returns, per UN/LOCODE, the berth occupation rate for commercial vessels, cargo, tankers and ro-ro with the gap from the port's usual level, the minimum, median and maximum time in port, and the number of vessels in port. Sinay charges one congestion credit per port it returns data for.

#### How is the CO2 per TEU calculated?

Sinay gives two figures. The trade lane method applies GLEC Framework emission factors to the voyage length (well to tank, tank to wheel and well to wheel). The vessel model method models the specific ship's hull, engine and capacity to estimate fuel burn (tank to wheel only).

#### What are the rate limits?

Sinay allows 10 requests per 10 seconds per API key and answers 429 beyond that. The actor paces itself at 50 requests per minute by default and backs off on a 429.

### Keyword map

container tracking API, bill of lading tracking, booking number tracking, container ETA API, container milestones, DCSA event codes, shipping line SCAC list, ocean freight visibility, vessel ETA prediction API, vessel arrival time, AIS vessel position, port congestion API, port berth occupation, vessels in port, time in port, UN/LOCODE port search, CO2 emissions per TEU, GLEC framework, shipping emissions calculator, underwater radiated noise, Sinay API, Safecube API.

### Routes and verification

Wrapped routes on api.sinay.ai: `GET /container-tracking/api/v2/shipment`, `GET /container-tracking/api/v2/sealines`, `GET /ports-intelligence/api/v1/ports/search`, `GET /ports-intelligence/api/v1/ports/{unlocode}`, `GET /ports-intelligence/api/v1/ports/{unlocode}/vessels-in-port`, `GET /congestion/api/v1/congestion/{portCode}`, `POST /etac/api/v1/compute-eta`, `POST /co2/api/v2/compute-co2`, `POST /noise/api/v1/compute-noise`. Probed on 2026-10-26 with a deliberately invalid key, twice each: all answered Sinay's 401 "api key is not valid", while an invented service prefix and a wrong API version answered 404. The gateway checks the key before routing inside a service, so paths below a real service prefix could not be told apart from invented ones without a key. Response shapes and fields come from the vendor's OpenAPI definitions and samples, not from live data.

### Licensing and data use

This actor works only with your own Sinay account and API key, and Sinay's terms apply to everything it returns. Sinay licenses its API data for internal use and for your own customer applications. This actor is not affiliated with or endorsed by Sinay.

# Actor input Schema

## `mode` (type: `string`):

Container shipments: one row per container, bill of lading or booking with carrier, status, POL, POD, ETA, vessel and AIS position. Container events: one row per milestone of each container. Supported shipping lines lists the carriers and SCAC codes. Port search finds ports by name or UN/LOCODE. Port berth occupation, Vessels in port and Port congestion read port intelligence by UN/LOCODE. Vessel ETA prediction, Voyage CO2 emissions and Underwater radiated noise compute a figure for a vessel between two ports. Nothing in your Sinay account is created or changed.

## `shipmentNumbers` (type: `array`):

Container shipments and Container events. One container number, bill of lading or booking number per line. ZZZZ0000000 is Sinay's free sandbox shipment (Le Havre to Rotterdam) for testing at no cost.

## `sealine` (type: `string`):

Container shipments and Container events, optional. The carrier's 4 letter SCAC code, such as MAEU, MSCU or ONEY. Sinay detects the carrier when it is empty, but giving it is faster and avoids a wrong detection. Applies to every number in the run.

## `shipmentType` (type: `string`):

Container shipments and Container events, optional. Leave empty to let Sinay detect it. Applies to every number in the run.

## `includeRoute` (type: `boolean`):

Container shipments and Container events. Asks Sinay for the route segments and the current position. Turning it off makes answers faster.

## `includeAis` (type: `boolean`):

Container shipments and Container events. Asks Sinay for the vessel's latest AIS position, last event and ports. Works only with the route.

## `portQueries` (type: `array`):

Port search only. One port name (such as Le Havre) or UN/LOCODE (such as FRLEH) per line.

## `portCodes` (type: `array`):

Port berth occupation, Vessels in port and Port congestion. One 5 character UN/LOCODE per line, such as FRLEH, NLRTM or SGSIN.

## `vesselImos` (type: `array`):

Vessel ETA prediction, Voyage CO2 emissions and Underwater radiated noise. One 7 digit IMO number per line; each vessel is computed for the ports below.

## `vesselMmsis` (type: `array`):

Same modes, optional. One 9 digit MMSI per line, for vessels you know by MMSI rather than IMO.

## `departurePort` (type: `string`):

Required for Voyage CO2 emissions and Underwater radiated noise, optional for Vessel ETA prediction. When it is empty, the ETA starts from the vessel's latest AIS position.

## `arrivalPort` (type: `string`):

Vessel ETA prediction, Voyage CO2 emissions and Underwater radiated noise. The port to compute the voyage to, such as ESBCN.

## `departureDate` (type: `string`):

Vessel ETA prediction only, optional, and only with a departure port. ISO 8601, such as 2026-11-02T08:00:00Z; a plain date means midnight UTC. Sinay uses the current time when it is empty.

## `speedKnots` (type: `number`):

Vessel ETA prediction and Voyage CO2 emissions, optional. A custom average speed, at most 25 knots. Sinay's routing estimates it when empty.

## `maxResults` (type: `integer`):

The most rows this run returns and charges for.

## `requestsPerMinute` (type: `integer`):

Pacing for calls to the Sinay API, which allows 10 requests per 10 seconds per key.

## `apiKey` (type: `string`):

Your own Sinay API key from app.safecube.ai/api/credentials. Stored as a secret and sent only to api.sinay.ai in the API_KEY header; it is never logged. You can instead set the DATA_API_KEY environment secret.

## Actor input object example

```json
{
  "mode": "shipments",
  "shipmentNumbers": [
    "ZZZZ0000000"
  ],
  "includeRoute": true,
  "includeAis": true,
  "maxResults": 100,
  "requestsPerMinute": 50
}
```

# Actor output Schema

## `records` (type: `string`):

One row per shipment, container event, shipping line, port, congestion reading, vessel in port or voyage computation.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "shipmentNumbers": [
        "ZZZZ0000000"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("nabeelbaghoor/container-vessel-eta-port-congestion-api").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "shipmentNumbers": ["ZZZZ0000000"] }

# Run the Actor and wait for it to finish
run = client.actor("nabeelbaghoor/container-vessel-eta-port-congestion-api").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "shipmentNumbers": [
    "ZZZZ0000000"
  ]
}' |
apify call nabeelbaghoor/container-vessel-eta-port-congestion-api --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,nabeelbaghoor/container-vessel-eta-port-congestion-api"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/nWDOemfvoSJGM4lwh/builds/tjBEwYnbGz2iDJZY7/openapi.json
