mail

package
v0.0.0-...-e2e9b64 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 10, 2025 License: MIT Imports: 7 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CreateInput

type CreateInput struct {
	From    string   `json:"from"`
	To      []string `json:"to"`
	Cc      []string `json:"cc"`
	Subject string   `json:"subject"`
	Body    string   `json:"body"`
	HTML    bool     `json:"html"`
}

func (CreateInput) Validate

func (input CreateInput) Validate() error

type CreateOutput

type CreateOutput struct {
	ID        int32     `json:"id"`
	Status    string    `json:"status"`
	CreatedAt time.Time `json:"createdAt"`
}

type GetInput

type GetInput struct {
	ID int32 `param:"id"`
}

func (GetInput) Validate

func (input GetInput) Validate() error

type GetOutput

type GetOutput struct {
	ID        int32     `json:"id"`
	From      string    `json:"from"`
	To        []string  `json:"to"`
	Cc        []string  `json:"cc"`
	Subject   string    `json:"subject"`
	Body      string    `json:"body"`
	HTML      bool      `json:"html"`
	Status    string    `json:"status"`
	CreatedAt time.Time `json:"createdAt"`
	UpdatedAt time.Time `json:"updatedAt"`
	RetryAt   time.Time `json:"retryAt"`
	Try       int16     `json:"try"`
}

type Handler

type Handler interface {
	Create(c echo.Context) error
	Get(c echo.Context) error
}

func NewHandler

func NewHandler(repo db.Repository) Handler

type Service

type Service interface {
	Create(ctx context.Context, input CreateInput) (CreateOutput, error)
	Get(ctx context.Context, input GetInput) (GetOutput, error)
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL