list_drafts_config

package
v1.119.0 Latest Latest
Warning

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

Go to latest
Published: Nov 19, 2026 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	// Query narrows what is listed, in the same format as the Gmail search box.
	// Empty lists every draft.
	Query string
	// IncludeSpamTrash lists drafts in spam and trash too, which Gmail leaves out
	// otherwise.
	IncludeSpamTrash bool
	// MaxResults is how many are asked for per page. Zero takes Gmail's own
	// default, which is a hundred; the most it serves is five hundred.
	MaxResults int
	// PageToken asks for the page after the one that returned it.
	PageToken    string
	FetchOptions []fetch_config.Option
}

func New

func New(options ...Option) *Config

type Option

type Option func(*Config)

func WithFetchOptions

func WithFetchOptions(fetchOptions ...fetch_config.Option) Option

func WithIncludeSpamTrash

func WithIncludeSpamTrash(includeSpamTrash bool) Option

func WithMaxResults

func WithMaxResults(maxResults int) Option

func WithPageToken

func WithPageToken(pageToken string) Option

func WithQuery

func WithQuery(query string) Option

Jump to

Keyboard shortcuts

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