Category Archives: eCommerce

Programatic submission of Australia Post’s CN23 customs form

A number of major international destinations of packages now will only accept packages with electronic CN23 customs declaration. Normally, you’d do this by rocking up to the Post Office with your pre-addressed parcel, filling in a CN23 paper form, and have that transcribed into Australia Post’s computer system by the postal worker behind the counter. You can elect to receive SMS notifications of change of status (landed, delivered, etc) for 50c.

Australia Post also allows you to fill in the appropriate details on their website; if you do this, then you get a QR code sent to you via SMS (free) and email (free) which the postal worker scans in and all the details (your name and address, destination name and address, contents, etc) are attached to your package’s details without any error-prone re-keying. The downside of going down this path is the dismal website Aussie Post provides, a JavaScript heavy, painfully slow dog of a site that doesn’t cache your own address.

Once the QR code is scanned, and the postal worker checks everything with you, they’ll print out the CN23, get you to sign it , and then it gets attached to your parcel. Because the To and From addresses are on the CN23 form (and those details are in electronic form, associated with the barcode for the package), it’s perfectly acceptable to present an unaddressed package to the post office (make sure you can tell which package is which, if you go down this route).

One thing you need to be aware of: Australia Post hasn’t heard of Unicode. You absolutely can’t use any characters not in the ASCII character set, and even then a very limited range of them. Certain fields allow some characters, which in turn aren’t allowed in other fields.

One of the fields you can supply is the HS tariff code, which is an international standard group of codes to describe “stuff” – the Harmonised System Tariff code. The sourcecode below uses the code for “Toy, plastic construction” – you should use the code for what you’re actually sending. You can specify multiple HS codes. Dollar values are in decimal dollars, weights are in decimal kilograms.

After calling the Australia Post website with your customs declaration, it returns to you a base-64 encoded PNG of the QR code to present at the counter, and a base-64 encoded PDF of the CN23 form – there’s no point printing this out, because it’s not paid for yet; let the Post Office print it out with the postage on it. You’ll also get the PNG via email and SMS (free).

Here’s some Python to make this submission:


    AP_session = requests.Session()
    jsonFormData =  {"customDeclaration":{
      "label":{"source":"AEM","postagePaidIndicator":False,"eadIndicator":False},
      "parcelCharacteristics":{
        "productClassification":11,
        "dangerousGoodsIndicator":False,
        "returnInstructions":"Return By Most Economical Route",
        "confirmationMobileNumber":"0411111111",
        "content":[{
          "content":"HS traffic code name for your stuff",
          "contentQuantity":1,
          "contentUnitValue":subtotal,
          "totalContentValue":subtotal,
          "contentWeight":int(order["total_weight"])/1000,
          "hsTariff":"95030039",
          "contentCountryOfOrigin":"DK"
          }],
        "totalConsignmentValue":subtotal},
      "senderAddress":{"firstName":"Josh","lastName":"FromGeekrant.org",
        "addressLine":["11 Example St"],"suburb":"YourSuburbName","state":"VIC",
        "postcode":"3000","email":"addr@example.com",
        "phone":"0411111111","smsConfirmation":False,"countryCode":"AU"},
      "receiverAddress":{"firstName":CustomsString(order["label_address_name_first"]),
        "lastName":CustomsString(order["label_address_name_last"]),
        "countryCode":order["label_address_two_char_country_code"],
        "addressLine":CustomsAddress(order),
        "suburb":CustomsString(order["label_address_city"]),
        "state":CustomsString(order["label_address_state"]),
        "postcode":CustomsString(order["label_address_postal_code"]),
        "email":order["buyer_email"]}
    }}

    stopact = {"jsonFormData":json.dumps(jsonFormData) }
    result = AP_session.post(url='https://auspost.com.au/bin/form/stopact', 
      data=stopact, timeout=2)
    response = json.loads(result.text)
    result.raise_for_status()
    filename = "{}-customsQRcode.png".format(orderid)
    with open(filename, "wb") as fh:
      fh.write(base64.b64decode(response['qrCode']))
    filename = "{}-CN23.pdf".format(orderid)
    with open(filename, "wb") as fh:
      fh.write(base64.b64decode(response['label']))

Car buying websites think they’re classified ads

I’m in the process of buying another car, and it seems that the major car buying websites are stuck in the classified ads mentality; you drill down by make, model, year, limit for a range of odometer readings (you get to set a minimum! Great! Who would ever set a minimum?) and a price range (you get to set a minimum! Great! Who would ever set a minimum?), then look at what you get. Now that we’re in the 20th century, you can even sort the results by ascending price! Wow, what did we ever do without computers?

But I while don’t know what model I want to buy, I do know I want curtain airbags. Can I search for that? No. Do they have the data on that, for each and every vehicle listed? Yes. They have pre-populated the check-boxes for each feature for every model of car ever sold. That would be a handy database to search, especially in nifty combinations like curtain airbags in five door vehicles getting better than 8l/100km, order by turning circle then price.

