{
"action": "SubmitShipment",
"carrier": "UPS-REST",
"params": {
"account_number": "your-account-number",
"key": "your-key-from-authenticate-request",
"to_email": "noreply123@someemail.com",
"alt_addr1": "14370 Myford Rd Suite #150",
"alt_attention_name": "RMA# 9771",
"alt_city": "Irvine",
"alt_code": "92606",
"alt_country": "US",
"alt_name": "AmScope",
"alt_phone": "2158801280",
"alt_state": "CA",
"currency": "USD",
"image_type": "GIF",
"label_stock_type": "PAPER_8.5X11_BOTTOM_HALF_LABEL",
"length_unit": "IN",
"packages": [
{
"height": 1,
"length": 1,
"reference_code": "00",
"reference_value": "ref 1",
"weight": 18,
"width": 1
}
],
"packaging_type": "02",
"residential": true,
"service": "03",
"ship_addr1": "542 W 112th St",
"ship_city": "New York",
"ship_code": "10025",
"ship_contact": "US Test - NY",
"ship_country": "US",
"ship_name": "US Test - NY",
"ship_phone": "2681549230",
"ship_state": "NY",
"shipper": "US Test - NY",
"test": true,
"to_addr1": "5685 Alcoa Ave",
"to_attention_name": "US Test - CA 1",
"to_city": "LOS ANGELES",
"to_code": "90058-3728",
"to_company": "US Test - CA 1",
"to_country": "US",
"to_name": "US Test - CA 1",
"to_phone": "5268194758",
"to_state": "CA",
"weight_unit": "LBS"
}
}
<?php
$rs = new RocketShipIt;
$response = $rs->request(
array (
'action' => 'SubmitShipment',
'carrier' => 'UPS-REST',
'params' =>
array (
'account_number' => 'your-account-number',
'key' => 'your-key-from-authenticate-request',
'to_email' => 'noreply123@someemail.com',
'alt_addr1' => '14370 Myford Rd Suite #150',
'alt_attention_name' => 'RMA# 9771',
'alt_city' => 'Irvine',
'alt_code' => '92606',
'alt_country' => 'US',
'alt_name' => 'AmScope',
'alt_phone' => '2158801280',
'alt_state' => 'CA',
'currency' => 'USD',
'image_type' => 'GIF',
'label_stock_type' => 'PAPER_8.5X11_BOTTOM_HALF_LABEL',
'length_unit' => 'IN',
'packages' =>
array (
0 =>
array (
'height' => 1,
'length' => 1,
'reference_code' => '00',
'reference_value' => 'ref 1',
'weight' => 18,
'width' => 1,
),
),
'packaging_type' => '02',
'residential' => true,
'service' => '03',
'ship_addr1' => '542 W 112th St',
'ship_city' => 'New York',
'ship_code' => '10025',
'ship_contact' => 'US Test - NY',
'ship_country' => 'US',
'ship_name' => 'US Test - NY',
'ship_phone' => '2681549230',
'ship_state' => 'NY',
'shipper' => 'US Test - NY',
'test' => true,
'to_addr1' => '5685 Alcoa Ave',
'to_attention_name' => 'US Test - CA 1',
'to_city' => 'LOS ANGELES',
'to_code' => '90058-3728',
'to_company' => 'US Test - CA 1',
'to_country' => 'US',
'to_name' => 'US Test - CA 1',
'to_phone' => '5268194758',
'to_state' => 'CA',
'weight_unit' => 'LBS',
),
)
);
rs.request(
{'action': 'SubmitShipment',
'carrier': 'UPS-REST',
'params': {'account_number': 'your-account-number',
'alt_addr1': '14370 Myford Rd Suite #150',
'alt_attention_name': 'RMA# 9771',
'alt_city': 'Irvine',
'alt_code': '92606',
'alt_country': 'US',
'alt_name': 'AmScope',
'alt_phone': '2158801280',
'alt_state': 'CA',
'currency': 'USD',
'image_type': 'GIF',
'key': 'your-key-from-authenticate-request',
'label_stock_type': 'PAPER_8.5X11_BOTTOM_HALF_LABEL',
'length_unit': 'IN',
'packages': [{'height': 1,
'length': 1,
'reference_code': '00',
'reference_value': 'ref 1',
'weight': 18,
'width': 1}],
'packaging_type': '02',
'residential': True,
'service': '03',
'ship_addr1': '542 W 112th St',
'ship_city': 'New York',
'ship_code': '10025',
'ship_contact': 'US Test - NY',
'ship_country': 'US',
'ship_name': 'US Test - NY',
'ship_phone': '2681549230',
'ship_state': 'NY',
'shipper': 'US Test - NY',
'test': True,
'to_addr1': '5685 Alcoa Ave',
'to_attention_name': 'US Test - CA 1',
'to_city': 'LOS ANGELES',
'to_code': '90058-3728',
'to_company': 'US Test - CA 1',
'to_country': 'US',
'to_email': 'noreply123@someemail.com',
'to_name': 'US Test - CA 1',
'to_phone': '5268194758',
'to_state': 'CA',
'weight_unit': 'LBS'}}
)
rs.request(
{"action"=>"SubmitShipment",
"carrier"=>"UPS-REST",
"params"=>
{"account_number"=>"your-account-number",
"key"=>"your-key-from-authenticate-request",
"to_email"=>"noreply123@someemail.com",
"alt_addr1"=>"14370 Myford Rd Suite #150",
"alt_attention_name"=>"RMA# 9771",
"alt_city"=>"Irvine",
"alt_code"=>"92606",
"alt_country"=>"US",
"alt_name"=>"AmScope",
"alt_phone"=>"2158801280",
"alt_state"=>"CA",
"currency"=>"USD",
"image_type"=>"GIF",
"label_stock_type"=>"PAPER_8.5X11_BOTTOM_HALF_LABEL",
"length_unit"=>"IN",
"packages"=>
[{"height"=>1,
"length"=>1,
"reference_code"=>"00",
"reference_value"=>"ref 1",
"weight"=>18,
"width"=>1}],
"packaging_type"=>"02",
"residential"=>true,
"service"=>"03",
"ship_addr1"=>"542 W 112th St",
"ship_city"=>"New York",
"ship_code"=>"10025",
"ship_contact"=>"US Test - NY",
"ship_country"=>"US",
"ship_name"=>"US Test - NY",
"ship_phone"=>"2681549230",
"ship_state"=>"NY",
"shipper"=>"US Test - NY",
"test"=>true,
"to_addr1"=>"5685 Alcoa Ave",
"to_attention_name"=>"US Test - CA 1",
"to_city"=>"LOS ANGELES",
"to_code"=>"90058-3728",
"to_company"=>"US Test - CA 1",
"to_country"=>"US",
"to_name"=>"US Test - CA 1",
"to_phone"=>"5268194758",
"to_state"=>"CA",
"weight_unit"=>"LBS"}}
)
rocketshipit.request(
{
"action": "SubmitShipment",
"carrier": "UPS-REST",
"params": {
"account_number": "your-account-number",
"key": "your-key-from-authenticate-request",
"to_email": "noreply123@someemail.com",
"alt_addr1": "14370 Myford Rd Suite #150",
"alt_attention_name": "RMA# 9771",
"alt_city": "Irvine",
"alt_code": "92606",
"alt_country": "US",
"alt_name": "AmScope",
"alt_phone": "2158801280",
"alt_state": "CA",
"currency": "USD",
"image_type": "GIF",
"label_stock_type": "PAPER_8.5X11_BOTTOM_HALF_LABEL",
"length_unit": "IN",
"packages": [
{
"height": 1,
"length": 1,
"reference_code": "00",
"reference_value": "ref 1",
"weight": 18,
"width": 1
}
],
"packaging_type": "02",
"residential": true,
"service": "03",
"ship_addr1": "542 W 112th St",
"ship_city": "New York",
"ship_code": "10025",
"ship_contact": "US Test - NY",
"ship_country": "US",
"ship_name": "US Test - NY",
"ship_phone": "2681549230",
"ship_state": "NY",
"shipper": "US Test - NY",
"test": true,
"to_addr1": "5685 Alcoa Ave",
"to_attention_name": "US Test - CA 1",
"to_city": "LOS ANGELES",
"to_code": "90058-3728",
"to_company": "US Test - CA 1",
"to_country": "US",
"to_name": "US Test - CA 1",
"to_phone": "5268194758",
"to_state": "CA",
"weight_unit": "LBS"
}
}
)