Open cstoafer opened 7 years ago
n.b: zip code does not determine congressional district in all cases. for example, my zip (10009) crosses over two congressional districts, and needs further address information (exact address or lat/long or zip+4) in order to make the determination. it looks like other zip codes may even cross state boundaries. cf. this illuminating article.
two ways we could deal with this:
i would lean towards the former, what do you all think?
Shoot, I was worried about this. Is it straightforward to lookup by address or do we need to find a geocoding service?
If it is trivial to use address instead of zipcode, let's do that for MVP. Otherwise, we can start with zipcode. In cases with multiple possibilities, we could show the possible matches as you suggested, which is also how the federal government does it: http://ziplook.house.gov/htbin/findrep?ZIP=10009&Submit=FIND+YOUR+REP+BY+ZIP.
This might sound designy, but maybe we should consider both and do some user testing. It is possible that users would much prefer to enter zipcode before entering their full address.
in the interest of getting something off the ground, let's start with zip input. we can always have a second line of defense when it comes to ambiguous areas, like a full address. the census bureau offers a free geocoding API which doesn't require a key but seems a bit on the slower end (read more here).
sunlight labs looks solid in terms of mapping location to district/representatives, but they seem to be having known issues with registering for API keys right now, and it also looks like they are ... closing? (see https://twitter.com/sunlightlabs)
not sure what the implications of this are.
That sucks. Hopefully someone will pick up their work (it sounds like somebody will).
So I've finally got a postgres db locally and on heroku. Not using it at all, but it's there (I think). For the first stage we don't really need a DB though, could just call an api to get contact info. DB will be useful for storing and prioritizing bills/issues.
I'll try to get a clean app ready to go and we can link in the contact info APIs as a first pass.
Create pipeline and functions to ingest representative names and phone number for a zip code input.
Does NOT need to be displayed in web app for issue to be closed.
Possible data sources: