 #   None
 #
 # Commands:
-#   hubot hello - <what the respond trigger does>
+#   hubot list - Returns available meme templates from Memegen.link and their respective URLs (keys)
+#   hubot <template> --top <text> --bottom <text> - Creates a <template> meme using <text> and returns links to it
 #
 # Notes:
 #   None

        bottomText = _spaceToHyphen(res.match[3])

        GetMGResult res, "/#{template}/#{topText}/#{bottomText}", null, (obj) ->
            res.send "Visible: #{obj.direct.visible}"
            res.send "Masked: #{obj.direct.masked}"

_spaceToHyphen = (str) ->
    str.replace(/\s+/g, '-').toLowerCase()

    res.http("#{MEMEGEN_API_URL}#{api}")
        .query(params)
        .get() (err, httpRes, body) ->
            # TODO: Improve error handling
            if err or (httpRes.statusCode isnt 200 and httpRes.statusCode isnt 302)
                res.reply "I'm unable to process your request at this time due to a server error. Please try again later."
                return res.robot.logger.error "hubot-memegen: #{body} (#{err})"

            handler JSON.parse(body)