Phone Your Rep - open source LiveView app for civic engagement

Hi forum,

Phone Your Rep is a LiveView app to enable civic engagement (currently U.S. specific). The user enters their address and the app returns a list of all of the offices, including small local district offices, for their elected representatives in Washington D.C. Having quick access to all of the local district offices for a legislator makes it easier for a citizen to amplify the power of their voice on the issues that they care about most. The vast majority of calls are routed to the capitol switchboard, creating bottlenecks and a small surface area for the voter’s influence.

PYR maintains its own geographic database of voting districts built from public census data, and can find the accurate district for a particular location without relying on external services. It also sorts the local offices by distance to the query point, so the more relevant data is at the top. Updates to legislator and office data are scheduled daily to prevent stale information (thanks to BEAM/OTP).

EDIT: You can copy and paste this address to test functionality
1375 E Buena Vista Dr, Orlando, FL 32830

Users can also download legislator contacts directly to their phone with vCard generation. Encoding contact info in QR Codes is planned for the future.

Also on the roadmap is an expansion of data to local representatives, and a GraphQL API. It would also be great to have collaboration on making this engine extendable to other governments and jurisdictions outside of the U.S.

This is an attempted rewrite of one of my first big projects years ago, originally written in Ruby on Rails. I’ve been working on this rewrite for a bit over a week. Thanks for checking this out, any feedback, contributions, code review, is all welcome!

2 Likes

Great initiative! The option to toggle Google autocompletion off is thoughtful. Hard to test the websites functionality any further as I don’t have a US address (and can’t grab the placeholder on mobile…which is fine of course)

I could check the menu, so I did. I was surprised that every link brought me to another website directly. From a user experience point of view I would recommend to make a change by:

  • making a page for every resource with a small description how it is related or why (reasons to open source for example) and on that page a link to the external resource

Or, less favorable but also less work: put a title above them ‘External resources’

All in all I really like the effort you put into it and the fact you published the code to share knowledge. Thanks!

1 Like

Thanks for the encouragement and feedback!

Google autocomplete is very convenient especially in that it can return geometry (lat, lon), which is what I need to query the database. I’d prefer not to use it at all for privacy, hence the toggle switch. But without it, I must unfortunately rely on valid fully qualified addresses to use the U.S. Census Bureau’s free geocoding service. Here is a valid address you can copy and paste if you want to test :slightly_smiling_face:

1375 E Buena Vista Dr, Orlando, FL 32830

Great suggestion, thank you! It was definitely a shortcut to just throw those links there with no context. I will work on improving that. At least the Privacy Policy is my own page :laughing:

2 Likes