Uk-constituencies is a project mainly written in Ruby, it's free.
Historic UK constituency data / API using CouchDB
Callable API to determine basic data about UK constituencies on a given date. Hoping to extend this to MP and electoral data eventually
Disclaimers:
Needs updating to include 2010 election data
Nowhere near finished yet!