Skip to main content
Magento 2 P21 Integration

How to Integrate Magento 2 With P21

By |May 24, 2021 September 19th, 2022No Comments

Magento is undoubtedly the most popular commerce platform in the world, trusted by a number of merchants across the globe helping with driving innovation. It is the topmost preferred option in B2B commerce, powering 41 merchants on the Internet Retailer B2B eCommerce Top 300 list. With Magento, you can create an outstanding B2B experience that exceeds customers’ expectations.

Epicor, on the other hand is a popular industry leader when it comes to distribution software, which is known for its emphasis on vertical markets and also the development of applications on a best-of-breed basis. The Epicor Distribution Suite portfolio consists of popular distribution systems, Prophet 21® and Eclipse™.

It can be best described as a fully integrated ERP solution with plenty of features for inventory control, accounting, pre-production materials planning, as well as manufacturing execution (MES). The system is delivered either on-premise or can be hosted, or you can even use it as a cloud-based Software as a Service (SaaS) offering.

ERP is short for enterprise resource planning. Enterprise resource planning(ERP) refers to a business process management software that allows an organization to use a system made up with integrated applications which can best manage a business and automate various back-office functions in association with technology, HR and different services.

Magento 2 – P 21 Integration

In this article, we share our knowledge to integrate the popular open-source digital commerce platform – Magento 2 with Prophet 21, called P 21.

Magento 2 has many new and improved features. Magento 2’s industry-standard API feature called REST was used to Integrate with P 21 in both ways.

REST API services of P 21 was implemented to sync Customer and Order data into P 21.

In the same way, P 21 uses Magento 2 REST API to send back Customer address update data, Product Create and update.

To create an order which originated in P 21 into Magento 2, we used Magento 2 cron which will extract JSON data from the file. Once the file is created, it is fed into Magento by P 21.

Magento P21 integration

Data Services – P 21

Customer Create

When a new customer is registered in Magento, it will also be created in P 21 and a P 21 customer id will be assigned.

Customer Specific Pricing

If the logged-in customer is a contractor, then the contract pricing will be pulled from P 21.


When a customer views the product listing in the website, the P 21 service checks the availability of the product stock and displays the current inventory status on the website.

Credit Line

The credit line service allows a customer to purchase without making any immediate payment.

Order Feed

P 21 offline orders (for e.g. by sales team) need to be synched with Magento and this is achieved by order feed CSV.

Data Services – Magento 2

Customer Update

When a customer is created in P 21 (based on a registration in Magento), it updates Magento with the following information – P 21 Customer ID, Sales Location ID, Billing and Shipping Address, and Freight Type.

Product Create and Update

The product created in P 21 will be created with basic information into Magento. If there is any change in the product price or weight, this will be updated in Magento.

Order Status Update

Status and tracking information will be updated using this web service for the orders which originated in Magento.


Magento allows you to make your site your own. Integration with an ERP makes it far more cost-effective than a re-platform and grants you access to a ton of benefits.

Seamless integration of Magento with P 21 is sure to make your lives easier and focus on customers and your business.

Cloras (now DCKAP Integrator), a DCKAP product, is an enterprise ERP integration platform specializing in Magento P21 integration. Request a free demo to see how Cloras can solve your current integration challenges.

If you have any queries…please visit our FAQ section or feel free to get in touch in the comments section below. Looking for Magento P21 integration? Here’s our team of Magento developers to make it happen. Let’s get started.


Author Iyappan

Iyappan is a Certified Magento Developer Plus Technical Architect at DCKAP. He is passionate about Magento. He is the 'go-to' guy for all our Magento needs. A cool-headed, hands-on veteran of many end-to-end implementations.

More posts by Iyappan

Discover What You’re Missing

Get the weekly email full of actionable ideas and insights you can use at work and home.