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

# Using the Asana Action Templates

[Back to Actions Integrations](https://koreai.mintlify.site/ai-for-service/integrations/overview.md#actions)

Use prebuilt Asana action templates to auto-create dialog tasks.

**Prerequisites:** Configure [Asana](https://koreai.mintlify.site/ai-for-service/integrations/actions/configuring-the-asana-action) and [install templates](https://koreai.mintlify.site/ai-for-service/integrations/actions/configuring-the-asana-action#install-asana-action-templates) before proceeding.

Navigate to **Automation AI > Use Cases > Dialogs**, then click the auto-created dialog to open the canvas with entity nodes, service nodes, and message scripts.

***

## Supported Actions

| Action | Description | Method |
| - | - | - |
| Get a Task by ID | Retrieves a task by task ID | GET |
| Find Tasks Created By a User | Retrieves tasks created by a user | GET |
| Find Tasks Assigned to User | Retrieves tasks assigned to a user | GET |
| List All Projects | Returns all projects | POST |
| List All Users | Returns all users | POST |

***

## Get Task by ID

1. Install the template from [Asana Templates](https://koreai.mintlify.site/ai-for-service/integrations/actions/configuring-the-asana-action#install-asana-action-templates).

2. The **Get Task by Id** dialog task is added with:

   ![Dialog task added](https://mintcdn.com/koreai/7TeKpNFD7QJEMcMu/ai-for-service/integrations/actions/images/asana-action-img13.png?fit=max\&auto=format\&n=7TeKpNFD7QJEMcMu\&q=85\&s=a3a798ad95d5f031289f93c447e55aed)

   * **getTaskById** - User intent to fetch a task by ID.

   * **taskId** - Entity node for the task ID.

   * **getTaskByIdService** - Bot action service to fetch the task. Click **Edit Request** to modify parameters.

     ![Edit request](https://mintcdn.com/koreai/7TeKpNFD7QJEMcMu/ai-for-service/integrations/actions/images/asana_template-img5.png?fit=max\&auto=format\&n=7TeKpNFD7QJEMcMu\&q=85\&s=5b12d81d8978b5ba45a87d92a9ab275a)

     Click **+Add Response** to add sample responses:

     ![Add Response](https://mintcdn.com/koreai/7TeKpNFD7QJEMcMu/ai-for-service/integrations/actions/images/asana_template-img6.png?fit=max\&auto=format\&n=7TeKpNFD7QJEMcMu\&q=85\&s=bf3a73710f1cbb2f9e1c619f668449a1)

     **Sample Response:**

     ```json theme={null}
     {
       "data": {
         "gid": "1204307990977944",
         "assignee": { "gid": "1204191722074650", "name": "Alan Walker" },
         "created_at": "2023-03-31T11:11:44.658Z",
         "created_by": { "gid": "1204191722074650", "name": "Alan Walker" },
         "name": "NEW TASK",
         "notes": "The description",
         "permalink_url": "https://app.asana.com/0/1xx60369/1XXX944",
         "projects": [{ "gid": "1204191735460369", "name": "Int1" }],
         "workspace": { "gid": "21968248715756", "name": "xyz.com" }
       }
     }
     ```

   * **getTaskByIdMessage** - Message node to display the task result.

3. Click **Train** to complete training.

4. Click **Talk to Bot** to test.

5. Enter the task ID when prompted.

   ![Enter Task ID](https://mintcdn.com/koreai/7TeKpNFD7QJEMcMu/ai-for-service/integrations/actions/images/asana_template-img7.png?fit=max\&auto=format\&n=7TeKpNFD7QJEMcMu\&q=85\&s=7006e25b7b24f2f0cd845d9723448f0c)

6. The task is returned. Click **View Task** to open it in Asana.

   ![Task found with ID](https://mintcdn.com/koreai/7TeKpNFD7QJEMcMu/ai-for-service/integrations/actions/images/asana_template-img8.png?fit=max\&auto=format\&n=7TeKpNFD7QJEMcMu\&q=85\&s=13c63649ca9289dcac8a1d0cf94aabb8)

   ![View task](https://mintcdn.com/koreai/7TeKpNFD7QJEMcMu/ai-for-service/integrations/actions/images/asana_template-img9.png?fit=max\&auto=format\&n=7TeKpNFD7QJEMcMu\&q=85\&s=7549ba7c0ca16068a67fb85096ed86b0)

***

## Find Tasks Created by a User

1. Install the template from [Asana Templates](https://koreai.mintlify.site/ai-for-service/integrations/actions/configuring-the-asana-action#install-asana-action-templates).

2. The **Find Tasks Created by User** dialog task is added with:

   ![Dialog task](https://mintcdn.com/koreai/7TeKpNFD7QJEMcMu/ai-for-service/integrations/actions/images/asana-template-img10-find_tasks.png?fit=max\&auto=format\&n=7TeKpNFD7QJEMcMu\&q=85\&s=49404dbf693403408c1b9749c5dcfbb8)

   * **findTasksCreatedByUser** - User intent to retrieve tasks created by a user.

   * **workSpaceId** - Entity node for the workspace ID.

   * **userId** - Entity node for the user ID.

   * **findCreatedTasksService** - Bot action service to find created tasks. Click **+Add Response**:

     ![Bot action service](https://mintcdn.com/koreai/7TeKpNFD7QJEMcMu/ai-for-service/integrations/actions/images/asana-template-img11-find_tasks2.png?fit=max\&auto=format\&n=7TeKpNFD7QJEMcMu\&q=85\&s=26ddfb41b24d2a84a84ea34abfae516e)

     **Sample Response:**

     ```json theme={null}
     {
       "data": [
         {
           "gid": "1204325494675011",
           "assignee": { "gid": "12041917XXX0", "name": "Alan Walker" },
           "created_at": "2023-04-03T20:32:00.270Z",
           "name": "30Apr NEW TASK",
           "notes": "The description",
           "projects": [{ "gid": "1204191735460369", "name": "Int1" }],
           "workspace": { "gid": "21968248715756", "name": "xyz.com" }
         }
       ]
     }
     ```

   * **createdTaskMessage** - Message node to display results.

3. Click **Train**, then **Talk to Bot** to test.

4. Follow prompts to enter workspace ID and user ID.

   ![Find tasks with user ID](https://mintcdn.com/koreai/7TeKpNFD7QJEMcMu/ai-for-service/integrations/actions/images/asana-template-img12-find_tasks5.png?fit=max\&auto=format\&n=7TeKpNFD7QJEMcMu\&q=85\&s=801b4862c93b1ef2fd61ed69f87aea5c)

   ![Enter user ID](https://mintcdn.com/koreai/7TeKpNFD7QJEMcMu/ai-for-service/integrations/actions/images/asana-template-img13-find_tasks6.png?fit=max\&auto=format\&n=7TeKpNFD7QJEMcMu\&q=85\&s=57fce85f60743b709ea1a476e6548980)

5. Click **View Task** to open in Asana.

   ![View task](https://mintcdn.com/koreai/7TeKpNFD7QJEMcMu/ai-for-service/integrations/actions/images/asana_template-img14.png?fit=max\&auto=format\&n=7TeKpNFD7QJEMcMu\&q=85\&s=dfe358fa22ebf7631491635201a9b652)

***

## Find Tasks Assigned to a User

1. Install the template from [Asana Templates](https://koreai.mintlify.site/ai-for-service/integrations/actions/configuring-the-asana-action#install-asana-action-templates).

2. The **FindTasks Assigned to a User** dialog task is added with:

   ![Dialog task](https://mintcdn.com/koreai/7TeKpNFD7QJEMcMu/ai-for-service/integrations/actions/images/asana-template-img15-find_task_assigned.png?fit=max\&auto=format\&n=7TeKpNFD7QJEMcMu\&q=85\&s=77482dc79da1f90e6867093ef926e421)

   * **findTasksAssignedToUser** - User intent to retrieve tasks assigned to a user.

   * **workSpaceId** - Entity node for workspace ID.

   * **userId** - Entity node for user ID.

   * **findAssignedTasksService** - Bot action service to fetch assigned tasks. Click **+Add Response**:

     ![Bot action service](https://mintcdn.com/koreai/7TeKpNFD7QJEMcMu/ai-for-service/integrations/actions/images/asana-template-img16-find_task_assigned1.png?fit=max\&auto=format\&n=7TeKpNFD7QJEMcMu\&q=85\&s=97f9f0a2ffb22aea2576575ec15b962a)

     **Sample Response:**

     ```json theme={null}
     {
       "data": [
         {
           "gid": "1204325494675011",
           "assignee": { "gid": "1204191722074650", "name": "Alan Walker" },
           "name": "30Apr NEW TASK",
           "projects": [{ "gid": "1204191735460369", "name": "Int1" }],
           "workspace": { "gid": "21968248715756", "name": "xyz.com" }
         }
       ]
     }
     ```

   * **assignedTaskMessage** - Message node to display results.

3. Click **Train**, then **Talk to Bot** to test.

4. Follow prompts to find tasks.

   ![Find task](https://mintcdn.com/koreai/7TeKpNFD7QJEMcMu/ai-for-service/integrations/actions/images/asana-template-img17-find_task_assigned3.png?fit=max\&auto=format\&n=7TeKpNFD7QJEMcMu\&q=85\&s=07d8298d57811fd8fbd45a272049d2c5)

   ![Enter task ID](https://mintcdn.com/koreai/7TeKpNFD7QJEMcMu/ai-for-service/integrations/actions/images/asana-template-img18-find_task_assigned4.png?fit=max\&auto=format\&n=7TeKpNFD7QJEMcMu\&q=85\&s=09a7a26571e9775ff44d4a0950a25f19)

5. Click **View Task** to open in Asana.

***

## List All Projects

1. Install the template from [Asana Templates](https://koreai.mintlify.site/ai-for-service/integrations/actions/configuring-the-asana-action#install-asana-action-templates).

2. The **List All Projects** dialog task is added with:

   ![Dialog task](https://mintcdn.com/koreai/7TeKpNFD7QJEMcMu/ai-for-service/integrations/actions/images/asana-template-img19-list_all_projects.png?fit=max\&auto=format\&n=7TeKpNFD7QJEMcMu\&q=85\&s=1990d993d75a9630cd5fee2f77b9cf8f)

   * **listAllProjects** - User intent to retrieve all projects.

   * **listAllProjectsService** - Bot action service to retrieve all projects. Click **+Add Response**:

     ![Bot action service](https://mintcdn.com/koreai/7TeKpNFD7QJEMcMu/ai-for-service/integrations/actions/images/asana-template-img20-list_all_projects1.png?fit=max\&auto=format\&n=7TeKpNFD7QJEMcMu\&q=85\&s=66a9a72b4ecc9c2a002b30cd89b8254b)

     **Sample Response:**

     ```json theme={null}
     {
       "data": [
         {
           "gid": "1190334540433515",
           "name": "integration",
           "owner": { "gid": "1190337001098545", "name": "Alan" },
           "workspace": { "gid": "21968248715756", "name": "xyz.com" }
         }
       ]
     }
     ```

   * **listProjectMessage** - Message node to display results.

3. Click **Train**, then **Talk to Bot** to test.

4. Follow prompts to list projects.

   ![List projects prompt](https://mintcdn.com/koreai/7TeKpNFD7QJEMcMu/ai-for-service/integrations/actions/images/asana-template-img21-list_all_projects2.png?fit=max\&auto=format\&n=7TeKpNFD7QJEMcMu\&q=85\&s=1470ef12a6f0d4cabb75e96e13c67740)

5. Click **View Project** to open in Asana.

***

## List All Users

1. Install the template from [Asana Templates](https://koreai.mintlify.site/ai-for-service/integrations/actions/configuring-the-asana-action#install-asana-action-templates).

2. The **List All Users** dialog task is added with:

   ![Dialog task](https://mintcdn.com/koreai/7TeKpNFD7QJEMcMu/ai-for-service/integrations/actions/images/asana-template-img22list_all_users.png?fit=max\&auto=format\&n=7TeKpNFD7QJEMcMu\&q=85\&s=a28e161fcf9830d4a3544220fae65dbd)

   * **listAllUsers** - User intent to retrieve all users.

   * **listAllUsersService** - Bot action service to find all users. Click **+Add Response**:

     ![Bot action service](https://mintcdn.com/koreai/7TeKpNFD7QJEMcMu/ai-for-service/integrations/actions/images/asana-template-img23-list_all_users1.png?fit=max\&auto=format\&n=7TeKpNFD7QJEMcMu\&q=85\&s=523cf34726801ee9e4cbb388589a44cb)

     **Sample Response:**

     ```json theme={null}
     {
       "data": [
         {
           "gid": "11xxxx674034",
           "email": "alan.walker@xyz.com",
           "name": "Alan Walker",
           "workspaces": [{ "gid": "219xxx756", "name": "xyz.com" }]
         }
       ]
     }
     ```

   * **listAllUsersMessage** - Message node to display results.

3. Click **Train**, then **Talk to Bot** to test.

4. Follow prompts to list users.

   ![List users prompt](https://mintcdn.com/koreai/7TeKpNFD7QJEMcMu/ai-for-service/integrations/actions/images/asana-template-img24-list_all_users2.png?fit=max\&auto=format\&n=7TeKpNFD7QJEMcMu\&q=85\&s=4074cb614c7bca47c6433b436990bf64)

5. Click **View User** to open in Asana.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.