Liking cljdoc? Tell your friends :D

mailseq.imap.connect

IMAP connection management.

Connect to an IMAP server and obtain a store that can be passed to functions in mailseq.imap.folder and mailseq.imap.fetch.

IMAP connection management.

Connect to an IMAP server and obtain a store that can be passed
to functions in `mailseq.imap.folder` and `mailseq.imap.fetch`.
raw docstring

connectclj

(connect
  {:keys [host port user password ssl oauth2-token] :or {ssl true} :as opts})

Connect to an IMAP server. Returns a map containing :store and :session.

Options: :host - IMAP server hostname (required) :port - port number (default: 993 for SSL, 143 otherwise) :user - username / email (required) :password - password (required) :ssl - use SSL (default: true) :starttls - use STARTTLS (default: false, ignored if :ssl is true). Connecting fails if the server does not offer it. :timeout - socket read timeout in ms (default: 30000) :connection-timeout - connection timeout in ms (default: 30000) :oauth2-token - authenticate with XOAUTH2 instead of password; Angus falls back to LOGIN if the server lacks AUTH=XOAUTH2. The token is fixed for the life of the connection: reconnect with a fresh one when it expires.

Example: (connect {:host "imap.example.com" :user "me@example.com" :password "secret"})

Connect to an IMAP server. Returns a map containing :store and :session.

Options:
  :host    - IMAP server hostname (required)
  :port    - port number (default: 993 for SSL, 143 otherwise)
  :user    - username / email (required)
  :password - password (required)
  :ssl     - use SSL (default: true)
  :starttls - use STARTTLS (default: false, ignored if :ssl is true).
              Connecting fails if the server does not offer it.
  :timeout  - socket read timeout in ms (default: 30000)
  :connection-timeout - connection timeout in ms (default: 30000)
  :oauth2-token - authenticate with XOAUTH2 instead of password; Angus
                  falls back to LOGIN if the server lacks AUTH=XOAUTH2.
                  The token is fixed for the life of the connection:
                  reconnect with a fresh one when it expires.

Example:
  (connect {:host "imap.example.com"
            :user "me@example.com"
            :password "secret"})
sourceraw docstring

connected?clj

(connected? {:keys [store]})

Returns true if the store is connected.

Returns true if the store is connected.
sourceraw docstring

disconnectclj

(disconnect {:keys [store]})

Disconnect from the IMAP server. Safe to call on already-closed connections.

Disconnect from the IMAP server. Safe to call on already-closed connections.
sourceraw docstring

cljdoc builds & hosts documentation for Clojure/Script libraries

Keyboard shortcuts
Ctrl+kJump to recent docs
←Move to previous article
→Move to next article
Ctrl+/Jump to the search field
× close