Recently, I am connecting with the e-commerce supply chain, and talk about the API interface of the open platform

The design of the B2B e-commerce open platform needs to be considered from the following aspects:

  1. The design of the open platform API interface is mainly to design the interface and corresponding fields that meet the business requirements from the perspective of functional requirements;

  2. What are the methods of information connection between the platform and merchants? What problems may be encountered during the docking process;

  3. The design of synchronization switch and authority handles the contradiction between automatic information synchronization and manual setting.

1. Open platform API interface design

1. Products   

Synchronization of commodities mainly takes into account:

  1. uploading of products;

  2. Commodity price synchronization;

  3. Commodity batch number synchronization;

  4. Synchronization of product loading and unloading.

Taobao Jingdong Pinduoduo API access test

1.1.1 Uploading of commodities

The purpose of product upload synchronization is to synchronize the products that the merchant needs to sell to the platform. The platform displays the products uploaded by the merchant on the front-end page. After the order is successfully placed, the product details are sent to the merchant along with the order information.

Problems that need to be dealt with during the product upload process:

  • The information uploaded by the product needs to include the "ERP product ID" as the unique identifier of the product;

  • Many platforms will have basic commodities, such as medicines, food, fruits, etc.; if the target of sale can be clearly defined, and the merchant only exists as a distributor, the platform can uniformly define the basic commodities;

  • In the case of basic products, the product information uploaded by the merchant needs to be matched with the basic products on the platform to generate SKUs for sale.

There are two matching methods:

  1. It can be matched according to the barcode, approval number, specification, manufacturer, etc. of the product, but it is required to fully confirm that the product and the basic product are the same product based on these conditions;

  2. For some products, when there is no definite specification for the program to complete the product matching, manual intervention is required to make a judgment, and then directly add the "basic product ID" when uploading, and directly associate through the "basic product ID".

Under normal circumstances, after the product is uploaded, it cannot be put on the shelf and sold immediately. Instead, the inventory must be synchronized first and then put on the shelf through the interface of calling the batch off-shelf or manually clicking on the shelf.

If the product needs to be sold directly on the shelves after uploading, the interface must also include product sales information such as: price and inventory, so the interface for product upload must include the default unit price and inventory, where the default unit price is required, and the inventory can be empty and defaults to 0 (At the same time, rules can be set: products with inventory of 0 will not be automatically put on sale, while products with inventory not at 0 will be automatically put on sale).

When there are no basic products on the platform, it is not recommended to put the products directly on the shelves, but needs to be reviewed, because the products uploaded by the merchants may not be allowed to be sold on the platform.

1.1.2 Modify commodity price

The prices of commodities sold by merchants on the platform are not fixed. For merchants with many SKUs, the prices of commodities are often directly modified in ERP and then synchronized to various third-party platforms. Therefore, price synchronization is indispensable and for Real-time, accuracy requirements are relatively high.

On the other hand, due to the cost factor or the different market focus, the sales price of the product often needs to be set differently for different regions and customer types, and these settings are also often set in ERP. sync to the platform.

Problems that need to be dealt with in commodity price synchronization:

  1. The interface needs to be able to meet the needs of commodities to modify multiple types of prices at the same time, including the default unit price, suggested retail price, regional price/customer level price;

  2. For regional prices or customer-level prices, it is necessary to define a standardized regional group or customer group in the platform. When synchronizing prices, the ID of the field "regional group" or "customer group" exists in the interface to match the product price on the platform. .

The concept of regional group: Since there are many units in administrative divisions, it is impossible to set a price for each administrative region. Usually, the definitions of regional prices for different commodities are the same. For example, two commodities in A and B are in Guangdong and Guangxi The pricing is the same but different from other regions, then Guangdong and Guangxi can be set as a region group; the price of the product can be defined for each region

1.1.3 Commodity batch number synchronization

The same product may have different batch numbers due to different production batches, especially for products with an expiration date, the expiration date of the product is directly linked to the batch number; after the batch number of the product is uploaded to the platform, it can be directly displayed in the product details , Customers can know the validity period of the goods they purchased. After the order is generated, it can be sent to the merchant's ERP system along with the order information as the basis for the merchant's delivery.

Problems that need to be dealt with when synchronizing commodity batch numbers:

  1. The fields that need to be transmitted by the interface mainly include batch number, production date and expiration date;

  2. Every time the batch number is synchronized through the interface, only the batch number that is being sold should be synchronized (you can judge whether the inventory is 0), and each time the full amount is updated, there should be no redundant batch number data in the database;

  3. In addition to updating the batch number in full each time, you can also choose to update only the latest or the largest batch number in stock each time.

