A temporary email right from your terminal
`tmpmail` tmpmail is a command line utility that allows you to create a temporary email address
and receive emails to the temporary email address. It uses 1secmail's [API](https://www.1secmail.com/api/)
to receive the emails.
By default `w3m` is used to render the HTML emails on the terminal.
But if you prefer another text based web browser or would rather view the email in a GUI web browser such as Firefox, simply
use the `--browser` argument followed by the command needed to launch the web browser of your choice.
## Requirements
- `w3m`
- `curl`
- [`jq`](https://github.com/stedolan/jq)
## Usage
```console
$ tmpmail --help
usage: tmpmail [-h] [--generate] [--browser BROWSER] [--recent] [ID]
optional arguments:
-h, --help Show this help message
--version Print version
-g, --generate Generate a new email address
-r, --recent View the most recent mail
-b, --browser Change the browser that is used to render the HTML (default: w3m)
```
### Examples
View the inbox
```console
$ tmpmail
[ Inbox for wdebivbyjor@1secmail.com ]
83414443 username@example.com Test Email
```
View the email
```console
$ tmpmail 83414443
```
View the most recent email
```console
$ tmpmail -r
```
View emails as pure text
```console
$ tmpmail -t 83414443
To: wdebivbyjor@1secmail.com
From: username@example.com
Subject: Test Email
Hello World
```
## Credits
This script is heavily inspired by Mitch Weaver's [`1secmail`](https://github.com/mitchweaver/bin/blob/master/application/1secmail) script