
TL;DR
Composio is a tool infrastructure layer that connects AI agents to Gmail, GitHub, Slack, Google Calendar, and hundreds more apps - all auth handled for you. Here is how to set it up and start building real cross-app workflows.
Read next
MCP lets AI agents connect to databases, APIs, and tools. Here is what it is and how to use it in your TypeScript projects.
5 min readA practical guide to building AI agents with TypeScript using the Vercel AI SDK. Tool use, multi-step reasoning, and real patterns you can ship today.
10 min readAI agents use LLMs to complete multi-step tasks autonomously. Here is how they work and how to build them in TypeScript.
6 min read| Source | Description |
|---|---|
| Composio Documentation | Official SDK and API reference |
| Composio Pricing | Current pricing tiers and limits |
| Composio Tools Catalog | Full list of 877+ supported toolkits |
| Composio MCP Guide | MCP server setup and configuration |
| Vercel AI SDK | Official AI SDK documentation |
Your AI agent can write code, run tests, and refactor files. But ask it to send an email, check your calendar, or create a GitHub issue from a bug report in your inbox - and it has no idea what to do. The agent is powerful but isolated, stuck inside the codebase with no connection to the tools you actually use every day.
Composio fixes this. It is a tool infrastructure layer that gives any AI agent the ability to take real actions across 500+ apps and 10,000+ individual tools. Gmail, GitHub, Slack, Google Calendar, Notion, Stripe, Linear, Salesforce - with all the authentication handled for you.
Building integrations for AI agents is brutal. For every app you want your agent to use, you need to handle OAuth flows, build and maintain API wrappers, optimize JSON schemas so the model actually understands what to call, manage token refresh, and figure out how to scale all of that as you add more tools.
Even with MCP (Model Context Protocol), which is supposed to solve this, you are limited to apps that have published their own MCP servers. GitHub has one. Slack has one. But what about the other 500 apps your team actually uses? Salesforce, HubSpot, Stripe, Google Sheets, Supabase?
Composio abstracts all of this into a single API call. One integration layer, one auth system, one SDK.
Here is where Composio gets clever. If you load just GitHub and Notion as regular MCP tools, that is about 70 tool schemas. Roughly 40,000 tokens burned before the user even says anything. Scale to 500 apps and the approach falls apart completely.
Composio takes a different approach. Your agent only gets five meta tools:
| Tool | What It Does |
|---|---|
COMPOSIO_SEARCH_TOOLS | Semantic search across 10,000+ tools. Returns exactly what is needed for the task. |
COMPOSIO_MANAGE_CONNECTIONS | Handles OAuth on the fly, mid-conversation. |
COMPOSIO_MULTI_EXECUTE_TOOL | Runs up to 20 tool calls in parallel. |
COMPOSIO_REMOTE_WORKBENCH | Sandboxed Python environment for bulk data processing. |
COMPOSIO_REMOTE_BASH_TOOL | Execute bash commands for file and data processing. |
So when you say "send an email to John," your agent does not have a SEND_EMAIL tool pre-loaded. Instead it calls COMPOSIO_SEARCH_TOOLS, which returns not just the send email action, but also the search contacts action - because it knows you will need John's email address first. In benchmarks, this prerequisite resolution hits 95% accuracy versus 56% with basic keyword search.
When something returns a huge payload - like 500 emails - Composio automatically routes that to the sandboxed workbench instead of blowing up your context window. That saves 48 to 84% on tokens for bulk operations.
Get the weekly deep dive
Tutorials on Claude Code, AI agents, and dev tools - delivered free every week.
From the archive
Mar 7, 2026 • 6 min read
Feb 28, 2026 • 5 min read
Feb 21, 2026 • 6 min read
Feb 19, 2026 • 6 min read
The fastest way to get Composio into a TypeScript project is through the Vercel AI SDK provider. Install the packages:
npm install @composio/core @composio/vercel ai @ai-sdk/anthropicGrab your COMPOSIO_API_KEY from platform.composio.dev/settings and add it alongside your Anthropic key in .env:
COMPOSIO_API_KEY=your_composio_api_key
ANTHROPIC_API_KEY=your_anthropic_api_key
Now build your agent. The Vercel provider is agentic - tools include an execute function, so the AI SDK handles tool calls automatically:
import { anthropic } from "@ai-sdk/anthropic";
import { Composio } from "@composio/core";
import { VercelProvider } from "@composio/vercel";
import { generateText, stepCountIs } from "ai";
const composio = new Composio({ provider: new VercelProvider() });
const session = await composio.create("user_123");
const tools = await session.tools();
const { text } = await generateText({
model: anthropic("claude-sonnet-4-5"),
tools,
prompt: "Star the composio repository on GitHub",
stopWhen: stepCountIs(10),
});
console.log(text);
That is the entire agent. The session.tools() call returns the five meta tools. The AI SDK handles the agentic loop - calling tools, processing results, calling more tools - until the task is complete or it hits the step limit.
If you use Claude Code, Cursor, or any MCP-compatible tool, you can add Composio as an MCP server and skip the SDK entirely. Install the CLI:
curl -fsSL https://composio.dev/install | bash
You can also create single-toolkit MCP servers programmatically for tighter control:
import { Composio } from "@composio/core";
const composio = new Composio({ apiKey: process.env.COMPOSIO_API_KEY });
const server = await composio.mcp.create("my-gmail-server", {
toolkits: [{ authConfigId: "ac_xyz123", toolkit: "gmail" }],
allowedTools: ["GMAIL_FETCH_EMAILS", "GMAIL_SEND_EMAIL"],
});
const instance = await composio.mcp.generate("user-123", server.id);
console.log("MCP Server URL:", instance.url);
This gives you a per-user MCP URL that works with any MCP client. Same tools, same auth, different agent.
Here is where Composio shines - cross-app workflows from a single prompt. Say you want to turn a bug report email into a GitHub issue:
const { text } = await generateText({
model: anthropic("claude-sonnet-4-5"),
tools,
prompt:
"Check my latest email. If there is a bug report, create a GitHub issue with the details.",
stopWhen: stepCountIs(10),
});
The agent will call COMPOSIO_SEARCH_TOOLS to find email-reading tools, fetch your latest emails, identify the bug report, search for GitHub issue creation tools, and create a properly formatted issue with title, description, and labels. Two apps, one prompt, and the agent figured out the workflow on its own.
This pattern extends to any combination of connected apps. Triage your inbox and create a summary spreadsheet. Read Slack messages and update a Notion board. Pull calendar events and draft a daily standup email.
Composio handles auth through the COMPOSIO_MANAGE_CONNECTIONS meta tool. When your agent tries to use a tool that requires authentication, it calls this meta tool, which returns an OAuth link. The user clicks, authenticates, and the connection is stored for future use.
For programmatic control, you can manage connections directly:
const session = await composio.create("user_123", {
manageConnections: false,
});
const connectionRequest = await session.authorize("github", {
callbackUrl: "https://your-app.com/callback",
});
// Redirect user to connectionRequest.redirectUrl
Connected accounts persist across sessions. Once a user connects their GitHub account, every future session for that user has GitHub access without re-authenticating.
Composio has a generous free tier: 20,000 tool calls per month, 1,000 connected accounts, no credit card required. That is enough to build and test real applications before spending anything.
Paid plans start at $29/month (200K tool calls) and go up to $229/month (2M tool calls). Premium tools like web scraping and search APIs count as 3x against your quota.
Composio supports 877 toolkits across every category you can think of - developer tools, CRM, analytics, e-commerce, finance, HR, marketing. The full catalog is at composio.dev/tools.
If you are building with the OpenAI Agents SDK instead of Vercel, swap the provider:
import { OpenAIAgentsProvider } from "@composio/openai-agents";
const composio = new Composio({ provider: new OpenAIAgentsProvider() });
The same pattern works with LangChain, CrewAI, LlamaIndex, Google ADK, and Mastra. Composio also supports event-driven workflows through triggers - webhook and polling-based events from connected apps that can kick off agent workflows automatically.
The core idea is simple: your agent should be able to use any tool you use. Composio makes that a five-minute setup instead of a five-week integration project.
Composio is a tool infrastructure layer that connects AI agents to 500+ apps and 10,000+ individual tools. It handles OAuth authentication, API wrappers, and JSON schema optimization so your agent can take real actions across Gmail, GitHub, Slack, Google Calendar, Notion, Stripe, Linear, and hundreds of other services through a single integration layer.
Composio uses a meta-tool architecture. Instead of loading all 10,000+ tool schemas upfront, your agent gets five meta tools including COMPOSIO_SEARCH_TOOLS, which semantically searches for exactly the tools needed for the current task. Benchmarks show 95% accuracy on prerequisite resolution and 48-84% token savings for bulk operations.
Yes. Composio provides an MCP server that works with Claude Code, Cursor, and any MCP-compatible tool. You can also create single-toolkit MCP servers programmatically for tighter control over which apps each user can access.
Composio has official providers for Vercel AI SDK, OpenAI Agents SDK, LangChain, CrewAI, LlamaIndex, Google ADK, and Mastra. The agentic tool pattern works the same across all of them - tools include an execute function that handles the tool call loop automatically.
The free tier includes 20,000 tool calls per month and 1,000 connected accounts with no credit card required. Paid plans start at $29/month for 200K tool calls and go up to $229/month for 2M tool calls. Premium tools like web scraping count as 3x against your quota.
When your agent tries to use a tool requiring auth, Composio returns an OAuth link through the COMPOSIO_MANAGE_CONNECTIONS meta tool. The user clicks, authenticates, and the connection is stored for all future sessions. You can also manage connections programmatically for custom flows.
Technical content at the intersection of AI and development. Building with AI agents, Claude Code, and modern dev tools - then showing you exactly how it works.
Gives AI agents access to 250+ external tools (GitHub, Slack, Gmail, databases) with managed OAuth. Handles the auth and...
View ToolThe TypeScript toolkit for building AI apps. Unified API across OpenAI, Anthropic, Google. Streaming, tool calling, stru...
View ToolLightweight Python framework for multi-agent systems. Agent handoffs, tool use, guardrails, tracing. Successor to the ex...
View ToolTypeScript-first AI agent framework. Agents, tools, memory, workflows, RAG, evals, tracing, MCP, and production deployme...
View ToolGive your agents a filesystem that branches like git. Crash-safe by default.
View AppReplay every MCP tool call to find why your agent went sideways.
View AppSpec out AI agents, run them overnight, wake up to a verified GitHub repo.
View AppWhat MCP servers are, how they work, and how to build your own in 5 minutes.
AI AgentsStep-by-step guide to building an MCP server in TypeScript - from project setup to tool definitions, resource handling, testing, and deployment.
AI AgentsConfigure Claude Code for maximum productivity -- CLAUDE.md, sub-agents, MCP servers, and autonomous workflows.
AI Agents
MCP lets AI agents connect to databases, APIs, and tools. Here is what it is and how to use it in your TypeScript projec...

A practical guide to building AI agents with TypeScript using the Vercel AI SDK. Tool use, multi-step reasoning, and rea...

AI agents use LLMs to complete multi-step tasks autonomously. Here is how they work and how to build them in TypeScript.
AI SDK 6 ships ToolLoopAgent and full MCP support. LangGraph hits 1.0 GA with durable state and built-in interrupt/resum...
Headroom is a context compression layer that intercepts your AI agent's tool outputs and strips 60-95% of the tokens bef...

Before an AI agent gets tools, files, APIs, MCP servers, or deployment access, decide what it can read, write, call, log...

New tutorials, open-source projects, and deep dives on coding agents - delivered weekly.