Thank you, TR for creating so great module. Is it possible to implement Printing Canada Post shipping labels from Ubercart Admin orders? Thank you in advance.

Comments

tr’s picture

Do you mean printing simple mailing labels, or do you mean printing pre-paid barcoded labels that will be accepted by Canada Post as postage?

LightFromArt’s picture

Thank you for a quick response. I meant printing pre-paid barcoded labels that will be accepted by Canada Post as postage. For a example Priority Mail or Xpresspost prepaid labels.

tr’s picture

The answer then is no. Canada Post has a very limited set of web services, and doesn't provide an API for label generation, or package tracking, or address validation, or anything else - even though these APIs are typical for other carriers (UPS, FedEx, USPS, etc.).

LightFromArt’s picture

I have sent a question to the Canada Post today may be they will develop some API for us? I will let you know about results, as soon as I will have an answer from them.

tr’s picture

Status: Active » Closed (fixed)
LightFromArt’s picture

Status: Closed (fixed) » Active

Thank you, TR for creating so great module. I still think we could do it.
See the following link with information about what was done by osCommerce team:
http://addons.oscommerce.com/info/6934
They wrote the following:
"This modification allows to ship an order electronically by submitting data to
PayPal server which then returns a GIF file with a label that should be placed
onto the package. Most of the information is automatically filled out given the
order data.
This is especially useful to Canadians as Canada Post does not provide any API
to electronically ship Light Packets Air. It's very time consuming to ship them
in person at the local postal outlet. Luckily, PayPal allows to ship those via
Canada Post electronically.
What this modification does is pretend to be a human. It goes to the PayPal site
and traverses it filling in all the fields like a human would. That's all done
with PHP and Curl magic. "
What do you think? They provided code at above link.
Thank you in advance,

tr’s picture

Status: Active » Closed (won't fix)

The way osCommerce does it in that code you linked to is so terrible and awful I won't even consider it for my Canada Post module. Scraping a web page like that is a nasty and fragile solution, which would be hell to maintain because it would have to be redone every time PayPal did a slight design change on their site. I'm not going to support that. But worst of all, that solution requires storing your PayPal user name and password in the Drupal database, and there's no way I'm going to be an enabler for that sort of behavior.

I should add, however, that if Canada Post ever makes an API for label printing, I will happily add that feature into the module.