Create a Newgistics Manifest (Closeout)

HTTP Request

POST /v1/manifests

Summary

This operation closes out the day for Newgistics parcels by electronically notifying Newgistics how many parcels await. Newgistics creates manifest files for all valid labels generated since the previous closeout. The operation does not generate a pickup slip.

You can close out parcels for up to five facilities with one API call. To close out parcels for additional facilities, you must issue the API call again.

To use this operation, a merchant must be onboarded for Newgistics, as described on the Newgistics Overview page.

Things to Consider

  1. When issuing the API call, you must set the following:

    Field Value
    carrier NEWGISTICS
    submissionDate The date the shipments are to be tendered to the carrier.
    parameters

    You must include the following Manifest Parameters:

  2. You can optionally include up to five instances of the CARRIER_FACILITY_ID_<#> parameter to close out pieces corresponding to specific facilities. Each instance specifies a Newgistics Facility ID. If this parameter is not specified, all un-manifested parcels are closed out. For more information, see Manifest Parameters.

  3. Manifest requests for Newgistics do not support filtering by tracking numbers or induction postal code. If you provide these values in the request, they will be ignored.

  4. The manifest response does not contain a pickup slip.

  5. You cannot reprint or retry a Newgistics manifest.

Request URIs

Sandbox: https://api-sandbox.pitneybowes.com/shippingservices/v1/manifests
Production: https://api.pitneybowes.com/shippingservices/v1/manifests

See also Requests from the Asia-Pacific Region.

Requests from the Asia-Pacific Region

If your request originates in the Asia-Pacific region, use the following URIs to optimize the routing and handling of the request:

Sandbox: https://apac-sandbox.shippingapi.pitneybowes.com/shippingservices/v1/manifests
Production: https://apac.shippingapi.pitneybowes.com/shippingservices/v1/manifests

If you use the Asia-Pacific URIs, you must set the carrier query parameter to Newgistics.

Query Parameter

Name Description
carrier Applies only to requests from the Asia-Pacific region. If your request originates in the Asia-Pacific region and if you use the Asia-Pacific URIs, you must set the carrier query parameter to Newgistics.

Request Headers

Name
Description
Authorization Required. OAuth token generated using the Generate an OAuth Token API.
Content-Type Required. The media type of the request entity. Set this to application/json.
X-PB-TransactionId

Required. A unique identifier for the transaction, up to 25 characters.

Important: You must ensure this is a unique id.

X-PB-UnifiedErrorStructure Recommended. Set this to true to use the standard error object if an error occurs.

Request / Response Elements

Important

The API call sends and receives a Manifest Object. The table below describes all possible fields in a Manifest Object. Some elements are not applicable to Newgistics and are marked as such.

Important:   See Things to Consider on this page for the required values when making a request.

Name Data Type Description
carrier String

Required. The carrier to which the manifest applies.

For some operations, this field is not present in the response.

Valid values:

  • USPS
  • NEWGISTICS - Valid only in a Create Manifest request
  • PBPresort - Valid only in a Create Manifest request
submissionDate String

Required. The time and date the shipments are to be tendered to the carrier. The time and date must be in UTC/GMT and in one of the following formats:

  • YYYY-MM-DD
  • YYYY-MM-DD HH:mm:ss
  • YYYY-MM-DD HH:mm:ss.SSS
fromAddress Address Object

Conditional. The shipment origin address.

Required for:

inductionPostalCode String

Conditional. Postal code where the shipments are tendered to the carrier.

This field does not apply to Newgistics manifests.

parcelTrackingNumbers Array[String]

Identifies shipments by their tracking numbers. List one or more shipment tracking numbers, separated by commas.

This field does not apply to Newgistics manifests.

parameters Array[Object]

Conditional. Each object in the array defines a different manifest parameter. This field is used only in the request and is not returned in the response.

Required for Newgistics manifests (closeouts).

        name String The name of the manifest parameter.
        value String The value of the manifest parameter.
manifestId String Response Only. The unique manifest ID.
manifestTrackingNumber String Response Only, USPS Only. The manifest tracking number.
documents Array[Documents Object]

Response Only. The manifest.

This field is not returned for a Newgistics manifest.

Sample Request

curl -X POST .../v1/manifests \
-H "Authorization: Bearer <oauth_token>" \
-H "Content-Type: application/json" \
-H "X-PB-TransactionId: 8e-485d-9313-4b6d1343a054" \
-H "X-PB-UnifiedErrorStructure: true" \
-d '
{
    "carrier": "NEWGISTICS",
    "submissionDate": "2018-03-12",
    "parameters": [ {
        "name": "SHIPPER_ID",
        "value": "9024324564"
    },{
        "name": "CARRIER_FACILITY_ID_1",
        "value": "1585"
    },{
        "name": "CLIENT_ID",
        "value": "NGST"
    } ]
}

Sample Response

{
    "carrier": "NEWGISTICS",
    "submissionDate": "2018-03-12",
    "manifestId": "NEWGISTICS03111552332799302",
    "parameters": [ {
        "name": "SHIPPER_ID",
        "value": "9024324564"
    },{
        "name": "CARRIER_FACILITY_ID_1",
        "value": "1585"
    },{
        "name": "CLIENT_ID",
        "value": "NGST"
    } ]
}

Error Codes

For a list of all PB Shipping APIs error codes, please see Error Codes.