MCP Gateway · OpenCode
Connect Asana to OpenCode
Asana work also gets scripted: bulk assignments, project health checks and quick lookups by ID. From the OpenCode terminal, through the Speakeasy MCP Gateway, you can resolve workspace and project IDs, read task counts across a team's projects and reassign work by email. Every prompt and tool call passes a Speakeasy check in the OpenCode plugin first, and token and cost totals are reported per turn.
- Category
- Project management
- Tools
- 44
- Authentication
- OAuth
- OpenCode
- Terminal
Behind the MCP Gateway
Run Asana MCP behind the MCP Gateway
One URL for every agent, sign-in through your IdP, RBAC down to the tool, and every Asana call inspected and logged.
Before you start
What Asana needs first
An Asana user with developer console access; an organization super admin if App management blocks the app does the Asana side of the setup.
- You need an Asana account with access to the developer console.
- You must be a member of every workspace you add under Specific workspaces.
- On Enterprise+ or Legacy Enterprise with App management, a super admin must allow the MCP client first.
In Asana
- Open the developer console from Settings > Apps.
- Create an MCP app and save its Client ID and Client secret.
- Add the Speakeasy redirect URL under OAuth.
- Set distribution to specific workspaces or any workspace.
- If the app is blocked, have a super admin unblock it in the Admin console.
Set up
Add Asana to OpenCode in 4 steps
- 01
Add Asana from the catalog
An admin finds Asana in the MCP Catalog (MCP Gateway > MCP > Catalog) and clicks Add. Speakeasy registers the vendor's server as a remote MCP server and proxies sessions to it. Nothing is copied or re-hosted.
Asana uses OAuth. Servers that support dynamic client registration get their OAuth configuration applied automatically.
Where MCP-scoped policies are enabled, the install offers a recommended risk policy for the new server that detects secrets and PII and inspects tool requests and responses.
- 02
Choose who can use Asana
Give teams the
mcp:connectscope on the Asana server through team access or a role. OpenCode connects to the Asana server's own URL, and the server's authorization decides who can connect and which tools they can call. - 03
Connect OpenCode
Add the server to OpenCode's own mcp config block as a remote server.
Copy the server's URL from its hosted install page in Speakeasy.
Add it to the
mcpblock of your OpenCode config withtypeset toremote.Restart OpenCode and sign in when prompted.
{ "mcp": { "<server slug>": { "type": "remote", "url": "<URL from the hosted install page>" } } } - 04
Sign in and use Asana from OpenCode
The first time OpenCode connects, it opens a browser so the person can sign in to Speakeasy through your identity provider.
Asana needs its own OAuth grant, so each person connects it once. Until they do, Asana calls fail while the rest of the gateway keeps working.
From then on, Asana's tools appear in OpenCode, limited to what the person's access allows, and every call lands in the gateway's tool logs.
OpenCode doesn't receive MCP servers from plugins. The observability package is installed separately, from a ZIP or with speakeasy-hooks install --provider=opencode, and the device agent can maintain it.
Use cases
What OpenCode users do with Asana
Resolve workspace and object IDs
Start by listing your workspaces, then use typeahead search to turn a project or task name into the ID that the rest of your script or prompt needs.
Check task counts across projects
List every project a team owns and pull incomplete, completed and milestone counts for each, to spot the project that stalled before standup.
Reassign work by email address
Look up a teammate by their email to get their Asana user ID, then hand a task over to them with a new assignee and due date.
Tools
44 tools
Each Asana tool can be allowed or denied per team and role at the MCP Gateway before OpenCode sees it.
asana_get_allocations
List allocations filtered by either workspace + assignee or parent (project). Returns allocation details including start/end dates, effort (hours or percentage), and associated projects or portfolios. Use for capacity planning and resource management.
asana_get_attachment
Get detailed attachment data including name, resource type, download_url, view_url, and parent. Returns complete attachment information needed for accessing attached files.
asana_get_attachments_for_object
List all attachments for a project, project brief, or task. Returns attachment names, IDs, and URLs (download_url, permanent_url, view_url). Use for accessing files attached to Asana objects. Supports pagination for objects with many attachments.
asana_get_goals
List goals filtered by context (portfolio, project, task, workspace, or team). One context required. Returns goal names, IDs. Use for goal overview or reporting.
asana_get_goal
Get detailed goal data including name, owner, current_status_update, and due_on. Use after finding goal ID via typeahead. Returns complete goal configuration needed for goal operations.
asana_create_goal
Create a new goal. REQUIRES name, time_period, and either workspace or team. Use to establish objectives and key results. Returns created goal details with ID. Supports start/due dates and goal ownership assignment.
Control
What Speakeasy can see and stop in OpenCode
The gateway covers every client the same way. The rest depends on what OpenCode exposes to Speakeasy.
Tool logs
Gateway
Every Asana call is logged with the person and the client that made it.
Access by role
Gateway
People reach only the Asana tools their team or role allows.
Request and response blocking
Gateway
A risk policy scoped to Asana can reject a tool request before it reaches the server, or withhold a result from OpenCode. MCP-scoped policies are enabled per organization.
Prompt and tool-call blocking
OpenCode
The OpenCode plugin sends each prompt and tool call to Speakeasy, which allows or denies it before it runs.
Usage telemetry
OpenCode
Token and cost totals flow through the plugin, reported per turn.
Device agent
OpenCode
The device agent installs and maintains the observability package.
- OpenCode has no OpenTelemetry exporter, so session data comes through the plugin.
- Tool output is blocked at the gateway rather than in OpenCode's hooks.
Questions
Frequently asked questions
Can OpenCode delete Asana tasks?
Is Asana tool output filtered in OpenCode?
How do OpenCode users get Asana?
Are Asana calls from OpenCode logged?
Connect more