Integration»Basic Shipping

Basic Shipping

Basic Shipping: Create a Domestic Shipment Script

Follow these steps to create a basic shipping script in your system to set values in the NRGship file for a domestic shipment. Note that not all values below are required, you should script based on your own needs.

NOTE: In order to submit a test request and generate a test label , set the value of Test.t to "YES"

Create a new script and call it "Set Ship Data and Create Label". Using the Set Field script step, you will need to set a value in the following fields of the Ship_ELS table:

Set recipient information

ToCompany.t
ToName.t
ToAddress1.t
ToAddress2.t
ToAddress3.t
ToCity.t
ToState.t
ToPostalCode.t
ToCountry.t
ToPhone.t
ToEmail.t

Set service information

MailClass.t

Set packaging information

MailpieceShape.t

Set reference ID for Endicia logs

ReferenceID.t

Set reference fields which will print on the label (Express Mail, international, and integrated labels will not include Rubber Stamp fields)

RubberStamp1.t
RubberStamp2.t
RubberStamp3.t

Set package information

Weight.n
InsuredValue.n
Width.n
Length.n
Height.n

[commit record]

Create Label

Perform External Script "External - Ship via USPS thru Endicia Label Server for Ship_ID" in NRGShip Toolkit for Endicia Label Server file

Once the Ship_ELS record is created, you can pass the _pk_ShipID.n value to scripts in theNRGShip Toolkit for Endicia Label Server file to ship the record. If Ship & Print is checked in Defaults, the label will be automatically printed.