@devries-cameron20 / composio Mirror · read-only / commits / a9a719e35
Fork 0

Composio powers 1000+ toolkits, tool search, context management, authentication, and a sandboxed workbench to help you build AI agents that turn intent into action.

Mirrored from https://github.com/Camo67/composio.git

Synced Nov 22, 03:15 UTC

docs: update to latest GPT and Claude model versions

Update all examples and docs to use gpt-5.4 (replacing gpt-4o-mini, gpt-4o, gpt-4.1, gpt-4-turbo) and claude-sonnet-4-6 (replacing claude-3-5-sonnet-latest, claude-sonnet-4-5). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

Sushmitha Mallesh committed Mar 11, 2026 at 02:27 UTC a9a719e3511a75a60996357abf22b438b948220f
30 files changed +37 -37
docs/content/docs/single-toolkit-mcp.mdx
+2 -2
@@ -168,7 +168,7 @@ mcp_server_url = "https://backend.composio.dev/v3/mcp/YOUR_SERVER_ID?user_id=YOU
168 mcp_headers = {"x-api-key": "YOUR_COMPOSIO_API_KEY"}
169
170 response = client.beta.messages.create(
171 - model="claude-sonnet-4-5",
171 + model="claude-sonnet-4-6",
172 max_tokens=1000,
173 messages=[{"role": "user", "content": "What are my latest emails?"}],
174 mcp_servers=[{
@@ -204,7 +204,7 @@ const agent = new Agent({
204 id: "assistant",
205 name: "Assistant",
206 instructions: "You are a helpful assistant that can read and manage emails.",
207 - model: openai("gpt-4-turbo"),
207 + model: openai("gpt-5.4"),
208 tools: await client.getTools()
209 });
210
docs/content/docs/tools-direct/executing-tools.mdx
+1 -1
@@ -46,7 +46,7 @@ tools = composio.tools.get(
46
47 # Ask the LLM to check calendar
48 result = openai.chat.completions.create(
49 - model="gpt-4o-mini",
49 + model="gpt-5.4",
50 tools=tools,
51 messages=[
52 {"role": "system", "content": "You are a helpful assistant."},
docs/content/docs/tools-direct/modify-tool-behavior/after-execution-modifiers.mdx
+2 -2
@@ -49,7 +49,7 @@ tools = composio.tools.get(user_id=user_id, slug="HACKERNEWS_GET_USER")
49
50 # Get response from the LLM
51 response = openai_client.chat.completions.create(
52 - model="gpt-4o-mini",
52 + model="gpt-5.4",
53 tools=tools,
54 messages=messages,
55 )
@@ -70,7 +70,7 @@ print(result)
70 ```typescript
71 // @noErrors
72 const response = await openai.chat.completions.create({
73 - model: "gpt-4o-mini",
73 + model: "gpt-5.4",
74 messages,
75 tools,
76 tool_choice: "auto",
docs/content/docs/tools-direct/modify-tool-behavior/before-execution-modifiers.mdx
+2 -2
@@ -51,7 +51,7 @@ tools = composio.tools.get(user_id=user_id, slug="HACKERNEWS_GET_LATEST_POSTS")
51
52 # Get response from the LLM
53 response = openai_client.chat.completions.create(
54 - model="gpt-4o-mini",
54 + model="gpt-5.4",
55 tools=tools,
56 messages=[{"role": "user", "content": "Fetch latest posts from hackernews"}],
57 )
@@ -72,7 +72,7 @@ print(result)
72 ```typescript
73 // @noErrors
74 const response = await openai.chat.completions.create({
75 - model: "gpt-4o-mini",
75 + model: "gpt-5.4",
76 messages,
77 tools,
78 tool_choice: "auto",
docs/content/docs/tools-direct/modify-tool-behavior/schema-modifiers.mdx
+2 -2
@@ -121,7 +121,7 @@ tools = composio.tools.get(
121
122 # Get response from the LLM
123 response = openai_client.chat.completions.create(
124 - model="gpt-4o-mini",
124 + model="gpt-5.4",
125 tools=tools,
126 messages=[
127 {"role": "system", "content": "You are a helpful assistant."},
@@ -170,7 +170,7 @@ const tools = await composio.tools.get(
170 console.log(JSON.stringify(tools, null, 2));
171
172 const response = await openai.chat.completions.create({
173 - model: 'gpt-4o-mini',
173 + model: 'gpt-5.4',
174 messages: [
175 {
176 role: 'system',
ts/examples/anthropic/src/streaming.ts
+1 -1
@@ -31,7 +31,7 @@ async function main() {
31 console.log('🔄 Creating message with Anthropic...');
32 const stream = await anthropic.messages
33 .stream({
34 - model: 'claude-3-5-sonnet-latest',
34 + model: 'claude-sonnet-4-6',
35 max_tokens: 1024,
36 messages: [
37 {
ts/examples/cloudflare-wrangler/src/index.ts
+2 -2
@@ -133,7 +133,7 @@ app.post('/hackernews-chat', async (c) => {
133 ];
134
135 const response = await openai.chat.completions.create({
136 - model: 'gpt-4o-mini',
136 + model: 'gpt-5.4',
137 messages: [{ role: 'user', content: message }],
138 tools,
139 });
@@ -150,7 +150,7 @@ app.post('/hackernews-chat', async (c) => {
150 if (toolResponses.length > 0) {
151 // create the final response
152 const finalResponse = await openai.chat.completions.create({
153 - model: 'gpt-4o-mini',
153 + model: 'gpt-5.4',
154 messages,
155 });
156
ts/examples/connected-accounts/src/magic-flow-demo.ts
+1 -1
@@ -44,7 +44,7 @@ const messages: OpenAI.ChatCompletionMessageParam[] = [
44 ];
45
46 const response = await openai.chat.completions.create({
47 - model: 'gpt-4o-mini',
47 + model: 'gpt-5.4',
48 messages,
49 tools: tools,
50 tool_choice: 'auto',
ts/examples/langchain/src/index.ts
+1 -1
@@ -19,7 +19,7 @@ const toolNode = new ToolNode(tools);
19
20 // Create a model and give it access to the tools
21 const model = new ChatOpenAI({
22 - model: 'gpt-4o-mini',
22 + model: 'gpt-5.4',
23 temperature: 0,
24 }).bindTools(tools);
25
ts/examples/llamaindex/src/index.ts
+1 -1
@@ -56,7 +56,7 @@ async function main() {
56 const hackernewsAgent = agent({
57 name: 'Hackernews Agent',
58 description: 'A helpful hackernews assistant',
59 - llm: openai({ model: 'gpt-4o-mini' }),
59 + llm: openai({ model: 'gpt-5.4' }),
60 systemPrompt:
61 'You are a helpful hackernews assistant that helps users with their queries related to hackernews',
62 tools,
ts/examples/mastra/src/experimental.mcp.ts
+1 -1
@@ -51,7 +51,7 @@ const agent = new MastraAgent({
51 When fetching emails, provide a clear summary of the results including sender, subject, and date.
52 Be concise and provide actionable information based on the email content.
53 `,
54 - model: openai('gpt-4o-mini'),
54 + model: openai('gpt-5.4'),
55 tools,
56 });
57
ts/examples/mastra/src/experimental.tool-router.ts
+1 -1
@@ -41,7 +41,7 @@ const agent = new MastraAgent({
41 When fetching emails, provide a clear summary of the results including sender, subject, and date.
42 Be concise and provide actionable information based on the email content.
43 `,
44 - model: openai('gpt-4o-mini'),
44 + model: openai('gpt-5.4'),
45 tools,
46 });
47
ts/examples/mastra/src/index.ts
+1 -1
@@ -55,7 +55,7 @@ const hackernewsAgent = new Agent({
55 name: 'Weather Agent',
56 instructions:
57 'You are a helpful assistant that can use the Hackernews API to get user information.',
58 - model: openai('gpt-4o-mini'),
58 + model: openai('gpt-5.4'),
59 tools: tools,
60 });
61
ts/examples/mastra/src/mcp.ts
+1 -1
@@ -105,7 +105,7 @@ const gmailAgent = new Agent({
105 When fetching emails, provide a clear summary of the results including sender, subject, and date.
106 Be concise and provide actionable information based on the email content.
107 `,
108 - model: openai('gpt-4o-mini'),
108 + model: openai('gpt-5.4'),
109 tools: wrapTools(serverInstance, tools),
110 });
111
ts/examples/mcp/src/index.ts
+1 -1
@@ -42,7 +42,7 @@ const tools = await mcpClient.tools();
42
43 // 6. Pass tools to Vercel-specific Agent.
44 const stream = streamText({
45 - model: openai('gpt-4o-mini'),
45 + model: openai('gpt-5.4'),
46 messages: [
47 {
48 role: 'user',
ts/examples/openai/src/agents-api/experiment.mcp.ts
+1 -1
@@ -45,7 +45,7 @@ const agent = new OpenAIAgent({
45 When fetching emails, provide a clear summary of the results including sender, subject, and date.
46 Be concise and provide actionable information based on the email content.
47 `,
48 - model: 'gpt-4o-mini',
48 + model: 'gpt-5.4',
49 tools: tools,
50 });
51
ts/examples/openai/src/agents-api/experiment.tool-router.ts
+1 -1
@@ -40,7 +40,7 @@ const agent = new OpenAIAgent({
40 When fetching emails, provide a clear summary of the results including sender, subject, and date.
41 Be concise and provide actionable information based on the email content.
42 `,
43 - model: 'gpt-4o-mini',
43 + model: 'gpt-5.4',
44 tools: tools,
45 });
46
ts/examples/openai/src/chat-completions.ts
+2 -2
@@ -32,7 +32,7 @@ async function main() {
32 console.log(`🔄 Sending query to OpenAI: "${query}"`);
33
34 const response = await openai.chat.completions.create({
35 - model: 'gpt-4o',
35 + model: 'gpt-5.4',
36 messages: [
37 {
38 role: 'system',
@@ -64,7 +64,7 @@ async function main() {
64 console.log('✅ Tool execution result:', JSON.parse(toolResult));
65
66 const finalResponse = await openai.chat.completions.create({
67 - model: 'gpt-4o',
67 + model: 'gpt-5.4',
68 messages: [
69 {
70 role: 'system',
ts/examples/openai/src/index.ts
+1 -1
@@ -35,7 +35,7 @@ const messages: OpenAI.ChatCompletionMessageParam[] = [
35 * Create a chat completion
36 */
37 const response = await openai.chat.completions.create({
38 - model: 'gpt-4o-mini',
38 + model: 'gpt-5.4',
39 messages,
40 tools: tools,
41 tool_choice: 'auto',
ts/examples/openai/src/responses-api/experiment.mcp.ts
+1 -1
@@ -41,7 +41,7 @@ console.log({ tools });
41 // 4. Pass tools to OpenAI-specific Agent.
42 const openai = new OpenAI();
43 const emailResponse = await openai.responses.create({
44 - model: 'gpt-4o-mini',
44 + model: 'gpt-5.4',
45 instructions: `
46 You are a helpful Gmail assistant that fetches and summarizes emails.
47 When fetching emails, provide a clear summary of the results including sender, subject, and date.
ts/examples/openai/src/responses-api/index.ts
+2 -2
@@ -13,7 +13,7 @@ console.log(`✅ Tools fetched from composio`);
13
14 console.log(`🔄 Generating response from OpenAI...`);
15 const initialResponse = await openai.responses.create({
16 - model: 'gpt-4.1',
16 + model: 'gpt-5.4',
17 input: 'Tell me about the user `pg` in hackernews',
18 tools,
19 });
@@ -40,7 +40,7 @@ const modelInputs = await composio.provider.handleResponse(
40 console.log(`🔄 Submitting tool outputs to OpenAI...`);
41 console.log(JSON.stringify(modelInputs, null, 2));
42 const finalResponse = await openai.responses.create({
43 - model: 'gpt-4.1',
43 + model: 'gpt-5.4',
44 input: [...initialResponse.output, ...modelInputs],
45 tools,
46 });
ts/examples/openai/src/tools.ts
+1 -1
@@ -16,7 +16,7 @@ const tools = await composio.tools.get('default', {
16 const query = 'What is the user "pg"';
17
18 const response = await openai.chat.completions.create({
19 - model: 'gpt-4o',
19 + model: 'gpt-5.4',
20 messages: [
21 {
22 role: 'system',
ts/examples/tool-router/src/claude-agent-sdk.ts
+1 -1
@@ -9,7 +9,7 @@ const session = await composio.create('user_123', { toolkits: ['gmail'] });
9 const stream = await query({
10 prompt: 'Use composio tools to fetch my last email from gmail',
11 options: {
12 - model: 'claude-sonnet-4-5-20250929',
12 + model: 'claude-sonnet-4-6',
13 permissionMode: "bypassPermissions",
14 mcpServers: {
15 composio: {
ts/examples/tool-router/src/index.ts
+1 -1
@@ -13,7 +13,7 @@ const session = await composio.create('user_123', { toolkits: ['gmail'] });
13 const tools = await session.tools(modifiers);
14
15 const stream = await streamText({
16 - model: openai('gpt-4o-mini'),
16 + model: openai('gpt-5.4'),
17 prompt: 'Find my last email from gmail?',
18 stopWhen: stepCountIs(10),
19 tools,
ts/examples/tool-router/src/langchain.ts
+1 -1
@@ -8,7 +8,7 @@ const composio = new Composio({
8 });
9
10 const llm = new ChatOpenAI({
11 - model: "gpt-4o",
11 + model: "gpt-5.4",
12 })
13
14 async function main() {
ts/examples/tool-router/src/mcp.ts
+1 -1
@@ -31,7 +31,7 @@ mcpProgress.succeed(`${Object.values(tools).length} tools retrieved from MCP`);
31
32 console.log(`🤖 Waiting for agent response...`);
33 const stream = await streamText({
34 - model: openai('gpt-4o-mini'),
34 + model: openai('gpt-5.4'),
35 prompt: 'Summarize my latest received email from gmail.',
36 stopWhen: stepCountIs(10),
37 onStepFinish: (step) => {
ts/examples/tools/src/ai.ts
+1 -1
@@ -41,7 +41,7 @@ const messages: OpenAI.ChatCompletionMessageParam[] = [
41 */
42 console.log('🔄 Creating chat completion...');
43 const response = await openai.chat.completions.create({
44 - model: 'gpt-4o-mini',
44 + model: 'gpt-5.4',
45 messages,
46 tools: tools,
47 tool_choice: 'auto',
ts/examples/vercel/src/ai.ts
+1 -1
@@ -35,7 +35,7 @@ async function run() {
35 ];
36
37 const { text } = await generateText({
38 - model: openai('gpt-4o-mini'),
38 + model: openai('gpt-5.4'),
39 tools,
40 messages,
41 stopWhen: stepCountIs(5),
ts/examples/vercel/src/stream.ts
+1 -1
@@ -13,7 +13,7 @@ const composio = new Composio({
13
14 const tools = await composio.tools.get('test-user-id', 'HACKERNEWS_GET_FRONTPAGE');
15 const stream = await streamText({
16 - model: openai('gpt-4o-mini'),
16 + model: openai('gpt-5.4'),
17 tools,
18 prompt: 'Summarize the front page of HackerNews',
19 stopWhen: stepCountIs(5),
ts/examples/vercel/src/tool-loop-agent.ts
+1 -1
@@ -32,7 +32,7 @@ console.log(`✅ Tools loaded: ${Object.keys(tools).join(', ')}`);
32
33 // 3. Create a ToolLoopAgent with Composio tools
34 const hackerNewsAgent = new ToolLoopAgent({
35 - model: openai('gpt-4o-mini'),
35 + model: openai('gpt-5.4'),
36 instructions: `You are a helpful assistant that can look up information about Hacker News users.
37 When asked about a user, use the available tools to fetch their profile information.
38 Provide a concise summary of the user's profile including their karma, about section, and any other relevant details.`,