Skip to content
Scalekit Docs
Talk to an Engineer Dashboard

Migrate from Composio to Scalekit

Move an agent from Composio to Scalekit AgentKit: map concepts, recreate connections, have users re-authorize, then move tool calls, MCP and custom tools.

This guide maps Composio concepts to their Scalekit AgentKit equivalents and walks through each migration step: SDK setup, authentication, tool execution, and MCP. Use it as a reference while porting your agent code.

ComposioScalekitNotes
Toolkit (e.g. GITHUB)Connector (e.g. github)Scalekit uses lowercase slugs
Tool (e.g. GITHUB_CREATE_ISSUE)Tool (e.g. github_issue_create)Same concept, lowercase naming
Auth configConnectionOAuth app credentials, scopes, redirect URIs
Connected accountConnected accountPer-user credential record
user_id / entity IDidentifierYour app’s unique user ID, passed per API call
Connect LinkAuthorization linkOAuth redirect URL for user consent
Session (composio.create())identifier on each callNo session to create: each call names the user
Provider package (composio_openai)@scalekit-sdk/node or scalekit-sdk-pythonOne SDK works with every framework
session.tools()listScopedTools()Get tools a user is authorized to call
session.tools.execute()executeTool()Execute a tool on behalf of a user
session.mcp.urlVirtual MCP server URL + session tokenStatic server URL with a short-lived bearer token per agent run
Custom tool (in-memory)Custom tool (API Proxy)Defined in your app code using actions.request()
executeToolRequest (proxy)actions.request()Proxied REST API call
TriggerYour own scheduler or the app’s webhooksRun executeTool() on a schedule, or subscribe to the app’s webhooks
COMPOSIO_SEARCH_TOOLSsearchTools()Rank tools by relevance to a task, or filter listScopedTools() by connection name
COMPOSIO_REMOTE_WORKBENCHYour own runtimeRun code where your agent runs
  1. Create a Scalekit account

    Sign up at app.scalekit.com and copy your API credentials from Dashboard > Developers > Settings > API Credentials.

  2. Set environment variables

    Terminal window
    SCALEKIT_CLIENT_ID=your_client_id
    SCALEKIT_CLIENT_SECRET=your_client_secret
    SCALEKIT_ENVIRONMENT_URL=https://your-env.scalekit.com
  3. Install the SDK

    Terminal window
    pip install scalekit-sdk-python
  4. Initialize the client

    Scalekit uses a single client instance. There is no session object — you pass identifier on each API call.

    import os
    import scalekit.client
    scalekit_client = scalekit.client.ScalekitClient(
    client_id=os.getenv("SCALEKIT_CLIENT_ID"),
    client_secret=os.getenv("SCALEKIT_CLIENT_SECRET"),
    env_url=os.getenv("SCALEKIT_ENVIRONMENT_URL"),
    )
    actions = scalekit_client.actions

In Composio, auth configs are created programmatically or via the dashboard. In Scalekit, you configure connections in the dashboard.

For each Composio toolkit your agent uses (Gmail, Slack, GitHub, etc.), create a corresponding connection in Dashboard > AgentKit > Connections > Add connection. See Configure a connection for the full walkthrough.

Composio auth typeScalekit equivalent
OAuth 2.0 (Composio managed)OAuth 2.0 (use Scalekit credentials to start, then bring your own)
OAuth 2.0 (custom)OAuth 2.0 (bring your own credentials)
API keyAPI key (user provides during connected account creation)
Bearer tokenBearer token
Basic authBasic auth

Both platforms create per-user records (connected accounts) and generate OAuth links. The SDK methods differ.

Before (Composio):

# Composio handles auth in-chat or via connect link
session = composio.create(user_id="user_123")
# Auth is triggered automatically when a tool requires it

After (Scalekit):

# Create or retrieve the connected account
response = actions.get_or_create_connected_account(
connection_name="gmail",
identifier="user_123",
)
connected_account = response.connected_account
# Generate an authorization link if the account is not yet active
if connected_account.status != "ACTIVE":
link_response = actions.get_authorization_link(
connection_name="gmail",
identifier="user_123",
)
auth_url = link_response.link
# Redirect or send auth_url to the user

Key difference: Composio can trigger auth in-chat automatically. With Scalekit, your app explicitly creates the connected account and sends the authorization link to the user. Once the user completes the OAuth flow, the connected account becomes ACTIVE and your agent can execute tools.

