
Your business is fast-paced and requires instant access to information via the web in order to flow seamlessly and ensure customer satisfaction. The solution: Averitt Web Services.
Averitt Web Services can provide XML feeds via WSDL directly to your website or any of your internal systems. Feeds available via Averitt Web Services at this time include:
-
Real-time rate quotes specific to your account
- Real-time shipment status by PRO
- Transit Times throughout the U.S. and Canada
- Retrieval of shipment-related images and documents
 |
Technical schema details on using Averitt Web Services are listed below. |
Need help? Contact our Customer Technology Support team at 877-281-7131 or by email.
Technical Schemas for Unsecured Web Services
TransitTimeServiceLocator locator = new
TransitTimeServiceLocator();
TransitTime transitPort = locator.getTransitTimePort();
GetTransitTimeResponseReturn transitTimeResponse =
transitPort.getTransitTime(request);//Populate the Request Object and
pass
LTLPublicTrackingServiceLocator loc = new
LTLPublicTrackingServiceLocator();
LTLPublicTracking service = loc.getLTLPublicTrackingPort();
GetTrackingStatusResponseReturn resp =
service.getTrackingStatus(req);//Populate the Request Object and pass
Technical Schemas for Secured Web Services
The web services listed below this point are secured and require authentication. Security is provided via Secure Sockets Layer (SSL), so businesses and consumers can rest assured that their credentials will remain secure.
With our secured web services, the username and password are sent in the SOAP header of a request SOAP message.
Following is a sample SOAP header. The "xmlns:sen" portion of the header (underlined below) will vary with the service invoked. The body of the request may vary also depending on the request.
If your client invokes SSL services, you may receive the message "unable to find valid certification path to requested target." If so, please refer to this solution.
Sample SOAP header:
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:sen="https://webservices.averittexpress.com/SendWebImageService">
<soapenv:Header xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<ns:authnHeader soapenv:mustUnderstand="0"
xmlns:ns="http://webservices.averittexpress.com/authn">
<Username>xxxxxxxx</Username>
<Password>xxxxxxxx</Password>
</ns:authnHeader>
</soapenv:Header>
LTLPrivateTrackingServiceLocator loc = new LTLPrivateTrackingServiceLocator();
LTLPrivateTracking service = loc.getLTLPrivateTrackingPort();
GetPrivateTrackingStatusResponseReturn resp = service.getPrivateTrackingStatus(req);//Populate the Request Object and pass
- LTL Rate Quote web service
LTLRateQuoteService_ServiceLocator loc = new LTLRateQuoteService_ServiceLocator();
LTLRateQuoteService_PortType port = loc.getLTLRateQuoteServicePort();
GetLTLRateResponseReturn resp = port.getLTLRate(req);//Populate the Request Object and pass
- Send WebImage web service
- Location:
https://webservices.averittexpress.com/SendWebImageService
- View: WSDL
| schema
-
Authentication required? Yes. Please see instructions above for including SOAP header.
- Web service options:
- getAvailableImages:
This option requires one parameter - "pro number" - and returns "document type"
- getDocument:
This option requires two parameters, "pro number" and "document type" and will
return a byte array that can be converted into a jpg, jpeg, pdf, bmp, or any available image format.
- To call this web service, see the sample Java code below:
getAvailableImages:
SendWebImageService serv = new SendWebImageService();
SendWebImage sendImg = serv.getSendWebImagePort();
String resp = sendImg.getAvailableImages("xxxxxxxxxx");//send pro number
getDocument:
SendWebImageService serv = new SendWebImageService();
SendWebImage sendImg = serv.getSendWebImagePort();
byte[] resp = sendImg.getDocument("xxxxxxxxxx","xxx");//send pro number and document type
Technical Schemas for .net
Sample .net schema:
HttpWebRequest request = CreateWebRequest();
XmlDocument soapEnvelopeXml = new XmlDocument();
soapEnvelopeXml.LoadXml(CreateXMLRequestGetDocument(ProNumber.ToString
().PadLeft(10, '0'), imageType));
HttpWebResponse response = (HttpWebResponse)request.GetResponse()
private static HttpWebRequest CreateWebRequest()
{
HttpWebRequest webRequest = (HttpWebRequest)WebRequest.Create(
@"https://webservices.averittexpress.com/SendWebImageService");
webRequest.Headers.Add(@"SOAP:Action");
webRequest.ContentType = "text/xml;charset=\"utf-8\"";
webRequest.Accept = "text/xml";
webRequest.Proxy = null;
webRequest.Method = "POST";
return webRequest;
}
private string CreateXMLRequestGetAvailableImages(string ProNumber)
{
string XMLRequest = string.Empty;
XMLRequest = @"
<soapenv:Envelope
xmlns:soapenv=""http://schemas.xmlsoap.org/soap/envelope/""
xmlns:sen=""https://webservices.averittexpress.com/SendWebImageService"">
<soapenv:Header
xmlns:soapenc=""http://schemas.xmlsoap.org/soap/encoding/""
xmlns:xsd=""http://www.w3.org/2001/XMLSchema""
xmlns:xsi=""http://www.w3.org/2001/XMLSchema-instance"">
<ns:authnHeader soapenv:mustUnderstand=""0""
xmlns:ns=""http://webservices.averittexpress.com/authn"">
<Username></Username>
<Password></Password>
</ns:authnHeader>
</soapenv:Header>
<soapenv:Body>
<sen:getAvailableImages>
<!--Optional:-->
<arg0>" + ProNumber + @"</arg0>
</sen:getAvailableImages>
</soapenv:Body>
<soapenv:Body>
<sen:getAvailableImages>
<!--Optional:-->
<arg0>" + ProNumber + @"</arg0>
</sen:getAvailableImages>
</soapenv:Body>
<soapenv:Body>
<sen:getAvailableImages>
<!--Optional:-->
<arg0>" + ProNumber + @"</arg0>
</sen:getAvailableImages>
</soapenv:Body>
</soapenv:Envelope>";
return XMLRequest;
}
Unsecured PHP call for Transit Times:
<?php
class AVTTransitTimeRequest {
public $OriginCity; // string
public $OriginState; // string
public $OriginZip; // string
public $DestinationCity; // string
public $DestinationState; // string
public $DestinationZip; // string
}
class AVTTransitTimeResponse {
public $OrigCity; // string
public $OrigState; // string
public $OrigZip; // string
public $origServiceCenter; // string
public $DestCity; // string
public $DestState; // string
public $DestZip; // string
public $destServiceCenter; // string
public $EstimatedDays; // string
public $Comment; // string
public $Error; // string
}
class getTransitTime {
public $arg0; // arg0
}
class arg0 {
public $OriginCity; // string
public $OriginState; // string
public $OriginZip; // string
public $DestinationCity; // string
public $DestinationState; // string
public $DestinationZip; // string
}
class getTransitTimeResponse {
public $response; // return
}
class response {
public $OrigCity; // string
public $OrigState; // string
public $OrigZip; // string
public $origServiceCenter; // string
public $DestCity; // string
public $DestState; // string
public $DestZip; // string
public $destServiceCenter; // string
public $EstimatedDays; // string
public $Comment; // string
public $Error; // string
}
/**
* TransitTimeService class
*
*
*
* @author {author}
* @copyright {copyright}
* @package {package}
*/
class TransitTimeService extends SoapClient {
private static $classmap = array(
'AVTTransitTimeRequest' => 'AVTTransitTimeRequest',
'AVTTransitTimeResponse' => 'AVTTransitTimeResponse',
'getTransitTime' => 'getTransitTime',
'arg0' => 'arg0',
'getTransitTimeResponse' => 'getTransitTimeResponse',
'response' => 'response',
);
public function TransitTimeService($wsdl = "TransitTimeService.wsdl", $options = array()) {
foreach(self::$classmap as $key => $value) {
if(!isset($options['classmap'][$key])) {
$options['classmap'][$key] = $value;
}
}
parent::__construct($wsdl, $options);
}
/**
*
*
* @param getTransitTime $parameters
* @return getTransitTimeResponse
*/
public function getTransitTime(getTransitTime $parameters) {
return $this->__soapCall('getTransitTime', array($parameters), array(
'uri' => 'http://webservices.averittexpress.com/TransitTimeService',
'soapaction' => ''
)
);
}
}
?>
Need help?
If you need assistance with our web services, contact our Customer Technology Support team at
877-281-7131 or by email.