 
 (defn api-request
   "Returns a request map for a particular api call.
-  The change spotify playlist cover api call demands raw data in the :form-params call
+  The change spotify playlist cover api call demands raw data in the request body
   and content-type to be set to image/jpeg that's why we do the if statements below."
   [method endpoint query-params-spec m t]
   (let [url (replace-url-values m (str spotify-api-url endpoint))

                                       params))
        form-params (apply dissoc params (keys query-params))]
    (merge
      {:debug true
       :debug-body true
       :method method
       :url url
       :oauth-token t
       :content-type (if (:image form-params)

      ([m t]
       (response-to-map
         (try
           (client/request (api-request method endpoint merged-query-params m t))
           (catch Exception e (ex-data e))))))))

