Shopify Integration for AI Agents

Securely connect your AI agents and chatbots (Claude, ChatGPT, Cursor, etc) with Shopify MCP or direct API to manage products, track orders, sync inventory, and automate customer workflows through natural language.
Shopify Logo
Gradient Top
Gradient Middle
Gradient Bottom
divider

Supported Tools

Tools
Add product to custom collectionAdds a product to an existing *custom collection*, optionally specifying its `position` if the collection is manually sorted.
Count product imagesRetrieves the total count of images for a shopify product, useful for inventory management or display logic; the provided `product id` must exist in the store.
Create a custom collectionCreates a new custom collection in a shopify store, requiring a unique title for manually curated product groupings (e.
Create CustomerTool to create a new customer in shopify.
Create an orderCreates a new order in shopify, typically requiring line items; if `customer id` is provided, it must correspond to an existing customer.
Create a productCreates a new product in a shopify store; a product title is generally required.
Create Product ImageTool to create a new product image for a given product.
Delete custom collectionPermanently deletes a custom collection from a shopify store using its `collection id`; this action is irreversible and requires a valid, existing `collection id`.
Delete a productDeletes a specific, existing product from a shopify store using its unique product id; this action is irreversible.
Delete product imageDeletes a specific image from a product in shopify, requiring the `product id` of an existing product and the `image id` of an image currently associated with that product.
Get All CustomersRetrieves customer records from a shopify store, with options for filtering, selecting specific fields, and paginating through the results.
Get collection by IDRetrieves a specific shopify collection by its `collection id`, optionally filtering returned data to specified `fields`.
Get collectsRetrieves a list of collects from a shopify store, where a collect links a product to a custom collection.
Get collects countRetrieves the total count of collects (product-to-collection associations) in a shopify store.
Get custom collectionsRetrieves a list of custom collections from a shopify store, optionally filtered by ids, product id, or handle.
Get custom collections countRetrieves the total number of custom collections in a shopify store.
Get CustomerRetrieves detailed information for a specific customer from a shopify store, provided their valid and existing `customer id`.
Get customer ordersRetrieves all orders for a specific, existing customer in shopify using their unique customer id.
Get order listRetrieves a list of orders from shopify using default api settings and filters.
Get order by idRetrieves a specific shopify order by its unique id, which must correspond to an existing order.
Get productRetrieves details for an existing shopify product using its unique product id.
Get product imageRetrieves detailed information for a specific product image, identified by its id and its associated product id, from a shopify store.
Get Product ImagesRetrieves all images for a shopify product, specified by its `product id` which must correspond to an existing product.
Get productsRetrieves a list of products from a shopify store.
Get products countRetrieves the total, unfiltered count of all products in a shopify store.
Get products in collectionRetrieves all products within a specified shopify collection, requiring a valid `collection id`.
Get Shop DetailsRetrieves comprehensive administrative information about the authenticated shopify store, as defined by the shopify api.
Update OrderUpdates the phone number for an existing shopify order, identified by its id; pass `phone=none` to remove the current phone number.

Connect Shopify 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 Shopify tools.',
    max_turns=10
)

async def main():
    async with ClaudeSDKClient(options=options) as client:
        await client.query('Create a new product called “Summer T-Shirt”')
        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 Shopify 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 Shopify 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': 'Add a new product called "Summer Hat" with price $29.99'
  }]
)
result = composio.provider.handle_tool_calls(
  response=response,
  user_id='your-user-id'
)
print(result)
Get tools from Tool Router session and execute Shopify actions with your Agent

Why Use Composio?

AI Native Shopify Integration

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

Managed Auth

  • Built-in OAuth handling with automatic token refresh and rotation
  • Central place to manage, scope, and revoke Shopify 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 Shopify
  • Scoped, least privilege access to Shopify resources
  • Full audit trail of agent actions to support review and compliance

Frequently Asked Questions

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

Yes, Shopify requires you to configure your own OAuth credentials. Once set up, Composio handles token storage, refresh, and lifecycle management for you.

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.