{
"carrier": "UPS",
"action": "GetAllRates",
"params": {
"freight_account_number": "YOUR_ACCOUNT_NUMBER",
"packages": [
{
"weight": 200,
"freight_class": "50",
"description": "bailing wire"
}
],
"customs": [],
"shipper": "RocketShipIt",
"ship_addr1": "1202 Chalet Ln",
"ship_addr2": "Do Not Delete - Test Account",
"ship_city": "Harrison",
"ship_state": "AR",
"ship_code": "72601",
"ship_country": "US",
"to_country": "US",
"to_city": "Akron",
"to_state": "OH",
"to_code": "44333",
"weight_unit": "LB",
"test": true
}
}
<?php
$rs = new RocketShipIt;
$response = $rs->request(
array (
'carrier' => 'UPS',
'action' => 'GetAllRates',
'params' =>
array (
'freight_account_number' => 'YOUR_ACCOUNT_NUMBER',
'packages' =>
array (
0 =>
array (
'weight' => 200,
'freight_class' => '50',
'description' => 'bailing wire',
),
),
'customs' =>
array (
),
'shipper' => 'RocketShipIt',
'ship_addr1' => '1202 Chalet Ln',
'ship_addr2' => 'Do Not Delete - Test Account',
'ship_city' => 'Harrison',
'ship_state' => 'AR',
'ship_code' => '72601',
'ship_country' => 'US',
'to_country' => 'US',
'to_city' => 'Akron',
'to_state' => 'OH',
'to_code' => '44333',
'weight_unit' => 'LB',
'test' => true,
),
)
);
rs.request(
{'action': 'GetAllRates',
'carrier': 'UPS',
'params': {'customs': [],
'freight_account_number': 'YOUR_ACCOUNT_NUMBER',
'packages': [{'description': 'bailing wire',
'freight_class': '50',
'weight': 200}],
'ship_addr1': '1202 Chalet Ln',
'ship_addr2': 'Do Not Delete - Test Account',
'ship_city': 'Harrison',
'ship_code': '72601',
'ship_country': 'US',
'ship_state': 'AR',
'shipper': 'RocketShipIt',
'test': True,
'to_city': 'Akron',
'to_code': '44333',
'to_country': 'US',
'to_state': 'OH',
'weight_unit': 'LB'}}
)
rs.request(
{"carrier"=>"UPS",
"action"=>"GetAllRates",
"params"=>
{"freight_account_number"=>"YOUR_ACCOUNT_NUMBER",
"packages"=>
[{"weight"=>200, "freight_class"=>"50", "description"=>"bailing wire"}],
"customs"=>[],
"shipper"=>"RocketShipIt",
"ship_addr1"=>"1202 Chalet Ln",
"ship_addr2"=>"Do Not Delete - Test Account",
"ship_city"=>"Harrison",
"ship_state"=>"AR",
"ship_code"=>"72601",
"ship_country"=>"US",
"to_country"=>"US",
"to_city"=>"Akron",
"to_state"=>"OH",
"to_code"=>"44333",
"weight_unit"=>"LB",
"test"=>true}}
)
rocketshipit.request(
{
"carrier": "UPS",
"action": "GetAllRates",
"params": {
"freight_account_number": "YOUR_ACCOUNT_NUMBER",
"packages": [
{
"weight": 200,
"freight_class": "50",
"description": "bailing wire"
}
],
"customs": [],
"shipper": "RocketShipIt",
"ship_addr1": "1202 Chalet Ln",
"ship_addr2": "Do Not Delete - Test Account",
"ship_city": "Harrison",
"ship_state": "AR",
"ship_code": "72601",
"ship_country": "US",
"to_country": "US",
"to_city": "Akron",
"to_state": "OH",
"to_code": "44333",
"weight_unit": "LB",
"test": true
}
}
)