Saltar para o conteúdo
duxt
Esta página ainda não está disponível no seu idioma
Está a lê-la em English (UK).

Replace a vessel's manifest

put
/vessels/{imo}/manifest

replaceManifest

The whole manifest at once — a PUT, because half a manifest is not a smaller manifest, it is a wrong one.

Autorização

  • Qualquer um destes

    • apiKeyapiKey · X-Api-Key · Cabeçalho

      A key from the account page.

  • Qualquer um destes

    • bearerhttp · bearer

      A token obtained from the authorisation server.

Parâmetros

Caminho

  • imo*Obrigatóriostringpadrão ^IMO[0-9]{7}$

    The vessel's IMO number.

Cabeçalho

  • If-Matchstring

    The manifest revision you are replacing.

Corpo do pedido Obrigatório

application/json

object
  • entries*Obrigatórioarray<object>

    Cada elemento

    objectManifestEntry
    • line*Obrigatóriointegermín 1
    • contents*Obrigatórioany

      Pelo menos um de

      • object
        • consignmentIdstring
      • object
        • descriptionstring
        • weightKgnumbermín 0
json
{
  "entries": [
    {
      "line": 1,
      "contents": {
        "consignmentId": "00000000-0000-4000-8000-000000000000"
      }
    }
  ]
}

Respostas

200
The manifest as it now stands.

application/json

array<object>

Cada elemento

objectManifestEntry
  • line*Obrigatóriointegermín 1
  • contents*Obrigatórioany

    Pelo menos um de

    • object
      • consignmentIdstring
    • object
      • descriptionstring
      • weightKgnumbermín 0
json
[
  {
    "line": 1,
    "contents": {
      "consignmentId": "00000000-0000-4000-8000-000000000000"
    }
  }
]
412
Something went wrong, described the same way every time.

application/problem+json

objectProblem
  • title*ObrigatóriostringA short, human-readable summary.
  • status*Obrigatóriointegermín 400máx 599
  • detailstring | null
json
{
  "title": "string",
  "status": 400,
  "detail": "string"
}

Enviar um pedido

Autenticação

O que escrever aqui fica neste separador, nunca é guardado e só é enviado para o servidor que escolheu.

Parâmetros

Este corpo não pode ser apresentado como formulário: edite-o como JSON.

O pedido é enviado pelo seu navegador, diretamente para esse servidor.

curl 'https://api.example.org/v3/consignments' \
  -H 'Content-Type: application/json' \
  -H 'Authorization: Bearer demo-token' \
  -H 'X-Request-Id: 00000000-0000-4000-8000-000000000000' \
  -d '{
  "reference": "HB-1042",
  "status": "booked"
}'