Pacejet

API Samples: POST Shipments to send a shipment to Pacejet

POST Shipments to send a shipment to Pacejet

  1. From the main menu, click Tools, API, and then click Samples.

  2. On the left-hand side, click the Shipments endpoint, click POST.

  3. From the --ADDITIONAL SAMPLES-- drop-down list, choose sample 21, and enter a value such as "PackList030901" for both a "TransactionID” and "ExternalTransactionID" that you add to the sample.

  4. Click Run It.
    A response with a returned URL and response header information will be displayed in the response = box.
    The request sent to Shipments for this example includes minimal data fields for a shipment such as the location, TransactionID, ExternalTransactionID, origin facility, and destination address. Notice that this example referenced a facility ID for the origin address rather than providing the optional address details (see the Using Facilities… section for more on this best practice).

{
  "Location": "DemoAPI",
  "TransactionID": "PackList030901",
  "ExternalTransactionID": "PackList030901",
  "Origin": {
    "LocationType": "Facility",
    "LocationSite": "MAIN",
    "LocationCode": "1",
  },
  "Destination": {
    "CompanyName": "Buysalot, Inc",
    "Address1": "3185 Main Ave",
    "City": "Fargo",
    "StateOrProvinceCode": "ND",
    "PostalCode": "58103",
    "CountryCode": "US",
    "ContactName": "Bob Buyers",
   "Email": "bob.buyers@buysalot.com",
    "Phone": "877-722-3538"
  }
}


The response returned by Shipments includes a URL for integrated applications to pop-up the Pacejet Rate and Ship screen for interactive quoting or shipping. Also, note that a standard HTTP Response Code of “200 OK” is returned when a request is successfully processed.


{
  "result":
"http://appn.pacejet.cc/DemoAPI/Content/Transactions/RateShip.aspx?RateQuoteName=~PackLi st030901"
}


For this example, the next step is for the calling application to forward the user (i.e., pop-up) to the Pacejet Rate & Ship screen using the returned URL. Perform these steps manually:

  1. Login to Pacejet.

  2. Enter a few containers with weights, and click the Rate Shipment icon to rate-shop and select a carrier.

  3. Click the Ship icon to process the sample shipment with a carrier.
    After your shipment processing is complete, the Ship Confirmation page will be displayed. The shipment is considered Complete but has not yet been marked as updated in your ERP.