Skip to content

Library that helps bot developer to read disposable email

License

Notifications You must be signed in to change notification settings

grittyninja/trashpass

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Trashpass

PyPI version

Trashpass /ˈtɹɛspəs/ - Library that helps bot developer to read disposable email from Trash-Mail

Getting Started

Prerequisites

you need to install prequisites libraries in order to make trashpass run

pip install requests bs4

Installing

pip install trashpass

Testing

this test ensure that you are able to read inbox from dummy email

import trashpass

tr = trashpass.Trashpass()

""" set disposable email to mysecretinbox1337@trash-mail.com """

tr.target('mysecretinbox1337')
messages = tr.read()


""" set disposable email to myverysecretinbox1337@trash-mail.com """

tr.target('myverysecretinbox1337')
messages = tr.read()
# messages = {}


""" refresh inbox """

tr.refresh()
messages = tr.read()
# messages = {'2': {'from': 'dummysend@gmail.com', 'subject': 'Re: this is test box email', 'date': '23.12.2017 - 8:07 am', 'text': 'hallo  '}, '1': {'from': 'dummysend@gmail.com', 'subject': 'this is test box email', 'date': '23.12.2017 - 8:05 am', 'text': 'halo  '}}

"" get session """
session = tr.session
# session = {'PHPSESSID': 'g24hq61gv6d9gnckck316f65u6'}

Built With

Versioning

We use SemVer for versioning. For the versions available, see the 1.1.

Authors

  • Herdian Nugraha (hrdn)

License

This project is licensed under the MIT License - see the LICENSE.md file for details

Acknowledgments

  • Thanks to beautifulsoup team for making this project possible