PHPackages                             temp-mail-io/temp-mail-php - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Mail &amp; Notifications](/categories/mail)
4. /
5. temp-mail-io/temp-mail-php

ActiveLibrary[Mail &amp; Notifications](/categories/mail)

temp-mail-io/temp-mail-php
==========================

0.2.1(1y ago)6113MITPHPPHP ~8.1.0 || ~8.2.0 || ~8.3.0 || ~8.4.0CI passing

Since Jan 18Pushed 1y ago2 watchersCompare

[ Source](https://github.com/temp-mail-io/temp-mail-php)[ Packagist](https://packagist.org/packages/temp-mail-io/temp-mail-php)[ RSS](/packages/temp-mail-io-temp-mail-php/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (3)Dependencies (8)Versions (5)Used By (0)

Temp Mail PHP Client
====================

[](#temp-mail-php-client)

[![Packagist Version](https://camo.githubusercontent.com/bbb6e11f384eae610ac56ca8bf7f8c9f0cff5d2bf0d14ac93bb724e069ebf2e5/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f74656d702d6d61696c2d696f2f74656d702d6d61696c2d706870)](https://camo.githubusercontent.com/bbb6e11f384eae610ac56ca8bf7f8c9f0cff5d2bf0d14ac93bb724e069ebf2e5/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f74656d702d6d61696c2d696f2f74656d702d6d61696c2d706870)[![PHP](https://github.com/temp-mail-io/temp-mail-php/actions/workflows/ci.yml/badge.svg)](https://github.com/temp-mail-io/temp-mail-php/actions)[![License: MIT](https://camo.githubusercontent.com/fdf2982b9f5d7489dcf44570e714e3a15fce6253e0cc6b5aa61a075aac2ff71b/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c6963656e73652d4d49542d79656c6c6f772e737667)](https://opensource.org/licenses/MIT)

The **official PHP Client** for [Temp Mail](https://temp-mail.io). This library provides developers a straightforward way to create and manage temporary email addresses, retrieve and delete messages, all via the Temp Mail API.

Table of Contents
-----------------

[](#table-of-contents)

- [Features](#features)
- [Installation](#installation)
- [Quick Start](#quick-start)
- [Usage Examples](#usage-examples)
    - [Listing Domains](#listing-domains)
    - [Getting Rate Limits](#getting-rate-limits)
    - [Creating Temporary Email](#creating-temporary-email)
    - [Fetching and Deleting Messages](#fetching-and-deleting-messages)
- [Testing](#testing)
- [Contributing](#contributing)
- [License](#license)
- [Support](#support)

Features
--------

[](#features)

- **Create** temporary email addresses with optional domain specifications
- **Get** current rate limits after API request
- **Delete** a temporary email along with all its messages
- **Retrieve** all messages for a specified email
- **Get** a specific message or download its attachment

Installation
------------

[](#installation)

To install this PHP package, run:

```
composer require temp-mail-io/temp-mail-php
```

Quick Start
-----------

[](#quick-start)

Below is a simple example to get started:

```
