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

# Asana

> Integrate your application with the Asana API

## 🚀 Quickstart

Connect to Asana with Nango and see data flow in 2 minutes.

<Steps>
  <Step title="Create the integration">
    In Nango ([free signup](https://app.nango.dev)), go to [Integrations](https://app.nango.dev/dev/integrations) -> *Configure New Integration* -> *Asana*.
  </Step>

  <Step title="Authorize Asana">
    Go to [Connections](https://app.nango.dev/dev/connections) -> *Add Test Connection* -> *Authorize*, then log in to Asana. Later, you'll let your users do the same directly from your app.
  </Step>

  <Step title="Call the Asana API">
    Let's make your first request to the Asana API (fetch a list of workspaces). Replace the placeholders below with your [secret key](https://app.nango.dev/dev/environment-settings), [integration ID](https://app.nango.dev/dev/integrations), and [connection ID](https://app.nango.dev/dev/connections):

    <Tabs>
      <Tab title="cURL">
        ```bash theme={null}
        curl "https://api.nango.dev/proxy/api/1.0/workspaces" \
          -H "Authorization: Bearer <NANGO-SECRET-KEY>" \
          -H "Provider-Config-Key: <INTEGRATION-ID>" \
          -H "Connection-Id: <CONNECTION-ID>"
        ```
      </Tab>

      <Tab title="Node">
        Install Nango's backend SDK with `npm i @nangohq/node`. Then run:

        ```typescript theme={null}
        import { Nango } from '@nangohq/node';

        const nango = new Nango({ secretKey: '<NANGO-SECRET-KEY>' });

        const res = await nango.get({
            endpoint: '/api/1.0/workspaces',
            providerConfigKey: '<INTEGRATION-ID>',
            connectionId: '<CONNECTION-ID>'
        });

        console.log(res.data.data);
        ```
      </Tab>
    </Tabs>

    Or fetch credentials with the [Node SDK](/reference/sdks/node#get-a-connection-with-credentials) or [API](/reference/api/connection/get).

    ✅ You're connected! Check the [Logs](https://app.nango.dev/dev/logs) tab in Nango to inspect requests.
  </Step>

  <Step title="Implement Nango in your app">
    Follow our [Auth implementation guide](/guides/primitives/auth) to integrate Nango in your app.

    To obtain your own production credentials, follow the setup guide linked below.
  </Step>
</Steps>

## 📚 Asana Integration Guides

Nango maintained guides for common use cases.

* [How to register your own Asana OAuth app](/api-integrations/asana/how-to-register-your-own-asana-api-oauth-app)\
  Register an OAuth app with Asana and obtain credentials to connect it to Nango

Official docs: [Asana API Documentation](https://developers.asana.com/reference/rest-api-reference)

## 🧩 Pre-built syncs & actions for Asana

Enable them in your dashboard. Extend and customize to fit your needs.

### Attachments

| Function name                 | Description                                           | Type                                         | Source code                                                                                                                       |
| ----------------------------- | ----------------------------------------------------- | -------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------- |
| `delete-attachment`           | Delete an attachment by gid.                          | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/delete-attachment.ts)           |
| `list-attachments-for-object` | List attachments on a task or other supported object. | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/list-attachments-for-object.ts) |

### Projects

| Function name                 | Description                              | Type                                         | Source code                                                                                                                       |
| ----------------------------- | ---------------------------------------- | -------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------- |
| `create-project`              | Create a project in a workspace or team. | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/create-project.ts)              |
| `delete-project`              | Delete a project by gid.                 | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/delete-project.ts)              |
| `get-project`                 | Fetch a single project by gid.           | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/get-project.ts)                 |
| `list-projects-for-team`      | List projects in a team.                 | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/list-projects-for-team.ts)      |
| `list-projects-for-workspace` | List projects in a workspace.            | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/list-projects-for-workspace.ts) |
| `update-project`              | Update mutable fields on a project.      | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/update-project.ts)              |

### Sections

| Function name               | Description                         | Type                                         | Source code                                                                                                                     |
| --------------------------- | ----------------------------------- | -------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------- |
| `create-section`            | Create a section in a project.      | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/create-section.ts)            |
| `delete-section`            | Delete a section by gid.            | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/delete-section.ts)            |
| `get-section`               | Fetch a single section by gid.      | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/get-section.ts)               |
| `list-sections-for-project` | List sections in a project.         | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/list-sections-for-project.ts) |
| `update-section`            | Update mutable fields on a section. | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/update-section.ts)            |

### Stories

| Function name           | Description                                | Type                                         | Source code                                                                                                                 |
| ----------------------- | ------------------------------------------ | -------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------- |
| `create-story-on-task`  | Create a comment or story entry on a task. | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/create-story-on-task.ts)  |
| `delete-story`          | Delete a story or comment by gid.          | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/delete-story.ts)          |
| `list-stories-for-task` | List stories and comments on a task.       | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/list-stories-for-task.ts) |

### Tags

