         (fmt-messages messages)))
 
 (defn fetch-unread-mail []
-  (let [messages (unread-messages folder)]
+  (let [messages (mail/unread-messages folder)]
     (when-not (empty? messages)
-      (mark-all-read folder)
+      (mail/mark-all-read folder)
       (fmt-you-have-mail messages))))
 
 (defn fetch-and-announce-unread-mail []

    [inflections.core :refer [pluralize]]
    [yetibot.core.config :refer [get-config]]
    [clojure-mail
     [core :refer :all]
     [message :as msg]]))

(def mail-schema


;; TODO - move into start
(when (configured?)
  (let [{:keys [user pass]} (:value (config))]
    (def store (mail/store user pass))))

(def pool (mk-pool))
(def poll-interval (* 1000 60))
