v1

latestOpenAPI 3.1.02026-07-2277219695.0 KB
User Parcel Templates

Create a new user parcel template

Creates a new user parcel template.

You can choose to create a parcel template using a preset carrier template as a starting point, or you can create an entirely custom one. To use a preset carrier template, pass in a unique template token from this list plus the weight fields (weight and weight_unit). Otherwise, omit the template field and pass the other fields, for the weight, length, height, and depth, as well as their units."

post/user-parcel-templates

Headers

SHIPPO-API-VERSIONstring
Example:2018-02-08

Optional string used to pick a non-default API version to use. See our API version guide.

Request body

OR

Example request

{
  "weight": "12",
  "weight_unit": "lb"
}

Response

User parcel template

distance_unit'cm' | 'in' | 'ft' | 'm' | 'mm' | 'yd'

The measure unit used for length, width and height.

heightstring

The height of the package, in units specified by the distance_unit attribute. Required, but if using a preset carrier template then this field must be empty.

lengthstring

The length of the package, in units specified by the distance_unit attribute. Required, but if using a preset carrier template then this field must be empty.

namestring

The name of the User Parcel Template

weightstring

The weight of the package, in units specified by the weight_unit attribute.

weight_unit'g' | 'kg' | 'lb' | 'oz'

The unit used for weight.

widthstring

The width of the package, in units specified by the distance_unit attribute. Required, but if using a preset carrier template then this field must be empty.

object_createdstring date-time

Date and time of User Parcel Template creation

object_idstring

Unique identifier of the given User Parcel Template object

object_ownerstring

Username of the user who created the User Parcel Template object

object_updatedstring date-time

Date and time of last update on User Parcel Template

Example response

{
  "distance_unit": "in",
  "height": "6",
  "length": "10",
  "name": "My Custom Template",
  "weight": "12",
  "weight_unit": "lb",
  "width": "8",
  "object_created": "2013-12-11T19:38:09.729Z",
  "object_id": "b958d3690bb04bb8b2986724872750f5",
  "object_owner": "shippotle@shippo.com",
  "object_updated": "2013-12-12T19:38:09.729Z",
  "template": {
    "carrier": "FedEx",
    "distance_unit": "in",
    "height": "1.5",
    "length": "12.375",
    "name": "FedEx® Small Box (S1)",
    "token": "FedEx_Box_Small_1",
    "width": "10.875"
  }
}