API Documentation

Integrate the Temporary Mail service into your application quickly. Use the endpoints below to manage virtual mailboxes.

Base URL Production

https://services.my-playground.space
Get

Generate Address

Create a new temporary email address with a unique domain @my-playground.space.

/api/v1/temp-mail/generate
{
  "address": "a1b2c3d4@my-playground.space"
}
Get

Get Inbox

Retrieve a list of email summaries incoming to a specific mailbox.

/api/v1/temp-mail/inbox/{address}
[
  {
    "id": "1",
    "from": "sender@example.com",
    "subject": "Hello World",
    "date": "2026-01-11T05:41:37Z",
    "seen": false
  }
]
Get

Read Message

Retrieve complete message content including format Text dan HTML based on message ID.

/api/v1/temp-mail/message/{address}/{id}
{
  "id": "1",
  "from": "sender@example.com",
  "subject": "Hello World",
  "body": {
    "text": "Konten teks biasa...",
    "html": "<div>Konten HTML...</div>"
  },
  "attachments": [
    {
      "filename": "image.png",
      "content-type": "image/png",
      "download-link": "https://services.my-playground.space/serve/..../image.png",
      "view-link": "https://services.my-playground.space/serve/..../image.png",
      "md5": "cd3a764f7c846c0..."
    }
  ]
}
Delete

Delete Message

Permanently delete a specific email from the server.

/api/v1/temp-mail/message/{address}/{id}
{
  "message": "Email deleted successfully"
}

File Handling

Each attachment file includes a download-link. Through this link, you can access the raw file directly. If the file is an image, use view-link for rendering thumbnails or gallery.

  • Download link → Download link available to get the raw file secara langsung.
  • View link (image) → If the file is an image, a view link is available for menampilkan thumbnail atau galeri pratinjau.
  • Keamanan akses → Semua file dilayani melalui koneksi HTTPS sehingga tetap safe when accessed.
  • Header Content-Type → File dikirim dengan Content-Type sesuai format aslinya, memastikan aplikasi dapat mengenali file dengan benar.

Quick Start

Terminal — cURL
# Generate email address
curl https://services.my-playground.space/api/v1/temp-mail/generate