Overview

Namespaces

  • ShippoClient
    • Entity
    • Http
      • Request
        • Addresses
        • Parcels
        • Shipments
        • Transactions
      • Response
        • Exception

Classes

  • CreateObject
  • Overview
  • Namespace
  • Class

Class CreateObject

Parcel objects are used for creating Shipment, obtaining Rates and printing Labels, and thus are one of the fundamental building blocks of the Shippo API. Parcel are created with their basic dimensions and their weight.

ShippoClient\Http\Request\CommonParameter uses TurmericSpice\ReadWriteAttributes (not available)
Extended by ShippoClient\Http\Request\Parcels\CreateObject uses TurmericSpice\ReadWriteAttributes (not available)
Namespace: ShippoClient\Http\Request\Parcels
Located at Http/Request/Parcels/CreateObject.php
Methods summary
public integer
# getLength( )

First dimension of the Parcel. The length should always be the largest of the three dimensions length, width and height; our API will automatically order them if this is not the case. Up to six digits in front and four digits after the decimal separator are accepted.

First dimension of the Parcel. The length should always be the largest of the three dimensions length, width and height; our API will automatically order them if this is not the case. Up to six digits in front and four digits after the decimal separator are accepted.

Required

Returns

integer

Throws

TurmericSpice\Container\InvalidAttributeException
public integer
# getWidth( )

Second dimension of the Parcel. The width should always be the second largest of the three dimensions length, width and height; our API will automatically order them if this is not the case. Up to six digits in front and four digits after the decimal separator are accepted.

Second dimension of the Parcel. The width should always be the second largest of the three dimensions length, width and height; our API will automatically order them if this is not the case. Up to six digits in front and four digits after the decimal separator are accepted.

Required

Returns

integer

Throws

TurmericSpice\Container\InvalidAttributeException
public integer
# getHeight( )

Third dimension of the parcel. The height should always be the smallest of the three dimensions length, width and height; our API will automatically order them if this is not the case. Up to six digits in front and four digits after the decimal separator are accepted.

Third dimension of the parcel. The height should always be the smallest of the three dimensions length, width and height; our API will automatically order them if this is not the case. Up to six digits in front and four digits after the decimal separator are accepted.

Required

Returns

integer

Throws

TurmericSpice\Container\InvalidAttributeException
public string
# getDistanceUnit( )

The unit used for length, width and height.

The unit used for length, width and height.

Required

Returns

string

Throws

TurmericSpice\Container\InvalidAttributeException
public integer
# getWeight( )

Weight of the parcel. Up to six digits in front and four digits after the decimal separator are accepted.

Weight of the parcel. Up to six digits in front and four digits after the decimal separator are accepted.

Required

Returns

integer

Throws

TurmericSpice\Container\InvalidAttributeException
public string
# getMassUnit( )

The unit used for weight.

The unit used for weight.

Required

Returns

string

Throws

TurmericSpice\Container\InvalidAttributeException
public string
# getTemplate( )

A parcel template is a predefined package used by one or multiple carriers. See the table below for all available values and the corresponding tokens. When a template is given, the parcel dimensions have to be sent, but will not be used for the Rate generation. The dimensions below will instead be used. The parcel weight is not affected by the use of a template.

A parcel template is a predefined package used by one or multiple carriers. See the table below for all available values and the corresponding tokens. When a template is given, the parcel dimensions have to be sent, but will not be used for the Rate generation. The dimensions below will instead be used. The parcel weight is not affected by the use of a template.

Optional

Returns

string
public
# toArray( )
Methods inherited from ShippoClient\Http\Request\CommonParameter
getMetadata()
API documentation generated by ApiGen