ERP Punchout to Unimarket (Technical Information)
The Punchout (Roundtrip) process is a standardized method for a user to leave their internal ERP system, shop within the Unimarket eMarketplace, and return a populated shopping cart to their ERP for approval and requisitioning.
The Three-Phase Punchout Process
The entire interaction happens through three primary cXML messages:
1. Punchout Setup Request (ERP → Unimarket)
The ERP initiates a session by sending an HTTPS POST request to Unimarket. This message establishes the user's identity and provides a "return address" for the cart.
Key attributes:
Community ID: Identifies the specific Unimarket customer community.
System Credentials: The
IdentityandSharedSecretfor authentication.Buyer Username: The specific user shopping in the session.
BrowserFormPost: The URL where Unimarket must send the final shopping cart data.
Example request:
2. Punchout Setup Response (Unimarket → ERP)
Once Unimarket authenticates the request, it creates a unique session and responds immediately.
The StartPage URL: This is the most critical element of the response. The ERP must take this URL and open it in the user's web browser. This URL automatically logs the user into the Unimarket home page without requiring a second login.
Example response:
3. Punchout Order Message (Unimarket → ERP)
After the user selects their items and clicks "Checkout" within Unimarket, the system redirects the user's browser back to the ERP.
Mechanism: Unimarket performs a POST to the
BrowserFormPostURL provided in Phase 1.Data Payload: The cart details are included in a parameter named
cxml-urlencoded.Requirement: The ERP system must URL-decode this parameter to retrieve the valid cXML, which contains line-item details like SKU, quantity, price, and UNSPSC codes.
Example Punchout Order Message (URL-encoded):
Example Punchout Order Message (decoded to XML):
Technical Implementation Details
Setup Request Configuration
The request must be sent as an HTTPS POST to the community-specific web service URL (e.g., https://miketest.unimarket-demo.com/ws).
The Return Handshake
The return process is "transparent" to the user. When they finish shopping, Unimarket bundles the PunchOutOrderMessage (containing the cart) and sends it via the user's browser back to the ERP. This allows the ERP to "grab" the items and populate a draft requisition automatically.
Troubleshooting Common Issues
401 Unauthorized: Usually caused by a mismatch in the
SharedSecretor a missingunimarket-idin the header.StartPage Not Opening: Ensure the ERP is configured to handle the
PunchOutSetupResponsesynchronously and can redirect the browser session to the provided URL.Empty Cart on Return: Check that the
BuyerCookiein the Order Message matches the cookie sent in the initial Setup Request.
Last updated