Create Comment

Definition

This action allows you to programmatically add a new comment to a specific task within Asana. It is designed to post updates, notes, or feedback directly onto an Asana task as part of an automated workflow.

Key capabilities:

  • Select a specific Workspace, Project, and Task to target for the comment.
  • Define the content of the comment using static or dynamic text.
  • Choose whether to pin the comment to the top of the task's activity feed.

This action is valuable for automating communication and logging updates in Asana, ensuring that relevant information is captured directly on the associated task without manual intervention.


Inputs

  1. Connection
    • Purpose: This field establishes a secure and authenticated link to your Asana account, granting zenphi permission to create comments on your behalf.
    • Practical Guidance: You must select a pre-configured Asana connection or create a new one. This is a required first step before you can access your workspaces, projects, or tasks.
    • Use Case Context: You would use the 'Connection' field to authorize zenphi to interact with your specific Asana instance.
  2. Workspace
    • Purpose: This field specifies the Asana Workspace that contains the project and task you want to comment on.
    • Practical Guidance: After you establish a connection, zenphi will automatically populate a dropdown list of all available Workspaces in your Asana account for you to choose from.
    • Use Case Context: You would use the 'Workspace' field to narrow down the scope to the correct high-level organization or team area in Asana.
  3. Project
    • Purpose: This field allows you to select the specific project where the target task is located.
    • Practical Guidance: Once a Workspace is selected, this field will display a list of all projects within that workspace. You can select the project from this list.
    • Use Case Context: You would use the 'Project' field to ensure your comment is being added to a task within the correct initiative or department.
  4. Task Id
    • Purpose: This is the unique identifier for the specific task where the comment will be posted.
    • Practical Guidance: You can provide this ID in two ways. You can select it from the dropdown list that appears, which is useful for static workflows. More commonly, you will use a dynamic value from the token picker by using the ID from a previous action, such as a "Create Task" or "Find Task" step.
    • Use Case Context: You would use the 'Task Id' field to tell zenphi exactly which task the comment should be added to.
  5. Text
    • Purpose: This field is where you compose the actual content of the comment that will be posted to the Asana task.
    • Practical Guidance: You can type a static value (e.g., "Task completed.") which will be the same every time the flow runs. Alternatively, you can insert dynamic values from the token picker to create detailed, context-specific comments (e.g., "New lead assigned from: [Lead Email] with a value of [Lead Value]. Please follow up.").
    • Use Case Context: You would use the 'Text' field to provide updates, log information, or notify team members about an event related to the task.
  6. Pin to top
    • Purpose: This field allows you to choose whether the comment should be pinned, making it prominently visible at the top of the task's story feed.
    • Practical Guidance: This is a simple boolean (true/false) choice. Select "yes" to pin the comment or "no" to have it appear in the standard chronological feed.
    • Use Case Context: You would set 'Pin to top' to "yes" for critical updates or instructions that you want to ensure are not missed by anyone viewing the task.

Outputs

  1. Id
    • Data Description: This output provides the globally unique identifier (ID) for the comment that was just created in Asana.
    • Workflow Utility: This ID is essential for managing the comment in subsequent workflow steps. For example, you could pass this ID to an "Update Comment" action to edit its text or to a "Delete Comment" action to remove it later.
  2. Text
    • Data Description: This output contains the full text content of the comment that was successfully posted.
    • Workflow Utility: This is useful for logging and auditing purposes. You can pass this text to a "Log Message" action to keep a record of the flow's operations or use it in a notification step, such as sending an email or a Slack message that includes the exact comment text.
  3. Pin to top
    • Data Description: This output returns a boolean value (true or false) indicating whether the newly created comment was pinned to the top of the task.
    • Workflow Utility: This value can be used in conditional logic later in your flow. For instance, you could set up a condition that says, "If 'Pin to top' is true, then send a high-priority notification to the project manager."


Example Use Cases

  1. Log Automated Updates Automatically post a comment on a task when a related process is completed, such as "Invoice Paid" or "Document Signed."
  2. Centralize Communications Capture feedback from a Google Form or an email and add it as a comment to the relevant Asana task to keep all discussions in one place.
  3. Notify Stakeholders of Progress Add a summary comment to a parent task when a subtask is completed, keeping project managers informed without manual updates.
  4. Create Audit Trails Post comments to log significant events or approvals within a workflow, creating a clear and automated history on the Asana task itself.

Example

Scenario: A sales team uses a Google Form to submit details for new client projects. To ensure a smooth handoff to the project management team, you need to automatically create a task in Asana for the new project and then add a comment containing all the key client details submitted in the form.

Steps to Implement:

  1. Set Up the Trigger: Begin the zenphi Flow with a "Google Forms - New form response" trigger. Configure it to watch the "New Client Project" form.
  2. Create the Asana Task: Add an Asana "Create task" action. Use the client's name from the form submission as the task title and assign it to the appropriate project and team member. This action will output the Task Id needed for the next step.
  3. Configure the "Create comment" Action: Add the Asana "Create comment" action to your Flow with the following settings:
    • Connection: Select your pre-configured Asana connection.
    • Workspace: Choose the "Company Projects" workspace.
    • Project: Select the "New Client Kickoff" project.
    • Task Id: Use the token picker to select the Id output from the "Create task" action in the previous step.
    • Text: Compose a detailed comment using tokens from the Google Form trigger. For example: "New Project Details:\n- Client Contact: [Contact Name]\n- Email: [Contact Email]\n- Budget: [Project Budget]\n- Desired Deadline: [Deadline]"
    • Pin to top: Select "yes" to ensure these critical details are immediately visible on the task.
  4. Run the Flow: Save and publish the Flow. Now, every new form submission will trigger this automated process.

Outcome: This automation completely eliminates the need for manual data entry and communication between the sales and project management teams. All critical client information is instantly and accurately logged as a pinned comment on the corresponding Asana task, ensuring the project team has everything they need to start immediately and reducing the risk of human error.



Best Practices

  1. Use Dynamic Tokens for Rich Context: Avoid static text. Populate the comment Text field with dynamic tokens from previous steps (like a form submission or a database query) to provide detailed, context-specific information directly on the task.
  2. Pin Critical Information: Use the Pin to top option for essential updates, summaries, or instructions. This ensures the most important information is not lost in a long thread of comments and is immediately visible to anyone who opens the task.
  3. Store the Comment ID: If you might need to update or delete the comment later in the workflow, save the Id output from this action into a Flow variable. This allows you to reference the exact comment in subsequent steps for reliable management.
  4. Standardize Comment Formats: For recurring updates, establish a consistent format for your comments (e.g., using labels like "Update:", "Approval:", "Error:"). This makes the activity feed easier to scan and understand, improving clarity for the entire team.