The one-shot pickup workflow provides a streamlined solution for creating individual shipments with immediate pickup request.
This workflow is designed for scenarios where each shipment requires its own dedicated pickup arrangement, offering real-time courier coordination and immediate confirmation or rejection feedback. For this reason, the one-shot workflow consolidates both shipment creation and pickup request submission into a single ShipmentRequest API call.
The ShipmentRequest call is now enhanced for including:
Sender information container setup for third-party addresses
Pickup data container configuration for scheduling parameters
The MOL validations still apply:
the MOL user must be enabled to create third party shipments and pickup
this includes having the permission to print the courier waybill for the selected courier
the MOL user must also be enabled to submit pickup requests for the chosen courier.
If the request is formally correct and the MOL user is allowed to execute pickup requests for the selected courier and the courier accepts the pickup request, the shipment will be created.
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:ns1="http://www.onlinembe.eu/ws/">
<SOAP-ENV:Body>
<ns2:ShipmentRequest xmlns:ns2="http://www.onlinembe.eu/ws/">
<RequestContainer>
<s>IT</s>
<Credentials>
<Username>your_username</Username>
<Passphrase>your_password</Passphrase>
</Credentials>
<InternalReferenceID>OR1536</InternalReferenceID>
<!-- Required: Custom Sender Information -->
<Sender>
<Name>Sender Contact Name</Name>
<CompanyName>Sender Company Name</CompanyName>
<Address>Via del sender address</Address>
<Phone>3331112222</Phone>
<ZipCode>20157</ZipCode>
<City>MILANO</City>
<State>MI</State>
<Country>IT</Country>
<Email>sender@email.com</Email>
</Sender>
<!-- Standard: Recipient Information -->
<Recipient>
<Name>Recipient Contact Name</Name>
<CompanyName>Recipient Company Name</CompanyName>
<Address>Recipient street address</Address>
<Phone>3331112222</Phone>
<ZipCode>20158</ZipCode>
<City>MILANO</City>
<State>MI</State>
<Country>IT</Country>
<Email>recipient@email.com</Email>
</Recipient>
<!-- Standard: Shipment Details -->
<Shipment>
<ShipperType>COURIERLDV</ShipperType>
<Description>Package description</Description>
<Service>2</Service>
<PackageType>GENERIC</PackageType>
<Items>
<Item>
<Weight>1</Weight>
<Dimensions>
<Lenght>15</Lenght>
<Height>15</Height>
<Width>25</Width>
</Dimensions>
</Item>
</Items>
</Shipment>
<!-- Required: Pickup Scheduling Data -->
<Pickup>
<PickupData>
<Notes>Special pickup instructions</Notes>
<Date>2023-07-12</Date>
<PreferredFrom>10:00</PreferredFrom>
<PreferredTo>12:00</PreferredTo>
<AlternativeFrom>14:00</AlternativeFrom>
<AlternativeTo>16:00</AlternativeTo>
</PickupData>
</Pickup>
</RequestContainer>
</ns2:ShipmentRequest>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
If the MOL user is not enabled to perform pickup requests for the selected courier, an error message will be returned
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<ns3:ShipmentRequestResponse xmlns:ns3="http://www.online.mbe.eu/ws/">
<Container>
<InternalReferenceID>091154</InternalReferenceID>
<Status>1</Status>
<Error>
<ID>1</ID>
<ErrorCode>SB_006</ErrorCode>
<Description>This MOL user is not enabled to do pickup requests for the selected courier. Check the smartchoice configuration.</Description>
</Error>
</Container>
</ns4:ShipmentRequestResponse>
</soap:Body>
</soap:Envelope>
If the courier rejects the pickup request, an error will be returned with a message generated by the courier:
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
<SOAP-ENV:Header/>
<SOAP-ENV:Body>
<ns3:ShipmentRequestResponse xmlns:ns3="http://www.onlineambs.eu/us/">
<RequestContainer>
<InternalReferenceID>OR1534</InternalReferenceID>
<Status>ERROR</Status>
<Errors>
<Error>
<Id>4</Id>
<ErrorCode>SR_006</ErrorCode>
<Description>Pickup date not valid</Description>
</Error>
<Error>
<Id>4</Id>
<ErrorCode>SR_006</ErrorCode>
<Description>Pickup data not valid. Shipments saved as draft in the courier systems</Description>
</Error>
</Errors>
</RequestContainer>
</ns3:ShipmentRequestResponse>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>