Get Carrier License Agreement

HTTP Request

GET /v1/carrier/license-agreements?carrier={carrier}&originCountryCode={two-character-ISO-code}

Summary

This operation retrieves a carrier’s license agreement. The operation is used in the Carrier Registration Tutorial.

Considerations

The returned license agreement includes escape characters (for example, \n, \t, and \"). You should substitute the escape characters with appropriate control characters or punctuation marks.

Request URIs

Sandbox: https://api-sandbox.pitneybowes.com/shippingservices/v1/carrier/license-agreements?carrier={carrier}&originCountryCode={two-character-ISO-code}
Production: https://api.pitneybowes.com/shippingservices/v1/carrier/license-agreements?carrier={carrier}&originCountryCode={two-character-ISO-code}

Query Parameters

Name Description
carrier

Required. The carrier.

Valid values:

  • UPS
  • FEDEX
originCountryCode

Required. The two-character ISO country code for the origin country.

Valid values: US

Request Header

Name
Description
Authorization Required. OAuth token generated using the Generate an OAuth Token API.

Response Element

Name Description
licenseText The license agreement.

Sample Request

curl -X GET .../v1/carrier/license-agreements?carrier=UPS&originCountryCode=US \
-H "Authorization: Bearer <oauth_token>" \
-H "X-PB-UnifiedErrorStructure: true"

Sample Response

{
    "licenseText": "<text>"
}

Error Codes

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