RetailCRM

RetailCRM: label from trigger

The RetailCRM trigger calls a bridge script with the order number. The bridge fetches order data, buys the cheapest label, and records the tracking in a custom field and manager's comment.

Downloadable files

What you’ll need

Step-by-step instructions

  1. Download retailcrm-bridge.php and shippickup.php, upload them to the same folder on your server.
  2. In the ShipPickup dashboard, create a live API key (rates:read, labels:create). Set environment variables from the top of the file: SHIPPICKUP_API_KEY, SHIPPICKUP_FROM, SHIPPICKUP_PARCEL, BRIDGE_SECRET, RETAILCRM_URL, RETAILCRM_API_KEY.
  3. Create a text custom field for tracking in the order with the code shippickup_tracking (use a different code in RETAILCRM_TRACK_FIELD if needed).
  4. In RetailCRM, go to “Administration”, “Triggers” and create a status change trigger with an “HTTP request” action: POST method, URL https://your-server/retailcrm-bridge.php?secret=BRIDGE_SECRET_VALUE, JSON body with the order number {"order_id": ...}, replacing dots with the order number variable from the trigger editor.
  5. Fill in the delivery address in the order (country as ISO code, postal code, region, city, street) and order weight in grams.

Important to know

Files contain no keys or passwords: all secrets are set by you in environment settings. Do not publish files with your values.

← All ready-made solutions · Common Scenarios