# Voyages

## **Prerequisites**

No prerequisites.

## **Integration Set-Up**

Accounting systems often require voyage related data before transferring accounting related transactions. Set up a scheduled task and use the request under [#data-transaction](#data-transaction "mention") to gather all voyages that has been modified since the last time a scheduled task was run.

## **Test Data**

Modify some existing voyages in the Booking and Operations module for testing, for example, changing a date in the schedule (***note**: changing dates will also affect the schedule for other voyages*).

## **Data Transaction**

### Get new voyages using webhooks

To get new voyages in [Webhooks](/api-release-8.25/dataloy-rest-api/webhooks.md) the following subscription can be created:

```
{
"eventType": "U",
"user":
"objectType": "VoyageHeader",
"expression": "(oldDlpObject.getVoyageStatus() != null && oldDlpObject.getVoyageStatus().getStatusTypeCode().equals(\"EST\") && dlpObject.getVoyageStatus() != null && dlpObject.getVoyageStatus().getStatusTypeCode().equals(\"NOM\")) || (oldDlpObject.getReferenceNo() == null && dlpObject.getReferenceNo() != null && dlpObject.getVoyageStatus() != null && dlpObject.getVoyageStatus().getStatusTypeCode().equals(\"NOM\"))",
"url":
}
```

To get updated for all changes on a voyage the following webhook subscription can be created:

```
{
"eventType": "U",
"user":
"objectType": "VoyageHeader",
"url":
}
```

### **Get all fixed voyages modified since given date**

To extract all fixed voyages from Dataloy VMS that has been modified since a given date, use request below in conjunction with the base URL:

```
GET /VoyageHeader?filter=modifiedDate(GTE)2014-01-01T12:30:00
```

### **Post Transaction**&#x20;

No post transaction is required.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://api.dataloy.com/api-release-8.25/user-guides/accounting-integration-api/voyages.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
