Datomic entity to case class to JSON