Excel Integration for AI Agents

Securely connect your AI agents and chatbots (Claude, ChatGPT, Cursor, etc) with Excel MCP or direct API to read spreadsheets, update cells, generate summaries, and automate data workflows through natural language.
Excel Logo
Gradient Top
Gradient Middle
Gradient Bottom
divider

Supported Tools

Tools
Add ChartAdd a chart to a worksheet using microsoft graph api.
Add SharePoint WorksheetAdd a new worksheet to a sharepoint excel workbook using microsoft graph sites api.
Add TableCreate a table in a workbook using microsoft graph api.
Add Table ColumnAdd a column to a table using microsoft graph api.
Add Table RowAdd a row to a table using microsoft graph api.
Add Workbook PermissionTool to grant access to a workbook via invite.
Add WorksheetAdd a new worksheet to an excel workbook using microsoft graph api.
Apply Table FilterApply a filter to a table column using microsoft graph api.
Apply Table SortApply a sort to a table using microsoft graph api.
Clear RangeTool to clear values, formats, or contents in a specified worksheet range.
Clear Table FilterClear a filter from a table column using microsoft graph api.
Close Excel SessionTool to close an existing excel workbook session.
Convert Table To RangeConvert a table to a range using microsoft graph api.
Create WorkbookTool to create a new workbook file at a specified drive path.
Delete Table ColumnDelete a column from a table using microsoft graph api.
Delete Table RowDelete a row from a table using microsoft graph api.
Delete WorksheetTool to delete a worksheet from the workbook.
Get Chart AxisTool to retrieve a specific axis from a chart.
Get Chart Data LabelsTool to retrieve the data labels object of a chart.
Get Chart LegendTool to retrieve the legend object of a chart.
Get RangeGet a range from a worksheet using microsoft graph api.
Create Excel SessionCreate a session for an excel workbook using microsoft graph api.
Get SharePoint RangeGet a range from a worksheet in sharepoint using microsoft graph sites api.
Get SharePoint WorksheetGet a worksheet by name or id from a sharepoint excel workbook using microsoft graph sites api.
Get Table ColumnTool to retrieve a specific column from a workbook table.
Get workbookTool to retrieve the properties and relationships of a workbook.
Get WorksheetGet a worksheet by name or id from an excel workbook using microsoft graph api.
Insert RangeTool to insert a new cell range into a worksheet, shifting existing cells down or right.
List ChartsList charts in a worksheet using microsoft graph api.
List Chart SeriesTool to list all data series in a chart.
List CommentsTool to list comments in an excel workbook.
List Drive FilesList files and folders in a drive root or specified path.
List Named ItemsList named items in a workbook using microsoft graph api.
List SharePoint TablesList tables in a sharepoint worksheet using microsoft graph sites api.
List SharePoint WorksheetsList worksheets in an excel workbook stored in sharepoint using microsoft graph sites api.
List Table ColumnsList columns in a table using microsoft graph api.
List Table RowsList rows in a table using microsoft graph api.
List TablesList tables in a worksheet using microsoft graph api.
List Workbook PermissionsTool to list permissions set on the workbook file.
List WorksheetsList worksheets in an excel workbook using microsoft graph api.
Merge CellsMerge cells in a worksheet range using microsoft graph api.
Protect WorksheetTool to protect a worksheet using optional protection options.
Sort RangeSort a range in a worksheet using microsoft graph api.
Update ChartUpdate a chart in a worksheet using microsoft graph api.
Update Chart LegendTool to update formatting or position of a chart legend.
Update RangeUpdate a range in a worksheet using microsoft graph api.
Update SharePoint RangeUpdate a range in a sharepoint worksheet using microsoft graph sites api.
Update TableUpdate a table in a workbook using microsoft graph api.
Update WorksheetUpdate worksheet properties (name, position) in an excel workbook using microsoft graph api.

Connect Excel MCP Tool with your Agent

