 (def registered-user-sid
   {:sid {:user_authorization_type_sid {:user_authorization_type "REGISTERED"}}})
 
-(defn get-current-sids
+(defn- get-current-sids
   "Returns the groups the user who owns the token belongs to"
   [context token-id]
   (let [{:keys [username group_guids]} (get-token-or-error context token-id)]

            (map (fn [guid]
                   {:sid {:group_sid {:group_guid guid}}})
                 group_guids)))))

(defn build-routes [system]
  (routes

            ;; echo-rest returns status code 400 for request with expired token
            (ah/status-bad-request {:errors ["Token [expired-token] has expired."]})
            (ah/status-ok (get-current-sids context token-id))))
        (GET "/token_info" {context :request-context headers :headers}
          (get-token-info context headers token-id))))
    (GET "/availability" {context :request-context}
      {:status 200})))
