This post will demonstrate a fast and easy way to get started with the Mailgun API in Android, using the Volley HTTP library.
This is well explained in the Android docs:
2. Creating & sending the request to Mailgun
In my use case, I have an app with a ‘Request Feature’ button that takes input from the the user: an email address and a message.
The POST request consists of header (authentication info), params (message data) and the URL (message post URL).
Sub out the Constants for your private Mailgun API key, mail domain name and recipient email. The available params can be found in the Mailgun docs.
Check the Logs in Mailgun for details of the request. If successful, email should be received to the recipient’s email: