Is there a method in Parse that would let me get the current time that is running on the server? I need to fetch the time from the server, and not depend on the local device's clock.
I'm using C#, Unity SDK. TIA!
Is there a method in Parse that would let me get the current time that is running on the server? I need to fetch the time from the server, and not depend on the local device's clock.
I'm using C#, Unity SDK. TIA!
You can create a cloud function, written in javascript, which will get the date and return it.
Parse.Cloud.define("getServerTime", function(request, response) {
var dateToday = new Date();
response.success(dateToday.toDateString());
});
You will likely want to do some specific formatting of the response so you can sensibly parse it on the client.