Clearly, the presumption here is that you have the slightest idea what you want, and that you care terribly about brands, but not at all about features. For me, in my situation, this is arse backwards. However, in my researching, I discovered that the Peugeot 307 was rated 158th of 159 cars for reliability. Could I exclude that please? No? Oh.

You can do a “keyword search”, which is just a text search of the description attached to the ad – whatever the advertiser types in. Typing in curtain gets a bunch of ads with curtain airbags, which thoughtful advertisers have included in their descriptive text – repeating all the text of the various feature check-boxes – but you also get to see a bunch of Kombi vans (they have actual curtains).

And the useful values, like ANCAP ratings, RACV (or whatever) crash worthiness ratings, RACV reliably ratings, choice vehicle reliability scores, are they in the databases? Can you search them?

Must try harder.

On another note, Toyota Australia’s website is a laugh riot. When you pull up their vehicle comparison tool, they include a bunch of very amusing “features”, such as “Steering wheel” and “door handles”. I wonder if they carry any cars without door handles?

Reviews that aren’t

You know what I really hate?

Googling for “product X review” and finding bazillions of web sites that purport to be reviews of product X, but which in fact are just shopping web sites which have manufacturer’s information, or possibly a “story” written word-for-word from a press release, and nothing else.

Oh sure, some of them might have space for a product review, if some hapless customer wants to donate their time and effort into writing one. But if it’s [obscure shopping site] then why would anybody bother?

And some might have comparative price listings from various retail and online shops. With reviews… of the shops.

No wonder I end up looking on amazon.com (where there’s enough customers who actually care about writing reviews to make it worthwhile) or epinions.com, but both being US-based means they don’t cover some models available in other countries.

Can we get Google to somehow sort the wheat from the chaff here? Or will some non-US sites rise from the rest and get a critical mass of reviewers?

Oh, and can anybody tell me if the Epson C59 printer offered today on Zazz is a cheap and cheerful (if ugly) bargain, or a foul demon waste of my hard-earned $50?

eBay ratings

The problem I have with eBay feedback is the positive ones are usually so over the top. “A1++++++++++++++ great ebayer!!!!!” is really too much when usually it just means the person in question sent the parcel/money on time, and answered emails. I prefer to put a little more actual information in the feedback I leave.

Amazon’s data loss

Amazon has lost historic data. Sales data. Data for profiling customers.

I know. They lost mine.

I found out because it wouldn’t let me look inside The Complete Far Side because I don’t have an account that’s bought stuff – according to their records.

Except now I can look at the excerpt, but still they reckon I haven’t bought anything.

Weird.

Ebay how-tos – will they ever agree?

Don’t be an eBay buyer, or you could turn into this crazy eBay woman. Be a seller. Perhaps you’re going to make a killing on PS3s. Or you’ve just cornered the world market in a particular Lego set. Just don’t pick some dud product. While you’re not going to become an eBay millionare, often the question is “What’s the trick to make the most money”?

Everyone with an opinion disagrees.

Shipping
Research shows that people are relatively insensitive to shipping costs, even though honour and the eBay rules say you can’t charge much beyond what it actually costs to ship. But perhaps the research was flawed, it only sampled 80 purchases.
Duration
The PS3 guy reckons 3 day auctions are the way to go. Roth reckons ten day ones are best, because they cover two weekends. Smith says 10 day auctions suck, but gives no reason.
Finish time
Sunday evening might work well, and in my sample of one it worked great, but:

Sunday evening may well be a peak time for ebay but bear in mind that there will be both an increase in buyers AND of auctions/competition so it’s not clear it’s the best time to end an auction. I’ve found Sunday, Monday, Thursday evenings to be good.

People are home on the weekends. Are they home, bored? I guess you want your auction to finish at such a time that when people see it, they’re willing to bid on it.
Body copy
Sean Blanda at College v2 says ‘don’t waste time on narrative‘. J.D. Roth thinks just the opposite. My anecdotal evidence says that amusing, engaging and informative copy makes for higher realised prices; the time investment in this, however, can be a killer. So you’d want to be selling multiples of whatever it is. Perhaps because I included a story of the item’s provenance it helped.
Starting price
Low starting bids are universally suggested, but often the following caveat is normally ignored:

It’s also not true that a 0.99 starting price is always the best policy. This is only true if your item has a lot of demand. Many times if there are only a few buyers interested and you list the item at near retail you will eventually get a buyer willing to pay that price – you may need to relist a few times. If you had starting it at 0.99 it may be that only one buyer happens to be interested at the time of the auction.

Moreover, if you have more than one item that will generally have few buyers and you list at 0.99 and it sells at that price, you’ve then set a precedence. People who search for completed listings will now perceive the item to be worth 0.99 – not good.

Myself, I’m going to use a buy-it-now price. I’m in no rush to sell, and really want the super premium I can capture.
Pictures
Everyone says put in a picture, but here’s a money-saving tip:

You can embed lots of pictures in your html rather than pay ebay to upload them – ebay gives one free & charges for the rest. It takes a little bit to learn this, but is NOT difficult.

Geeks aren’t afraid of HTML. And we love optimizing things, such as cost.

Feeback
Early or late? I think you’ve done unilateral disarmament if you’ve left feedback before the buyer has. But some people think you ought to leave feedback as soon as you’ve got the money. But a buyer can screw you over in so many ways after giving you the money. Bad move.

Unclear
I don’t know what the right Finish Time is. Any suggestions, with reasoning or, better yet, evidence?

Wow, how did I miss the Mechanical Turk?

Amazon Mechanical Turk is an astonishing idea – an Artificial AI marketplace. Basically, there’s an API you can call to get humans to do tasks (oddly enough, they want to be paid). Currently, a big favourite for the tasks is transcribing podcasts. I can see that it would be a cheap way to truth a set of training data for AI systems, like number plate detection / recognition.

An artist has used the Mechanical Turk to acquire 10,000 hand drawn left-facing sheep and put them on a site for your viewing pleasure – plus, there was an exhibition of the collectable stamp sheets etc (you can buy the as stamp-sheets for only $20 a sheet). Given the images cost less than a cent each to acquire, he may be a bullshit artist.

The Turk is an example of what Wired calls Rise of Crowdsourcing – Remember outsourcing? Sending jobs to India and China is so 2003. The new pool of cheap labor: everyday people using their spare cycles to create content, solve problems, even do corporate R & D. It’s about the markets, people. These are markets for micro-transactions – micro in their repeatability, or micro in their value.

Where are the aliens?

Coffee drinkers are easier to persuade.

Fermi’s Paradox is explained by aliens getting adicited to computer gaming.

Strom reckons he knows how to make money with a website: ads! Plus a little other stuff.

An Irishman has a rather good summery of how to negotiate an intial salary.

Cross-platform rounded corners without images, extra markup nor CSS. The holy grail of web-design dweebs.

AUSTRALIA’S FIRST WEB CHICKEN

Walking to the train station from work, saw this big red ad – and I must admit, I think my vision is going – I think it’s degenerated to the point where it’s as good as most people’s. And perhaps I’m slightly dyslexic, but I read the ad as “Australia’s first web chicken”. Perhaps I spent too much time in NZ as a child. In fact, in looking critically at it, and recalling a UI design subject I didn’t do (but damn it, should have, it would have been one of the few subjects I would still be using), humans are crap at reading uppercase letters.
Australia
Ha! So, I’m going to claim it’s not my fault I misread it, and I’m going to do a geekrant about it, because now it’s a geek issue – look, it’s got web on it. And the fun part is, a few months after the ad went up I noticed it, but just as soon as I blog about it they pull it down. So you’re just going to have to take my word for it – the ad was up there. There’s a beer ad now.

What’s with that logo in the bottom-right corner? How does that add to the ad’s message? Why isn’t the VirginBlue in a more prominant location? Why did they change colours midway through the web address, and what’s with that aeroplane tail – are they intentionally making this hard to read? Or perhaps they’re making the name look like a plane – so why haven’t they added wings? And what does “me-time” have to do with the smirking idiot on the left hand side?

If you join the mile-high club after doing a web chicken, is that kinky?

Ad blocking begins to have an economic effect

So I was checking out copper (as you do), and followed the wikipedia copper entry link to EnvironmentalChemistry.com’s copper data, and I discovered that ad blockers are beginning to change the economics of the web. The web site whinged that they had detected ad blocking, and if I wanted to get the content I’d have to turn it off (and provided directions – which I followed, but it just turned out to be a bunch of atomic numbers and covalent bonds and useless crap like that).

The economics of a lot of the web are not dissimilar to those of free-to-air television; there’s a covenant between the producers (broadcasters/webauthors) and the consumers – we will let this stuff out to anyone, and you will consume our advertising. Advertisers give the producers cash to cover the costs of publishing. There’s a profit in it, and everyone’s happy.

Except that consumers have decided they don’t like the deal anymore. People are taping TV shows, and skipping the ads. People are using ad blockers in their browsers. The economics of the model are breaking down. I personally am behaving this way because I find the advertising increasingly intrusive and irrelevant, and thus annoying. The ads suck, for products that suck, and they’re shoved down my throat. So I avoid them. This is how a character in Carl Sagan’s novel Contact became the richest man on earth – by selling TV ad blockers.

The three outcomes I can forecast from this are:

  1. increased relevance of advertising (unlikely, the reason advertising is necessary is because of an inherent suckiness of the products, otherwise they’d be compelling)
  2. decreased expenditure on content provision (on TV, cheaper nastier shows – if that’s possible; on the web, uneconomic sites being pulled or at least not updated)
  3. product placement, which is a bit like 1, ‘cept different because it’s more about appropriate products in appropriate places

I for one have no idea how this will play out, but I’m sure advertising will get more subtle. It’s done that over the last century, and will continue to in response to increasing consumer sophistication. Perhaps advertisers will find a way to back off, and only offer their products to customers who want them; they certainly want to act that way, because it’s a waste of money advertising women’s sanitary napkins to the gay male viewers of Friends — unless they’re planning to fix their car’s leaky roof with one.

BTW, how did they figure out I was blocking their ads?