Import manifests with the Manifest Import Agent
The Manifest Import Agent is a Copilot agent that processes manifest files received by email. The agent reads the vendor email and the attached manifest file, creates a manifest, checks the manifest, and creates the purchase orders. When the agent is unsure about a value or a check fails, the agent stops and asks a user to intervene instead of guessing. The agent never releases or posts a purchase order and never bypasses an approval.
The Manifest Import Agent is available as an early preview. Using the agent can result in costs for the organization.
Prerequisites
Before the agent is set up:
- The Manifest Import capability is turned on on the Copilot & agent capabilities page. For more information, see Configure Copilot and AI agent capabilities.
- An email account is set up in Business Central for the mailbox that receives the manifest files.
- The vendors that send manifest files exist. The vendor name, email address, or number matches the exporter name in the manifest file or the sender of the email.
- The ports of departure and arrival that are used in the manifest files exist on the Un/LoCodes page. For more information, see Define codes for loading and unloading locations.
- The master data that the manifest check requires, such as items with a GTIN and locations, exists. For more information, see Manifests.
Set up the agent
- In the navigation bar at the upper right of the role center, select the Agent icon, and then start the setup of the Manifest Import Agent.
The Configure Manifest Import Agent page opens. -
In the Monitor incoming information group, fill in the fields as follows:
Field Description Mailbox Select the checkbox to let the agent read the emails of the selected account. Account Select the email account that the agent monitors. Permission to the mailbox is required to activate the agent. Folder Select the email folder that the agent monitors. This field is optional. Last sync Specifies the date and time of the last import of emails. This field is displayed after the first import. Analyze attachments Select the checkbox to pass the attachments of an email to the agent. Only PDF files are supported. Daily email limit Enter the maximum number of emails that are imported in one run. The default value is 100. The value must be greater than 0. - The limit applies to each import of received emails, not to a calendar day.
- The first import considers all unread emails in the selected folder. Use a dedicated folder for manifest emails to avoid that other emails are imported.
-
Select the Update action.
When the agent is set up for the first time with email monitoring turned on and an account selected, a message asks to confirm the activation. The agent cannot be activated without a mailbox.
If the Manifest Import capability is turned off, the message The Manifest Import Agent capability is not enabled. is displayed when the setup page is opened.
Import received emails
Emails are not imported automatically. The import is started on the Manifest Import Agent Emails page.
- Select the Search icon
, enter Manifest Import Agent Emails, and then choose the related link.
The Manifest Import Agent Emails page opens. - On the action bar, select Import Received Emails.
The message All emails received since the last run have been imported successfully. is displayed.
The following fields are displayed for each imported email:
| Field | Description |
|---|---|
| Sender Name | Specifies the name of the person who sent the email. |
| Sender Address | Specifies the email address of the sender. |
| Received | Specifies when the email was received. |
| Processed | Specifies whether the email has been processed by the agent. |
| Task ID | Specifies the ID of the agent task that was created for the email. |
During the import, the following rules apply:
- Only unread emails are imported. Each imported email is marked as read in the mailbox.
- One agent task is created for each email conversation. A later email of the same conversation is added to the existing agent task.
- An email that was already imported is not imported again.
- Only PDF attachments are passed to the agent. Attachments of other file types are ignored.
Process a manifest with the agent
For each agent task, the agent works through the following steps:
- The agent reads the email and all pages of the attached file. The file must be a PDF file with Vessel-List in the file name. Otherwise, the agent asks a user to intervene.
- The agent finds the vendor. The exporter name in the file is matched against the Name, E-Mail, and No. field values of the vendors. If no vendor is found, the sender of the email is matched in the same way. If still no vendor is found, the agent asks a user to intervene.
- The agent finds the ports of departure and arrival on the Un/LoCodes page by the Code or Name field value. If a port is not found, the agent asks a user to intervene.
- The agent creates a manifest and fills in the manifest header and one manifest line for each pallet row of the file.
- The agent selects the Recheck action on the Manifest page. If the No. of Errors field value is not 0, the agent asks a user to intervene and no purchase order is created.
- The agent selects the Create Purchase Order action on the Manifest page. If the No. of Errors field value is not 0, the agent asks a user to intervene.
The agent fills in only the following fields.
| Manifest header field | Value |
|---|---|
| Document Date | The work date. |
| Vendor No. | The vendor that was found. |
| Description | The file name of the attachment. |
| Location Code | The port of arrival from the header of the file. The location is where the goods are placed and can differ from the port of arrival. |
| Planned Receipt Date | The ETA from the header of the file. |
| Manifest line field | Value |
|---|---|
| Pallet ID | The pallet ID of the file row. The pallet ID is unique in the file. |
| Container No. | The container number of the file row. |
| Pack Date | The date of packaging of the file row. |
| Quantity | The number of cartons per pallet. |
| GTIN | The GTIN-13 of the product. The GlobalGAP number is not used. |
| Vessel | The vessel name of the file row. |
| Port of Loading | The code of the port of departure that was found. |
| Port of Discharge | The code of the port of arrival that was found. |
| Location Code | The Location Code field value of the manifest header. |
| Departure Date | The ETD from the header of the file. |
| Arrival Date | The ETA from the header of the file. |
The agent works with its own profile, Global Trade - Manifest Import Agent (Copilot). On the Manifest page, only the Recheck and Create Purchase Order actions are available to the agent. The Un/LoCodes page is read-only for the agent, which means that the agent does not create vendors, ports, or other master data.
For example, a vendor sends an email with the attachment Vessel-List-2611.pdf. The exporter name in the file matches the name of a vendor, and both ports exist on the Un/LoCodes page. After Import Received Emails is selected, the agent creates a manifest with the description Vessel-List-2611.pdf and one manifest line for each pallet row. The Recheck action finds no errors, so the agent creates the purchase order. The purchase order is not released. A user reviews the purchase order and continues with the standard process. If the port of arrival were missing on the Un/LoCodes page, the agent would stop and ask a user to intervene, and no purchase order would be created.