Python
TypeScript

Install Composio

python
pip install composio claude-agent-sdk
Install the Composio SDK and Claude Agent SDK

Create Tool Router Session

python
from composio import Composio
from claude_agent_sdk import ClaudeSDKClient, ClaudeAgentOptions

composio = Composio(api_key='your-composio-api-key')
session = composio.create(user_id='your-user-id')
url = session.mcp.url
Initialize the Composio client and create a Tool Router session

Connect to AI Agent

python
import asyncio

options = ClaudeAgentOptions(
    permission_mode='bypassPermissions',
    mcp_servers={
        'tool_router': {
            'type': 'http',
            'url': url,
            'headers': {
                'x-api-key': 'your-composio-api-key'
            }
        }
    },
    system_prompt='You are a helpful assistant with access to Excel tools.',
    max_turns=10
)

async def main():
    async with ClaudeSDKClient(options=options) as client:
        await client.query('Add a chart to Q2 sales worksheet')
        async for message in client.receive_response():
            if hasattr(message, 'content'):
                for block in message.content:
                    if hasattr(block, 'text'):
                        print(block.text)

asyncio.run(main())
Use the MCP server with your AI agent

Connect Excel API Tool with your Agent

Python
TypeScript

Install Composio

python
pip install composio_openai
Install the Composio SDK

Initialize Composio and Create Tool Router Session

python
from openai import OpenAI
from composio import Composio
from composio_openai import OpenAIResponsesProvider

composio = Composio(provider=OpenAIResponsesProvider())
openai = OpenAI()
session = composio.create(user_id='your-user-id')
Import and initialize Composio client, then create a Tool Router session

Execute Excel Tools via Tool Router with Your Agent

python
tools = session.tools
response = openai.responses.create(
  model='gpt-4.1',
  tools=tools,
  input=[{
    'role': 'user',
    'content': 'Insert a new row into the "Sales" table with today\'s data'
  }]
)
result = composio.provider.handle_tool_calls(
  response=response,
  user_id='your-user-id'
)
print(result)
Get tools from Tool Router session and execute Excel actions with your Agent

Why Use Composio?

AI Native Excel Integration

  • Supports both Excel MCP and direct API based integrations
  • Structured, LLM-friendly schemas for reliable tool execution
  • Rich coverage for reading, writing, and querying your Excel data

Managed Auth

  • Built-in OAuth handling with automatic token refresh and rotation
  • Central place to manage, scope, and revoke Excel access
  • Per user and per environment credentials instead of hard-coded keys

Agent Optimized Design

  • Tools are tuned using real error and success rates to improve reliability over time
  • Comprehensive execution logs so you always know what ran, when, and on whose behalf

Enterprise Grade Security

  • Fine-grained RBAC so you control which agents and users can access Excel
  • Scoped, least privilege access to Excel resources
  • Full audit trail of agent actions to support review and compliance

Frequently Asked Questions

Do I need my own developer credentials to use Excel with Composio?

No, you can get started immediately using Composio's built-in Excel app. For production, we recommend configuring your own OAuth credentials.

Can I use multiple toolkits together?

Yes! Composio's Tool Router enables agents to use multiple toolkits. Learn more.

Is Composio secure?

Composio is SOC 2 and ISO 27001 compliant with all data encrypted in transit and at rest. Learn more.

What if the API changes?

Composio maintains and updates all toolkit integrations automatically, so your agents always work with the latest API versions.

Used by agents from

Context
ASU
Letta
glean
HubSpot
Agent.ai
Altera
DataStax
Entelligence
Rolai
Context
ASU
Letta
glean
HubSpot
Agent.ai
Altera
DataStax
Entelligence
Rolai
Context
ASU
Letta
glean
HubSpot
Agent.ai
Altera
DataStax
Entelligence
Rolai

Never worry about agent reliability

We handle tool reliability, observability, and security so you never have to second-guess an agent action.