mirror of
https://github.com/moparisthebest/mailcatcher
synced 2024-08-13 17:03:45 -04:00
Added Django usage instructions
This commit is contained in:
parent
16264a89ba
commit
091ae6d1fc
12
README.md
12
README.md
@ -63,6 +63,18 @@ You can do this in an [Apache htaccess file](http://php.net/manual/en/configurat
|
||||
|
||||
If you've installed via RVM this probably won't work unless you've manually added your RVM bin paths to your system environment's PATH. In that case, run `which catchmail` and put that path into the `sendmail_path` directive above instead of `/usr/bin/env catchmail`.
|
||||
|
||||
### Django
|
||||
|
||||
For use in Django, simply add the following configuration to your projects' settings.py
|
||||
|
||||
```python
|
||||
EMAIL_HOST = '127.0.0.1'
|
||||
EMAIL_HOST_USER = ''
|
||||
EMAIL_HOST_PASSWORD = ''
|
||||
EMAIL_PORT = 1025
|
||||
EMAIL_USE_TLS = False
|
||||
```
|
||||
|
||||
### API
|
||||
|
||||
A fairly RESTful URL schema means you can download a list of messages in JSON from `/messages`, each message's metadata with `/messages/:id.json`, and then the pertinent parts with `/messages/:id.html` and `/messages/:id.plain` for the default HTML and plain text version, `/messages/:id/:cid` for individual attachments by CID, or the whole message with `/messages/:id.source`.
|
||||
|
Loading…
Reference in New Issue
Block a user