---
title: "Get all cached messages related to a departure"
method: GET
path: "/customs/transits/movements/departures/{departureId}/messages"
tags: ["Departures"]
---

# Get all cached messages related to a departure

`GET /customs/transits/movements/departures/{departureId}/messages`

Get all messages related to a specific departure declaration sent to the customs office of departure within the past 60 days.
You can filter for departure declarations received before and/or after a specific date and time.
Movements older than 60 days are archived, so any messages to related to them cannot be returned by the API.
For a multi-page query you can filter for a specific page, and optionally the number of items per page.
A successful response will include the total count of the number of messages and Movement Reference Number (MRN) only after it has been allocated to a movement. <br/><br/> The `status` parameter in a successful response can have the following values:

 - `Pending`: the file has not yet been uploaded or checks are not yet completed
 - `Processing`: the file has been received by us and the message is being processed
 - `Success`: the file has been processed successfully
 - `Failed`: there was a problem with the file and the message was not processed

**Note:** You can view a transit movement only if your Economic Operators Registration and Identification (EORI) number matches the EORI number that created the transit declaration for that movement.  Your EORI number is part of the bearer token that you use for API authentication.

## Path parameters

- `departureId` string, required

## Query parameters

- `receivedSince` string, date-time
- `page` integer
- `count` integer
- `receivedUntil` string, date-time

## Headers

- `Accept` 'application/vnd.hmrc.3.0+json', required

## Response `200`

A successful get all messages related to departure response

- object
  - `_links` object, required
    - `self` object, required
      - `href` string, required
    - `departure` object, required
      - `href` string, required
  - `totalCount` number, required
  - `messages` object[], required
    - `_links` object, required
      - `self` object, required
        - `href` string, required
      - `departure` object, required
        - `href` string, required
    - `id` string, required
    - `departureId` string, required
    - `received` string, required
    - `type` string
    - `status` string, required

## Other responses

- `404` — Departure or Page Not Found
- `406` — Not Acceptable

---

[API](https://skmtc.net/hmrc/apis/common-transit-convention-traders.md) · [All operations](https://skmtc.net/hmrc/apis/common-transit-convention-traders/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/hmrc/common-transit-convention-traders/revisions/3f42685e9ab3/schema)
