Email tạm thời theo Domain
Tài liệu hướng dẫn sử dụng API của MailDomain. API này cho phép bạn tạo và quản lý email tạm thời theo domain một cách dễ dàng.
Base URL: https://mail.vokhactamdev.net/api
Lấy danh sách domain có sẵn.
{
"status": true,
"data": [
{
"domain": "example.com",
"date": "2024-03-20",
"expiry": "2025-03-20"
},
{
"domain": "example.net",
"date": "2024-03-20",
"expiry": "2025-03-20"
}
]
}
Tạo một email tạm thời mới.
| Parameter | Type | Required | Description |
|---|---|---|---|
| domain | string | Yes | Domain để tạo email |
{
"success": true,
"data": {
"email": "user123@example.com",
"expires_in": 3600
}
}
Kiểm tra email đã nhận.
| Parameter | Type | Required | Description |
|---|---|---|---|
| string | Yes | Email cần kiểm tra |
{
"success": true,
"data": {
"emails": [
{
"from": "sender@example.com",
"subject": "Test Email",
"date": "2024-03-20T10:30:00Z",
"content": "Hello World!"
}
]
}
}
Lấy thông tin về tình trạng hệ thống.
{
"cpu_percent": "0.00",
"ram_percent": "19.58"
}
// Tạo email mới
async function generateEmail() {
const response = await fetch('https://mail.vokhactamdev.net/api/generate-email?domain=example.com');
const data = await response.json();
console.log(data.data.email);
}
// Kiểm tra email
async function checkEmails() {
const response = await fetch('https://mail.vokhactamdev.net/api/check-emails?email=user123@example.com');
const data = await response.json();
console.log(data.data.emails);
}
// Lấy thông tin hệ thống
async function getSystemStats() {
const response = await fetch('https://mail.vokhactamdev.net/api/stats.php');
const data = await response.json();
console.log(`CPU: ${data.cpu_percent}%, RAM: ${data.ram_percent}%`);
}
import requests
# Tạo email mới
def generate_email():
response = requests.get('https://mail.vokhactamdev.net/api/generate-email',
params={'domain': 'example.com'})
data = response.json()
print(data['data']['email'])
# Kiểm tra email
def check_emails():
response = requests.get('https://mail.vokhactamdev.net/api/check-emails',
params={'email': 'user123@example.com'})
data = response.json()
print(data['data']['emails'])
# Lấy thông tin hệ thống
def get_system_stats():
response = requests.get('https://mail.vokhactamdev.net/api/stats.php')
data = response.json()
print(f"CPU: {data['cpu_percent']}%, RAM: {data['ram_percent']}%")