Supplier Integration | DTG2go

Supplier Integration | DTG2go

Settings
Username, Password & API key
The API key needed to connect with the DTG2go API can be obtained from the DTG2go portal https://www.dtg2goportal.com/. A username and password is needed to login to the portal. 

Setup Instructions

1. Shipping method on Order should be one of DTG2go supported shipping methods. If a shipping method is not specified on the order, a 'Standard' shipping method is used. The Standard shipping uses a USPS first class mail. Please see below list of supported shipping methods:


Standard
Rush
UPSMIExpeditedDomestic
UPSMIPriorityInternational
UPSMIEconomyInternational
Express
First
Priority
FirstOrPriority
UPSGround
UPS3Day
UPS2Day
UPS1Day
UPSSurePost
UPSSurePostSnap
FirstClassPackageInternationalService
PriorityMailInternational
ExpressMailInternational
USPSFirstOrPriorityInternational
ParcelsGroundDomestic
ParcelPlusGroundDomestic
ParcelsExpeditedDomestic
ParcelPlusExpeditedDomestic
DHLPacketInternationalStandard
DHLParcelInternationalStandard
DHLPacketPlusInternational
DHLPacketInternationalPriority
DHLParcelInternationalPriority
DHLParcelDirectInternationalPriority
DHLDomestic
DHLDomesticRush
DHLInternational
DHLInternationalRush
DHLSmartMailParcelGround
DHLSmartMailParcelExpedited
DHLSmartMailParcelPlusGround
DHLSmartMailParcelPlusExpedited
Asendia IPA
FedEx2Day
FedEx2DaySaturday
FedExHome
FedExGround
FedExInternationalPriority
FedExStandardOvernight
FedExPriorityOvernight
FedExPriorityOvernightSaturday
FedExExpressSaver
FedExSmartPost
FedExInternationalEconomy
APCParcelConnectPriorityDDU
TShirtCentral
ZazzleLabel
DHLGlobalMailPacketIPA
DHLGlobalMailPacketISAL


2. The item mapped SKU should be one of DTG2go's supported manufacturer product code. Each code maps to a specific colour name and size ranges.
Please see supported codes in the 'Available Charts' section on the DTG2go API tab.

3. Verify the colour and sizes on the item are defined and that they map to one of the colours provided in the selected  (item mapped SKU/Product SKU) code in step 2.

4. Verify the items are print job items.

The products should also define 'Front' and 'Back' print areas.

The front print area should have the name 'Front' and the back print area should have the name 'Back'. This is critical to generating the necessary artwork needed by the API.


DTG2go Portal Settings

1. To submit a work order (OMS orders), the DTG2go API requires a EasyPost API key and UPS account information to be configured.
The API will return errors if both of these are not configured. Please see the 'Edit Profile' tab on the DTG2go portal to configure these settings.


2. The status of orders is retrieved via a webhook. The webhook can also be setup in the Edit Profile tab as thus:
- On the API options column, in the Webhook URL field, enter https://api-client.custom-gateway.net/dtg2go 

- Verify 'Receive Web Hooks' is selected in the Pull or receive webhooks field

- In the 'Webhooks Type' field, select the option 'Shipped' as we are only interested in when the item has been shipped.

- Click Save to save all changes.

Workflow

Below is an example of the structure and content of the work order submitted to DTG2go. Please note each item in an order in OMS is sent as a work order to the DTG2go API.


