Composio sdk

From aAAaqwq/AGI-Super-Team · View interactive version

Composio sdk is an AI agent skill from the GitHub repository aAAaqwq/AGI-Super-Team. Build AI agents and apps with Composio - access 200+ external tools with Tool Router or direct execution

How to use this skill

Skill file

Composio

Comprehensive guide to building AI agents and applications with Composio. Choose between:

When to use

Use this skill when:

Building AI Agents:

Building Traditional Applications:

1. Building Agents

Use Tool Router to build interactive chat-based agents or autonomous long-running task agents. Tool Router creates isolated MCP sessions for users with scoped access to toolkits and tools.

Key Features:

1.1 Session Management & Configuration

Essential patterns for creating agent sessions and configuring tools:

1.2 Authentication Flows

Authentication patterns for seamless user experiences:

1.3 Toolkit Querying & UI Building

Build connection UIs and check toolkit states:

1.4 Event-Driven Agents (Triggers)

Real-time event handling and webhook integration patterns:

2. Building Apps with Composio Tools

Use Composio for traditional applications where tools are executed manually without agent frameworks. This approach gives you full control over tool execution, authentication, and resource management.

Key Capabilities:

2.1 Core Operations

Fundamental patterns for fetching and executing tools:

2.2 Resource Management (CRUD Patterns)

Manage authentication and connections programmatically:

2.3 Extensibility & Customization

Extend Composio with custom tools and behavior:

2.4 Event-Driven Applications

Build reactive applications with triggers (shared with agents):

2.5 User Context & Multi-Tenancy

Manage user context and multi-tenant isolation:

Quick Start Examples

Building an Agent with Tool Router

import { Composio } from '@composio/core';

const composio = new Composio();

// Create a session with Gmail tools
const session = await composio.create('user_123', {
  toolkits: ['gmail'],
  manageConnections: true
});

// Use MCP URL with any AI framework
console.log('MCP URL:', session.mcp.url);

Building an App with Direct Execution

import { Composio } from '@composio/core';

const composio = new Composio({
  apiKey: 'your-api-key',
  toolkitVersions: { github: '12082025_00' }
});

// Fetch tools
const tools = await composio.tools.get('user_123', {
  toolkits: ['github']
});

// Execute a tool
const result = await composio.tools.execute('GITHUB_GET_REPO', {
  userId: 'user_123',
  arguments: { owner: 'composio', repo: 'sdk' },
});

console.log(result.data);

References

Tool Router (Agents):

Direct Execution (Apps):

Shared:

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.