International Document Generation

RocketShipIt is capable of producing international customs documentation. Here are a few examples:

UPS

Example:

<?php
$shipment = new \RocketShipIt\Shipment('UPS');
$shipment->setParameter('toCompany', 'Australia Zoo');
$shipment->setParameter('toName', 'Mark Sanborn');
$shipment->setParameter('toAttentionName', 'Mark Sanborn');
$shipment->setParameter('toPhone', '17077262676');
$shipment->setParameter('toAddr1', '1638 Steve Irwin Way');
$shipment->setParameter('toCity', 'Beerwah');
$shipment->setParameter('toCode', '4519');
$shipment->setParameter('toCountry', 'AU');

$shipment->setParameter('shipPhone', '17077262676');
$shipment->setParameter('service', '65');

$shipment->setParameter('invoice', '12345');
$shipment->setParameter('invoiceDate', '20120702');
$shipment->setParameter('soldCompany', 'RocketShipIt');
$shipment->setParameter('soldName', 'Mark Sanborn');
$shipment->setParameter('soldTaxId', '803070713RT0001');
$shipment->setParameter('soldPhone', '7077262676');
$shipment->setParameter('soldAddr1', '60 Healey Road');
$shipment->setParameter('soldAddr2', 'Unit 2');
$shipment->setParameter('soldCity', 'Bolton');
$shipment->setParameter('soldState', 'ON');
$shipment->setParameter('soldCode', 'L7E5A5');
$shipment->setParameter('soldCountry', 'CA');

$customs = new \RocketShipIt\Customs('ups');
$customs->setParameter('invoiceLineNumber', '1');
$customs->setParameter('invoiceLinePartNumber', '123');
$customs->setParameter('invoiceLineDescription', 'My Description');
$customs->setParameter('invoiceLineValue', '1');
$customs->setParameter('invoiceLineOriginCountryCode', 'CN');

$shipment->addCustomsLineToShipment($customs);

$customs = new \RocketShipIt\Customs('ups');
$customs->setParameter('invoiceLineNumber', '2');
$customs->setParameter('invoiceLinePartNumber', '567');
$customs->setParameter('invoiceLineDescription', 'Another Description');
$customs->setParameter('invoiceLineValue', '2');
$customs->setParameter('invoiceLineOriginCountryCode', 'CN');

$shipment->addCustomsLineToShipment($customs);

$package = new \RocketShipIt\Package('UPS');
$package->setParameter('length','5');
$package->setParameter('width','5');
$package->setParameter('height','5');
$package->setParameter('weight','5');

$shipment->addPackageToShipment($package);

$response = $shipment->submitShipment();

You can specify the Tax Id in customs forms by setting the taxId parameter

FedEx

Example:

<?php
$shipment = new \RocketShipIt\Shipment('fedex');

$shipment->setParameter('toCompany', 'John Doe');
$shipment->setParameter('toName', 'John Doe');
$shipment->setParameter('toPhone', '1231231234');
$shipment->setParameter('toAddr1', '361A Old Finch Avenue');
$shipment->setParameter('toCity', 'Toronto');
$shipment->setParameter('toState', 'ON');
$shipment->setParameter('toCode', 'M1B5K7');
$shipment->setParameter('toCountry', 'CA');
$shipment->setParameter('service', 'INTERNATIONAL_PRIORITY');
$shipment->setParameter('packagingType', 'YOUR_PACKAGING');

$shipment->setParameter('length', '5');
$shipment->setParameter('width', '5');
$shipment->setParameter('height', '5');
$shipment->setParameter('weight','5');

$shipment->setParameter('customsCurrency', 'USD');
$shipment->setParameter('customsValue', '20.00');

$customs = new \RocketShipIt\Customs('fedex');
$customs->setParameter('customsNumberOfPieces', '1');
$customs->setParameter('countryOfManufacture', 'US');
$customs->setParameter('weightUnit', 'LB');
$customs->setParameter('customsDescription', 'Industrial Dishwasher');
$customs->setParameter('customsWeight', '5');
$customs->setParameter('customsQuantity', '1');
$customs->setParameter('customsQuantityUnits', 'ea');
$customs->setParameter('customsLineAmount', '20.00');

$shipment->addCustomsLineToShipment($customs);

$shipment->setParameter('generateDocs', array('COMMERCIAL_INVOICE', 'NAFTA_CERTIFICATE_OF_ORIGIN'));
$shipment->setParameter('docImageType', 'PDF');
$shipment->setParameter('docStockType', 'PAPER_LETTER');
$shipment->setParameter('paperlessCustoms', 'YES');

$shipment->setParameter('shipTaxIdType', 'BUSINESS_NATIONAL');
$shipment->setParameter('shipTaxId', '1234567');

$shipment->setParameter('toTaxIdType', 'BUSINESS_NATIONAL');
$shipment->setParameter('toTaxId', '5551234');

$response = $shipment->submitShipment();

Importer of Record Parameters

In addition to the shipment parameters above you can also specify the importer of record using these paramters:

  • iorAccountNumber
  • iorContactId
  • iorPersonName
  • iorTitle
  • iorCompany
  • iorPhone
  • iorPhoneExtension
  • iorPagerNumber
  • iorFaxNumber
  • iorEmailAddress
  • iorAddr1
  • iorCity
  • iorState
  • iorCode
  • iorUrbanizationCode
  • iorCountry
  • iorResidential
  • iorTaxId

iorTaxIdType

Values:

  • BUSINESS_NATIONAL
  • BUSINESS_STATE
  • BUSINESS_UNION
  • PERSONAL_NATIONAL
  • PERSONAL_STATE