A few months back, I coded a custom solution for another community member that did something similar.
The client had a list of agents. Once a visitor entered their own zip code, I used the zipcodeapi to do a calculation as to which is the nearest agent. Once it's calculated, a hidden field gets filled with the agent's email address.
After that, based on the hidden field the client had another webhook/script that would route the lead to the appropriate email address.
Gary's solution seems like a well thought out implementation and if you are using a CRM might be worth exploring as it would give you more flexibility in the future.
Last but not least, you might want to look into Zapier as a quick fix.