   :post! #(create-circle %)
   :new? true
   :handle-ok #(map (fn [id] (str (build-entry-url (get % :request) id)))
-                   (keys @circles))
+                   (keys @anchor-circle))
   :handle-created #(when (::create-failed %) 
                      (ring-response {:status 400 
                                      :body (::create-failed %)}))

  :allowed-methods [:get]
  :known-content-type? #(check-content-type % ["application/json"])
  :exists? (fn [_]
             (let [e (get @circles (url-decode id))]
               (if-not (nil? e)
                 {::circle e})))
  :available-media-types ["application/json"]

        [ring.util.codec :only [url-encode url-decode]])
  (:import java.net.URL))

(defonce anchor-circle (ref {}))

;;;; http://clojure-liberator.github.io/liberator/tutorial/all-together.html
;; convert the body to a reader. Useful for testing in the repl
