> For the complete documentation index, see [llms.txt](https://kb.bevica.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://kb.bevica.com/documentation/integration/bevica_warehouse_integration/vision_warehouse_integration_-_moving_to_the_api.md).

# Vision Warehouse Integration - moving to the API

Guidance for moving Vision integration from files/email to API.

## Overview

The integration for sending Outbound Requests to a warehouse managed by Vision software (LCB, Vinotheque, EHD, Lanchester, and Coterie Vaults) is changing from email to the API. There is already functionality within Bevica to send requests via the API, but you will need to complete a testing phase with Vision before you can start sending live files via the API.

## Timescales

Whilst the deadline for moving to the API is 31/12/24, we would recommend you start the process as soon as you are able to and by **1st November at the latest**. Vision has advised it will typically take around 6 weeks to complete the switch. Please note that the last day for the submission of new test files during the Christmas period is 13/12/24. See [Blackout periods for testing](https://visionsoftware.atlassian.net/wiki/spaces/VEDI/pages/843907075/Testing+Inbound+EDI#Blackout-periods-for-testing).

## Steps to Switch from Email to the API - Testing Phase

To move to the API, you need to complete the following steps:

{% stepper %}
{% step %}

### Step 1

Have a sandbox environment which can be used to send test requests to Vision. Note that the Bevica team can create a new sandbox environment based on production if required.
{% endstep %}

{% step %}

### Step 2

Log a ticket with Vision (email <editest@visionsuite.co.uk>) requesting your API username and password. You will need to provide your **Warehouse Company Name**, **Stock Holding Customer Account Code**, and the 2 character **Site Code**. Note that they aim to respond to your request within 3 working days, but it is a first-come, first-served basis and they can get quite busy at certain times of the year. If you have not heard from them within 5 working days, contact them again.
{% endstep %}

{% step %}

### Step 3

Vision will check your existing incoming orders which they have been receiving by email to make sure you have been achieving a 95% success rate or higher, and that there are no long-standing or unaddressed issues.
{% endstep %}

{% step %}

### Step 4

Once Vision has checked your account and is happy, they will set you to TEST mode. Note that you can continue to send live files via email during the testing period.
{% endstep %}

{% step %}

### Step 5

To change the setup from Email to API, within the sandbox environment you will be testing in, search for **Warehouse Integration Setup** and amend the relevant **Warehouse Supplier Setup** record:

* Change the **File Delivery Method** from Email to API
* Change the **Records per File** to 1
* Populate the **Client ID** with the information provided by Vision
* Populate the **Client Secret** with the information provided by Vision
* Populate the **URL base** with the information provided by Vision, e.g., [http://kingmoor.lcb.co.uk](https://kingmoor.lcb.co.uk)
  {% endstep %}

{% step %}

### Step 6

You will now be able to start sending test files to Vision. You will need to let them know when you have sent a few days' worth of test transmissions.
{% endstep %}

{% step %}

### Step 7

Vision will review the test transmissions, and if they are all okay, they will agree on a date with you to switch you live on with API.
{% endstep %}
{% endstepper %}

For more information, see [Switching from Email to API](https://visionsoftware.atlassian.net/wiki/spaces/VEDI/pages/3512467457/Switching+to+API) and [Testing Inbound EDI](https://visionsoftware.atlassian.net/wiki/spaces/VEDI/pages/843907075/Testing+Inbound+EDI).

{% hint style="info" %}
**Note**

The timescale of the testing phase relies on the speed and quality of test files sent to Vision.
{% endhint %}

## Steps to Switch from Email to the API - Production Environment

Once a date has been agreed with Vision to move to the API, you will need to change the same setup in your Production environment after your last files have been sent via email. Note the details will be the same as you tested the API with.

1. Search for **Warehouse Integration Setup**
2. Open the relevant **Warehouse Supplier Setup** records and make the following changes:
   * Change the **File Delivery Method** from Email to API
   * Change the **Records per File** to 1
   * Populate the **Client ID**
   * Populate the **Client Secret**
   * Populate the **URL Base**


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://kb.bevica.com/documentation/integration/bevica_warehouse_integration/vision_warehouse_integration_-_moving_to_the_api.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
