When I retrieve the info, I'm getting date time string as below.
"last_seen": "2023-01-16 12:03:16",
I want to get "2023-01-12T05:19:25.000000Z" something like this. same like created_at.
I tried to cast the type to datetime in my model. but still getting the date time string.
@ajithlal You can try using the toIso8601String() method on the Carbon instance when you're updating the last_seen field. This will format the timestamp as an ISO-8601 string, which is the format that you're looking for.