# Application / Usage

This describes the process from the provision of validated squeeze purchasing documents to external workflows to the posting transfer of released documents.

# Breeze Interface Documents

All documents that are in the Breeze process are listed here.

[![image-1694763197320.png](https://docs.squeeze.one/uploads/images/gallery/2023-09/scaled-1680-/image-1694763197320.png)](https://docs.squeeze.one/uploads/images/gallery/2023-09/image-1694763197320.png)

##### Statuswerte

- WaitingForRetrieval: The document is ready and waiting to be picked up by the workflow system.
- Retrieved: The document was picked up by the workflow.
- Processed: The document was processed successfully.
- Error: The document has at least one error, which must be corrected in the workflow.
- Rejected: The document was marked as rejected by the workflow system.
- WaitingForJson: The document is waiting for the Json file to be enriched.
- ChangeCompany: The document is waiting to be processed by the background process and transferred to another client.

# Transfer to the unposted purchasing documents

After the workflow system has released the purchasing document, it is transferred to the Breeze interface. A plausibility check is then performed in the interface. If the check is successful, an unposted purchasing document is created.

If the plausibility check failed, the document is set to the status "error" and the error message is appended to the respective position in the Json structure of the document. Now the document is again waiting to be picked up and corrected by the workflow.

[![image-1694763696103.png](https://docs.squeeze.one/uploads/images/gallery/2023-09/scaled-1680-/image-1694763696103.png)](https://docs.squeeze.one/uploads/images/gallery/2023-09/image-1694763696103.png)

The unposted purchase document is created with all data from the Json structure. If attachments from the process have been attached, these will also be transferred to the unposted document.

[![image-1694763737921.png](https://docs.squeeze.one/uploads/images/gallery/2023-09/scaled-1680-/image-1694763737921.png)](https://docs.squeeze.one/uploads/images/gallery/2023-09/image-1694763737921.png)

# Breeze Interface API

Here you will find the documentation for the following products:

- [Invoice](https://documenter.getpostman.com/view/23495599/2s83YTnmEF#intro)
- [Procurement](https://documenter.getpostman.com/view/23495599/2s93z9b2mn)
- [Order Confirmation](https://documenter.getpostman.com/view/23495599/2s93z9b2r4)
- [Delivery Note](https://documenter.getpostman.com/view/23495599/2s93z9b2r5)

### BC-side API

In addition to the interfaces documented above, the Breeze Interface publishes the following web services on the Business Central side. They are used by the external system to exchange documents, attachments and status information.

#### Breeze Documents API

OData API (entity set `breezedocumentsapi`) over the Breeze Document table. It is used to create and read Breeze documents in Business Central.

#### Breeze Attachments API

OData API (entity set `breezeattachmentsapi`) for the attachments of a Breeze document. The file content is transferred through the `dataAsBase64` field, which is used for both uploading and downloading the attachment as a Base64-encoded string.

#### GetDocumentStatus

Status callback exposed as a web service. The external system polls this endpoint to retrieve the current status of a document (for example whether the resulting purchase document has been created, posted, closed, deleted or cancelled).

#### Read-only lookup web services

The following read-only pages are published as web services so that the external system can look up master and reference data:

- **Bin List**
- **GL Setup Dimensions**
- **Orderdata Purchase Lines**
- **Posted Purchase Rcpt. Lines**