---
updatedAt: 2025-08-18T14:31:34.000Z
agentTools:
  projectIndex: https://documentation.safecube.ai/llms.txt
---

# Get Vessels in port

Retrieve a list of vessels currently in the specified port

<Callout icon="🚧" theme="warn">
  This API is a `BETA`

  <Anchor label="Send your feedbacks !" target="_blank" href="mailto:customersuccess@sinay.fr">Send your feedbacks !</Anchor>
</Callout>

# OpenAPI definition

```json
{
  "openapi": "3.0.3",
  "info": {
    "title": "Safecube Ports Intelligence API",
    "version": "1.0.0-beta",
    "description": "Welcome to the documentation of the Safecube Ports Intelligence API\n<p><strong>Beta Version</strong></p> <p><strong>This API is currently in BETA It is subject to change and may not be fully stable.</p> <p>Use with caution in production environments.</strong></p>\n<h1>Compatibility guidelines</h1> <p>The HTTP API is versioned with a single number, which is currently 1</p> <p>This number symbolizes the major version number. New features can be added to the API in the same version number if there is no breaking change.</p> <p>The version number is present in the url, for instance <strong>/ports-intelligence/api/v1</strong> for the current version.\n<h1>Documentation</h1> <p>You can find the complete documentation for our API at <a href='https://documentation.safecube.ai/'>Safecube documentation</a>.</p>\n<h1>Authentication</h1> <p>Every endpoints of this API require authentication using an API key with a specific authorization.</p> <p>If you don't have an API Key and you need to use the Safecube Shipment Management API, you need to ask Sinay to have one.</p> <p>To use the API Key, you must add a header named <strong>API_KEY</strong> with your API Key as a value.</p> <h1>Test the API with Swagger-ui</h1> <p>To test the API using Swagger-ui, you must click on the button <strong>Authorize</strong> and then fill the <strong>apiKey</strong> field and click on <strong>Authorize</strong>.</p> <p>Swagger-ui will then use the api key automatically in each request.</p> <p>On every endpoints, you can click on <strong>Try it out</strong>, you can modify the body and then click on <strong>Execute</strong></p> <p>You will be able to see the response.</p>"
  },
  "servers": [
    {
      "url": "https://api.sinay.ai/ports-intelligence/api/v1"
    }
  ],
  "security": [
    {
      "ApiKey": []
    }
  ],
  "paths": {
    "/ports/{unlocode}/vessels-in-port": {
      "get": {
        "tags": [
          "Ports"
        ],
        "summary": "Get Vessels in port",
        "description": "Retrieve a list of vessels currently in the specified port",
        "operationId": "getVesselsInPort",
        "parameters": [
          {
            "name": "unlocode",
            "in": "path",
            "required": true,
            "description": "UN/LOCODE of the port",
            "schema": {
              "type": "string",
              "example": "FRLEH"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/VesselInPort"
                  }
                },
                "examples": {
                  "vessels_in_port": {
                    "summary": "Vessels in Port Example",
                    "value": [
                      {
                        "name": "CMA CGM COLUMBA",
                        "imo": 9410789,
                        "mmsi": 215249000,
                        "shipType": "Cargo",
                        "id": "c038b31f-ad40-3ef1-93aa-a6151330d833"
                      }
                    ]
                  }
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/UnauthorizedError"
          },
          "404": {
            "$ref": "#/components/responses/NotFoundError"
          },
          "500": {
            "$ref": "#/components/responses/InternalServerError"
          }
        }
      }
    }
  },
  "components": {
    "securitySchemes": {
      "ApiKey": {
        "type": "apiKey",
        "in": "header",
        "name": "API_KEY",
        "description": "API key for authentication"
      }
    },
    "schemas": {
      "VesselInPort": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "nullable": true,
            "description": "Vessel name"
          },
          "imo": {
            "type": "string",
            "nullable": true,
            "description": "International Maritime Organization number"
          },
          "mmsi": {
            "type": "string",
            "description": "Maritime Mobile Service Identity"
          },
          "shipType": {
            "type": "string",
            "nullable": true,
            "description": "Type of ship"
          },
          "id": {
            "type": "string",
            "description": "Veesel's id"
          }
        }
      },
      "Error": {
        "type": "object",
        "properties": {
          "error": {
            "type": "string",
            "description": "Error message"
          },
          "code": {
            "type": "string",
            "description": "Error code"
          },
          "timestamp": {
            "type": "string",
            "format": "date-time",
            "description": "Error timestamp"
          }
        }
      }
    },
    "responses": {
      "UnauthorizedError": {
        "description": "Authentication information is missing or invalid",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            },
            "example": {
              "error": "Unauthorized",
              "code": "AUTH_001",
              "timestamp": "2025-07-17T10:30:00Z"
            }
          }
        }
      },
      "NotFoundError": {
        "description": "The requested resource was not found",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            },
            "example": {
              "error": "Resource not found",
              "code": "NOT_FOUND",
              "timestamp": "2025-07-17T10:30:00Z"
            }
          }
        }
      },
      "InternalServerError": {
        "description": "Internal server error",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            },
            "example": {
              "error": "Internal server error",
              "code": "INTERNAL_ERROR",
              "timestamp": "2025-07-17T10:30:00Z"
            }
          }
        }
      }
    }
  },
  "tags": [
    {
      "name": "Ports",
      "description": "Retrieve data related to port information and vessels in ports"
    }
  ]
}
```