Sanjoy Roy

[MCM, MCP, SCJP] – Senior PHP Programmer

TNT API Documentation




From Direct Link:

Demo Link:

1. System Overview
The External RTT application provides an interface for TNT customers to retrieve a list of TNT’s available operational services, their cutoff times, estimated delivery dates and prices. This service has been designed for integration into the software or websites of TNT customers. The system overview is presented in figure1, the client application will make an HTTP POST request over SSL and an XML document will be returned.
1.1. Authentication

In order to use the External RTT service users will need to authenticate successfully to the system. This will require users to have a valid account with TNT which has been registered for use with the system. During the registration process users will be assigned a username and password which will be used for authentication. In addition to the username and password authentication the account number passed in the xml request body will be validated.

1.2. Request Format 

The External RTT service will take an application/x-www-form-urlencoded HTTP POST request in the following format. Where the username and password are those provided by TNT during the registration process and the XML Request is an XML string which conforms to the schema listed in section 2 of this document. The xml string should be URL encoded. The request content type should be application/x-www-form-urlencoded NOT text/xml.

Post Data:

1.3. Response Format

The response will be an XML document conforming to the schema listed in section 3 of this document. The http headers for the response will set the MIME type to “text/xml”. Any errors encountered by the system will be returned in an XML format for consumption by the client application.
Examples of the request and response format are show in section 6 of this document.
1.4. Security
In order maintain the security of your username and password you should not perform request to RTT service from client side scripts (AJAX). Doing so will expose your username and password on the internet. Requests to the service should be performed from server side code using SSL.
The client side requests to the service can also cause cross domain security exceptions in modern browsers depending on how your scripts are coded.
It is suggested that a ‘proxy’ page could be created on your web server (under the same domain) for client side scripts. This page could pass the requests to the RTT service and return the unaltered result back to the client page. This will avoid any cross domain security exceptions and will ensure the security of your username and password which would only be sent from the server side script.


5 responses to “TNT API Documentation

  1. Fischöl Kapseln 22/06/2013 at 9:57 PM

    I’m gone to tell my little brother, that he should also visit this blog on regular basis to take updated from hottest news update.

  2. iram 10/05/2014 at 2:58 PM

    hi, i want to integrate TNT shipping API in simple PHP can you help me… from documentation i am confused at some points..

  3. Vishaal 10/09/2015 at 4:16 PM

    Thank you for this information…

  4. Shahul Hameed 19/12/2016 at 12:21 AM

    Hi i am not able to create a shipment by TNT Express Connection , it has showing error like Below

    unable to determine pick up depot from sender address

    unable to determine pick up depot from collection address

    Kindly send the reply

  5. Shahul Hameed 20/12/2016 at 12:03 AM

    When I going to create a shipment by Ship Single Consignment function but it has given error please send reply will helpful for our work.

    Element content is incomplete according to the DTD/Schema. Expecting: COLLECTION.

    <![CDATA[ ]]>

    Thank you .,

    Best Regards .,

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: