Date format for REST API

I want to encode the date format to send the date through my REST API request. I have sample response as
createDate=1449092965474
I don’t know which format it is. Kindly help me decoding this date format.

19 thoughts on “Date format for REST API”

  1. Dates written as numbers, specifies the number of milliseconds since January 1, 1970, 00:00:00. So if you convert it to normal date it will be Wed Dec 02 2015 16:49:25 GMT-0500 (Eastern Standard Time).

    Reply
  2. Server Side (C#)

    Before Sending the date from your API.

    Convert the date to a string.

    like this .

    string YourNewDateObj = YourDateObj.toString("yyyy-MM-dd HH:mm:ss");

    Client Side

    new Date(1449092965474)

    This is give you response.

    Reply

Leave a Comment