# Get Parcel Types

The operation fetches Parcel Types based on the provided carrier, origin county, and the destination country. If query parameters are not provided, this will default to `USPS` as carrier, `US` as both origin and destination country code.

Endpoint: GET /api/v1/parcelTypes
Version: 1.0.0
Security: bearerAuth

## Query parameters:

  - `carrier` (string)
    The CarrierID, a unique identifier given to an individual carrier. It can be referred from the response of Get Carriers API

  - `originCountryCode` (string)
    The Source Country. The two-character ISO country code for the country where the Shipment originates.

  - `destinationCountryCode` (string)
    The Destination Country for the Shipment. The two-character ISO country code for the country where the shipment is to be delivered.

## Header parameters:

  - `X-PB-Developer-Partner-Id` (string)
    This is the Developer Partner ID. When the developer is the only partner, this field is not required.

## Response 200 fields (application/json):

  - `parcels` (array)

  - `parcels.brandedName` (string)
    The branded name of parcel type
    Example: Box 1092

  - `parcels.carrier` (string)
    A unique identifier associated with the specific carrier.
    Example: USPS

  - `parcels.dimensionRules` (array)
    Defines the maximum and minimum dimension supported for given parcel type.
    Example: [{"maxLengthPlusGirth":58,"maxParcelDimensions":{"length":18,"width":2,"height":18,"unitOfMeasurement":"IN"},"minLengthPlusGirth":0.001,"minParcelDimensions":{"length":0.001,"width":0.001,"height":0.0…

  - `parcels.dimensionRules.maxLengthPlusGirth` (number)
    This measures the parcel's maximum length and determine parcel’s girth.
    Example: 58

  - `parcels.dimensionRules.maxParcelDimensions` (object)

  - `parcels.dimensionRules.maxParcelDimensions.length` (number)
    Length is a part of Dimension object having highest numeric value out of three required parameters (length, width, and height) of Dimension. It helps determine a parcel’s girth.
    Example: 18

  - `parcels.dimensionRules.maxParcelDimensions.width` (number)
    Width is a part of Dimension object having lowest numeric value out of three required parameters of dimension (length, width, and height). This helps determine a parcel’s girth.
    Example: 2

  - `parcels.dimensionRules.maxParcelDimensions.height` (number)
    Height is a part of Dimension object where it helps determine a parcel’s girth.
    Example: 18

  - `parcels.dimensionRules.maxParcelDimensions.unitOfMeasurement` (string)
    UnitofMeasurement is a standard for measuring the physical quantities of specified dimension parameters.
    Example: IN

  - `parcels.dimensionRules.minLengthPlusGirth` (number)
    This measures the parcel's minimum length and determine parcel’s girth.
    Example: 0.001

  - `parcels.dimensionRules.minParcelDimensions` (object)

  - `parcels.dimensionRules.minParcelDimensions.length` (number)
    Length is a part of Dimension object having highest numeric value out of three required parameters (length, width, and height) of Dimension. It helps determine a parcel’s girth.
    Example: 0.001

  - `parcels.dimensionRules.minParcelDimensions.width` (number)
    Width is a part of Dimension object having lowest numeric value out of three required parameters of dimension (length, width, and height). This helps determine a parcel’s girth.
    Example: 0.001

  - `parcels.dimensionRules.minParcelDimensions.height` (number)
    Height is a part of Dimension object where it helps determine a parcel’s girth.
    Example: 0.001

  - `parcels.dimensionRules.minParcelDimensions.unitOfMeasurement` (string)
    DimUnit is a standard for measuring the physical quantities of specified dimension parameters.
    Example: IN

  - `parcels.dimensionRules.required` (boolean)
    Example: true

  - `parcels.dimensionRules.unitOfMeasurement` (string)
    UnitofMesurement is a standard for measuring the physical quantities of specified dimension parameters.
    Example: IN

  - `parcels.groupName` (string)
    Example: Specialty Boxes and Envelopes

  - `parcels.brandedDimensions` (object)
    This will be available for parcels with Parcel Type as branded.

  - `parcels.brandedDimensions.girth` (number)
    This is the measure around parcel by area or circumference.
    Example: 0

  - `parcels.brandedDimensions.length` (number)
    Length is a part of Dimension object having highest numeric value out of three required parameters (length, width, and height) of Dimension. It helps determine a parcel’s girth.
    Example: 12.25

  - `parcels.brandedDimensions.width` (number)
    Width is a part of Dimension object having lowest numeric value out of three required parameters of dimension (length, width, and height). This helps determine a parcel’s girth.
    Example: 2.875

  - `parcels.brandedDimensions.height` (number)
    Height is a part of Dimension object where it helps determine a parcel’s girth.
    Example: 13.6875

  - `parcels.brandedDimensions.unitOfMeasurement` (string)
    UnitofMesurements is a standard for measuring the physical quantities of specified dimension parameters.
    Example: IN

  - `parcels.parcelId` (string)
    A unique identifier associated with the Parcel.
    Example: B1092

  - `parcels.isBranded` (boolean)
    If the Parcel is Branded. If yes, it will take `true`, else will take `false`.
    Example: true

  - `parcels.parcelType` (string)
    Defines the type of Parcel.
    Example: LP

  - `parcels.serviceId` (string)
    A unique identifier associated with the carrier-based service.
    Example: PM

  - `parcels.serviceName` (string)
    Name of the Carrier Service.
    Example: Priority Mail®

  - `parcels.suggestedTrackableSpecialserviceId` (string)
    Defines the parcel has feature to track special serviceID.
    Example: DelCon

  - `parcels.weightRules` (array)
    Defines the maximum and minimum weight supported for given parcel type.
    Example: [{"maxWeight":1120,"minWeight":0.01,"required":true,"unitOfMeasurement":"OZ"}]

  - `parcels.weightRules.maxWeight` (number)
    Defines maximum weight, which can be considered.
    Example: 1120

  - `parcels.weightRules.minWeight` (number)
    Defines minimum weight, which can be considered.
    Example: 0.01

  - `parcels.weightRules.required` (boolean)
    Example: true

  - `parcels.weightRules.unitOfMeasurement` (string)
    UnitOfMeasurement is a standard for measuring the physical quantities of specified dimension parameters.
    Example: OZ

## Response 400 fields (application/json):

  - `errorCode` (string)
    Error code(s) that appear due to HTTP  400- Invalid or Bad Request, e.g., validation-error.
    Example: validation_error

  - `errorDescription` (string)
    The HTTP 400 Bad Request response status code indicates that the server cannot process the request due to something that is perceived to be a client error (e.g., malformed request syntax, invalid request message framing, or deceptive request routing).
    Example: string

  - `additionalCode` (string)
    A unique identifier for the error, for example 1101055, 0100008, or 1021126.

  - `additionalInfo` (string)
    This is an additional information about the error. This error 'Invalid Request' might appear due to invalid dimension, weight, or serviceID, or if the information is missing.

  - `additionalParameters` (array)

## Response 401 fields (application/json):

  - `message` (string, required)
    This is HTTP 401 Unauthorized response status code, which indicates that the client request has not been completed because it lacks valid authentication credentials for the requested resource.

## Response 500 fields (application/json):

  - `message` (string, required)
    This is HTTP 500 Internal Server Error response status code, which indicates that the server encountered an unexpected condition that prevented it from fulfilling the request.

