fake-smtp/internal/model/email.go

28 lines
490 B
Go
Raw Normal View History

2020-04-17 17:53:01 +02:00
package model
import (
"net/mail"
"time"
)
type Email struct {
ID int `storm:"id,increment"`
HTML string
Text string
Headers map[string][]string
From []*mail.Address
To []*mail.Address
Cc []*mail.Address
Cci []*mail.Address
Subject string
SentAt time.Time
Attachments []*Attachment
Seen bool `storm:"index"`
}
type Attachment struct {
Name string
ContentType string
Data []byte
}