- Published on
How to get current time as unix timestamp in MacroDroid
- Authors
- Name
- Ashik Nesin
- @AshikNesin
MacroDroid is a super useful automation app for Android. With it, you can pretty much automate anything on your Android device.
Recently, I had a use case in which I had to send the current time as unix timestamp webhook.
Here's how I did it:
When assigning value for the variable, use the magic text.
If you want to get it in milliseconds, use the following expression.
{system_time_ms}
If you want to get it in seconds, use the following expression.
{system_time}
You can also choose it from the options in the UI as well.
Note: The system time will always be in UTC.
Happy getting time 🕒