     res.send "Processing time entries..."
     tags = ["Pagado"]
     action = "add"
-    end = moment()
-    start = end.subtract 1, "years"
+    end = moment().toISOString()
+    start = moment().subtract(1, "years").toISOString()
     user = robot.brain.userForName res.message.user.name
     encryptor = simpleEncryptor secret
     message = ""
     toggl = getClient encryptor.decrypt user.toggl.api_token
-    toggl.getTimeEntriesAsync(start.toISOString(), end.toISOString()).then (timeEntries) ->
+    toggl.getTimeEntriesAsync(start, end).then (timeEntries) ->
       process timeEntries, amount, price
     .then (data) ->
       message = "Ready#{data.difference}"

#
# Commands:
#   hubot toggl login <token> <password> - Login to Toggl
#   hubot toggl payment <amount> <price> <password> - Close time entries for the amount and price
#
# Author:
#   lgaticaq

    url: "http://indicadoresdeldia.cl/webservice/indicadores.json"
    json: true
    transform: (body) ->
      parseFloat body.indicador.uf.replace(/[$.]/g, "").replace(",", ".")
  rp options

process = (timeEntries, amount, price) ->
