<commit_before>(ns akvo.lumen.endpoint.invite
  (:require [akvo.lumen.component.tenant-manager :refer [connection]]
            [akvo.lumen.component.user-manager :as user-manager]
            [compojure.core :refer :all]))


(defn endpoint [{:keys [tenant-manager user-manager]}]
  (context "/api/admin/invites" {:keys [jwt-claims params server-name tenant]}

    (let-routes [tenant-conn (connection tenant-manager tenant)]
      (GET "/" _
        (user-manager/invites user-manager tenant-conn))

      (POST "/" {{:strs [email]} :body}
        (println "@3")
        (user-manager/invite user-manager tenant-conn server-name email jwt-claims)))))

(defn verify-endpoint [{:keys [tenant-manager user-manager]}]
  (context "/verify" {:keys [tenant]}
    (let-routes [tenant-conn (connection tenant-manager tenant)]
      (GET "/:id" [id]
        (user-manager/verify-invite user-manager tenant-conn tenant id)))))<commit_msg>[#455] Remove print statement<commit_after>(ns akvo.lumen.endpoint.invite
  (:require [akvo.lumen.component.tenant-manager :refer [connection]]
            [akvo.lumen.component.user-manager :as user-manager]
            [compojure.core :refer :all]))


(defn endpoint [{:keys [tenant-manager user-manager]}]
  (context "/api/admin/invites" {:keys [jwt-claims params server-name tenant]}

    (let-routes [tenant-conn (connection tenant-manager tenant)]
      (GET "/" _
        (user-manager/invites user-manager tenant-conn))

      (POST "/" {{:strs [email]} :body}
        (user-manager/invite user-manager tenant-conn server-name email jwt-claims)))))

(defn verify-endpoint [{:keys [tenant-manager user-manager]}]
  (context "/verify" {:keys [tenant]}
    (let-routes [tenant-conn (connection tenant-manager tenant)]
      (GET "/:id" [id]
        (user-manager/verify-invite user-manager tenant-conn tenant id)))))
{'fraction_non_alphanumeric': 0.1611681990265008, 'fraction_numerical': 0.002163331530557058, 'mean_word_length': 3.468599033816425, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7237686', 'n_tokens_mistral': 590, 'n_tokens_neox': 588, 'n_words': 134}