modulepackage
2.0.0-beta.4
Repository: https://github.com/emersion/go-imap.git
Documentation: pkg.go.dev
# README
go-imap
An IMAP4rev2 library for Go.
Note This is the README for go-imap v2. This new major version is still in development. For go-imap v1, see the v1 branch.
Usage
To add go-imap to your project, run:
go get github.com/emersion/go-imap/v2
Documentation and examples for the module are available here:
License
MIT
# Packages
Package imapclient implements an IMAP client.
Package imapserver implements an IMAP server.
# Functions
AuthCap returns the capability name for an SASL authentication mechanism.
IsSearchRes checks whether a sequence set is a reference to the last SEARCH result.
NewRightsIdentifierUsername returns a rights identifier referring to a username, checking for reserved values.
SearchRes returns a special marker which can be used instead of a UIDSet to reference the last SEARCH result.
SeqSetNum returns a new SeqSet containing the specified sequence numbers.
UIDSetNum returns a new UIDSet containing the specified UIDs.
# Constants
RFC 4314.
RFC 7889.
Registered capabilities.
RFC 3516.
RFC 4469.
RFC 3348.
RFC 7162.
RFC 5259.
RFC 6154.
RFC 5161.
RFC 4731.
RFC 5267.
RFC 5466.
RFC 2971.
RFC 2177.
RFC 3501.
RFC 9051.
RFC 9585.
RFC 5255.
RFC 5258.
RFC 9590.
RFC 8440.
RFC 5819.
RFC 7888.
RFC 7888.
Registered capabilities.
RFC 2221.
RFC 2193.
RFC 5464.
RFC 5464.
RFC 6851.
RFC 3502.
RFC 7377.
RFC 2342.
RFC 5465.
RFC 8474.
RFC 8970.
RFC 7162.
RFC 9208.
RFC 9208.
RFC 8508.
RFC 4959.
RFC 8514.
RFC 6203.
RFC 5182.
RFC 5256.
RFC 5957.
RFC 6154.
Registered capabilities.
RFC 8438.
RFC 9586.
RFC 4315.
RFC 8437.
RFC 3691.
RFC 4467.
RFC 5550.
RFC 6855.
RFC 6855.
RFC 5032.
Widely used flags.
RFC 8457.
Message Disposition Notification sent.
System flags.
Permanent flags.
Role (aka.
RFC 8457.
Base attributes.
APPENDLIMIT.
METADATA.
perform SETACL.
CREATE new sub-mailboxes in any implementation-defined hierarchy.
STORE DELETED flag, perform EXPUNGE.
perform APPEND, COPY into mailbox.
mailbox is visible to LIST/LSUB commands.
send mail to submission address for mailbox, not enforced by IMAP4 itself.
SELECT the mailbox, perform CHECK, FETCH, PARTIAL, SEARCH, COPY from mailbox.
keep seen/unseen information across sessions (STORE SEEN flag).
RightsIdentifierAnyone is the universal identity (matches everyone).
STORE flags other than SEEN and DELETED.
# Variables
RightSetAll contains all standard rights.
# Structs
Address represents a sender or recipient of a message.
AppendData is the data returned by an APPEND command.
AppendOptions contains options for the APPEND command.
BodyStructureDisposition describes the content disposition of a part (specified in the Content-Disposition header field).
BodyStructureMessageRFC822 contains metadata specific to RFC 822 parts for BodyStructureSinglePart.
BodyStructureMultiPart is a body structure with multiple parts.
BodyStructureMultiPartExt contains extended body structure data for BodyStructureMultiPart.
BodyStructureSinglePart is a body structure with a single part.
BodyStructureSinglePartExt contains extended body structure data for BodyStructureSinglePart.
BodyStructureText contains metadata specific to text parts for BodyStructureSinglePart.
CopyData is the data returned by a COPY command.
CreateOptions contains options for the CREATE command.
Envelope is the envelope structure of a message.
FetchItemBinarySection is a FETCH BINARY[] data item.
FetchItemBinarySectionSize is a FETCH BINARY.SIZE[] data item.
FetchItemBodySection is a FETCH BODY[] data item.
FetchItemBodyStructure contains FETCH options for the body structure.
FetchOptions contains options for the FETCH command.
ListData is the mailbox data returned by a LIST command.
ListOptions contains options for the LIST command.
NamespaceData is the data returned by the NAMESPACE command.
NamespaceDescriptor describes a namespace.
SearchCriteria is a criteria for the SEARCH command.
SearchData is the data returned by a SEARCH command.
SearchOptions contains options for the SEARCH command.
SectionPartial describes a byte range when fetching a message's payload.
SelectData is the data returned by a SELECT command.
SelectOptions contains options for the SELECT or EXAMINE command.
SeqRange is a range of message sequence numbers.
StatusData is the data returned by a STATUS command.
StatusOptions contains options for the STATUS command.
StatusResponse is a generic status response.
StoreFlags alters message flags.
StoreOptions contains options for the STORE command.
UIDRange is a range of message UIDs.
# Interfaces
BodyStructure describes the body structure of a message.
LiteralReader is a reader for IMAP literals.
NumSet is a set of numbers identifying messages.
# Type aliases
BodyStructureWalkFunc is a function called for each body structure visited by BodyStructure.Walk.
Cap represents an IMAP capability.
CapSet is a set of capabilities.
ConnState describes the connection state.
Error is an IMAP error caused by a status response.
Flag is a message flag.
MailboxAttr is a mailbox attribute.
PartSpecifier describes whether to fetch a part's header, body, or both.
QuotaResourceType is a QUOTA resource type.
ResponseCode is a response code.
Right describes a set of operations controlled by the IMAP ACL extension.
RightModification indicates how to mutate a right set.
A RightSet is a set of rights.
RightsIdentifier is an ACL identifier.
SeqSet is a set of message sequence numbers.
StatusResponseType is a generic status response type.
StoreFlagsOp is a flag operation: set, add or delete.
ThreadAlgorithm is a threading algorithm.
UID is a message unique identifier.
UIDSet is a set of message UIDs.