Hydra
API Reference

Retrieve active tracked vessel positions.

GET /public/vessels

Returns the latest known position for each tracked vessel from the last 2 hours. Only vessels currently being monitored by Hydra's AIS stream are included.

Request

GET https://api.hydra.fast/public/vessels

Headers: None required

Query Parameters: None

Response

Status: 200 OK

Content-Type: application/json

{
  "data": [
    {
      "mmsi": "211234567",
      "name": "NORTHERN SPIRIT",
      "lat": 57.68,
      "lng": 11.94,
      "speed": 12.3,
      "category": "TANKER",
      "flag": "DE",
      "timestamp": "2026-03-21T08:25:00.000Z"
    },
    {
      "mmsi": "352987654",
      "name": "PACIFIC GUARDIAN",
      "lat": 33.75,
      "lng": -118.27,
      "speed": 0.0,
      "category": "CARGO",
      "flag": "PA",
      "timestamp": "2026-03-21T08:20:00.000Z"
    }
  ]
}

Response Fields

Field Type Description
mmsi string Maritime Mobile Service Identity (9-digit unique ID)
name string | null Vessel name
lat number Latitude in decimal degrees
lng number Longitude in decimal degrees
speed number | null Speed over ground in knots
category string Vessel classification
flag string | null Flag state ISO 3166-1 alpha-2 code
timestamp string ISO 8601 position timestamp

Vessel Categories

CARGO       Bulk carriers, container ships, general cargo
TANKER      Oil, chemical, LNG tankers
MILITARY    Naval warships, auxiliaries, coast guard

Code Examples

cURL

curl https://api.hydra.fast/public/vessels

JavaScript (fetch)

const response = await fetch('https://api.hydra.fast/public/vessels');
const { data } = await response.json();

console.log(`Tracking ${data.length} vessels`);

// Filter to military vessels only
const military = data.filter(v => v.category === 'MILITARY');
console.log(`${military.length} military vessels active`);

military.forEach(v => {
  console.log(`${v.name || v.mmsi} [${v.flag}] — ${v.lat}, ${v.lng}`);
});

Python (requests)

import requests

response = requests.get("https://api.hydra.fast/public/vessels")
vessels = response.json()["data"]

for vessel in vessels:
    name = vessel.get("name") or vessel["mmsi"]
    print(f"{name} [{vessel.get('flag', '??')}] — {vessel['category']}")
    print(f"  Position: {vessel['lat']}, {vessel['lng']} | Speed: {vessel.get('speed', 0)} kts")

Notes

  • Returns the latest position per vessel (deduplicated by MMSI)
  • Only vessels from the last 2 hours are included
  • Maximum of 300 positions returned
  • For course, heading, destination, and ship type data, use the token-gated API