| Function name             | Description                     | Type                                         | Source code                                                                                                                   |
| ------------------------- | ------------------------------- | -------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------- |
| `create-tag`              | Create a tag in a workspace.    | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/create-tag.ts)              |
| `delete-tag`              | Delete a tag by gid.            | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/delete-tag.ts)              |
| `get-tag`                 | Fetch a single tag by gid.      | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/get-tag.ts)                 |
| `list-tags-for-workspace` | List tags in a workspace.       | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/list-tags-for-workspace.ts) |
| `update-tag`              | Update mutable fields on a tag. | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/update-tag.ts)              |

### Tasks

| Function name               | Description                                         | Type                                         | Source code                                                                                                                     |
| --------------------------- | --------------------------------------------------- | -------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------- |
| `add-project-to-task`       | Add a task to a project, optionally into a section. | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/add-project-to-task.ts)       |
| `add-tag-to-task`           | Attach an existing tag to a task.                   | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/add-tag-to-task.ts)           |
| `create-subtask`            | Create a subtask under a parent task.               | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/create-subtask.ts)            |
| `create-task`               | Create a task in Asana.                             | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/create-task.ts)               |
| `delete-task`               | Delete a task by gid.                               | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/delete-task.ts)               |
| `get-task`                  | Fetch a single task by gid.                         | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/get-task.ts)                  |
| `list-subtasks-for-task`    | List subtasks under a parent task.                  | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/list-subtasks-for-task.ts)    |
| `list-tasks-for-project`    | List tasks in a project.                            | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/list-tasks-for-project.ts)    |
| `list-tasks-for-section`    | List tasks in a project section.                    | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/list-tasks-for-section.ts)    |
| `remove-project-from-task`  | Remove a task from a project                        | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/remove-project-from-task.ts)  |
| `remove-tag-from-task`      | Remove a tag from a task.                           | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/remove-tag-from-task.ts)      |
| `search-tasks-in-workspace` | Search tasks in a workspace with filters.           | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/search-tasks-in-workspace.ts) |
| `update-task`               | Update mutable fields on a task.                    | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/update-task.ts)               |

### Teams

| Function name              | Description                 | Type                                         | Source code                                                                                                                    |
| -------------------------- | --------------------------- | -------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------ |
| `get-team`                 | Fetch a single team by gid. | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/get-team.ts)                 |
| `list-teams-for-user`      | List teams for a user.      | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/list-teams-for-user.ts)      |
| `list-teams-for-workspace` | List teams in a workspace.  | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/list-teams-for-workspace.ts) |

### Users

| Function name              | Description                 | Type                                         | Source code                                                                                                                    |
| -------------------------- | --------------------------- | -------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------ |
| `get-user`                 | Fetch a single user by gid. | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/get-user.ts)                 |
| `list-users-for-team`      | List users in a team.       | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/list-users-for-team.ts)      |
| `list-users-for-workspace` | List users in a workspace.  | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/list-users-for-workspace.ts) |

### Workspaces

| Function name     | Description                                          | Type                                         | Source code                                                                                                           |
| ----------------- | ---------------------------------------------------- | -------------------------------------------- | --------------------------------------------------------------------------------------------------------------------- |
| `get-workspace`   | Fetch a single workspace by gid.                     | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/get-workspace.ts)   |
| `list-workspaces` | List workspaces available to the authenticated user. | [Action](/guides/functions/action-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/actions/list-workspaces.ts) |

### Others

| Function name | Description                                                    | Type                                           | Source code                                                                                                    |
| ------------- | -------------------------------------------------------------- | ---------------------------------------------- | -------------------------------------------------------------------------------------------------------------- |
| `projects`    | Sync projects for workspaces or teams in scope.                | [Sync](/guides/functions/syncs/sync-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/syncs/projects.ts)   |
| `sections`    | Sync sections for projects in scope                            | [Sync](/guides/functions/syncs/sync-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/syncs/sections.ts)   |
| `subtasks`    | Sync subtasks for parent tasks in scope.                       | [Sync](/guides/functions/syncs/sync-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/syncs/subtasks.ts)   |
| `tags`        | Sync workspace tags.                                           | [Sync](/guides/functions/syncs/sync-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/syncs/tags.ts)       |
| `tasks`       | Sync tasks for projects, sections, or workspace search scopes. | [Sync](/guides/functions/syncs/sync-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/syncs/tasks.ts)      |
| `teams`       | Sync teams for workspaces in scope.                            | [Sync](/guides/functions/syncs/sync-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/syncs/teams.ts)      |
| `users`       | Sync users for workspaces or teams in scope.                   | [Sync](/guides/functions/syncs/sync-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/syncs/users.ts)      |
| `workspaces`  | Sync workspaces visible to the authenticated Asana user.       | [Sync](/guides/functions/syncs/sync-functions) | [🔗 Github](https://github.com/NangoHQ/integration-templates/blob/main/integrations/asana/syncs/workspaces.ts) |

***