{ "work_orders" : [ { "product_name" : "<PRODUCT NAME FOR ITEM 1>", "merchant_sku" : "<ITEM 1 SKU", "to_name" : "<CUSTOMER NAME ON ORDER>", "to_address" : "<SHIPPING ADDRESS 1 AND SHIPPING ADDRESS 2 ON ORDER>", "to_city" : "<SHIPPING ADDRESS 4 ON ORDER>", "to_state" : "<SHIPPING ADDRESS 5 ON ORDER>",
"to_zip" : "<SHIPPING POSTCODE ON ORDER>",
"to_country" : "<SHIPPING COUNTRY CODE ON ORDER>", "front_image" : { "url" : "<FRONT ARTWORK IMAGE URL. AUTOMATICALLY GENERATED WHEN A 'FRONT' PRINT AREA IS SPECIFIED FOR THE PRINT JOB>" }, "back_image" : { "url" : "<BACK ARTWORK IMAGE URL. AUTOMATICALLY GENERATED WHEN A 'BACK' PRINT AREA IS SPECIFIED FOR THE PRINT JOB>"
}, "designs" : [ { "position" : "Front", "physical_height" : "<PRINT HEIGHT>", "physical_width" : "<PRINT WIDTH>", "media" : { "url":"<FRONT ARTWORK IMAGE URL AS ABOVE>"
} } ], "variations" : [ { "color" : "<ITEM COLOUR - PLEASE SEE SET UP INSTRUCTIONS FOR HOW THIS SHOULD BE SET>", "manufacturer_product" : "<ITEM MAPPED SKU. THIS SHOULD BE A DTG2GO SPECIFIC CODE AS DESCRIBED IN THE 'SET UP INSTRUCTIONS' SECTION OF THIS DOCUMENT>", "quantities" : [ { "size" : "ITEM SIZE", "quantity" : "<ITEM QUANTITY>" }, ] } ], "requested_shipping_method" : "<SHIPPING METHOD - PLEASE SEE SET UP INSTRUCTIONS ABOVE>", "merchant_shipment_id" : "<EXTERNAL REF ON ORDER>" }, {
"product_name" : "<PRODUCT NAME FOR ITEM 2>",
"merchant_sku" : "<ITEM 2 SKU",
"to_name" : "<CUSTOMER NAME ON ORDER>",
"to_address" : "<SHIPPING ADDRESS 1 AND SHIPPING ADDRESS 2 ON ORDER>",
"to_city" : "<SHIPPING ADDRESS 4 ON ORDER>",
"to_state" : "<SHIPPING ADDRESS 5 ON ORDER>",
"to_zip" : "<SHIPPING POSTCODE ON ORDER>",
"to_country" : "<SHIPPING COUNTRY CODE ON ORDER>", "front_image" : { "url" : "<FRONT ARTWORK IMAGE URL. AUTOMATICALLY GENERATED WHEN A 'FRONT' PRINT AREA IS SPECIFIED FOR THE PRINT JOB>" }, "back_image" : { "url" : "<BACK ARTWORK IMAGE URL. AUTOMATICALLY GENERATED WHEN A 'BACK' PRINT AREA IS SPECIFIED FOR THE PRINT JOB>"
}, "designs" : [ { "position" : "Front", "physical_height" : "<PRINT HEIGHT>", "physical_width" : "<PRINT WIDTH>", "media" : { "url":"<FRONT ARTWORK IMAGE URL AS ABOVE>"
} } ], "variations" : [ { "color" : "<ITEM COLOUR - PLEASE SEE SET UP INSTRUCTIONS FOR HOW THIS SHOULD BE SET>", "manufacturer_product" : "<ITEM MAPPED SKU. THIS SHOULD BE A DTG2GO SPECIFIC CODE AS DESCRIBED IN THE 'SET UP INSTRUCTIONS' SECTION OF THIS DOCUMENT>", "quantities" : [ { "size" : "ITEM SIZE", "quantity" : "<ITEM QUANTITY>" }, ] } ], "requested_shipping_method" : "<SHIPPING METHOD - PLEASE SEE SET UP INSTRUCTIONS ABOVE>", "merchant_shipment_id" : "<EXTERNAL REF ON ORDER>
}]}

A successful request (i.e submission to the DTG2go API) returns a list of work order ids. The total number of work order ids returned should match the total number of items submitted in the work order. Each work order id is stored for the specific item in the item attributes in OMS. The item attribute value is the work order id. The status on the order is also changed to 'Received By Supplier'

When the status of the work order changes to 'Shipped', DTG2go sends a request (JSON containing shipment information) to the configured webhook URL. Please see below example of a status message:

{
    "id":<WORK ORDER ID>,
    "current_state":"Shipped",
    "merchant_sku":"<ITEM SKU>",
    "ordered_on_date":"2015-08-16T00:00:00+0200",
    "ship_by_date":"2015-08-21T00:00:00+0200",
    "shipping_carrier":"<SHIPPING CARRIER RETURNED BY DTG2go>",
    "shipping_tracking":"<TRACKING NUMBER RETURNED BY DTG2go>"
}

The shipment information is saved for the item with the specified work order id and item sku. Once all the shipment information for the items in an orders is received, the status of the order in OMS is changed to 'Dispatched'. Also the tracking and shipping carrier information on the order are updated with the information provided in the last DTG2go json for the order.
    • Related Articles

    • Supplier Integration | Goof Buzz

      Introduction This article has been created to show how to setup the supplier integration Kornit X has built to connect to Goof Buzz. Setup To setup the Goof Buzz integration, please head to your company and within the advanced settings head to ...
    • Supplier Integration | Probo Supplier

      Introduction This article has been created to show how to setup the supplier integration Kornit X has built to connect to Probo.  Setup To setup the Probo integration, please head to your company and within the advanced settings head to "Supplier ...
    • Supplier Integration | Dubow

      Introduction This article has been created to show how to setup the supplier integration Kornit X has built to connect to OnPrintShop.  Setup To setup the Dubow integration, please head to your company and within the advanced settings head to ...
    • Supplier Integration | GrandHome

      Introduction This article has been created to show how to setup the supplier integration Kornit X has built to connect to GrandHome.  Setup To setup the GrandHome integration, please head to your company and within the advanced settings head to ...
    • Supplier Integration | Staples

      Introduction This article has been created to show how to setup the supplier integration Kornit X has built to connect to Staples. Setup To setup the Staples integration, please head to your company and within the advanced settings head to "Supplier ...