updating time() function to return timestamp as a string

return timestamp as a string to avoid 401 unauthorized error