Convert.ToInt64(DateTime.Now.Subtract(new DateTime(1970, 1, 1)).TotalMilliseconds);
Use this code to get the timestamp usually 8 hours earlier than the actual time, we guess the reason may be new DateTime (1970,1,1) actually get is the return of Beijing, the value that is UTC + 8.
GMT is the standard time stamp to 8 hours, summary, time stamps are correct code is as follows
Convert.ToInt64(DateTime.UTCNow.Subtract(new DateTime(1970, 1, 1)).TotalMilliseconds);
Get the right time