# Messages

Send email two ways via our REST API:
1. Send emails using MIME format using a MIME building library
2. Submit the individual parts (Text, html, attachments, etc.)

Reminder: You can also send email via SMTP with Mailgun. Please reference the user manual.

 - [POST /v3/{domain_name}/messages](https://documentation.mailgun.com/docs/inboxready/api-reference/optimize/mailgun/messages/post-v3--domain-name--messages.md): Pass the components of the messages such as To, From, Subject, HTML, text parts, attachments, etc. Mailgun will build a MIME representation of the message and send it. In order to send you must provid
 - [POST /v3/{domain_name}/messages.mime](https://documentation.mailgun.com/docs/inboxready/api-reference/optimize/mailgun/messages/post-v3--domain-name--messages-mime.md): Build a MIME string yourself using a MIME library and submit it to Mailgun. Important: Send options (parameters starting with o:, h:, v:, or t:) are limited to 16KB total
 - [GET /v3/domains/{domain_name}/messages/{storage_key}](https://documentation.mailgun.com/docs/inboxready/api-reference/optimize/mailgun/messages/get-v3-domains--domain-name--messages--storage-key-.md): Event(s) created from sending an email with Mailgun will contain a `storage.key` to use to retrieve the email.
 - [POST /v3/domains/{domain_name}/messages/{storage_key}](https://documentation.mailgun.com/docs/inboxready/api-reference/optimize/mailgun/messages/post-v3-domains--domain-name--messages--storage-key-.md)
 - [GET /v3/domains/{name}/sending_queues](https://documentation.mailgun.com/docs/inboxready/api-reference/optimize/mailgun/messages/get-v3-domains--name--sending-queues.md): Provides default and scheduled message queue information.
 - [DELETE /v3/{domain_name}/envelopes](https://documentation.mailgun.com/docs/inboxready/api-reference/optimize/mailgun/messages/delete-v3--domain-name--envelopes.md): Deletes all scheduled and undelivered mail from the domain queue. This endpoint must be called on the same storage API host as the mail's generated storage URL. e.g. https://storage-us-east4.api.mai
