Extracting UID information from a URL and sending email to this user
You can solve your problem using Out of the box Webform Module. 


  Webform is the module for making surveys in Drupal. After a
  submission, users may be sent an e-mail "receipt" as well as sending a
  notification to administrators. Results can be exported into Excel or
  other spreadsheet applications. Webform also provides some basic
  statistical review and has and extensive API for expanding its
  features.



You can read uid value from URL .. Webform has support for tokens. You need to create a field to collect UID and configure default value.


For Example:
%get[key] - Tokens may be populated from the URL by creating URLs of the form http://example.com/my-form?foo=bar. Using the token %get[foo] would print "bar".


Your URL should be http://example.com/my-form?uid=value .. You will configure default value as %get[uid]
Webform has Email support out of the box.
You can see user submitted results in webform you created.
It automatically creates schema for you, and it has lot more features...