https://github.com/osmn-byhn/mail-send-api
https://github.com/osmn-byhn/mail-send-api
docs mail mailsend mailsender project-completed
Last synced: 4 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/osmn-byhn/mail-send-api
- Owner: osmn-byhn
- License: mit
- Created: 2025-01-25T13:59:38.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-01-25T14:04:17.000Z (over 1 year ago)
- Last Synced: 2025-01-25T15:18:22.409Z (over 1 year ago)
- Topics: docs, mail, mailsend, mailsender, project-completed
- Language: HTML
- Homepage: https://mail-api.osmanbeyhan.com/
- Size: 41 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Send Email API
This API allows you to send emails using different email services like Gmail, Outlook, and Yandex. You can dynamically specify the email service, or if none is provided, it defaults to Gmail.
## API Endpoint
**URL:**
`https://mail-send-api2.onrender.com/send-email`
**Method:**
`POST`
## Request Body Parameters
| Parameter | Type | Description | Required |
|------------|---------|-----------------------------------------------------------------------------------------------------|----------|
| `email` | string | Your email address | Yes |
| `password` | string | Your email account's app password | Yes |
| `to` | string | Recipient's email address | Yes |
| `subject` | string | Subject of the email | Yes |
| `text` | string | Body of the email | Yes |
| `service` | string | (Optional) Email service provider (`gmail`, `outlook`, `yandex`). Defaults to `gmail` if not provided. | No |
## Example Usage
### Sending an Email with Gmail (Default)
```bash
curl -X POST https://mail-send-api2.onrender.com/send-email \
-H "Content-Type: application/json" \
-d '{
"email": "your-email@gmail.com",
"password": "your-gmail-app-password",
"to": "send-to-email@mail.com",
"subject": "Subject",
"text": "message text"
}'