1.1.4 Synchronization of product loading and unloading

The synchronous interface for product loading and unloading is mainly used for batch operations of removing or removing products from the shelves, especially when new products are just uploaded, the products are in the state of being put on the shelves, and batches of products need to be removed from the shelves; For multiple commodities, it is more efficient to operate through the interface than to click on the interface one by one.

2. Inventory

Inventory Synchronization

Inventory synchronization is the most frequently used and real-time interface with the highest accuracy requirements; untimely or inaccurate inventory synchronization may cause goods to be sold out or customers cannot place orders to purchase.

Problems that need to be dealt with in inventory synchronization:

  1. Synchronization intervals must be as short and accurate as possible;

  2. Some ERP system inventory is associated with the batch number, and it is necessary to sum up the inventory related to the batch number of the product.

3. Customers

Merchant ERP customer synchronization

Normally, the customer saved in the merchant's ERP system does not need to be passed to the platform, only the consignee, receiving phone number, delivery address and the invoice information left by the customer when placing the order are required for the order to complete the delivery operate.

However, for some special products and special industries, due to commercial reasons or industry rules (such as pharmaceutical B2B procurement requires buyers to have relevant qualification certificates), ERP customer information must first exist when generating orders in the ERP system, then the ERP customer number must be First send to the platform, and then match and map with the platform's customers. When synchronizing orders, the ERP customer information needs to be transmitted to the ERP at the same time, and the merchant's ERP generates a new ERP order based on the ERP customer information.

Problems that need to be dealt with in merchant ERP customer synchronization:

There are multiple options for synchronizing ERP customers to the platform:

  1. After the platform generates an order, the merchant sees the customer information corresponding to the order, and supplements the ERP customer number based on the platform's customer information. When the platform synchronizes the order information to the merchant's ERP, the ERP customer number is also passed along, and the merchant's ERP can be based on this ERP. The customer number generates an ERP order;

  2. The merchant ERP directly synchronizes all customers in the ERP to the platform in advance and matches them with the platform customers. After the order is generated, if the customer who placed the order has an ERP customer number, the order will be directly synchronized to the ERP system to generate the ERP order. Create customer data in the ERP system and synchronize it to the platform (ERP customer data and platform customers can be matched based on the unified credit code of the business license).

Option 1 can better protect the merchant’s customer information and ensure that it will not be leaked; Option 2 is more convenient and requires less manual operation.

4. Order

The synchronization of orders includes the following aspects:

  1. Query the order list;

  2. Synchronize logistics information;

  3. Synchronize delivery information;

  4. Synchronize ERP order status.

1.4.1 Query order list

This interface is used by the merchant's ERP system to request the synchronization of paid orders on the platform, and the problems that need to be handled by the query order list interface:

  1. The interface needs to support querying orders based on the synchronization status. After the order query is successful, the platform needs to change the synchronization status of the corresponding order to "Synchronized", so as to ensure that "unsynchronized" orders are checked every time. In addition, if To query the synchronized order, you can also specify the corresponding status to query.

  2. The query method needs to support searching by conditions, such as: start time, end time, order status, synchronization status, etc., and also needs to support precise query by order number.

  3. The response data should be divided into four parts: basic order information; order amount information; delivery information; invoice information; order item information. The delivery information and invoice information generally already exist in the merchant's ERP system, but they may be inconsistent with the information on the platform, so they need to be returned to the ERP system together.

  4. Commodity item information can include the batch number of the shipment, and the customer transmits the batch number information that the customer sees when placing an order to the merchant's ERP, which can greatly reduce the customer refund rate.

1.4.2 Logistics information synchronization

After the order is delivered by the merchant's ERP system, the corresponding logistics information needs to be transmitted to the platform for display to customers. Problems that need to be dealt with in the logistics information synchronization interface:

  1. The logistics provider in the merchant’s ERP system and the logistics provider on the platform must correspond one-to-one in order to transmit and display logistics information, so the platform can provide a logistics provider code and logistics provider name to the merchant’s ERP, and the ERP will correspond The logistics provider code and order number are sent to the platform.

  2. The synchronization of logistics information also means that the order must have been shipped. If no other interface for changing the order status is designed, the platform can automatically change the order status to "delivered" when the ERP uploads the logistics information.

1.4.3 Shipping information synchronization

For B2B e-commerce, when the orders generated by the platform are transmitted to the ERP system, the following problems may arise:

  1. The same product may be purchased multiple times, and some products may be out of stock due to inventory reasons, so when shipping, a certain product or a part of a certain product may be shipped less;

  2. Due to different batches of products in the merchant's ERP, the production date and expiration date may be inconsistent. After the user pays successfully, he needs to see the expiration date corresponding to the product batch number in the delivery information, so the merchant's ERP needs to pass the relevant information to the platform.

The delivery information synchronization interface is mainly to transmit the details of the goods out of the warehouse to the platform after the ERP system order is out of the warehouse. The fields that need to be transmitted include: ERP product number, delivery quantity, batch number, production date, and expiration date.

1.4.4 Synchronize ERP order status

ERP order status mainly refers to the various states of the order in the ERP processing link. After the order is transmitted to the ERP system, it may need to carry out bill of lading, sorting, delivery, delivery and other links. After the customer receives the goods, the logistics company will also feedback Sign for information.

After the ERP order status is synchronized to the platform, it has the following two functions:

  1. The platform can independently generate logistics information according to the status of the ERP order and display it to customers. For example, if the status of the ERP order changes to "Bill of Lading", a new item of logistics information will be added: the order has been processed and the merchant is picking goods.

  2.  A specific ERP order status can be associated with the platform order status. For example, if the ERP order status changes to "signed for", the platform can change the order status to "transaction completed" after receiving the information about the ERP order status.

2. Channels for synchronizing business information to the platform

According to the technical capabilities of merchants, various docking solutions can be provided for merchants:

  1. Develop the ERP system through the API interface provided by the platform to realize the connection with the platform, which is suitable for merchants with professional technology development capabilities;

  2. The platform uniformly develops the service system, and the platform personnel implement the docking of the merchant's ERP and the platform, which is suitable for those who have no professional technical docking ability, have an ERP system and a large amount of information is not suitable for manual operation;

  3. Manually create or modify information on the platform by importing excel or direct manual operation in the merchant operation background provided by the platform. It is suitable for merchants who have no professional technical docking ability and have a relatively small number of product SKUs and orders. Can be used as an alternative to technology docking.

2.1 API interface docking

When merchants have technical development capabilities, they can design and modify the business system according to the interface call documentation provided by the platform, and realize the information flow between merchants and the platform by directly calling the API interface and obtaining the returned data.

2.2 Platform Unified Service System

The main implementation method is: the platform technicians modify the business logic of the merchant's ERP system, and separately create a view, stored procedure or intermediate table that conforms to the platform interface function on the merchant's ERP system, call the interface of the platform to transfer the view, and store the process The information of the platform is sent to the platform, and the response data of the platform interface is stored in the intermediate table.

Due to the differences in the database structure and business logic of different ERP systems, the platform needs to study the ERP systems of different customers for a unified design.

2.3 Manual operations in the backend of the merchant

The manual operation in the background of the merchant is not only suitable for customers who cannot be connected to the system, but also as a temporary alternative when the interface synchronization fails, so the manual operation function needs to meet all the needs of the system connection.

The functions of manual operation include: creating new products (batch upload), putting products on and off shelves, modifying product prices, modifying product inventory, uploading ERP customer codes, downloading orders in batches, changing order status, etc.

3. Design of synchronization switch and authority

Because merchants have two modes of manual synchronization and automatic synchronization for information such as products, customers, prices, inventory, and orders, when the two modes exist and are in progress at the same time, the data may be messy and inconvenient, such as: due to Insufficient inventory, the page cannot place an order. At this time, the merchant needs to carry out negative sales, and there is a need to manually modify the inventory at this time, but after the modification, the inventory will soon be overwritten by the new inventory data sent by the synchronization system.

In order to solve the above problems, we need to make a switch according to different functional modules, that is, whether to enable automatic synchronization for a certain function setting. As in the example just now, if the product needs to temporarily modify the inventory at this time and maintain it for a period of time (to ensure that customers have enough time to place an order and pay), you can temporarily close the inventory synchronization service.

In addition, the design of permissions can be designed in more detail, that is, whether to automatically synchronize inventory for a certain product, so that when the product inventory synchronization function is turned off, it will not affect the synchronization of other product inventories

Guess you like

Origin blog.csdn.net/Jernnifer_mao/article/details/132646345