Architecture
Above are the explanation of the fields in the json payload for a good account to fit in the BEES.
The account, representing a POC, is informed by the ERP used in the specific Zone containing information about the Customer. It also contains some attributes of the Customer, like the delivery window and main payment method. For more details look up for the whole service in the links that will be shown later in this document.
Highlight fields
Below are described which fields or attributes are important to have for a valid account:
It's important the account to have a valid set of information in order to further services work properly.
Set as an Account, it does not process or have other functionality beyond the scope of an account other than represent its main configuration, payment methods and others.
Entites are linked by the following fields:
Accounts - DeliveryScheduleId should be relationed to DeliveryWindows - _id
Account data details
Account information related to:
"maximumOrder": {
"paymentMethods": "CASH",
"type": "PRODUCT_QUANTITY",
"value": 20
},
"minimumOrder": {
"paymentMethods": "CASH",
"type": "PRODUCT_QUANTITY",
"value": 20
}The types could be:
- PRODUCT_QUANTITY
- ORDER_VOLUME - It requires that all items should have the unit of measurement in liters.
- ORDER_TOTAL
- SKU_DEFINED - It requires that all items should have minimum quantity informed.
Account Deletion
The account deletion is a resource available in the account relay, it is accessed in the same endpoint as the account, passing the id of the account in the path of this endpoint.
Previously the link would be accessed by the POST method of the http protocol, the difference now is the method, being the DELETE method.
Credit Management
The following statement describes how the information are shown, not necessarily included in the platform the order described, in fact the platform receives the information references of an account separately of the representation of its delivery window, and credit if the payment method has credit attribute.
Credit configuration for account is inserted after the account is created, in the /credits endpoint in the relay, in which the field accountId is used to reference its configuration to the account, and the other fields are used as a configuration for the credit, where is it listed here:
“available”;
“balance”;
“consumption”;
“overdue”;
“paymentTerms”;
“total”.
Where each one of the fields represent the current status of the account credit.
Load limits
Regardless the robustness infrastructure the Bees platform has, it is necessary to limit the size of payload in 1 MB per request, related to security and performance reasons. This number could be greater if the payload is compressed. Check the limit number per entity below: