views:

232

answers:

3

A friend just brought by 1,000 lines of USA shipping addresses. (Excel.) I've read this into a Ruby program via CSV::.

Now I would like to check the mailing addresses for sanity. It doesn't have to be a perfect check. Her shipping contractor will be using a UPS program of some sort and we are just trying to minimize the number of addresses they choke on.

Any ideas?

(My first SO question! And I don't have to use Ruby.)

+1  A: 

A quick google search reveals this: Pure Ruby implementation of the Address Information API from USPS Web-Services.

No idea if it's any good.

JRL
Looks like it's vaporware.
Ewan Todd
A: 

Write a small method to post the address to Google Maps or similar service and screen scrape/use API to find out if the address is recognized ...

Niels Castle
I had of course already thought of this but it is the best answer...and I guess I was also asking "do I have to do this?", and you did answer that as well.
DigitalRoss
Not an "enterprise" solution but sometimes simple does it...
Niels Castle
A: 

Confusingly, JRL's link went to that "OStatic" site which appears to be a software listing and review site. I believe he was actually referring to this USPS gem (opensource) at:

http://rubyforge.org/projects/usps-api/

Mike Buckbee
But it is also an empty project. I did find http://github.com/FotoVerite/awesome-usps
DigitalRoss
Sorry, I should have looked at that more closely. They were quite serious about their project being "Pre-Alpha" apparently.
Mike Buckbee