OnTrac - Rates

Carrier
OnTrac
Action
Rates
{
  "carrier": "OnTrac",
  "action": "getallrates",
  "params": {
    "test": true,
    "account_number": "37",
    "password": "testpass",
    "packages": [
      {
        "weight": 20.2,
        "length": 5,
        "width": 7,
        "height": 7
      }
    ],
    "customs": [],
    "ship_code": "90210",
    "to_code": "94115",
    "weight_unit": "LB",
    "service": ""
  }
}

<?php
$rs = new RocketShipIt;
$response = $rs->request(
array (
  'carrier' => 'OnTrac',
  'action' => 'getallrates',
  'params' => 
  array (
    'test' => true,
    'account_number' => '37',
    'password' => 'testpass',
    'packages' => 
    array (
      0 => 
      array (
        'weight' => 20.2,
        'length' => 5,
        'width' => 7,
        'height' => 7,
      ),
    ),
    'customs' => 
    array (
    ),
    'ship_code' => '90210',
    'to_code' => '94115',
    'weight_unit' => 'LB',
    'service' => '',
  ),
)
);

rs.request(
  {'action': 'getallrates',
 'carrier': 'OnTrac',
 'params': {'account_number': '37',
            'customs': [],
            'packages': [{'height': 7,
                          'length': 5,
                          'weight': 20.2,
                          'width': 7}],
            'password': 'testpass',
            'service': '',
            'ship_code': '90210',
            'test': True,
            'to_code': '94115',
            'weight_unit': 'LB'}}

)

rs.request(
  {"carrier"=>"OnTrac",
 "action"=>"getallrates",
 "params"=>
  {"test"=>true,
   "account_number"=>"37",
   "password"=>"testpass",
   "packages"=>[{"weight"=>20.2, "length"=>5, "width"=>7, "height"=>7}],
   "customs"=>[],
   "ship_code"=>"90210",
   "to_code"=>"94115",
   "weight_unit"=>"LB",
   "service"=>""}}

)

rocketshipit.request(
  {
  "carrier": "OnTrac",
  "action": "getallrates",
  "params": {
    "test": true,
    "account_number": "37",
    "password": "testpass",
    "packages": [
      {
        "weight": 20.2,
        "length": 5,
        "width": 7,
        "height": 7
      }
    ],
    "customs": [],
    "ship_code": "90210",
    "to_code": "94115",
    "weight_unit": "LB",
    "service": ""
  }
}
)

← All OnTrac examples