Appearance
CMP
CMP supplies catalog data and can receive eligible dropship orders. The reviewed integration mutates local catalog and price records; it has no dry-run mode in the import command.
Evidence boundary
This page describes source at commit 42116ebc0ba509bce9cc6651a55ecefd9a5fdb38. API credentials, scheduled execution, and provider readback remain unverified.
Entry points
| Operation | Command or event | Source behavior |
|---|---|---|
| Catalog import | menzzo:cmp:import-products-from-api --action=<action> | Reads CMP products, upserts mz_cmp_product, creates categories, recalculates prices, updates linked Logidav products, queues price updates, and deactivates products absent from the API result. |
| Order submission | AfterSaleCreatedEvent / AfterSaleUpdatedEvent | Submits eligible CMP lines after the sale enters processing, then stores cmp_order_id on success. |
The action value is required by the command. The onlyCreatedProduct path filters existing products; it is not a preview. Treat every run as a write operation.
Catalog and price mapping
The import stores supplier unit price, shipping price, availability, quantity, and product identifiers. It calculates menzzo_price from the supplier unit price and shipping amount; “LOT DE” products use a quantity multiplier before the final price is written. Linked store-3 price, dropship price, depot price, quantity, and active status can change, with price-log rows and a downstream ProductPriceUpdateProcessor event where applicable.
When a product is missing from the API result, the source can mark the corresponding local product unavailable. Confirm the API result scope before running this in production so a partial provider response cannot be interpreted as a complete catalog.
Order rules
The order service only considers a processing sale and non-canceled, non-shipped CMP lines without an existing CMP order id. It sends the supplier part number, quantity, line dimensions, weight, and the split shipping address. Addresses are split at 25 characters for the provider payload.
Carrier selection is based on the aggregate line dimensions and weight:
- carrier
081when total length is at most200and total weight is at most30; - carrier
097otherwise.
On a successful provider response with code 200, the service stores the returned order id. Exceptions persist an error message and create a CMP alert; the transaction is rolled back.
What remains unknown
- The valid
--actionvalues and the provider-side meaning of each. - Whether a provider response is always complete before the “missing from API” deactivation step.
- Which scheduled jobs, stores, and API credentials are active.
Source locations
src/CmpBundle/Command/ImportProductsFromApiCommand.php— catalog import, pricing, linked product updates, and deactivation behavior.src/CmpBundle/Services/OrderService.php— order eligibility, carrier thresholds, persistence, and alerts.