This n8n workflow is designed to convert Unix timestamps into ISO 8601 date strings via a webhook. It automates the process of receiving a timestamp, converting it into a human-readable date format, and returning the result as a webhook response. This workflow is useful for developers or systems that need to transform raw timestamp data into standardized date formats for logging, reporting, or integration purposes.
The workflow begins with a ‘Webhook Input’ node that listens for POST requests containing a JSON body with a ‘timestamp’ property. The ‘Convert to ISO 8601’ node retrieves this timestamp, multiplies it by 1000 (since Unix timestamps are in seconds and JavaScript Date requires milliseconds), and converts it into an ISO 8601 formatted string using JavaScript code within a ‘Set’ node. Finally, the ‘Respond with Converted Time’ node sends the formatted date back as the webhook response, completing the data transformation process.
This setup is particularly useful in scenarios where systems need to interact with timestamp data, such as synchronizing logs, creating time-based filters, or integrating with other APIs that require ISO date formats.
Reviews
There are no reviews yet.