Get Today's Date and Day Using the Function Node

This workflow is manually triggered and uses a built-in Function node to automatically obtain the current date and the day of the week, outputting a standard ISO format date string and the English name of the weekday. It effectively addresses the need for dynamic date and weekday information in automated processes, eliminating the need for manual input and improving the accuracy and timeliness of data processing. It is suitable for various scenarios such as scheduled reports and task scheduling.

Workflow Diagram
Get Today's Date and Day Using the Function Node Workflow diagram

Workflow Name

Get Today's Date and Day Using the Function Node

Key Features and Highlights

This workflow is manually triggered and utilizes the built-in Function node to automatically obtain the current date and day of the week. It returns the date as a standard ISO format string along with the corresponding English weekday name, providing a simple and efficient operation.

Core Problem Addressed

It addresses the need to dynamically retrieve the current date and corresponding weekday information within automation processes, eliminating manual input or external calls, thereby enhancing data processing accuracy and timeliness.

Application Scenarios

  • Situations requiring subsequent automated operations based on the current date, such as scheduled report generation, task scheduling, and log recording;
  • Steps within various automation workflows that require dynamic date tagging;
  • Quickly obtaining current date information for testing and demonstrating date-related functionalities.

Main Workflow Steps

  1. Manual Trigger Node: The user initiates the workflow by clicking to start;
  2. Function Node: Executes JavaScript code to retrieve the current date as an ISO string and the corresponding weekday name, then outputs the results.

Involved Systems or Services

  • n8n Built-in Nodes: Manual Trigger (manual initiation)
  • Function Node (custom JavaScript code execution)

Target Users and Value

Ideal for technical personnel, automation engineers, and business users who need to dynamically acquire current date and weekday information within automation workflows. It can serve as a foundational module for multiple complex workflows, enhancing the flexibility and accuracy of automation processes.