James and James (ControlPort) adapter - setup and reference
Everything you need to connect the LataSys 3PL Connector to James and
James Fulfilment via the ControlPort Client API v2: prerequisites,
connection setup, mappings, capabilities and provider-specific
behaviour.
What this adapter provides
| Flow |
Supported |
| Order push and despatch write-back |
Yes |
| Order amendment and hold/release |
Yes (state-gated by ControlPort) |
| Order cancellation |
Yes (until the order is labelled) |
| Inventory sync (batch/lot level) |
Yes |
| Product match and push |
Yes |
| Supplier push |
Yes (ControlPort expects a supplier on ASNs) |
| ASNs / GRNs |
Yes (goods-in polled; detail arrives on the ASN callback) |
| Returns (registration and discovery) |
Yes (no label from the API - see below) |
| Warehouse list fetch |
Yes |
| Carrier/services list fetch |
Yes (per warehouse) |
| Proof of delivery |
No - not offered by this provider's API |
| Webhook registration |
No API - see Callbacks below |
Prerequisites
- The LataSys 3PL Connector (core app) installed and licensed.
- A James and James account with ControlPort access, and from their
side:
- an API key generated in ControlPort Settings, encoded into the
bearer token per their recipe (published behind the client
portal under Settings - API Authentication);
- an approved E-Commerce Channel Account (Settings - Channels;
you request approval in the UI and their team approves it) - its
numeric id is required before any order can be pushed;
- at least one active Return Reason if you will register
returns.
- Verify the encoded token against the live account during onboarding:
the encoding recipe is not public, so the token cannot be validated
offline.
Installation
Install the LataSys 3PL Connector: James and James (ControlPort)
Adapter module. The provider then appears in the provider list when
creating a 3PL instance, along with its provider card (API operations
reference) under Configuration - Providers.
Connection setup
Authentication is a bearer token: every request carries
Authorization: Bearer <encoded token>. On the instance's Connection
tab:
- The API root URL is
https://api.controlport.co.uk for every
environment (ControlPort has no separate sandbox host); override
only if James and James gave you a different host.
- Paste the encoded bearer token into the API Key field, then
press Test Connection. The test lists your warehouse ids - the
same ids the warehouse mappings need. The instance moves from Draft
to Connected and the full HTTP exchange is captured in the Sync
Log.
Mappings
- Warehouses - press Fetch Warehouses and map each Odoo
warehouse to its numeric ControlPort warehouse id. Orders from an
unmapped warehouse are left to ControlPort's automatic
(cheapest-cost) warehouse allocation; ASNs always require a mapped
warehouse.
- Carriers - press Fetch Carriers to pull the carrier/service
list for the first mapped warehouse. The remote carrier code is
ControlPort's numeric carrier id - exactly what order create accepts
as
preferred_carrier_id. Note ControlPort may ignore the
preference if that carrier has no suitable service for an order.
- Statuses - press Load Missing Defaults. The adapter seeds
ControlPort's status vocabulary (pending, picking, awaiting_pack,
packing, checking, amending, boxed, labelled, despatched, held,
returned, deleted, plus the needs-attention codes) with canonical
meanings;
despatched triggers the despatch write-back.
- Requested Methods - press Load Requested Methods. The
options are the fixed postage-speed vocabulary (0 Urgent, 1
Priority, 2 Standard, 3 Economy) plus your carriers (code = carrier
id). Map each requested-delivery-method value your orders use: a
0-3 code becomes the order's
postage_speed, a carrier id becomes
its preferred_carrier_id. Unmapped values fall back to a keyword
heuristic, then to ControlPort's default (Standard).
ControlPort Options tab
| Field |
What it does |
| Channel Account ID |
The approved E-Commerce Channel Account (ControlPort Settings - Channels) orders are pushed to. Required - order pushes fail with a clear error until it is set |
| Tracked Delivery |
Request a postage method with carrier tracking events on every order |
| Signature on Delivery |
Request a postage method requiring a signature at the point of delivery on every order |
| Send Callback URLs |
Attach this instance's webhook URL as the callback_url on every order and ASN, so despatch/return/goods-in events push back instantly |
Callbacks / webhooks
ControlPort has no webhook-registration API. Two complementary routes:
- Account-wide - paste the instance's webhook URL (Connection tab)
into ControlPort's own settings as the Order / ASN callback URL.
- Per-record - switch on Send Callback URLs and the adapter
attaches the webhook URL to every order and ASN it sends.
Either way, inbound events trigger a targeted re-check of the
referenced record; scheduled polling remains the safety net.
Provider-specific behaviour
- Integer ids everywhere - ControlPort keys orders, products,
warehouses, carriers, batches, suppliers and ASNs by its own
integer ids. Order and ASN lines are resolved from SKUs to
ControlPort product ids at push time; a push fails with the full
list of unknown SKUs, so push the products first.
- Contacts - ControlPort requires name, phone, address line 1,
city, country NAME (not code) and postcode on every shipping,
billing and supplier contact; missing data raises a clear error
before anything is sent.
- State-gated edits - amendments are accepted until the order
starts picking (lines, billing, warehouse) or is labelled (address,
speed, tracked/signed-for); holds toggle until picking; cancels are
possible until labelled (pending orders are deleted, processing
orders return to stock). Later attempts surface as retryable logged
errors with ControlPort's own message.
- Products - creation requires a harmonised code (8-10 digits,
from the Odoo HS Code,
00000000 placeholder when unset), a
customs description (the product name, trimmed to 40 characters)
and an alpha-3 country of origin (converted from the product's
origin country, falling back to the company country).
- Returns - registering a return notifies ControlPort of the
expected items and creates a return ASN; the API produces no
label (tracked return labels are a separate ControlPort feature
their customer service enables per account). Returned orders are
also discovered by polling orders in status
returned; quantities
are taken from the despatched parcels, as the REST API does not
expose per-line received-return figures - the Order Return callback
carries the authoritative event.
- GRNs - ASN status
booked_in marks the delivery complete and
books the announced quantities; the received/discrepancy breakdown
(stockable vs unstockable) only travels on the ASN Update callback.
- ASNs expire - ControlPort expires ASNs after a prolonged period
of inactivity (about 90 days); only active or expired ASNs can be
cancelled.
Troubleshooting
| Symptom |
Likely cause |
| "credentials missing" on every flow |
Encoded bearer token not pasted into the API Key field |
| Connection test fails with 401 |
Token not encoded per ControlPort's recipe - re-check Settings - API Authentication in their portal |
| Order push fails with "Channel Account ID" |
Set the approved channel's numeric id on the ControlPort Options tab |
| Order push lists missing SKUs |
Push the products to ControlPort first (Product Sync / Push Products) |
| Order rejected as out of stock |
ControlPort rejects lines that are out of stock unless pre-orders are allowed on the channel |
| ASN push fails about warehouse mapping |
Map the Odoo warehouse to its numeric ControlPort warehouse id |
| Lots missing from stock sync |
Switch on the instance's lot tracking option - batch numbers are resolved via the Batch API only when it is on |
See also: James and James (ControlPort) adapter - process maps for
the end-to-end flow diagrams.
James and James, James and James Fulfilment and ControlPort are
trademarks of their respective owner; the names are used solely to
identify the service this module interoperates with.
Related Articles
James and James (ControlPort) adapter - process maps
How every flow in the LataSys 3PL Connector runs when the James and James (ControlPort) adapter is installed. Transport: REST/JSON Client API v2 over HTTPS. Auth: Authorization: Bearer <encoded token> (API key generated in ControlPort Settings, ...
ShipBob adapter - setup and reference
Everything you need to connect the LataSys 3PL Connector to ShipBob: prerequisites, connection setup, mappings, capabilities and provider-specific behaviour. ShipBob's Developer API is versioned REST/JSON (this adapter speaks the 2026-07 version). ...
Huboo adapter - setup and reference
Everything you need to connect the LataSys 3PL Connector to Huboo: prerequisites, connection setup, mappings, capabilities and provider-specific behaviour. The adapter speaks Huboo's public REST API v2. What this adapter provides Flow Supported Order ...
ShipHero adapter - setup and reference
Everything you need to connect the LataSys 3PL Connector to ShipHero: prerequisites, connection setup, mappings, capabilities and provider-specific behaviour. What this adapter provides Flow Supported Order push and despatch write-back Yes Order ...
MintSoft adapter - setup and reference
Everything you need to connect the LataSys 3PL Connector to MintSoft (Mintsoft OMS/WMS): prerequisites, connection setup, mappings, capabilities and provider-specific behaviour. What this adapter provides Flow Supported Order push and despatch ...