Shipping REST API Postman collection

The Metapack Shipping REST API Postman collection is a packaged and downloadable bundle of REST API requests that can be run in Postman.

The collection enables you to quickly access a logical sequence of pre-written API calls that take you from creating a consignment through to manifesting.

Postman

Postman is a free cross-platform API client app that allows you to experiment easily with API requests using a friendly interface.

You can download Postman here for Mac, Windows or Linux. It is also recommended that you set up a free Postman account to enable easy sharing.

Notice

The Postman extension for Google Chrome is deprecated and should not be used as an alternative to the Postman app.

Downloading the collection

You can download the collection by clicking the Run in Postman button below.

Tip

To learn about the basics of sending API requests in Postman, go to Sending your first request.

Using the collection

If you want to use the Postman collection, you will need to use an API key to make any API requests.

You have two API key options for using the collection.

API key option

Description

Benefit

Use provided API key

The Postman collection is provided with an environment that includes an API key.

The environment includes includes all of the configuration and static data for a fictitious shipper.

You can will not have to modify any of the requests in the collection.

Use your own API key

You can elect to get your own API key.

By not using the environment provided with the collection, you will have to modify some of the parameters in many of the requests included in the collection.

You can try out the collection using your own Metapack Shipper Platform setup.

Using your own API key

You have two options for entering your API key in the collection.

API key entry option

Description

Enter your API key manually

Complete the following steps:

  1. In the Type list on the Authorization tab of the collection, select Basic Auth.

    This is necessary because the Shipping REST API uses basic access authentication method, so you must provide an Authorization request header with the Basic prefix followed by a Base64-encoded <username>:<password> string.

  2. In the Username field, enter your username.

  3. In the Password field, enter your password.

Use the Variables tab of the collection

Enter your API key as variables.

Postman recommends using this approach for managing sensitive data if you are working in a collaborative environment.

API requests used in the collection

The collection includes the following API requests:

  • Create a consignment

  • Create a consignment and use shipping rules to allocate it

  • Validate a consignment and its shipping rules

  • Update the manifest group code of an unallocated consignment

  • Update an unallocated consignment

  • Get a consignment

  • Search for consignments by order reference

  • Search for consignments by consignment tracking identifier

  • Search for consignments by parcel tracking identifier

  • Search for consignments by parcel code

  • Get the paperwork of a consignment

  • Get labels of a consignment in PNG format

  • Delete a consignment

  • Add a parcel to a consignment

  • Get the paperwork of a parcel

  • Remove a parcel from a consignment

  • Create a consignment with paperwork and allocate it

  • Allocate an unallocated consignment to a subscribed carrier service

  • Indicate the shipping readiness of a consignment

  • Delete the allocation of a consignment

  • Create a manifest for future despatch

  • Get the paperwork of a manifest

  • Create a set of shipping rates for a consignment

  • Get a list of carriers associated with your shipper account

  • Get a list of carrier services associated with your shipper account

  • Get a list of warehouses associated with your shipper account

Running a request within the collection

You use the Postman Collection Runner to send your API requests and view the responses.