N8n: Project Estimation Workflow
    NB
    Rajasingh Selvakumar

    9 months ago

    N8n: Project Estimation Workflow

    #React.JS

    #Node.JS

    N8N local setup

    In this n8n setup we are going to use docker desktop for this entire video. This is my option to make the work easy to do all the steps in simple two commands. You can use npm to install n8n and run them locally; the option is yours.

    Docker Desktop setup

    To install the docker desktop on your windows, linux or mac machine visit this url docker desktop, and download the application once you install the application successfully please run this command to verify docker is installed successfully.

    docker --version
    

    Now you can see the docker version if you installed properly

    N8n docker setup

    Before you run the n8n command you have to create docker volume to store all the n8n persistent data. For your reference here I'm giving the n8n setup document

    Docker command to create volume

    docker volume create n8n_data
    

    Once the command executed successfully on your terminal to verify the volume use this command

    docker volume ls
    

    By running this command you are able to see the volume name n8n_data on the list.

    The run command is

    docker run -it --rm --name n8n -p 5678:5678 -v n8n_data:/home/node/.n8n docker.n8n.io/n8nio/n8n
    

    Explanation of each part:

    docker run

    • Start a new container from an image.

    -it

    • Interactive mode + TTY.
    • -i keeps STDIN open.
    • t allocates a terminal.

    Together, they let you interact with the container (useful for debugging or CLI access).

    --rm

    Automatically remove the container when it exits (keeps your system clean, no leftover stopped containers).

    --name n8n

    Assign the container a name: n8n.(Easier to reference instead of using the random container ID).

    -p 5678:5678

    Port mapping. Left (5678): host machine port. Right (5678): container port. This means you can access n8n at http://localhost:5678.

    -v n8n_data:/home/node/.n8n

    Volume mapping (persistent storage). n8n_data is a named Docker volume (stored on your host). /home/node/.n8n is the directory inside the container where n8n stores workflows, credentials, and settings. This ensures data is not lost when the container stops or is removed.

    docker.n8n.io/n8nio/n8n

    The Docker image to run (official n8n image hosted by n8n on their registry).

    This command starts n8n in Docker, makes it available on http://localhost:5678 , keeps workflows/credentials in a persistent volume called n8n_data, and cleans up the container automatically when stopped.

    Trigger Email IMAP

    I am using IMAP with the Email Trigger node to simplify the process so that anyone can run the workflow. In this example, I am demonstrating the configuration using GoDaddy IMAP settings to connect to the Email Trigger node.

    Enter the following Incoming Server details:

    • Username: Your email address
    • Password: Your email password
    • IMAP server: imap.secureserver.net
    • Security type: SSL
    • Port: 993

    Gemini generate api key

    1. Go to Google AI Studio.
    2. Once your account is set up, locate the Get API Key button at the top-right corner.
    3. Click the button and create a new API key.
    4. Copy the generated API key and store it securely on your machine for future use.


    Google Client ID and Client Secret Generation

    To create an API on Google, go to Google Cloud Console and either select an existing project or create a new one.

    • If you are creating a new project, provide a project name.
    • If you have an organization, select it; otherwise, leave it empty.
    • Click Create. (It may take a few minutes for the project to be created.)

    Once your project is created, select it from the project dropdown at the top left. Then:

    1. In the search bar, type API & Services and select it.
    2. Go to Library.
    3. Search for Google Drive API.
    4. Open it and click Enable.

    Creating OAuth Client ID

    After enabling the Google Drive API, go to the Credentials section:

    1. Click Create Credentials → OAuth client ID.
    2. You must first configure the OAuth consent screen:
    • App name: n8n-workflow
    • Select the User support email
    • Audience: Select External
    • Contact information: Enter your email address
    • Accept the terms and conditions, then click Create

    Setting up OAuth Client

    Now create the OAuth client:

    1. Application type: Select Web application
    2. Name: n8n-workflow-client
    3. Authorized redirect URIs:For local environments, use: http://localhost:5678/rest/oauth2-credential/callback. Add this URL under Authorized redirect URIs
    4. Click Create.

    Your Client ID and Client Secret will be generated. Copy and store them securely for use in your n8n workflow.

    Text classification

    To classify the email text for requirement here is the prompt

    Category - requirement

    Prompt -

    You are an AI classifier specialized in business and project management. Analyze the following text and classify it into ONE of these categories:
    
    *   **Feature Request:** A suggestion or demand for a new product feature or enhancement.
    *   **Bug Report:** A description of a malfunction, error, or flaw in an existing product.
    *   **General Inquiry:** A question about products, services, pricing, or capabilities that is not a specific feature request or bug.
    *   **Project Proposal:** A formal document outlining a new project's goals, scope, timeline, and budget.
    *   **Technical Requirement:** A detailed, specific specification for how a system should behave (e.g., "The system shall...").
    *   **Business Requirement:** A high-level statement of a business objective or need (e.g., "Increase user retention by 10%").
    *   **Unrelated:** The text is not a business or project requirement.
    

    For other category

    Category - others

    Prompt - other is not related to requirement

    AI Agent Project manager

    EstimateGPT is an AI Project Analyst designed to analyze software requirements and generate detailed estimation documents. It acts like a seasoned Senior Project Manager with 15+ years of experience in agile practices, risk assessment, and software delivery. The agent breaks projects into Epics, Tasks, and User Stories, estimating effort using Fibonacci-based Story Points mapped to 8-hour person-days. It always asks clarifying questions, considers non-functional requirements, and assigns confidence levels to each estimate. The output is delivered in structured, professional markdown and JSON formats, suitable for documentation and email sharing.

    User prompt-

    **ACTION: ANALYZE REQUIREMENTS AND GENERATE ESTIMATION DOCUMENT**
    
    **Objective:** Analyze the following requirements and generate a detailed estimation document based on our standard guidelines.
    
    **Requirements Content:**
    {{ $json.pageContent.join('\n\n\n', null, 2) }}
    

    System Prompt

    You are "EstimateGPT", an expert AI Project Analyst. Your sole purpose is to help users create accurate and realistic project estimations. Your core personality is that of a meticulous, experienced, and cautious Senior Project Manager with 15+ years of experience in software development, agile methodologies, and risk assessment.
    
    **Core Rules of Engagement:**
    1.  **Always** begin by summarizing the user's requirements to ensure mutual understanding.
    2.  **Always** ask insightful, clarifying questions to uncover hidden complexities, technical constraints, and assumptions before providing a final estimate. Never guess on ambiguous points.
    3.  **Always** break down projects into Epics and discrete, actionable Tasks/User Stories.
    4.  **Always** use Story Points based on the Fibonacci sequence (1, 2, 3, 5, 8, 13) for estimation. You will define 1 Story Point as equivalent to one standard 8-hour person-day of development effort.
    5.  **Always** provide a confidence level (High, Medium, Low) for each estimated task and justify low-confidence estimates.
    6.  **Always** structure your final output in a clean, professional markdown format. You are to output a complete estimation document.
    7.  **Never** provide a single lump-sum estimate without a detailed breakdown. You must be transparent in your calculation.
    8.  **Never** ignore non-functional requirements (e.g., security, scalability, performance) and potential risks.
    

    JSON schema for structured output

    {
      "type": "object",
      "properties": {
        "subject": {
          "type": "string",
          "description": "the email subject"
        },
        "content": {
          "type": "string",
          "description": "The estimation content content"
        },
        "htmlContent": {
          "type": "string",
          "description": "The HTML content to draft the estimation over email"
        }
      },
      "required": ["subject", "content", "htmlContent"]
    }
    

    Github project

    Please visit my github project to get the sample project documents and email templates. Visit here