This official Open Street Map library can read, export, and handle OpenStreetMap data in Ruby language. This library can export Google Earth files, GPS exchange format, and comma separated values. The API supports information of updates and geometries.
Quick, what is your House of Representatives district? Many people don't know this number, or the member who represents them. The New York Times' new Districts API makes it easy for your application to answer the question for any point within New York City, though it could serve as a template for a nationwide--or even international--service.