Browse Source

Expanded the Store

main
Julio Biason 2 years ago
parent
commit
95dc6fe224
  1. 1
      README.md
  2. 29
      design/email.md
  3. 37
      design/store.md

1
README.md

@ -22,3 +22,4 @@ Currently, I'm considering the following Capturers (based on my own life):
- [ ] [Netflix](design/netflix.md)
- [ ] [Deezer](design/deezer.md)
- [ ] [Calendar/CalDav](design/caldav.md)
- [ ] [Email](design/email.md)

29
design/email.md

@ -0,0 +1,29 @@
# Email Capturer
The Email capturer keeps listening to an IMAP and produces one entry for each
new email.
This can be used for creating random notes over the day.
## Configuration
The Capturer will require:
- IMAP address
- Username
- Password
**Note**: We may need to support IMAPS.
## Internals
Keep a list of email IDs in the database. Once we reach an ID that is already
there, we stop producing entries.
## Output
```
{{ email.content }}
```
Title is the email Subject field.

37
design/store.md

@ -6,8 +6,35 @@ functionality for Viewers.
We would probably need a design like:
- id: UUID of the record
- title: String, produced by a Capturer
- content: Text, produced by a Capturer, must always be Markdown (to avoid having a format that needs to be specially processed by some viewer)
- source: Name of the Capturer
- meta: HashMap, with some information the Capturer has about the entry
## Entry
| Field | Description |
| ------- | --------------------------------------------------- |
| id | UUID of the record. |
| title | String, produced by a Capturer. |
| content | Text, produced by a Capturer. It's always Markdown. |
| source | Capturer name. |
## Meta
Meta contains the meta information of the entry, used by a Capturer. A view may
or may not display those fields.
| Field | Description |
| ------- | --------------------------------------------------- |
| id | UUID of the record. |
| entry | ForeignKey of the entry. |
| name | Meta field name. |
| value | Meta field value. |
## Attachments
Attachments are not meta information, but something related to the entry -- for
example, if the content contains any images, those are added as attachments.
| Field | Description |
| ------------ | --------------------------------------------------- |
| id | UUID of the record. |
| entry | ForeignKey of the entry. |
| content_type | Type of the content. |
| content | Attachment content, in Base64. |

Loading…
Cancel
Save