The BookShipment method places an order for your selected service. The response (if successful) includes an order reference, a breakdown of the billing for the order, the file content in Base64 encoding for any labels and other shipment documentation for the order along with download links.
There are two ways you can book a shipment on this method:
Quote id for a shipment can be obtained by submitting a request to the GetQuote method. A successful response will return the QuoteID for that shipment:
The QuoteID can then be used in the QuoteSelection section of the book request to use the shipment information from the quote request without having to re-submit it.
Instead of submitting a QuoteID the full shipment details can be specified within the book request via the Shipment property. This uses the same structure as the Shipment object from the GetQuote request, so the same logic used to construct that section of the GetQuote request on your implementation will work for populating the book request.
{ "Credentials": { "APIKey": "[API KEY]", "Password": "[API PASSWORD]" }, "QuoteSelection": { "QuoteID": 183 }, "BookDetails": { "ServiceID": 53, "YourReference": "MyRef123", "ShippingCharges": 45.89, "Collection": { "CollectionDate": "2020-04-07", "ReadyFrom": "12:30", "CollectionOptionID": 1 }, "BookAccessories": [ { "Code": "SIG" } ], "Insurance": { "CoverValue": 119.78, "ExcessValue": 20.0, "GoodsAreNew": true, "GoodsAreFragile": false }, "DeliveryInstructions": "Leave in the porch" } }
<BookShipmentRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://www.transglobalexpress.co.uk/API/V2"> <Credentials> <APIKey>[API KEY]</APIKey> <Password>[API PASSWORD]</Password> </Credentials> <QuoteSelection> <QuoteID>183</QuoteID> </QuoteSelection> <BookDetails> <ServiceID>53</ServiceID> <YourReference>MyRef123</YourReference> <ShippingCharges>45.89</ShippingCharges> <Collection> <CollectionDate>2020-04-07</CollectionDate> <ReadyFrom>12:30</ReadyFrom> <CollectionOptionID>1</CollectionOptionID> </Collection> <BookAccessories> <BookAccessory> <Code>SIG</Code> </BookAccessory> </BookAccessories> <Insurance> <CoverValue>119.78</CoverValue> <ExcessValue>20</ExcessValue> <GoodsAreNew>true</GoodsAreNew> <GoodsAreFragile>false</GoodsAreFragile> </Insurance> </BookDetails> </BookShipmentRequest>
{ "Credentials": { "APIKey": "[API KEY]", "Password": "[API PASSWORD]" }, "Shipment": { "Consignment": { "ItemType": "Parcel", "ItemsAreStackable": true, "ConsignmentSummary": "Stationary", "ConsignmentValue": 50.45, "ConsignmentCurrency":{ "CurrencyCode": "GBP" }, "Packages": [ { "Weight": 25.0, "Length": 30.0, "Width": 20.0, "Height": 10.0, "CommodityDetails": [ { "CommodityCode": "8708999790", "CommodityDescription": "Car Batteries", "CountryOfOrigin": { "CountryCode": "DE" }, "NumberOfUnits": 5, "UnitValue": 15.5, "UnitWeight": 4.0, "ProductCode": "YourProductCode", "ManufacturerAddress": { "CompanyName": "[MANUFACTURER ADDRESS COMPANY NAME]", "AddressLineOne": "[MANUFACTURER ADDRESS LINE 1]", "AddressLineTwo": "[MANUFACTURER ADDRESS LINE 2]", "City": "[MANUFACTURER ADDRESS CITY]", "County": "[MANUFACTURER ADDRESS COUNTY]", "Postcode": "[MANUFACTURER ADDRESS POSTCODE]", "Country": { "CountryCode": "GB" } } }, { "CommodityCode": "8708301040", "CommodityDescription": "Brake Pads", "CountryOfOrigin": { "CountryCode": "FR" }, "NumberOfUnits": 2, "UnitValue": 11.0, "UnitWeight": 2.5, "ProductCode": "YourProductCode2" } ] }, { "Weight": 3.5, "Length": 47.98, "Width": 45.62, "Height": 12.5, "CommodityDetails": [ { "CommodityCode": "8708951010", "CommodityDescription": "Air Bag", "CountryOfOrigin": { "CountryID": 231 }, "NumberOfUnits": 1, "UnitValue": 35.78, "UnitWeight": 3.5, "ProductCode": "YourProductCode3", "ManufacturerAddress": { "CompanyName": "[MANUFACTURER ADDRESS COMPANY NAME]", "AddressLineOne": "[MANUFACTURER ADDRESS LINE 1]", "AddressLineTwo": "[MANUFACTURER ADDRESS LINE 2]", "City": "[MANUFACTURER ADDRESS CITY]", "County": "[MANUFACTURER ADDRESS COUNTY]", "Postcode": "[MANUFACTURER ADDRESS POSTCODE]", "Country": { "CountryID": 232 } } } ] } ] }, "CollectionAddress": { "Forename": "Joe", "Surname": "Bloggs", "EmailAddress": "joe.bloggs@testsender.co.uk", "TelephoneNumber": "[TELEPHONE NUMBER HERE]", "MobileNumber": "[MOBILE NUMBER HERE]", "CompanyName": "Transglobal Express", "AddressLineOne": "Unit 5, The Gateway", "AddressLineTwo": "Old Hall Road", "City": "Bromborough", "County": "Merseyside", "Postcode": "CH62 3NX", "Country": { "CountryID": 231 }, "IsAddressResidential": false, "EORINumber": "[SENDER EORI NUMBER]", "VATNumber": "[SENDER VAT NUMBER]" }, "DeliveryAddress": { "Forename": "Test", "Surname": "Testerson", "EmailAddress": "testerson@testreceiver.com", "TelephoneNumber": "[TELEPHONE NUMBER HERE]", "MobileNumber": "[MOBILE NUMBER HERE]", "CompanyName": "Test Corp", "AddressLineOne": "Test Street", "City": "New York", "County": "NY", "Postcode": "10005", "Country": { "CountryCode": "US" }, "IsAddressResidential": true, "EORINumber": "[RECEIVER EORI NUMBER]", "VATNumber": "[RECEIVER VAT NUMBER]" }, "ExporterAddress": { "Forename": "Joe", "Surname": "Bloggs", "EmailAddress": "joe.bloggs@testsender.co.uk", "TelephoneNumber": "[TELEPHONE NUMBER HERE]", "MobileNumber": "[MOBILE NUMBER HERE]", "CompanyName": "Transglobal Express", "AddressLineOne": "Unit 5, The Gateway", "AddressLineTwo": "Old Hall Road", "City": "Bromborough", "County": "Merseyside", "Postcode": "CH62 3NX", "Country": { "CountryID": 231 }, "IsAddressResidential": false, "EORINumber": "[EXPORTER EORI NUMBER]", "VATNumber": "[EXPORTER VAT NUMBER]" }, "ImporterAddress": { "Forename": "Test", "Surname": "Testerson", "EmailAddress": "testerson@testreceiver.com", "TelephoneNumber": "[TELEPHONE NUMBER HERE]", "MobileNumber": "[MOBILE NUMBER HERE]", "CompanyName": "Test Corp", "AddressLineOne": "Test Street", "City": "New York", "County": "NY", "Postcode": "10005", "Country": { "CountryCode": "US" }, "IsAddressResidential": true, "EORINumber": "[IMPORTER EORI NUMBER]", "VATNumber": "[IMPORTER VAT NUMBER]" } }, "BookDetails": { "ServiceID": 53, "YourReference": "MyRef123", "ShippingCharges": 45.89, "Collection": { "CollectionDate": "2020-04-07", "ReadyFrom": "12:30", "CollectionOptionID": 1 }, "BookAccessories": [ { "Code": "SIG" } ], "Insurance": { "CoverValue": 119.78, "ExcessValue": 20.0, "GoodsAreNew": true, "GoodsAreFragile": false }, "DeliveryInstructions": "Leave in the porch" } }
<BookShipmentRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://www.transglobalexpress.co.uk/API/V2"> <Credentials> <APIKey>[API KEY]</APIKey> <Password>[API PASSWORD]</Password> </Credentials> <Shipment> <Consignment> <ItemType>Parcel</ItemType> <ItemsAreStackable>true</ItemsAreStackable> <ConsignmentSummary>Stationary</ConsignmentSummary> <ConsignmentValue>50.45</ConsignmentValue> <ConsignmentCurrency> <CurrencyCode>GBP</CurrencyCode> </ConsignmentCurrency> <Packages> <Package> <Weight>25</Weight> <Length>30</Length> <Width>20</Width> <Height>10</Height> <CommodityDetails> <CommodityLine> <CommodityCode>8708999790</CommodityCode> <CommodityDescription>Car Batteries</CommodityDescription> <CountryOfOrigin> <CountryCode>DE</CountryCode> </CountryOfOrigin> <NumberOfUnits>5</NumberOfUnits> <UnitValue>15.5</UnitValue> <UnitWeight>4</UnitWeight> <ProductCode>YourProductCode</ProductCode> <ManufacturerAddress> <CompanyName>[MANUFACTURER ADDRESS COMPANY NAME]</CompanyName> <AddressLineOne>[MANUFACTURER ADDRESS LINE 1]</AddressLineOne> <AddressLineTwo>[MANUFACTURER ADDRESS LINE 2]</AddressLineTwo> <City>[MANUFACTURER ADDRESS CITY]</City> <County>[MANUFACTURER ADDRESS COUNTY]</County> <Postcode>[MANUFACTURER ADDRESS POSTCODE]</Postcode> <Country> <CountryCode>GB</CountryCode> </Country> </ManufacturerAddress> </CommodityLine> <CommodityLine> <CommodityCode>8708301040</CommodityCode> <CommodityDescription>Brake Pads</CommodityDescription> <CountryOfOrigin> <CountryCode>FR</CountryCode> </CountryOfOrigin> <NumberOfUnits>2</NumberOfUnits> <UnitValue>11</UnitValue> <UnitWeight>2.5</UnitWeight> <ProductCode>YourProductCode2</ProductCode> </CommodityLine> </CommodityDetails> </Package> <Package> <Weight>3.5</Weight> <Length>47.98</Length> <Width>45.62</Width> <Height>12.5</Height> <CommodityDetails> <CommodityLine> <CommodityCode>8708951010</CommodityCode> <CommodityDescription>Air Bag</CommodityDescription> <CountryOfOrigin> <CountryID>231</CountryID> </CountryOfOrigin> <NumberOfUnits>1</NumberOfUnits> <UnitValue>35.78</UnitValue> <UnitWeight>3.5</UnitWeight> <ProductCode>YourProductCode3</ProductCode> <ManufacturerAddress> <CompanyName>[MANUFACTURER ADDRESS COMPANY NAME]</CompanyName> <AddressLineOne>[MANUFACTURER ADDRESS LINE 1]</AddressLineOne> <AddressLineTwo>[MANUFACTURER ADDRESS LINE 2]</AddressLineTwo> <City>[MANUFACTURER ADDRESS CITY]</City> <County>[MANUFACTURER ADDRESS COUNTY]</County> <Postcode>[MANUFACTURER ADDRESS POSTCODE]</Postcode> <Country> <CountryID>232</CountryID> </Country> </ManufacturerAddress> </CommodityLine> </CommodityDetails> </Package> </Packages> </Consignment> <CollectionAddress> <Forename>Joe</Forename> <Surname>Bloggs</Surname> <EmailAddress>joe.bloggs@testsender.co.uk</EmailAddress> <TelephoneNumber>[TELEPHONE NUMBER HERE]</TelephoneNumber> <MobileNumber>[MOBILE NUMBER HERE]</MobileNumber> <CompanyName>Transglobal Express</CompanyName> <AddressLineOne>Unit 5, The Gateway</AddressLineOne> <AddressLineTwo>Old Hall Road</AddressLineTwo> <City>Bromborough</City> <County>Merseyside</County> <Postcode>CH62 3NX</Postcode> <Country> <CountryID>231</CountryID> </Country> <IsAddressResidential>false</IsAddressResidential> <EORINumber>[SENDER EORI NUMBER]</EORINumber> </CollectionAddress> <DeliveryAddress> <Forename>Test</Forename> <Surname>Testerson</Surname> <EmailAddress>testerson@testreceiver.com</EmailAddress> <TelephoneNumber>[TELEPHONE NUMBER HERE]</TelephoneNumber> <MobileNumber>[MOBILE NUMBER HERE]</MobileNumber> <CompanyName>Test Corp</CompanyName> <AddressLineOne>Test Street</AddressLineOne> <City>New York</City> <County>NY</County> <Postcode>10005</Postcode> <Country> <CountryCode>US</CountryCode> </Country> <IsAddressResidential>true</IsAddressResidential> <EORINumber>[RECEIVER EORI NUMBER]</EORINumber> </DeliveryAddress> <ExporterAddress> <Forename>Joe</Forename> <Surname>Bloggs</Surname> <EmailAddress>joe.bloggs@testsender.co.uk</EmailAddress> <TelephoneNumber>[TELEPHONE NUMBER HERE]</TelephoneNumber> <MobileNumber>[MOBILE NUMBER HERE]</MobileNumber> <CompanyName>Transglobal Express</CompanyName> <AddressLineOne>Unit 5, The Gateway</AddressLineOne> <AddressLineTwo>Old Hall Road</AddressLineTwo> <City>Bromborough</City> <County>Merseyside</County> <Postcode>CH62 3NX</Postcode> <Country> <CountryID>231</CountryID> </Country> <IsAddressResidential>false</IsAddressResidential> <EORINumber>[SENDER EORI NUMBER]</EORINumber> <VATNumber>[SENDER VAT NUMBER]</VATNumber> </ExporterAddress> <ImporterAddress> <Forename>Test</Forename> <Surname>Testerson</Surname> <EmailAddress>testerson@testreceiver.com</EmailAddress> <TelephoneNumber>[TELEPHONE NUMBER HERE]</TelephoneNumber> <MobileNumber>[MOBILE NUMBER HERE]</MobileNumber> <CompanyName>Test Corp</CompanyName> <AddressLineOne>Test Street</AddressLineOne> <City>New York</City> <County>NY</County> <Postcode>10005</Postcode> <Country> <CountryCode>US</CountryCode> </Country> <IsAddressResidential>true</IsAddressResidential> <EORINumber>[RECEIVER EORI NUMBER]</EORINumber> <VATNumber>[RECEIVER VAT NUMBER]</VATNumber> </ImporterAddress> </Shipment> <BookDetails> <ServiceID>53</ServiceID> <YourReference>MyRef123</YourReference> <ShippingCharges>45.89</ShippingCharges> <Collection> <CollectionDate>2020-04-07</CollectionDate> <ReadyFrom>12:30</ReadyFrom> <CollectionOptionID>1</CollectionOptionID> </Collection> <BookAccessories> <BookAccessory> <Code>SIG</Code> </BookAccessory> </BookAccessories> <Insurance> <CoverValue>119.78</CoverValue> <ExcessValue>20</ExcessValue> <GoodsAreNew>true</GoodsAreNew> <GoodsAreFragile>false</GoodsAreFragile> </Insurance> </BookDetails> </BookShipmentRequest>
Property Name | Data Type | Parent | M | Comment | Example |
---|---|---|---|---|---|
BookShipmentRequest | Container | M | The root container for the request. | ||
Credentials | |||||
Credentials | Container | BookShipmentRequest | M | The api credentials container. | |
APIKey | string | Credentials | M | The api key. | Th6fLmTxBv |
Password | string | Credentials | M |
The api password. Please note this is NOT the password used to log into the website. |
rGf3!lmT4dA |
QuoteSelection | |||||
QuoteSelection | Container | BookShipmentRequest | M | The quote selection container. | |
QuoteID | integer | QuoteSelection | M | The quote id to get shipment details from. | 183 |
Shipment | |||||
Shipment | Container | BookShipmentRequest | M | The shipment container. | |
Consignment | |||||
Consignment | Container | Shipment | M | The consignment container. | |
ItemType | string | Consignment | M |
The item type. Valid values are: Parcel, Document, Pallet, Suitcase |
Parcel |
ItemsAreStackable | string | Consignment | O |
Indicates whether or not the items in the consignment
are stackable. Valid values are "true" and "false". Some carriers levy a surcharge if the items are not stackable, which will be show as part of the price breakdown of the service result. If not supplied the value will be defaulted to "true", however if the items go on to be deemed non stackable by the carrier and a surcharge applied this will be invoiced by our accounts team. |
false |
ConsignmentSummary | string | Consignment | M | The summmary for the whole consignment. | Car Parts |
ConsignmentValue | decimal | Consignment | M | The monetary value for the whole consignment. | 102.78 |
ConsignmentCurrency | Container | Consignment | O |
Defines the currency the consignment value/commodity unit values are specified in. Please note: This section only specifies the currency for the consignment value/commodity values that will be used on your customs invoice, it does not affect any monetary values received in the api response; any monetary values in an api response will be in the default currency of GBP |
|
CurrencyCode | string | ConsignmentCurrency | M |
The currency code that specifies the consignment value currency. Available options are: GBP: Great British Pound EUR: Euro USD: US Dollar AUD: Australian Dollar NZD: New Zealand Dollar CAD: Canadian Dollar CHF: Swiss Franc CNY: Chinese Renminbi SEK: Swedish Krona HKD: Hong Kong Dollar AED: UAE Dirham JPY: Japanese Yen |
GBP |
Packages | |||||
Packages | Container | Consignment | M | The container for consignment items. | |
Package | Container | Packages | M |
The container for a consignment item. Note: The element container is used in XML format requests, if using JSON format it is not explicitly named, the "Packages" element (see above) is an array of Package objects. This is demonstrated in the provided JSON example above this table. |
|
Weight | decimal | Package | M | The item weight in Kg. | 3.5 |
Length | decimal | Package | M | The item length in Cm. | 47.98 |
Width | decimal | Package | M | The item width in Cm. | 45.62 |
Height | decimal | Package | M | The item height in Cm. | 12.5 |
CommodityDetails | |||||
CommodityDetails | Container | Package | C |
The container for commodity information. The information provided in this section will be used to generate a packing list if required when exporting to/importing from the destination. Some carriers require this information in order to place a booking with them, so this information may be required even if the client will be using their own packing list. The CommodityDetails must be provided if the shipment ItemType is not Document type, and it is importing from or exporting to a country outside of the EU. |
|
CommodityLine | Container | CommodityDetails | O |
The container for commodity line information for each commodity type within the package. Note: The element container is used in XML format requests, if using JSON format it is not explicitly named, the "CommodityDetails" element (see above) is an array of CommodityLine objects. This is demonstrated in the provided JSON example above this table. |
|
CommodityCode | string | CommodityLine | O | The commodity code. | 8708999790 |
CommodityDescription | string | CommodityLine | M | The commodity description. | Car Batteries |
CountryOfOrigin | Container | CommodityLine | M |
The container for defining the country of origin. Note this is the same container format when specifying a country anywhere in this request. |
|
CountryID | integer | CountryOfOrigin | C |
The country id as defined within the Transglobal Express system. Note: This value can be omitted if providing a value for CountryCode. If both CountryID and CountryCode are provided, the CountryCode value will be ignored and the country will be selected based on the CountryID value. Country id values can be discovered via the countries section of the Transglobal Express API (/Country/V2/GetCountries). |
73 |
CountryCode | string | CountryOfOrigin | C |
The ISO code for the country. Note: This value can be omitted if providing a value for CountryID. If both CountryID and CountryCode are provided, the CountryCode value will be ignored and the country will be selected based on the CountryID value. Country code values can be discovered via the countries section of the Transglobal Express API (/Country/V2/GetCountries). |
FR |
NumberOfUnits | integer | CommodityLine | M |
The number of items for this commodity within the package. If sending large quantites of commodities it may be necessary to specify the number based on subgroupings such as "packs" rather than the individual unit. Some carriers validate the commodity data stringently and therefore so must we. An example would be sending a box of 10,000 pens in packs of 20, with a total value of £50.00 If specifying 1000 units the unit price would be £0.005, which would then be rejected by the carrier. If the unit value was increased to the minimum allowed ad inflated consignment value would be declared that could potentially incur greater customs charges. The best solution therefore is to specify the CommodityDescription as "pack of pens" and NumberOfUnits as "500" and then you can specify the unit value as "0.1". |
2 |
UnitValue | decimal | CommodityLine | M | The monetary value of a single commodity item. | 11.00 |
UnitWeight | decimal | CommodityLine | M | The weight in Kg of a single commodity item. | 2.5 |
ProductCode | decimal | CommodityLine | C | The product code/reference of the commodities being sent. If you have products set up in your Account Product Library (See "Save items in your Product Library" on our Contents Declaration Page for more information), and you this will be used to link your commodity line to that product and gain access to data set there such as the manufacturer address, which may be required by certain carriers (eg USPS). | PR012462542 |
ManufacturerAddress | Container | CommodityLine | C |
When sending with USPS, certain HS codes (subject to change) may require manufacturer address to be supplied in order for the booking to
be accepted. This can be passed via this ManufacturerAddress property, or be automatically looked up via the ProductCode property if
you have an entry in your Transglobal Account Product Library matching that product code with a manufacturer address already set. When passing via the ManufacturerAddress property, you can use the same object as is used for Collection/Delivery address. While the Forename, Surname, TelephoneNumber, EmailAddress properies need not be populated for the manufacturer address, including them will not negatively affect the booking. |
PR012462542 |
CompanyName | string | ManufacturerAddress | M | The company name. | Transglobal Express Ltd |
AddressLineOne | string | ManufacturerAddress | M | The address line one. | Unit 5, The Gateway |
AddressLineTwo | string | ManufacturerAddress | O | The address line two. | Old Hall Road |
City | string | ManufacturerAddress | M | The city. | Bromborough |
County | string | ManufacturerAddress | C |
The county. While optional in most cases, when the addess is for the United States or Canada, the two letter state code must be provided here. |
Merseyside |
Postcode | string | ManufacturerAddress | C |
The postcode. This is mandatory for all countries that have a postal or zip code. It is marked as conditional here because some countries such as Ireland (at the time of writing this documentation) do not use postcodes and as such no postcode would be required for an address in that country. |
CH62 3NX |
Country | Container | ManufacturerAddress | M |
The postcode. The container for defining the address country. Note this is the same container format when specifying a country anywhere in this request. |
|
CountryID | integer | Country | C |
The country id as defined within the Transglobal Express system. Note: This value can be omitted if providing a value for CountryCode. If both CountryID and CountryCode are provided, the CountryCode value will be ignored and the country will be selected based on the CountryID value. Country id values can be discovered via the countries section of the Transglobal Express API (/Country/V2/GetCountries). |
231 |
CountryCode | string | Country | C |
The ISO code for the country. Note: This value can be omitted if providing a value for CountryID. If both CountryID and CountryCode are provided, the CountryCode value will be ignored and the country will be selected based on the CountryID value. Country code values can be discovered via the countries section of the Transglobal Express API (/Country/V2/GetCountries). |
GB |
CollectionAddress | |||||
CollectionAddress | Container | Shipment | M | The collection address container. | |
Forename | string | CollectionAddress | M | The forename. | Joe |
Surname | string | CollectionAddress | M | The surname. | Bloggs |
Surname | string | CollectionAddress | M | The surname. | Bloggs |
EmailAddress | string | CollectionAddress | M | The email address. | joe.bloggs@testsender.co.uk |
TelephoneNumber | string | CollectionAddress | M | The phone number. | 01234567890 |
MobileNumber | string | CollectionAddress | O | The mobile phone number. | 01234567890 |
CompanyName | string | CollectionAddress | O | The company name. | Transglobal Express |
AddressLineOne | string | CollectionAddress | M | The address line one. | Unit 5, The Gateway |
AddressLineTwo | string | CollectionAddress | O | The address line two. | Old Hall Road |
City | string | CollectionAddress | M | The city. | Bromborough |
County | string | CollectionAddress | C |
The county. While optional in most cases, when the addess is for the United States or Canada, the two letter state code must be provided here. |
Merseyside |
Postcode | string | CollectionAddress | C |
The postcode. This is mandatory for all countries that have a postal or zip code. It is marked as conditional here because some countries such as Ireland (at the time of writing this documentation) do not use postcodes and as such no postcode would be required for an address in that country. |
CH62 3NX |
Country | Container | CollectionAddress | M |
The postcode. The container for defining the address country. Note this is the same container format when specifying a country anywhere in this request. |
|
CountryID | integer | Country | C |
The country id as defined within the Transglobal Express system. Note: This value can be omitted if providing a value for CountryCode. If both CountryID and CountryCode are provided, the CountryCode value will be ignored and the country will be selected based on the CountryID value. Country id values can be discovered via the countries section of the Transglobal Express API (/Country/V2/GetCountries). |
231 |
CountryCode | string | Country | C |
The ISO code for the country. Note: This value can be omitted if providing a value for CountryID. If both CountryID and CountryCode are provided, the CountryCode value will be ignored and the country will be selected based on the CountryID value. Country code values can be discovered via the countries section of the Transglobal Express API (/Country/V2/GetCountries). |
GB |
IsAddressResidential | boolean | CollectionAddress | O |
Indicates whether or not the address is residential. true = Residential false = Non Residential |
true |
EORINumber | string | CollectionAddress | C | The sender EORI Number | GBXXXXXXX |
VATNumber | string | CollectionAddress | O | The sender VAT Number | FRXXXXXXX |
DeliveryAddress | |||||
DeliveryAddress | Container | Shipment | M | The collection address container. | |
Forename | string | DeliveryAddress | M | The forename. | Joe |
Surname | string | DeliveryAddress | M | The surname. | Bloggs |
Surname | string | DeliveryAddress | M | The surname. | Bloggs |
EmailAddress | string | DeliveryAddress | M | The email address. | joe.bloggs@testsender.co.uk |
TelephoneNumber | string | DeliveryAddress | M | The phone number. | 01234567890 |
MobileNumber | string | DeliveryAddress | O | The mobile phone number. | 01234567890 |
CompanyName | string | DeliveryAddress | O | The company name. | Transglobal Express |
AddressLineOne | string | DeliveryAddress | M | The address line one. | Unit 5, The Gateway |
AddressLineTwo | string | DeliveryAddress | O | The address line two. | Old Hall Road |
City | string | DeliveryAddress | M | The city. | Bromborough |
County | string | DeliveryAddress | C |
The county. While optional in most cases, when the addess is for the United States or Canada, the two letter state code must be provided here. |
Merseyside |
Postcode | string | DeliveryAddress | C |
The postcode. This is mandatory for all countries that have a postal or zip code. It is marked as conditional here because some countries such as Ireland (at the time of writing this documentation) do not use postcodes and as such no postcode would be required for an address in that country. |
CH62 3NX |
Country | Container | DeliveryAddress | M |
The postcode. The container for defining the address country. Note this is the same container format when specifying a country anywhere in this request. |
|
CountryID | integer | Country | C |
The country id as defined within the Transglobal Express system. Note: This value can be omitted if providing a value for CountryCode. If both CountryID and CountryCode are provided, the CountryCode value will be ignored and the country will be selected based on the CountryID value. Country id values can be discovered via the countries section of the Transglobal Express API (/Country/V2/GetCountries). |
232 |
CountryCode | string | Country | C |
The ISO code for the country. Note: This value can be omitted if providing a value for CountryID. If both CountryID and CountryCode are provided, the CountryCode value will be ignored and the country will be selected based on the CountryID value. Country code values can be discovered via the countries section of the Transglobal Express API (/Country/V2/GetCountries). |
US |
IsAddressResidential | boolean | DeliveryAddress | O |
Indicates whether or not the address is residential. true = Residential false = Non Residential |
true |
EORINumber | string | DeliveryAddress | C | The receiver EORI Number | FRXXXXXXX |
VATNumber | string | DeliveryAddress | O | The receiver VAT Number | FRXXXXXXX |
ExporterAddress | |||||
ExporterAddress | Container | Shipment | M |
The exporter address container. Please note, this is optional. If your exporter address details are an exact match of the CollectionAddress details then you do not need to include this section (though you can if you wish). |
|
Forename | string | ExporterAddress | M | The forename. | Joe |
Surname | string | ExporterAddress | M | The surname. | Bloggs |
Surname | string | ExporterAddress | M | The surname. | Bloggs |
EmailAddress | string | ExporterAddress | M | The email address. | joe.bloggs@testsender.co.uk |
TelephoneNumber | string | ExporterAddress | M | The phone number. | 01234567890 |
MobileNumber | string | ExporterAddress | O | The mobile phone number. | 01234567890 |
CompanyName | string | ExporterAddress | O | The company name. | Transglobal Express |
AddressLineOne | string | ExporterAddress | M | The address line one. | Unit 5, The Gateway |
AddressLineTwo | string | ExporterAddress | O | The address line two. | Old Hall Road |
City | string | ExporterAddress | M | The city. | Bromborough |
County | string | ExporterAddress | C |
The county. While optional in most cases, when the addess is for the United States or Canada, the two letter state code must be provided here. |
Merseyside |
Postcode | string | ExporterAddress | C |
The postcode. This is mandatory for all countries that have a postal or zip code. It is marked as conditional here because some countries such as Ireland (at the time of writing this documentation) do not use postcodes and as such no postcode would be required for an address in that country. |
CH62 3NX |
Country | Container | ExporterAddress | M |
The postcode. The container for defining the address country. Note this is the same container format when specifying a country anywhere in this request. |
|
CountryID | integer | Country | C |
The country id as defined within the Transglobal Express system. Note: This value can be omitted if providing a value for CountryCode. If both CountryID and CountryCode are provided, the CountryCode value will be ignored and the country will be selected based on the CountryID value. Country id values can be discovered via the countries section of the Transglobal Express API (/Country/V2/GetCountries). |
231 |
CountryCode | string | Country | C |
The ISO code for the country. Note: This value can be omitted if providing a value for CountryID. If both CountryID and CountryCode are provided, the CountryCode value will be ignored and the country will be selected based on the CountryID value. Country code values can be discovered via the countries section of the Transglobal Express API (/Country/V2/GetCountries). |
GB |
IsAddressResidential | boolean | CollectionAddress | O |
Indicates whether or not the address is residential. true = Residential false = Non Residential |
true |
EORINumber | string | ExporterAddress | C |
The sender EORI Number. This will take precedence over an EORI number value entered in both the CollectionAddress section and BookDetails section. |
GBXXXXXXX |
VATNumber | string | ExporterAddress | O |
The sender VAT Number. This will take precedence over a VAT number value entered in both the CollectionAddress section and BookDetails section. |
FRXXXXXXX |
ImporterAddress | |||||
ImporterAddress | Container | Shipment | O |
The importer address container. Please note, this is optional. If your importer address details are an exact match of the DeliveryAddress details then you do not need to include this section (though you can if you wish). |
|
Forename | string | ImporterAddress | M | The forename. | Joe |
Surname | string | ImporterAddress | M | The surname. | Bloggs |
Surname | string | ImporterAddress | M | The surname. | Bloggs |
EmailAddress | string | ImporterAddress | M | The email address. | joe.bloggs@testsender.co.uk |
TelephoneNumber | string | ImporterAddress | M | The phone number. | 01234567890 |
MobileNumber | string | ImporterAddress | O | The mobile phone number. | 01234567890 |
CompanyName | string | ImporterAddress | O | The company name. | Transglobal Express |
AddressLineOne | string | ImporterAddress | M | The address line one. | Unit 5, The Gateway |
AddressLineTwo | string | ImporterAddress | O | The address line two. | Old Hall Road |
City | string | ImporterAddress | M | The city. | Bromborough |
County | string | ImporterAddress | C |
The county. While optional in most cases, when the addess is for the United States or Canada, the two letter state code must be provided here. |
Merseyside |
Postcode | string | ImporterAddress | C |
The postcode. This is mandatory for all countries that have a postal or zip code. It is marked as conditional here because some countries such as Ireland (at the time of writing this documentation) do not use postcodes and as such no postcode would be required for an address in that country. |
CH62 3NX |
Country | Container | ImporterAddress | M |
The postcode. The container for defining the address country. Note this is the same container format when specifying a country anywhere in this request. |
|
CountryID | integer | Country | C |
The country id as defined within the Transglobal Express system. Note: This value can be omitted if providing a value for CountryCode. If both CountryID and CountryCode are provided, the CountryCode value will be ignored and the country will be selected based on the CountryID value. Country id values can be discovered via the countries section of the Transglobal Express API (/Country/V2/GetCountries). |
232 |
CountryCode | string | Country | C |
The ISO code for the country. Note: This value can be omitted if providing a value for CountryID. If both CountryID and CountryCode are provided, the CountryCode value will be ignored and the country will be selected based on the CountryID value. Country code values can be discovered via the countries section of the Transglobal Express API (/Country/V2/GetCountries). |
US |
IsAddressResidential | boolean | ImporterAddress | O |
Indicates whether or not the address is residential. true = Residential false = Non Residential |
true |
EORINumber | string | ImporterAddress | C |
The receiver EORI Number. This will take precedence over an EORI number value entered in both the DeliveryAddress section and BookDetails section. |
FRXXXXXXX |
VATNumber | string | ImporterAddress | O |
The receiver VAT Number. This will take precedence over a VAT number value entered in both the DeliveryAddress section and BookDetails section. |
FRXXXXXXX |
BookDetails | |||||
BookDetails | Container | BookShipmentRequest | M | The book details container. | |
ServiceID | integer | BookDetails | M |
The id of the service to book order with. This can be found in the ServiceID property of the service result in the GetQuote response. |
53 |
YourReference | string | BookDetails | O |
The order reference used within your system. Including this will allow us to make the order searchable from your account by the order reference that is used on your system. Some carrier will also display it on their generated label (though this is not guaranteed for all carriers). |
MyRef123 |
EORINumber | string | BookDetails | O |
DEPRECATED: where possible use EORINumber fields as part of the address sections. The sender EORI number in the case of exports, The receiver EORI number in the case of imports. Please note - if the relevant EORI number is populated as part of the address, that value will be used instead of this one. When this happens a warning message stating this will be returned in the response. |
33231 |
VATNumber | string | BookDetails | O |
DEPRECATED: where possible use EORINumber fields as part of the address sections. The sender VAT number in the case of exports, the receiver VAT number in the case of imports. Please note - if the relevant VAT number is populated as part of an address, that value will be used instead of this one. When this happens a warning message stating this will be returned in the response. |
GB112233 |
IOSSNumber | string | BookDetails | O | Your IOSS number. | 012345678910 |
IncludePreferredOriginNoticeOnPackingList | boolean | BookDetails | O | If your goods are being sent into th EU and can be declared as being of preferential origin, setting this property to true will display this declaration on the Transglobal generated customs invoice. | true |
ShippingCharges | decimal | BookDetails | O | The shipping charges to be used on customs invoice. | 45.89 |
Delivery Instructions | string | BookDetails | O | The delivery instructions to be added onto the order. This field is optional because it is a carrier specific field. 64 characters max. | Leave in porch |
Collection | |||||
Collection | Container | BookDetails | O |
The container for collection details. If this section is omitted from the request, a collection WILL NOT be booked as part of the order. |
|
CollectionDate | string | Collection | M |
The collection date. Must be in fromat YYYY-MM-DD |
2020-04-07 |
ReadyFrom | string | Collection | O |
The time from which the consignment will be ready for collection. Must be in fromat HH:MM If ommitted a value of 09:00 will be used when booking with carriers. |
12:30 |
CollectionOptionID | integer | Collection | O |
The id of the collection option you wish to use to collect the consignment. The id can be found in the CollectionOptionID property within the GetQuote response object. |
1 |
BookAccessories | |||||
BookAccessories | Container | BookDetails | O | The container for optional booking extras. | |
BookAccessory | Container | BookAccessories | M | The book accessory item. Note: The element container is used in XML format requests, if using JSON format it is not explicitly named, the "BookAccessories" element (see above) is an array of BookAccessory objects. This is demonstrated in the provided JSON example above this table. | |
Code | string | BookAccessory | M | The identifying code of the book accessory. | SIG |
Insurance | |||||
Insurance | Container | BookDetails | O | The container for insurance details. | |
CoverValue | decimal | Insurance | M | The value for which to cover the goods. | 119.78 |
ExcessValue | decimal | Insurance | M | The insurance excess value. | 20 |
GoodsAreNew | boolean | Insurance | M | Indicates whether or not the goods are in new condition. | true |
GoodsAreFragile | boolean | Insurance | M | Indicates whether or not the goods are fragile. | false |
{ "Status": "SUCCESS", "Notifications": [], "OrderReference": "TP-0445469", "OrderInvoice": { "InvoiceReference": null, "TotalNet": 97.23, "Tax": 0.00, "TotalGross": 97.23, "InvoiceItems": [ { "ItemDescription": "TG Express Worldwide\n 2 x Packages (Total Chargeable Weight: 28.50kg)\nFrom: CH62 3NX, GB\nTo: Test Street, , 10005, US", "AmountNet": 77.57 }, { "ItemDescription": "Collection", "AmountNet": 19.66 } ] }, "Labels": [ { "LabelRole": "Collection", "LabelFormat": "PDF", "LabelSize": "A4", "AirWaybillReference": "68531156511651651", "LabelContent": "JVBERi0xLjUKJeLjz9MKMSAwIG9iago8PC9BbHRlcm5hdGUvRGV2aWNlUkdCL0xlbmd0aCAyNTk1L04gMy9GaWx0ZXIvRmxhdGVEZWNvZGU+PnN0...[BASE 64 LABEL CONTENT]", "DownloadURL": "[URL STRING]", "CarrierName": "DHL", "ServiceName": "TG Express Worldwide" }, { "LabelRole": "Collection", "LabelFormat": "PDF", "LabelSize": "Thermal", "AirWaybillReference": "68531156511651651", "LabelContent": "JVBERi0xLjUKJeLjz9MKMSAwIG9iago8PC9BbHRlcm5hdGUvRGV2aWNlUkdCL0xlbmd0aCAyNTk1L04gMy9GaWx0ZXIvRmxhdGVEZWNvZGU+PnN0c...[BASE 64 LABEL CONTENT]", "DownloadURL": "[URL STRING]", "CarrierName": "DHL", "ServiceName": "TG Express Worldwide" } ], "Documents": [ { "DocumentType": "PackingList", "Format": "PDF", "Content": "JVBERi0xLjUKJeLjz9MKMSAwIG9iago8PC9UeXBlL1hPYmplY3QvQml0c1BlckNvbXBvbmVudCA4L1N1YnR5cGUvSW1hZ2UvV2lkdGggMjAwL0NvbG9yU3B...[BASE 64 DOCUMENT CONTENT]", "DownloadURL": "[URL STRING]" } ], "TrackingURL": "[URL STRING]" }
<BookShipmentResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/TransglobalWebAPI.Responses.V2"> <Status>SUCCESS</Status> <Notifications xmlns:d2p1="http://www.transglobalexpress.co.uk/API/V2" /> <OrderReference>TP-0445470</OrderReference> <OrderInvoice> <InvoiceItems> <OrderInvoiceItem> <AmountNet>77.57</AmountNet> <ItemDescription> TG Express Worldwide 2 x Packages (Total Chargeable Weight: 28.50kg) From: CH62 3NX, GB To: Test Street, , 10005, US </ItemDescription> </OrderInvoiceItem> <OrderInvoiceItem> <AmountNet>19.66</AmountNet> <ItemDescription>Collection</ItemDescription> </OrderInvoiceItem> </InvoiceItems> <InvoiceReference i:nil="true" /> <Tax>0.00</Tax> <TotalGross>97.23</TotalGross> <TotalNet>97.23</TotalNet> </OrderInvoice> <Labels> <Label> <LabelRole>Collection</LabelRole> <LabelFormat>PDF</LabelFormat> <LabelSize>A4</LabelSize> <AirWaybillReference>68531156511651651</AirWaybillReference> <LabelContent>JVBERi0xLjUKJeLjz9MKMSAwIG9iago8PC9BbHRlcm5hdGUvRGV2aWNlUkdCL0xlbmd0aCAyNTk1L04gMy9GaWx0ZXIvRmxhdGVEZWNvZGU+PnN0cmVhbQp4nJ2Wd1RU1xaHz713eqHNMBQpQ+...[BASE 64 LABEL CONTENT]</LabelContent> <DownloadURL>[URL STRING]</DownloadURL> <CarrierName>DHL</CarrierName> <ServiceName>TG Express Worldwide</ServiceName> </Label> <Label> <LabelRole>Collection</LabelRole> <LabelFormat>PDF</LabelFormat> <LabelSize>Thermal</LabelSize> <AirWaybillReference>68531156511651651</AirWaybillReference> <LabelContent>JVBERi0xLjUKJeLjz9MKMSAwIG9iago8PC9BbHRlcm5hdGUvRGV2aWNlUkdCL0xlbmd0aCAyNTk1L04gMy9GaWx0ZXIvRmxhdGVEZWNvZGU+PnN0cmVhbQp4nJ2Wd1RU1xaHz713eqHNMBQpQ...[BASE 64 DOCUMENT CONTENT]</LabelContent> <DownloadURL>[URL STRING]</DownloadURL> <CarrierName>DHL</CarrierName> <ServiceName>TG Express Worldwide</ServiceName> </Label> </Labels> <Documents> <Document> <Content>JVBERi0xLjUKJeLjz9MKMSAwIG9iago8PC9UeXBlL1hPYmplY3QvQml0c1BlckNvbXBvbmVudCA4L1N1YnR5cGUvSW1hZ2UvV2lkdGggMjAwL0NvbG9yU3BhY2UvRGV2aWNlUkdCL0ZpbHRlci9GbG...[BASE 64 LABEL CONTENT]</Content> <DocumentType>PackingList</DocumentType> <DownloadURL>[URL STRING]</DownloadURL> <Format>PDF</Format> </Document> </Documents> <TrackingURL>[URL STRING]</TrackingURL> </BookShipmentResponse>
{ "Status": "FAIL", "Notifications": [ { "Message": "Rate not found for selected service", "Severity": "ERROR" } ], "OrderReference": null, "OrderInvoice": null, "Labels": null, "Documents": null }
<BookShipmentResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/TransglobalWebAPI.Responses.V2"> <Documents i:nil="true" /> <Labels i:nil="true" /> <Notifications> <Notification> <Message>Rate not found for selected service</Message> <Severity>ERROR</Severity> </Notification> </Notifications> <OrderInvoice i:nil="true" /> <OrderReference i:nil="true" /> <Status>FAIL</Status> </BookShipmentResponse>
Property Name | Data Type | Parent | M | Comment | Example |
---|---|---|---|---|---|
BookShipmentResponse | string | M |
The root element of the response. When returning JSON this is not explicitly named but is instead the object container of the response. |
||
Status | string | BookShipmentResponse | M |
The status indicating whe success of the request. Possible values are: SUCCESS, PARTIAL, FAIL, ERROR |
SUCCESS |
Notification | |||||
Notifications | Container | BookShipmentResponse | M |
The container for list of notifications. Can be empty. |
|
Notification | Container | Notifications | M |
The container for notifications information. When using JSON this element is not explicitly named, instead the Notifications property is a list of anonymous objects containing the notification data. |
|
Message | string | Notification | M | The notification message. | Authentication Failed |
Severity | string | Notification | M | The notification severity level. | ERROR |
OrderReference | string | BookShipmentResponse | M | The notification severity level. | TP-0123456 |
OrderInvoice | |||||
OrderInvoice | Container | BookShipmentResponse | M | The invoice container. | |
InvoiceReference | string | OrderInvoice | O |
The invoice reference. The is only expected to return if booking on a "Card" account. In the case of credit accounts the invoice items will be appended to the currently open invoice that will be sent out on the monthly billing cycle and as such will not have an individual invoice reference at the time of booking. |
INV-0123456 |
TotalNet | decimal | OrderInvoice | M | The total net value. | 97.23 |
Tax | decimal | OrderInvoice | M | The total tax value. | 12.3 |
TotalGross | decimal | OrderInvoice | M | The total gross value. | 109.53 |
InvoiceItems | Container | OrderInvoice | M | The container for the individual invoice items. | |
OrderInvoiceItem | Container | InvoiceItems | M |
The container for the invoice items. When using JSON this element is not explicitly named, instead the InvoiceItems property is a list of anonymous objects containing the invoice item data. |
|
ItemDescription | decimal | OrderInvoiceItem | M | The item description. | Remote Charge |
AmountNet | decimal | OrderInvoiceItem | M | The net value for the item. | 77.57 |
Labels | |||||
Labels | Container | BookShipmentResponse | M |
The container for list of notifications. Can be empty. |
|
Label | Container | Labels | M |
The container for label information. When using JSON this element is not explicitly named, instead the Labels property is a list of anonymous objects containing the label data. |
|
LabelRole | string | Label | M |
The role the label plays within the shipment. Primary - The label that will direct your shipment to it's final destination. For non "warehouse" services this will be the only label required from collection to delivery. Collection - Used in the case of "warehouse" services. This label that will will take your shipment from the collection point to our warehouse depot. If a primary label was not supplied in the response, you need only affix the collection label, the primary label will be printed and attached upon receiving your shipment at our warehouse depot. |
Primary |
LabelFormat | string | Label | M |
The label format. Currently labels are returned exclusively in PDF format across all services, so this property mostly server the purpose of "future proofing". |
|
LabelSize | string | Label | M |
The label size. A4 - label is designed to print out on A4 sized paper. This is the default label as generated by the carrier. Thermal - label has been transformed for intention of printing on a thermal label printer. While available for most services, there are some carriers where a thermal label cannot be offered (eg Fedex) so this version of the label should not be relied on. |
A4 |
AirWaybillReference | string | Label | M | The label air waybill reference returned by the carrier. | 68531156511651651 |
LabelContent | string | Label | M | The label content in Base64 encoding. | [LARGE BASE64 STRING] |
DownloadURL | string | Label | M |
The url for downloading the label If a change has been made and the job rebooked (for example the client has called customer services to amend an address) this will return the most recent label for the label role. |
[URL STRING] |
CarrierName | string | Label | M | The carrier name | DHL |
ServiceName | string | Label | M | The service name | TG Express Worldwide |
Documents | |||||
Documents | Container | BookShipmentResponse | M |
The container for list of notifications. Can be empty. |
|
Document | Container | Documents | M |
The container for document information. When using JSON this element is not explicitly named, instead the Documents property is a list of anonymous objects containing the document data. |
|
DocumentType | string | Document | M | The type of the document (this pertains to the role it plays within the shipment process as opposed to the format type which is defined separately). | PackingList |
Format | string | Document | M |
The document format. Currently documents we will return (such as packing list) are returned exclusively in PDF format across all services, so this property mostly server the purpose of "future proofing". |
|
Content | string | Document | M | The document content in Base64 encoding. | |
DownloadURL | string | Document | M |
The url for downloading the document If a change has been made to the document (for example the client has called customer services and amendment has been made to the packing list) this will return the most recent version of the document. |
[URL STRING] |
TrackingURL | string | BookShipmentResponse | M |
The tracking url. PLEASE NOTE: This tracking url links to the Transglobal Express tracking page. No tracking information can be returned as the carriers do not provide simulated tracking data. The staging site is ip restricted currently, so in order to view the staging tracking link you will need to send any ip addresses that need "whitelisting" to itsupport@transglobalexpress.co.uk |
|
FailReference | string | BookShipmentResponse | O |
If an order fails via the API then no action corrective action will be taken on it by
the Transglobal Express customer services team, as the client system will think it has
failed and have no way of knowing when it is fixed. If an order fails at a point after a reference has been created in our system it will be returned with the failed response. Should the client wish to seek assistance from customer services or IT support this reference can be used to identify the failed order and more quickly resolve the problem. |