Everything seems to be working as expected with one exception, I am trying to save the timestamp of when the request was made and store that in a date/time field on the custom module.
I have tried to use the zoho.currenttime
function, which seemed to give me what I needed: ("14-Mar-2023 13:01:57"). This looks like a date/time field to me and I thought I could easily save this value into a date/time field on a record of a module.
Here is a more complete snippet for reference:
Request_Log.put("Send_Date_Time", zoho.currenttime);
Request_Record = zoho.crm.createRecord("Request_Log",Request_Log);
info Request_Record;
Which results in this error:
"{"code":"INVALID_DATA","details":{"expected_data_type":"datetime","api_name":"Send_Date_Time"},"message":"invalid data","status":"error"}"
And thus the "Request_Log" record is not created.
What am I missing here? How can I format the date time value from "zoho.currenttime" to allow my new record to be created?
Help is appreciated!