 (defn resource->actions [schema resource]
   (->> (schema->resource-node schema resource)
        :links
-       (map :rel)
+       (map :title)
        sort))
 
 (defn schema->resources [schema]
   (->> (vals (:definitions schema))
-       (map :envelope)
+       (map :title)
        sort))
 
 (defn read-as-text [file c]

(defn schema->action-node [schema resource action]
  (let [action (->> (schema->resource-node schema resource)
                    :links
                    (filter #(= (:rel %) action))
                    first)]
    (update-in action [:example] format-example)))


(defn schema->resource-node [schema resource]
  (->> (:definitions schema)
       vals
       (filter #(= (:title %) resource))
       first))

(defn format-example [example]
