Google Shopping Merchant Accounts V1beta Client - Class CarrierRate (0.2.0)

Reference documentation and code samples for the Google Shopping Merchant Accounts V1beta Client class CarrierRate.

A list of carrier rates that can be referred to by main_table or single_value.

Generated from protobuf message google.shopping.merchant.accounts.v1beta.CarrierRate

Namespace

Google \ Shopping \ Merchant \ Accounts \ V1beta

Methods

__construct

Constructor.

Parameters
Name Description
data array

Optional. Data for populating the Message object.

↳ name string

Required. Name of the carrier rate. Must be unique per rate group.

↳ carrier string

Required. Carrier service, such as "UPS" or "Fedex".

↳ carrier_service string

Required. Carrier service, such as "ground" or "2 days".

↳ origin_postal_code string

Required. Shipping origin for this carrier rate.

↳ percentage_adjustment string

Optional. Multiplicative shipping rate modifier as a number in decimal notation. Can be negative. For example "5.4" increases the rate by 5.4%, "-3" decreases the rate by 3%.

↳ flat_adjustment Google\Shopping\Type\Price

Optional. Additive shipping rate modifier. Can be negative. For example { "amount_micros": 1, "currency_code" : "USD" } adds $1 to the rate, { "amount_micros": -3, "currency_code" : "USD" } removes $3 from the rate.

getName

Required. Name of the carrier rate. Must be unique per rate group.

Returns
Type Description
string

hasName

clearName

setName

Required. Name of the carrier rate. Must be unique per rate group.

Parameter
Name Description
var string
Returns
Type Description
$this

getCarrier

Required. Carrier service, such as "UPS" or "Fedex".

Returns
Type Description
string

hasCarrier

clearCarrier

setCarrier

Required. Carrier service, such as "UPS" or "Fedex".

Parameter
Name Description
var string
Returns
Type Description
$this

getCarrierService

Required. Carrier service, such as "ground" or "2 days".

Returns
Type Description
string

hasCarrierService

clearCarrierService

setCarrierService

Required. Carrier service, such as "ground" or "2 days".

Parameter
Name Description
var string
Returns
Type Description
$this

getOriginPostalCode

Required. Shipping origin for this carrier rate.

Returns
Type Description
string

hasOriginPostalCode

clearOriginPostalCode

setOriginPostalCode

Required. Shipping origin for this carrier rate.

Parameter
Name Description
var string
Returns
Type Description
$this

getPercentageAdjustment

Optional. Multiplicative shipping rate modifier as a number in decimal notation. Can be negative. For example "5.4" increases the rate by 5.4%, "-3" decreases the rate by 3%.

Returns
Type Description
string

hasPercentageAdjustment

clearPercentageAdjustment

setPercentageAdjustment

Optional. Multiplicative shipping rate modifier as a number in decimal notation. Can be negative. For example "5.4" increases the rate by 5.4%, "-3" decreases the rate by 3%.

Parameter
Name Description
var string
Returns
Type Description
$this

getFlatAdjustment

Optional. Additive shipping rate modifier. Can be negative. For example { "amount_micros": 1, "currency_code" : "USD" } adds $1 to the rate, { "amount_micros": -3, "currency_code" : "USD" } removes $3 from the rate.

Returns
Type Description
Google\Shopping\Type\Price|null

hasFlatAdjustment

clearFlatAdjustment

setFlatAdjustment

Optional. Additive shipping rate modifier. Can be negative. For example { "amount_micros": 1, "currency_code" : "USD" } adds $1 to the rate, { "amount_micros": -3, "currency_code" : "USD" } removes $3 from the rate.

Parameter
Name Description
var Google\Shopping\Type\Price
Returns
Type Description
$this