Composio tracks two statuses (ACTIVE and INACTIVE). Scalekit uses more granular states:

Scalekit statusMeaning
PENDING_AUTHUser hasn’t completed authentication
PENDING_VERIFICATIONAuthentication complete; user verification still required
ACTIVECredentials valid, ready for tool calls
EXPIREDCredentials expired or were revoked; re-authentication required
DISCONNECTEDAccount was disconnected

Check status before executing tools. If the account is not ACTIVE, generate a new authorization link.

Before (Composio):

session = composio.create(user_id="user_123")
tools = session.tools() # all tools the user is authorized for

After (Scalekit):

tools_response, _ = scalekit_client.actions.tools.list_scoped_tools(
identifier="user_123",
# Required: list every connection whose tools the agent should see
filter={"connection_names": ["gmail"]},
page_size=100,
)

Before (Composio):

session = composio.create(user_id="user_123")
tools = session.tools()
# Framework handles execution via the agent loop, or:
# composio.tools.execute(tool_name="GMAIL_FETCH_MAILS", params={...})

After (Scalekit):

result = actions.execute_tool(
tool_name="gmail_fetch_mails",
identifier="user_123",
connection_name="gmail",
tool_input={"query": "is:unread", "max_results": 5},
)
print(result.data)

Key differences:

  • Composio tool names are uppercase (GMAIL_FETCH_MAILS); Scalekit uses lowercase (gmail_fetch_mails)
  • Composio’s session model means you don’t pass user_id on each call. With Scalekit, pass identifier and the connection name on every executeTool call: connection_name in Python, connector in Node.js
  • Both return structured, LLM-ready output

Composio and Scalekit may name tools differently for the same connector. Browse the connector’s tool list in the Scalekit connector catalog to find the exact tool names. Common patterns:

Composio tool nameScalekit tool name
GMAIL_FETCH_MAILSgmail_fetch_mails
SLACK_SEND_MESSAGEslack_send_message
GITHUB_CREATE_ISSUEgithub_issue_create
NOTION_CREATE_PAGEnotion_page_create

Tool input schemas may also differ. Check each tool’s parameters in the connector catalog and update your agent’s tool input accordingly.

Both platforms support MCP (Model Context Protocol) for framework-agnostic tool discovery and execution.

Before (Composio):

{
"mcpServers": {
"composio": {
"url": "https://backend.composio.dev/v3/mcp/{SERVER_ID}?user_id={USER_ID}",
"headers": {
"x-api-key": "<COMPOSIO_API_KEY>"
}
}
}
}

After (Scalekit):

Scalekit MCP uses Virtual MCP servers:

  1. Create a Virtual MCP server — define which connections and tools the server exposes (one-time). This gives you a static mcp_server_url.
  2. Mint a session token — before each agent run, call create_session_token for the user. Pass it as a bearer auth header.

See Virtual MCP servers for the full setup.

{
"mcpServers": {
"scalekit": {
"url": "<MCP_SERVER_URL>",
"headers": {
"Authorization": "Bearer <SESSION_TOKEN>"
}
}
}
}

Key difference: Composio embeds the user ID in the URL. Scalekit uses a static server URL shared across all users, with a short-lived session token per agent run for authentication.

In Scalekit, custom tools use API Proxy mode (actions.request). The proxy is available out of the box for every connector with no extra configuration. You define the tool contract in your application code and call the provider’s REST endpoint through Scalekit, which injects the user’s credentials automatically.

Composio approachScalekit approach
@composio.tools.custom_tool decoratorDefine the tool in your app code
In-memory, lost on restartLives in your codebase
executeToolRequest for authenticated API callsactions.request() — works out of the box for every connector
response = actions.request(
connection_name="gmail",
identifier="user_123",
method="GET",
path="/gmail/v1/users/me/messages",
)

If your agent connects to an API or MCP server that isn’t in Scalekit’s built-in catalog, you can add your own connector. Custom connectors support OAuth 2.0, API keys, bearer tokens, and other auth types. Once created, they work exactly like built-in connectors — same connected account flow, same actions.request() proxy, same MCP tool calling.

See Add your own connector for the full walkthrough.

API reference

The endpoints this page's code calls, with every field and the SDK method for each: