📜 ⬆️ ⬇️

API to search for congressmen and elections from Google based on open source projects

To understand how the openness of public policy in the United States is arranged, it is interesting to turn to the most recent examples.

Just a few days ago, Google announced the appearance of the Google Civic Information API (Google API with civilian information), which now publishes information on elections, on elected representatives and polling stations.


')
It all comes down to a few challenges:

electionQuery

Returns a list of choices

Call example:
https://www.googleapis.com/civicinfo/us_v1/elections?key=<YOUR_API_KEY> 


Sample sample results:
 { "kind": "civicinfo#electionsqueryresponse", "elections": [ { "id": "2000", "name": "VIP Test Election", "electionDay": "2013-06-06" }, { "id": "2124", "name": "Rhode Island 2012 Primary Election", "electionDay": "2012-09-11" }, { "id": "2126", "name": "Delaware 2012 Primary Election", "electionDay": "2012-09-11" } ] } 


voterInfoQuery

Returns information relevant to the voter at his registration address.

Returned information may include:


An example call for the year 2000 and the city of Kansas:
 curl \ -H "Content-Type: application/json" \ -d "{ 'address': '1263 Pacific Ave. Kansas City KS' }" \ "https://www.googleapis.com/civicinfo/us_v1/voterinfo/2000/lookup?key=<YOUR_API_KEY>" 


An example of the answer and details can be found in the documentation: https://developers.google.com/civic-information/docs/us_v1/elections/voterInfoQuery

representativeInfoQuery

Returns information about political geography and (optional) information about elected representatives at.

Returned information may include:


Call example:
 curl \ -H "Content-Type: application/json" \ -d "{ 'address': '1263 Pacific Ave. Kansas City KS' }" \ "https://www.googleapis.com/civicinfo/us_v1/representatives/lookup?key=<YOUR_API_KEY>" 


An example of the answer and details can be found in the documentation: https://developers.google.com/civic-information/docs/us_v1/representatives/representativeInfoQuery

As an example, you can open an example on AppSpot - http://mapyourreps.appspot.com/
where if you enter any address, like this “1263 Pacific Ave. Kansas City KS ” , you can get a list of your favorites and their contacts.

This is how it looks.


Voting Information Project


And, of course, all this would have been impossible if a lot of activists in recent years had not created such projects as the Open Civic Data and the Voting Information Project .

Projects are made by numerous non-profit organizations such as the Sunlight Foundation, Open North, and others, and are supported by Facebook, Google, Microsoft, Foursquare, and other large information businesses.

It is worth noting that no one waits for officials to ripen to publish data in a convenient way, instead, the activists themselves analyze all the sites of election commissions and turn them into a convenient API. And large companies such as Google create their own services based on the data, which are also open to all.

And what about Russia?



Russia has signed the G8 charter, and we hope that the data of election campaigns will also be available from us. But personally, I think that one should not expect that they will be soon or will be very convenient. If public policy returns to our country, then we need the same initiatives as the Voting Information Project and Open Civic Data.

Source: https://habr.com/ru/post/203062/


All Articles