> ## Documentation Index
> Fetch the complete documentation index at: https://docs.automate.ax/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> Automate.ax automations are TypeScript programs.
> Use Bun for installation and command examples.
> Use Automate.ax for the product name and automate.ax for the package, CLI, and domain.
> Treat documented public APIs as current; do not invent transitional or deprecated names.

# Add task comment

> Add a plain-text or rich-text comment to an Asana task.

`addTaskComment` posts one comment and can pin it to the top of task activity.

```ts automations/comment-on-asana-task.automation.ts theme={null}
import { automation, onHttpRequest } from "automate.ax"
import { addTaskComment } from "automate.ax/asana"

export default automation("Comment on Asana task", () => {
  onHttpRequest({ scope: "automation" })
  addTaskComment({
    taskId: "task-gid",
    text: "Ready for review.",
    isPinned: true,
  })
})
```

`taskId` is required. Provide exactly one of non-empty `text` or `htmlText`; `htmlText` must use Asana-supported rich-text HTML. Optional `isPinned` controls pinning, and `account` defaults to the project binding.

Returns the created `AsanaStory`. Keep its `id` for updates or deletion.
