Asana
Overview
The Asana connector enables your AI Colleagues to integrate with your organization's Asana platform, facilitating automated task management, project tracking, and workflow automation.
Asana is a work management and collaboration platform that helps teams organize, track, and manage their work. The Asana connector allows Leena AI to automate task workflows, manage projects, and interact with Asana seamlessly.
API Details
Leena AI integrates with Asana via REST APIs.
Documentation link: https://developers.asana.com/reference/rest-api-reference
Setup
The Asana connector supports two authentication methods:
- OAuth 2.0 authentication with the authorization code grant type (recommended for multi-user apps)
- Personal Access Token (PAT) authentication (recommended for scripts and simple integrations)
Prerequisites
Before setting up the Asana connector, ensure you have:
- An Asana account with appropriate permissions
- Access to the Asana Developer Console (https://app.asana.com/0/my-apps)
- Ability to create OAuth applications or generate Personal Access Tokens in Asana
- Access to your Leena AI workspace with connector management permissions
Get credentials
Option 1: OAuth 2.0 (Recommended for Multi-User Apps)
Here is how to create an OAuth application in Asana Developer Console:
- Log in to the Asana Developer Console at https://app.asana.com/0/my-apps
- Click on Create new app
- Enter the App Details:
- App name: Enter a descriptive name for your application (e.g., "Leena AI Integration")
- Purpose: Select the appropriate use case for your app
- Click Create app
- Configure OAuth Settings:
- Navigate to OAuth in the left sidebar
- Click + Add redirect URL
- Add the Redirect URL from Leena AI (This will be filled later from Leena AI)
- Click Add
- Configure Permission Scopes:
- Under OAuth > Permission scopes, select the required scopes:
tasks:read- Read access to taskstasks:write- Write access to tasksprojects:read- Read access to projectsprojects:write- Write access to projects- Or toggle Full permissions for access to all endpoints
- Save the changes
- Under OAuth > Permission scopes, select the required scopes:
- Note Your Credentials:
- Client ID: Found in the OAuth section
- Client Secret: Found in the OAuth section (keep this secure)
- Configure Distribution:
- Navigate to Manage distribution in the left sidebar
- Choose distribution method based on your requirements:
- Specific workspaces: Limit access to specific Asana workspaces
- Any workspace: Allow any user to authorize the app
Option 2: Personal Access Token (PAT)
Here is how to create a Personal Access Token in Asana:
- Log in to the Asana Developer Console at https://app.asana.com/0/my-apps
- Navigate to Personal access tokens section
- Click + Create new token
- Enter a Token name (e.g., "Leena AI Integration")
- Check the box to agree to the Asana API terms
- Click Create token
- Copy the token immediately (it will only be shown once)
- Store the token securely
Add connection
Here is how to add a connection on Leena AI:
For OAuth 2.0 Authentication:
- Log in to your Leena AI workspace
- Navigate to Settings > Integrations
- Search for "Asana" and select it from the list to add its new connector
- Start configuring the connector:
- Client ID: OAuth application client ID from Asana
- Client Secret: OAuth application client secret from Asana
- Scope: List of permissions required to perform actions through Leena AI (Pre-filled with default scopes)
- Grant Type: Authorization grant type for OAuth 2.0 (Pre-filled as 'authorization_code')
- Authorization URL: https://app.asana.com/-/oauth_authorize
- Token URL: https://app.asana.com/-/oauth_token
- ID Mapping Fields: The profile field in Leena AI, which corresponds to unique identifier in Asana (Pre-filled with 'email')
- Redirect URL: The callback URL for OAuth flow (Auto-generated by Leena AI)
- Complete OAuth Flow and Save Configurations:
- Click Connect in Leena AI for Asana connector setup
- You'll be redirected to Asana authorization page
- Sign in to your Asana account if prompted
- Click Allow to grant permissions
- You'll be redirected back to Leena AI with a successful connection
- The connector will be saved
- Copy Callback URL and Update Asana OAuth App:
- Once the connector is saved in Leena AI, you can reopen the connector to view the Callback URL
- Copy the Callback URL from Leena AI
- Go back to Asana Developer Console > Your App > OAuth
- Add the Callback URL to redirect URLs
- Save the changes
For Personal Access Token Authentication:
- Log in to your Leena AI workspace
- Navigate to Settings > Integrations
- Search for "Asana" and select it from the list to add its new connector
- Start configuring the connector:
- Personal Access Token: The PAT generated from Asana Developer Console
- ID Mapping Fields: The profile field in Leena AI, which corresponds to unique identifier in Asana (Pre-filled with 'email')
- Save the configuration
Actions
The following actions are supported for the Asana connector:
Create Task
Creates a new task in Asana. The Agent can leverage the skill (workflow), which has been designed to create a new task in Asana, once the user raises a query to do so.
Input Parameters
Here are the input parameters required to set up this action:
Mandatory
| Name | Description |
|---|---|
| Workspace GID | The globally unique identifier of the workspace where the task will be created |
| Name | The name/title of the task |
Optional
| Name | Description |
|---|---|
| Projects | Array of project GIDs to add the task to |
| Assignee | The GID of the user to assign the task to, or "me" for the authenticated user |
| Due On | The date on which the task is due (format: YYYY-MM-DD) |
| Due At | The date and time on which the task is due (ISO 8601 format) |
| Notes | Free-form text description of the task |
| HTML Notes | HTML-formatted description of the task |
| Start On | The date on which work begins for the task (format: YYYY-MM-DD) |
| Start At | The date and time on which work begins (ISO 8601 format) |
| Tags | Array of tag GIDs to add to the task |
| Followers | Array of user GIDs to add as followers |
| Parent | The GID of the parent task (for creating subtasks) |
| Custom Fields | Object containing custom field values |
Here is a sample JSON input:
{
"data": {
"workspace": "12345678901234",
"name": "Complete quarterly report",
"projects": ["98765432109876"],
"assignee": "me",
"due_on": "2025-09-15",
"notes": "Compile and review all department submissions for the Q3 report",
"followers": ["11111111111111", "22222222222222"],
"tags": ["33333333333333"]
}
}Response
Upon successful creation, the action returns the created task details including:
- Task GID
- Task name
- Assignee information
- Project associations
- Due date
- Created timestamp
- Permalink URL
Get Task
Retrieves the details of a specific task from Asana. The Agent can leverage the skill (workflow) to fetch task information when a user requests details about a specific task.
Input Parameters
Here are the input parameters required to set up this action:
Mandatory
| Name | Description |
|---|---|
| Task GID | The globally unique identifier of the task to retrieve |
Optional
| Name | Description |
|---|---|
| Opt Fields | Comma-separated list of optional fields to include in the response |
Here is a sample JSON input:
{
"task_gid": "12345678901234",
"opt_fields": "name,assignee,due_on,notes,projects,tags,completed,custom_fields"
}Response
The action returns the task details including:
- Task GID
- Task name
- Resource type
- Assignee details
- Due date
- Notes/description
- Completion status
- Project associations
- Tags
- Custom field values
- Followers
- Created and modified timestamps
Update Task
Updates an existing task in Asana. The Agent can leverage the skill (workflow), which has been designed to modify an existing task in Asana, once the user provides the task details to be updated.
Input Parameters
Here are the input parameters required to set up this action:
Mandatory
| Name | Description |
|---|---|
| Task GID | The globally unique identifier of the task to update |
Optional
| Name | Description |
|---|---|
| Name | The updated name/title of the task |
| Assignee | The GID of the user to assign the task to |
| Due On | The updated due date (format: YYYY-MM-DD) |
| Due At | The updated due date and time (ISO 8601 format) |
| Notes | Updated free-form text description |
| HTML Notes | Updated HTML-formatted description |
| Completed | Boolean to mark the task as complete or incomplete |
| Start On | Updated start date (format: YYYY-MM-DD) |
| Custom Fields | Object containing updated custom field values |
Here is a sample JSON input:
{
"task_gid": "12345678901234",
"data": {
"name": "Complete quarterly report - Updated",
"due_on": "2025-09-20",
"assignee": "98765432109876",
"notes": "Updated: Include additional data from marketing department",
"completed": false
}
}Response
Upon successful update, the action returns the updated task details including:
- Updated task properties
- Task GID
- Modification timestamp
- Permalink URL
Delete Task
Deletes an existing task from Asana. The Agent can leverage the skill (workflow), which has been designed to remove a task from Asana, once the user specifies the task to be deleted.
Input Parameters
Here are the input parameters required to set up this action:
Mandatory
| Name | Description |
|---|---|
| Task GID | The globally unique identifier of the task to delete |
Here is a sample JSON input:
{
"task_gid": "12345678901234"
}Response
Upon successful deletion, the action returns:
- Confirmation of successful deletion (empty data object)
- HTTP status 200
List Tasks
Retrieves a list of tasks from Asana based on specified filters. This action can be leveraged by Leena AI Orchestrator/Agent to list tasks from a project, section, or user's task list.
Input Parameters
Here are the input parameters required to set up this action:
Optional (at least one filter required)
| Name | Description |
|---|---|
| Project GID | The project GID to retrieve tasks from |
| Section GID | The section GID to retrieve tasks from |
| Assignee | The user GID or "me" to filter tasks by assignee |
| Workspace GID | The workspace GID (required when using assignee filter) |
| Completed Since | Only return tasks completed since this time (ISO 8601 format) |
| Modified Since | Only return tasks modified since this time (ISO 8601 format) |
| Opt Fields | Comma-separated list of optional fields to include |
| Limit | Maximum number of results to return (1-100) |
Here is a sample JSON input:
{
"project": "98765432109876",
"opt_fields": "name,assignee,due_on,completed,tags",
"limit": 50
}Response
The action returns a list of tasks, each containing:
- Task GID
- Task name
- Resource type
- Assignee information
- Due date
- Completion status
- Additional requested fields
Search Tasks
Searches for tasks in a workspace based on specified criteria. This action enables finding tasks by text, assignee, projects, tags, and other attributes.
Input Parameters
Here are the input parameters required to set up this action:
Mandatory
| Name | Description |
|---|---|
| Workspace GID | The workspace GID to search within |
Optional
| Name | Description |
|---|---|
| Text | Text to search for in task names and descriptions |
| Projects.any | Comma-separated project GIDs to search within |
| Assignee.any | Comma-separated user GIDs to filter by assignee |
| Tags.any | Comma-separated tag GIDs to filter by tags |
| Completed | Boolean to filter by completion status |
| Due On | Filter by specific due date |
| Due On.before | Filter for tasks due before this date |
| Due On.after | Filter for tasks due after this date |
| Sort By | Field to sort by (due_date, created_at, modified_at, likes, etc.) |
| Sort Ascending | Boolean for sort direction |
Here is a sample JSON input:
{
"workspace": "12345678901234",
"text": "quarterly report",
"assignee.any": "98765432109876",
"completed": false,
"due_on.before": "2025-09-30",
"sort_by": "due_date",
"sort_ascending": true
}Response
The action returns a list of matching tasks with:
- Task GID
- Task name
- Assignee details
- Due date
- Project associations
- Completion status
Create Project
Creates a new project in Asana. The Agent can leverage the skill (workflow) to create a new project when a user requests to set up a new project.
Input Parameters
Here are the input parameters required to set up this action:
Mandatory
| Name | Description |
|---|---|
| Workspace GID | The workspace GID where the project will be created (required if team is not specified) |
| Name | The name of the project |
Optional
| Name | Description |
|---|---|
| Team GID | The team GID to create the project in (for organization workspaces) |
| Notes | Free-form text description of the project |
| HTML Notes | HTML-formatted description of the project |
| Color | The color of the project (dark-pink, dark-green, dark-blue, dark-red, dark-teal, dark-brown, dark-orange, dark-purple, dark-warm-gray, light-pink, light-green, light-blue, light-red, light-teal, light-brown, light-orange, light-purple, light-warm-gray, none) |
| Due On | The date on which the project is due (format: YYYY-MM-DD) |
| Start On | The date on which work begins (format: YYYY-MM-DD) |
| Default View | The default view of the project (list, board, calendar, timeline) |
| Public | Boolean to set project visibility |
| Followers | Array of user GIDs to add as followers |
Here is a sample JSON input:
{
"data": {
"workspace": "12345678901234",
"name": "Q4 Marketing Campaign",
"notes": "Marketing campaign planning and execution for Q4 2025",
"color": "light-blue",
"due_on": "2025-12-31",
"default_view": "board",
"public": true
}
}Response
Upon successful creation, the action returns the created project details including:
- Project GID
- Project name
- Workspace information
- Team information (if applicable)
- Color
- Due date
- Permalink URL
- Created timestamp
Get Project
Retrieves the details of a specific project from Asana.
Input Parameters
Here are the input parameters required to set up this action:
Mandatory
| Name | Description |
|---|---|
| Project GID | The globally unique identifier of the project to retrieve |
Optional
| Name | Description |
|---|---|
| Opt Fields | Comma-separated list of optional fields to include in the response |
Here is a sample JSON input:
{
"project_gid": "98765432109876",
"opt_fields": "name,notes,owner,team,due_on,members,custom_fields"
}Response
The action returns the project details including:
- Project GID
- Project name
- Notes/description
- Owner details
- Team information
- Due date
- Members list
- Custom field values
- Created and modified timestamps
Add Comment to Task
Creates a comment (story) on a task in Asana. The Agent can leverage this action to add updates or notes to existing tasks.
Input Parameters
Here are the input parameters required to set up this action:
Mandatory
| Name | Description |
|---|---|
| Task GID | The globally unique identifier of the task to comment on |
| Text | The plain text content of the comment |
Optional
| Name | Description |
|---|---|
| HTML Text | The HTML-formatted content of the comment |
| Is Pinned | Boolean to pin the comment to the top |
Here is a sample JSON input:
{
"task_gid": "12345678901234",
"data": {
"text": "Updated the report with the latest sales figures. Ready for review."
}
}Response
Upon successful creation, the action returns the created comment details including:
- Story GID
- Created timestamp
- Created by (user details)
- Text content
- Resource type
- Target task information
Update Project
Updates an existing project in Asana.
Input Parameters
Here are the input parameters required to set up this action:
Mandatory
| Name | Description |
|---|---|
| Project GID | The globally unique identifier of the project to update |
Optional
| Name | Description |
|---|---|
| Name | The updated name of the project |
| Notes | Updated free-form text description |
| HTML Notes | Updated HTML-formatted description |
| Color | Updated color of the project |
| Due On | Updated due date (format: YYYY-MM-DD) |
| Start On | Updated start date (format: YYYY-MM-DD) |
| Archived | Boolean to archive or unarchive the project |
| Public | Boolean to update project visibility |
Here is a sample JSON input:
{
"project_gid": "98765432109876",
"data": {
"name": "Q4 Marketing Campaign - Phase 2",
"due_on": "2026-01-15",
"notes": "Extended timeline for additional market analysis"
}
}Response
Upon successful update, the action returns the updated project details including:
- Updated project properties
- Project GID
- Modification timestamp
- Permalink URL
Delete Project
Deletes an existing project from Asana.
Input Parameters
Here are the input parameters required to set up this action:
Mandatory
| Name | Description |
|---|---|
| Project GID | The globally unique identifier of the project to delete |
Here is a sample JSON input:
{
"project_gid": "98765432109876"
}Response
Upon successful deletion, the action returns:
- Confirmation of successful deletion (empty data object)
- HTTP status 200
Updated 1 day ago
