Shipment
extends EasyPostObject
in package
Table of Contents
- $batch_id : string
- $batch_message : string
- $batch_status : string
- $buyer_address : Address
- $created_at : string
- $customs_info : CustomsInfo
- $fees : array<string|int, Fee>
- $forms : array<string|int, mixed>
- $from_address : Address
- $id : string
- $insurance : Insurance
- $is_return : bool
- $messages : array<string|int, Message>
- $mode : string
- $object : string
- $options : object
- $parcel : Parcel
- $postage_label : PostageLabel
- $rates : array<string|int, Rate>
- $reference : string
- $refund_status : string
- $return_address : Address
- $scan_form : ScanForm
- $selected_rate : Rate
- $status : string
- $to_address : Address
- $tracker : Tracker
- $tracking_code : string
- $updated_at : string
- $usps_zone : bool
- $_immutableValues : array<string|int, mixed>
- $_values : array<string|int, mixed>
- $_name : string
- $_parent : string
- __construct() : mixed
- Constructor for EasyPost objects.
- __get() : mixed
- Getter.
- __isset() : bool
- `isset` magic method.
- __set() : mixed
- Standard accessor magic methods.
- __toArray() : array<string|int, mixed>
- Convert object to an array.
- __toJSON() : string
- Convert object to JSON.
- __toString() : string
- Convert object to a string.
- __unset() : mixed
- `unset` magic method.
- constructFrom() : mixed
- Construct EasyPost objects from a response.
- convertEach() : mixed
- Convert each piece of an EasyPost object.
- current() : mixed
- Iterator methods.
- key() : mixed
- Iterator methods.
- lowestRate() : Rate
- Get the lowest rate for the shipment.
- next() : mixed
- Iterator methods.
- offsetExists() : bool
- ArrayAccess methods.
- offsetGet() : mixed
- ArrayAccess methods.
- offsetSet() : mixed
- ArrayAccess methods.
- offsetUnset() : mixed
- ArrayAccess methods.
- rewind() : void
- Iterator methods.
- valid() : bool
- Iterator methods.
Properties
$batch_id
public
string
$batch_id
$batch_message
public
string
$batch_message
$batch_status
public
string
$batch_status
$buyer_address
public
Address
$buyer_address
$created_at
public
string
$created_at
$customs_info
public
CustomsInfo
$customs_info
$fees
public
array<string|int, Fee>
$fees
$forms
public
array<string|int, mixed>
$forms
$from_address
public
Address
$from_address
$id
public
string
$id
$insurance
public
Insurance
$insurance
$is_return
public
bool
$is_return
$messages
public
array<string|int, Message>
$messages
$mode
public
string
$mode
$object
public
string
$object
$options
public
object
$options
$parcel
public
Parcel
$parcel
$postage_label
public
PostageLabel
$postage_label
$rates
public
array<string|int, Rate>
$rates
$reference
public
string
$reference
$refund_status
public
string
$refund_status
$return_address
public
Address
$return_address
$scan_form
public
ScanForm
$scan_form
$selected_rate
public
Rate
$selected_rate
$status
public
string
$status
$to_address
public
Address
$to_address
$tracker
public
Tracker
$tracker
$tracking_code
public
string
$tracking_code
$updated_at
public
string
$updated_at
$usps_zone
public
bool
$usps_zone
$_immutableValues
protected
array<string|int, mixed>
$_immutableValues
$_values
protected
array<string|int, mixed>
$_values
$_name
private
string
$_name
$_parent
private
string
$_parent
Methods
__construct()
Constructor for EasyPost objects.
public
__construct([string $parent = null ][, string $name = null ]) : mixed
Parameters
- $parent : string = null
- $name : string = null
Return values
mixed —__get()
Getter.
public
__get(string $k) : mixed
Parameters
- $k : string
Return values
mixed —__isset()
`isset` magic method.
public
__isset(string $k) : bool
Parameters
- $k : string
Return values
bool —__set()
Standard accessor magic methods.
public
__set(string $k, mixed $v) : mixed
Parameters
- $k : string
- $v : mixed
Return values
mixed —__toArray()
Convert object to an array.
public
__toArray([bool $recursive = false ]) : array<string|int, mixed>
Parameters
- $recursive : bool = false
Return values
array<string|int, mixed> —__toJSON()
Convert object to JSON.
public
__toJSON() : string
Return values
string —__toString()
Convert object to a string.
public
__toString() : string
Return values
string —__unset()
`unset` magic method.
public
__unset(string $k) : mixed
Parameters
- $k : string
Return values
mixed —constructFrom()
Construct EasyPost objects from a response.
public
static constructFrom(EasyPostClient $client, array<string|int, mixed> $values, string $class) : mixed
Parameters
- $client : EasyPostClient
- $values : array<string|int, mixed>
- $class : string
Return values
mixed —convertEach()
Convert each piece of an EasyPost object.
public
convertEach(EasyPostClient $client, array<string|int, mixed> $values) : mixed
Parameters
- $client : EasyPostClient
- $values : array<string|int, mixed>
Return values
mixed —current()
Iterator methods.
public
current() : mixed
Return values
mixed —key()
Iterator methods.
public
key() : mixed
Return values
mixed —lowestRate()
Get the lowest rate for the shipment.
public
lowestRate([array<string|int, mixed> $carriers = [] ][, array<string|int, mixed> $services = [] ]) : Rate
To exclude a carrier or service, prepend the string with !.
Parameters
- $carriers : array<string|int, mixed> = []
- $services : array<string|int, mixed> = []
Return values
Rate —next()
Iterator methods.
public
next() : mixed
Return values
mixed —offsetExists()
ArrayAccess methods.
public
offsetExists(string $k) : bool
Parameters
- $k : string
Return values
bool —offsetGet()
ArrayAccess methods.
public
offsetGet(string $k) : mixed
Parameters
- $k : string
Return values
mixed —offsetSet()
ArrayAccess methods.
public
offsetSet(string $k, mixed $v) : mixed
Parameters
- $k : string
- $v : mixed
Return values
mixed —offsetUnset()
ArrayAccess methods.
public
offsetUnset(string $k) : mixed
Parameters
- $k : string
Return values
mixed —rewind()
Iterator methods.
public
rewind() : void
Return values
void —valid()
Iterator methods.
public
valid() : bool