Publisher Specific Product Selector API - Documentation
This API allows you to compare the cost of sending magazine and sample combinations. If a publisher is logged in to Ratefinder, then the prices returned are valid only for that specified publisher; otherwise standard rates are returned.
Test out the API here
Request
Send an HTTP GET to http://api.uat.nzpost.co.nz/ratefinder/bulk_mail_for_publisher with all of the parameters listed below.
Parameter Name | Description | Required | Example |
---|---|---|---|
api_key |
Your license key for the application. Please contact developer@nzpost.co.nz for a license key | yes | 1234-5678-90ab-cdfe |
includes_sample |
Does the lodgement include a sample? | Yes | 0 |
num_items |
How many items do you want to send (per lodgement)? | Yes | 1000 |
height |
Total height (mm) | Yes | 80 |
length |
Total length (mm) | Yes | 120 |
thickness |
Total thickness (mm) | Yes | 5 |
weight |
Total weight (g) | Yes | 250 |
time_of_day |
What time of the day do you wish to lodge? 'S' for 'By 12 noon Monday to Friday', 'A' for 'By 5pm Monday to Friday' or 'E' for 'After 5pm or on a weekend' | Yes | S |
postcode_sorted |
Is the lodgement sorted in ascending postcode order? 1 for yes or 0 for no | Yes | 1 |
delivery_sorted |
Is the lodgement sorted in delivery sequence order? 1 for yes or 0 for no | No | 1 |
has_soa |
Does the lodgement have a Statement of Accurary? 1 for yes or 0 for no | Yes | 1 |
format |
The format of the response (it can also be set by the content-type header). Can be 'json', 'html' or 'xml' | Yes | json |
Response
If the format parameter is set to JSON, the response object is a json hash.
Success is determined by the 'success' key-value pair (either true or false). The product code and description is in the product hash.
Example Request
Example Response
{ "success": true, "product": { "code":"VP1MS", "description":"VolumePost 1 Medium Standard", "price_excluding_gst":"0.3395", "price_including_gst":"0.3904" } }