maildropy


Namemaildropy JSON
Version 1.0.0 PyPI version JSON
download
home_pageNone
SummaryA Python package to read emails from maildrop.cc
upload_time2024-05-02 08:46:03
maintainerNone
docs_urlNone
authorNone
requires_python>=3.10
licenseNone
keywords disposable mail maildrop python throwable
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # A Python package to read emails from maildrop.cc

__THIS IS STILL WIP__

This package provides a very simple class MailDropReader that mimics the graphql API of maildrop.cc.
You create a new reader with `MailDropReader(<your maildrop.cc inbox name>)
The methods are:
* __status()__: provides the current maildrop.cc status. Returns 'operational' or an error string from the server
* __ping(string)__: pings the maildrop.cc server with the given string. Returns 'pong <string>'
* __inbox()__: returns all messages of your inbox 
  Returns a list of messages with only basic fields filled.
  __(currently returns ALL messages, the filters aren't working)__. 
* __message(message_id)__: returns a full message including its body, its sender IP, ...
* __delete__(message_id)__: deletes a message by its id. Returns True if ok
* __statistics()__: returns maildrop.cc statistics. Returns a tuple (blocked, saved)
* __altinbox()__: returns an alias for your inbox. Subsequent MailDropReaders created with this alias will return messages from the original inbox

## Example:
```python
from maildropy import MailDropReader
reader = MailDropReader("my_own-inbox")

msgs = reader.inbox()
for msg in msgs:
  print(f"subject: {msg.subject}, from: {msg.mailfrom}, date:{msg.date}")
  message = reader.message(msg.id)
  print(f"content: {message.html}, ip={message.ip}, headerfrom={message.headerfrom}"
```

# Install
`pip install -r requirements.txt`

## Testing
To test the module, clone the repo, then copy `.env.example` in `.env` and provide the email sending settings.
These settings are used to send emails to maildrop.cc 
Then run `python test_maildrop.py`
            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "maildropy",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.10",
    "maintainer_email": null,
    "keywords": "disposable, mail, maildrop, python, throwable",
    "author": null,
    "author_email": "Olivier LEVILLAIN <levillain.olivier@gmail.com>",
    "download_url": "https://files.pythonhosted.org/packages/fb/ba/7e93b6a106f79eeaf4c15534196dd2f2eb89187e5c9a9ac433359be05bbc/maildropy-1.0.0.tar.gz",
    "platform": null,
    "description": "# A Python package to read emails from maildrop.cc\n\n__THIS IS STILL WIP__\n\nThis package provides a very simple class MailDropReader that mimics the graphql API of maildrop.cc.\nYou create a new reader with `MailDropReader(<your maildrop.cc inbox name>)\nThe methods are:\n* __status()__: provides the current maildrop.cc status. Returns 'operational' or an error string from the server\n* __ping(string)__: pings the maildrop.cc server with the given string. Returns 'pong <string>'\n* __inbox()__: returns all messages of your inbox \n  Returns a list of messages with only basic fields filled.\n  __(currently returns ALL messages, the filters aren't working)__. \n* __message(message_id)__: returns a full message including its body, its sender IP, ...\n* __delete__(message_id)__: deletes a message by its id. Returns True if ok\n* __statistics()__: returns maildrop.cc statistics. Returns a tuple (blocked, saved)\n* __altinbox()__: returns an alias for your inbox. Subsequent MailDropReaders created with this alias will return messages from the original inbox\n\n## Example:\n```python\nfrom maildropy import MailDropReader\nreader = MailDropReader(\"my_own-inbox\")\n\nmsgs = reader.inbox()\nfor msg in msgs:\n  print(f\"subject: {msg.subject}, from: {msg.mailfrom}, date:{msg.date}\")\n  message = reader.message(msg.id)\n  print(f\"content: {message.html}, ip={message.ip}, headerfrom={message.headerfrom}\"\n```\n\n# Install\n`pip install -r requirements.txt`\n\n## Testing\nTo test the module, clone the repo, then copy `.env.example` in `.env` and provide the email sending settings.\nThese settings are used to send emails to maildrop.cc \nThen run `python test_maildrop.py`",
    "bugtrack_url": null,
    "license": null,
    "summary": "A Python package to read emails from maildrop.cc",
    "version": "1.0.0",
    "project_urls": {
        "Download": "https://github.com/leolivier/maildropy/archive/refs/tags/1.0.0.tar.gz",
        "Homepage": "https://github.com/leolivier/maildropy",
        "Issues": "https://github.com/leolivier/maildropy/issues",
        "Repository": "https://github.com/leolivier/maildropy.git"
    },
    "split_keywords": [
        "disposable",
        " mail",
        " maildrop",
        " python",
        " throwable"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "8f27103e8a33f3f521761b374d11bafb0e32e2b666c4a71aab744878d80f3de1",
                "md5": "d2df9fd4acb263c79c65552362393a77",
                "sha256": "86ec65ab7ba926c3f632d8f428913721a7f5983f7788492a26d05ced2c3ce9f3"
            },
            "downloads": -1,
            "filename": "maildropy-1.0.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "d2df9fd4acb263c79c65552362393a77",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.10",
            "size": 4388,
            "upload_time": "2024-05-02T08:46:01",
            "upload_time_iso_8601": "2024-05-02T08:46:01.728389Z",
            "url": "https://files.pythonhosted.org/packages/8f/27/103e8a33f3f521761b374d11bafb0e32e2b666c4a71aab744878d80f3de1/maildropy-1.0.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "fbba7e93b6a106f79eeaf4c15534196dd2f2eb89187e5c9a9ac433359be05bbc",
                "md5": "59943c88e3e5436274a5bca7b87fea7f",
                "sha256": "aeed583ef201d5ba4dd10108de820677f73275d448d5f02501b605a4c686727c"
            },
            "downloads": -1,
            "filename": "maildropy-1.0.0.tar.gz",
            "has_sig": false,
            "md5_digest": "59943c88e3e5436274a5bca7b87fea7f",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.10",
            "size": 5495,
            "upload_time": "2024-05-02T08:46:03",
            "upload_time_iso_8601": "2024-05-02T08:46:03.761944Z",
            "url": "https://files.pythonhosted.org/packages/fb/ba/7e93b6a106f79eeaf4c15534196dd2f2eb89187e5c9a9ac433359be05bbc/maildropy-1.0.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-05-02 08:46:03",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "leolivier",
    "github_project": "maildropy",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "maildropy"
}
        
Elapsed time: 0.23568s