@devries-cameron20 / composio Mirror · read-only / commits / a032fb8ed
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: add managed auth list page and improve toolkits landing

Add searchable managed auth page at /toolkits/managed-auth with tabs for managed vs unmanaged OAuth toolkits, copy slugs, and auto-tab switching on search. Use fumadocs Cards on toolkits landing page. Add server-side markdown generation for LLM view. Fix title/back-link ordering for toolkit MDX pages. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

Sushmitha Mallesh committed Mar 9, 2026 at 20:05 UTC a032fb8edc351ab8c1a832ea528bb89a9d60325b
8 files changed +313 -18
docs/app/(home)/toolkits/[[...slug]]/page.tsx
+2
@@ -208,6 +208,8 @@ export default async function ToolkitsPage({ params }: { params: Promise<{ slug?
208 const MDXContent = page.data.body;
209 return (
210 <article className="prose prose-fd max-w-none">
211 + <a href="/toolkits" className="text-sm text-fd-primary no-underline hover:underline">← All Toolkits</a>
212 + <h1>{page.data.title}</h1>
213 <PageActions path={page.url} />
214 <MDXContent components={getMDXComponents()} />
215 </article>
docs/app/llms.mdx/[[...slug]]/route.ts
+67
@@ -706,6 +706,60 @@ function toolkitToMarkdown(toolkit: Toolkit, detailedTools?: Tool[], detailedTri
706 return lines.join('\n');
707 }
708
709 +// Generate markdown for /toolkits/managed-auth.md
710 +async function generateManagedAuthIndex(): Promise<string> {
711 + const toolkits = await getAllToolkits();
712 +
713 + // Only include OAuth toolkits
714 + const oauthToolkits = toolkits.filter((t) =>
715 + t.authSchemes?.some((s) => s.toUpperCase().includes('OAUTH'))
716 + );
717 +
718 + const managed = oauthToolkits
719 + .filter((t) => t.composioManagedAuthSchemes && t.composioManagedAuthSchemes.length > 0)
720 + .sort((a, b) => (a.name?.trim() || '').localeCompare(b.name?.trim() || ''));
721 +
722 + const unmanaged = oauthToolkits
723 + .filter((t) => !t.composioManagedAuthSchemes || t.composioManagedAuthSchemes.length === 0)
724 + .sort((a, b) => (a.name?.trim() || '').localeCompare(b.name?.trim() || ''));
725 +
726 + const lines: string[] = [
727 + '# Composio Managed Auth',
728 + '',
729 + 'Toolkits with managed auth work out of the box with no OAuth setup. For toolkits without managed auth, you need to provide your own credentials.',
730 + '',
731 + 'You can also check programmatically whether a toolkit has managed auth:',
732 + '',
733 + '```bash',
734 + "curl 'https://backend.composio.dev/api/v3/toolkits/posthog' \\",
735 + " -H 'x-api-key: YOUR_API_KEY'",
736 + '```',
737 + '',
738 + 'See [When to use your own developer credentials](/docs/custom-app-vs-managed-app.md) for help deciding which approach fits your use case.',
739 + '',
740 + `## Composio Managed App Available (${managed.length})`,
741 + '',
742 + '| Toolkit | Slug |',
743 + '|---------|------|',
744 + ];
745 +
746 + for (const t of managed) {
747 + lines.push(`| [${t.name?.trim() || t.slug}](/toolkits/${t.slug}.md) | \`${t.slug.toUpperCase()}\` |`);
748 + }
749 +
750 + lines.push('');
751 + lines.push(`## Requires Your Own Credentials (${unmanaged.length})`);
752 + lines.push('');
753 + lines.push('| Toolkit | Slug |');
754 + lines.push('|---------|------|');
755 +
756 + for (const t of unmanaged) {
757 + lines.push(`| [${t.name?.trim() || t.slug}](/toolkits/${t.slug}.md) | \`${t.slug.toUpperCase()}\` |`);
758 + }
759 +
760 + return lines.join('\n');
761 +}
762 +
763 // Generate a comprehensive toolkits index for /toolkits.md
764 async function generateToolkitsIndex(): Promise<string> {
765 const toolkits = await getAllToolkits();
@@ -720,6 +774,9 @@ async function generateToolkitsIndex(): Promise<string> {
774 '',
775 `Composio supports ${toolkits.length} toolkits for building AI agents.`,
776 '',
777 + '- [Premium Tools](/toolkits/premium-tools.md) - Learn about pricing and limits',
778 + '- [Composio Managed Auth](/toolkits/managed-auth.md) - Check which toolkits have managed auth',
779 + '',
780 '## All Toolkits',
781 '',
782 '| Toolkit | Slug | Tools | Triggers | Auth | Managed App |',
@@ -852,6 +909,16 @@ export async function GET(
909 });
910 }
911
912 + // Special handling for managed auth page - generate server-side list
913 + if (prefix === 'toolkits' && rest.length === 1 && rest[0] === 'managed-auth') {
914 + const managedAuthIndex = await generateManagedAuthIndex();
915 + return new Response(managedAuthIndex, {
916 + headers: {
917 + 'Content-Type': 'text/markdown; charset=utf-8',
918 + },
919 + });
920 + }
921 +
922 // Special handling for changelog index - /docs/changelog
923 if (prefix === 'docs' && rest[0] === 'changelog' && rest.length === 1) {
924 const changelogIndex = generateChangelogIndex();
docs/components/toolkits/managed-auth-list.tsx new
+208
@@ -0,0 +1,208 @@
1 +'use client';
2 +
3 +import { useState, useMemo, useDeferredValue, useEffect, useRef } from 'react';
4 +import Link from 'next/link';
5 +import { Search, Copy, Check } from 'lucide-react';
6 +
7 +interface ManagedAuthToolkit {
8 + slug: string;
9 + name: string;
10 + logo: string | null;
11 + authSchemes: string[];
12 + composioManagedAuthSchemes?: string[];
13 + toolCount: number;
14 + triggerCount: number;
15 +}
16 +
17 +function CopyButton({ toolkits }: { toolkits: ManagedAuthToolkit[] }) {
18 + const [copied, setCopied] = useState(false);
19 +
20 + const handleCopy = () => {
21 + const text = toolkits.map((t) => t.slug).join(', ');
22 + navigator.clipboard.writeText(text);
23 + setCopied(true);
24 + setTimeout(() => setCopied(false), 2000);
25 + };
26 +
27 + return (
28 + <button
29 + onClick={handleCopy}
30 + className="inline-flex items-center gap-1 text-xs text-fd-muted-foreground transition-colors hover:text-fd-foreground"
31 + >
32 + {copied ? <Check className="h-3 w-3 text-green-500" /> : <Copy className="h-3 w-3" />}
33 + {copied ? 'Copied!' : 'Copy slugs'}
34 + </button>
35 + );
36 +}
37 +
38 +function CopySlugButton({ slug }: { slug: string }) {
39 + const [copied, setCopied] = useState(false);
40 +
41 + const handleCopy = (e: React.MouseEvent) => {
42 + e.preventDefault();
43 + navigator.clipboard.writeText(slug.toUpperCase());
44 + setCopied(true);
45 + setTimeout(() => setCopied(false), 2000);
46 + };
47 +
48 + return (
49 + <button
50 + onClick={handleCopy}
51 + aria-label={`Copy ${slug.toUpperCase()} to clipboard`}
52 + className="inline-flex items-center gap-1 rounded bg-fd-muted px-1.5 py-0.5 font-mono text-xs text-fd-muted-foreground transition-colors hover:text-fd-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-orange-500"
53 + >
54 + <span className="max-w-[120px] truncate sm:max-w-none">{slug.toUpperCase()}</span>
55 + {copied ? <Check className="h-3 w-3 text-green-500" aria-hidden="true" /> : <Copy className="h-3 w-3" aria-hidden="true" />}
56 + </button>
57 + );
58 +}
59 +
60 +function ToolkitIcon({ toolkit }: { toolkit: ManagedAuthToolkit }) {
61 + const [imgFailed, setImgFailed] = useState(false);
62 + const fallback = toolkit.name.trim().charAt(0).toUpperCase();
63 +
64 + return (
65 + <div className="flex h-9 w-9 shrink-0 items-center justify-center rounded-lg border border-fd-border/50 bg-fd-background text-sm font-medium text-fd-muted-foreground sm:h-10 sm:w-10">
66 + {toolkit.logo && !imgFailed ? (
67 + <img
68 + src={toolkit.logo}
69 + alt=""
70 + loading="lazy"
71 + decoding="async"
72 + className="h-[65%] w-[65%] object-contain"
73 + onError={() => setImgFailed(true)}
74 + />
75 + ) : (
76 + fallback
77 + )}
78 + </div>
79 + );
80 +}
81 +
82 +function ToolkitRow({ toolkit }: { toolkit: ManagedAuthToolkit }) {
83 + return (
84 + <Link
85 + href={`/toolkits/${toolkit.slug}`}
86 + className="group flex flex-col gap-2 px-2 py-3 transition-colors hover:bg-fd-accent/30 sm:flex-row sm:items-center sm:justify-between sm:px-0 sm:py-2.5"
87 + >
88 + <div className="flex items-center gap-3">
89 + <ToolkitIcon toolkit={toolkit} />
90 + <div className="flex min-w-0 flex-1 flex-col gap-1 sm:flex-row sm:items-center sm:gap-3">
91 + <span className="truncate text-sm font-medium text-fd-foreground">{toolkit.name.trim()}</span>
92 + <CopySlugButton slug={toolkit.slug} />
93 + </div>
94 + </div>
95 + </Link>
96 + );
97 +}
98 +
99 +export function ManagedAuthList() {
100 + const [data, setData] = useState<ManagedAuthToolkit[] | null>(null);
101 + const [tab, setTab] = useState<'managed' | 'unmanaged'>('managed');
102 + const [search, setSearch] = useState('');
103 + const deferredSearch = useDeferredValue(search);
104 +
105 + useEffect(() => {
106 + fetch('/data/toolkits.json')
107 + .then((res) => res.json())
108 + .then((all: ManagedAuthToolkit[]) => {
109 + setData(all.filter((t) => t.authSchemes?.some((s) => s.toUpperCase().includes('OAUTH'))));
110 + });
111 + }, []);
112 +
113 + const filtered = useMemo(() => {
114 + if (!data) return [];
115 + const s = deferredSearch.toLowerCase();
116 + const list = s
117 + ? data.filter((t) => t.name.toLowerCase().includes(s) || t.slug.toLowerCase().includes(s))
118 + : data;
119 + return list.sort((a, b) => a.name.trim().localeCompare(b.name.trim()));
120 + }, [data, deferredSearch]);
121 +
122 + const managed = useMemo(
123 + () => filtered.filter((t) => t.composioManagedAuthSchemes && t.composioManagedAuthSchemes.length > 0),
124 + [filtered]
125 + );
126 + const notManaged = useMemo(
127 + () => filtered.filter((t) => !t.composioManagedAuthSchemes || t.composioManagedAuthSchemes.length === 0),
128 + [filtered]
129 + );
130 +
131 + // Auto-switch tab when search leaves current tab empty but other has results
132 + const prevSearch = useRef(deferredSearch);
133 + useEffect(() => {
134 + if (deferredSearch !== prevSearch.current) {
135 + prevSearch.current = deferredSearch;
136 + if (tab === 'managed' && managed.length === 0 && notManaged.length > 0) {
137 + setTab('unmanaged');
138 + } else if (tab === 'unmanaged' && notManaged.length === 0 && managed.length > 0) {
139 + setTab('managed');
140 + }
141 + }
142 + }, [deferredSearch, tab, managed.length, notManaged.length]);
143 +
144 + const activeList = tab === 'managed' ? managed : notManaged;
145 +
146 + if (!data) {
147 + return <p className="py-8 text-center text-sm text-fd-muted-foreground">Loading toolkits...</p>;
148 + }
149 +
150 + return (
151 + <div className="space-y-4">
152 + {/* Search */}
153 + <div className="relative">
154 + <Search className="absolute left-3 top-1/2 h-4 w-4 -translate-y-1/2 text-fd-muted-foreground" />
155 + <input
156 + type="text"
157 + placeholder="Search toolkits..."
158 + autoComplete="off"
159 + value={search}
160 + onChange={(e) => setSearch(e.target.value)}
161 + className="h-10 w-full rounded-lg border border-fd-border bg-fd-background pl-10 pr-4 text-sm text-fd-foreground placeholder:text-fd-muted-foreground focus:outline-none focus-visible:border-orange-500/50 focus-visible:ring-2 focus-visible:ring-orange-500/20"
162 + />
163 + </div>
164 +
165 + {/* Tabs + Copy */}
166 + <div className="flex items-center justify-between border-b border-fd-border">
167 + <div className="flex items-center gap-1">
168 + <button
169 + onClick={() => setTab('managed')}
170 + className={`flex items-center gap-2 border-b-2 px-3 py-2 text-sm font-medium transition-colors ${
171 + tab === 'managed'
172 + ? 'border-green-500 text-fd-foreground'
173 + : 'border-transparent text-fd-muted-foreground hover:text-fd-foreground'
174 + }`}
175 + >
176 + <span className="inline-block h-2 w-2 rounded-full bg-green-500" />
177 + Composio Managed App Available
178 + <span className="rounded-full bg-fd-muted px-1.5 py-0.5 text-xs">{managed.length}</span>
179 + </button>
180 + <button
181 + onClick={() => setTab('unmanaged')}
182 + className={`flex items-center gap-2 border-b-2 px-3 py-2 text-sm font-medium transition-colors ${
183 + tab === 'unmanaged'
184 + ? 'border-amber-500 text-fd-foreground'
185 + : 'border-transparent text-fd-muted-foreground hover:text-fd-foreground'
186 + }`}
187 + >
188 + <span className="inline-block h-2 w-2 rounded-full bg-amber-500" />
189 + Requires your own credentials
190 + <span className="rounded-full bg-fd-muted px-1.5 py-0.5 text-xs">{notManaged.length}</span>
191 + </button>
192 + </div>
193 + <CopyButton toolkits={activeList} />
194 + </div>
195 +
196 + {/* List */}
197 + {activeList.length > 0 ? (
198 + <div className="divide-y divide-fd-border">
199 + {activeList.map((t) => (
200 + <ToolkitRow key={t.slug} toolkit={t} />
201 + ))}
202 + </div>
203 + ) : (
204 + <p className="py-8 text-center text-sm text-fd-muted-foreground">No toolkits found.</p>
205 + )}
206 + </div>
207 + );
208 +}
docs/components/toolkits/toolkits-landing.tsx
+7 -13
@@ -2,7 +2,8 @@
2
3 import { useState, useMemo, useDeferredValue } from 'react';
4 import Link from 'next/link';
5 -import { Search, Sparkles, ArrowRight, Wrench, Zap, Copy, Check, ExternalLink, Grip } from 'lucide-react';
5 +import { Search, Sparkles, Wrench, Zap, Copy, Check, ExternalLink, Grip, ShieldCheck } from 'lucide-react';
6 +import { Card, Cards } from 'fumadocs-ui/components/card';
7 import toolkitsData from '@/public/data/toolkits-list.json';
8 import type { ToolkitSummary } from '@/types/toolkit';
9 import { PageActions } from '@/components/page-actions';
@@ -178,18 +179,11 @@ export function ToolkitsLanding() {
179 </div>
180 </div>
181
181 - {/* Premium Tools Card */}
182 - <Link
183 - href="/toolkits/premium-tools"
184 - className="group flex items-center justify-between gap-3 rounded-md border border-orange-500/30 bg-orange-500/5 px-3 py-2.5 transition-all hover:border-orange-500/50 hover:bg-orange-500/10"
185 - >
186 - <div className="flex flex-wrap items-center gap-x-2 gap-y-1">
187 - <Sparkles className="h-4 w-4 shrink-0 text-orange-500" />
188 - <span className="text-sm font-medium text-fd-foreground">Premium Tools</span>
189 - <span className="hidden text-sm text-fd-muted-foreground sm:inline">— Learn about pricing and limits</span>
190 - </div>
191 - <ArrowRight className="h-4 w-4 shrink-0 text-fd-muted-foreground transition-transform group-hover:translate-x-1 group-hover:text-orange-500" />
192 - </Link>
182 + {/* Cards */}
183 + <Cards>
184 + <Card icon={<ShieldCheck />} title="Composio Managed Auth" href="/toolkits/managed-auth" description="Check which toolkits have managed auth" />
185 + <Card icon={<Sparkles />} title="Premium Tools" href="/toolkits/premium-tools" description="Learn about pricing and limits" />
186 + </Cards>
187
188 {/* Search */}
189 <div className="relative">
docs/content/docs/common-faq.mdx
+10 -1
@@ -231,7 +231,16 @@ curl 'https://backend.composio.dev/api/v3/toolkits/github' \
231 -H 'x-api-key: YOUR_API_KEY'
232 ```
233
234 -If the array is empty, you'll need to provide your own credentials. You can also check on each toolkit's page on the [toolkits page](/toolkits).
234 +If the array is empty, you'll need to provide your own credentials.
235 +
236 +To fetch all toolkits and filter by managed auth availability, use the list endpoint:
237 +
238 +```bash
239 +curl 'https://backend.composio.dev/api/v3/toolkits' \
240 + -H 'x-api-key: YOUR_API_KEY'
241 +```
242 +
243 +Each toolkit in the response includes `composio_managed_auth_schemes`. You can also browse the full list on the [managed auth page](/toolkits/managed-auth) or check individual toolkit pages on the [toolkits page](/toolkits).
244 </Accordion>
245
246 <Accordion title="What happens to existing connections when I switch to my own OAuth app?">
docs/content/toolkits/managed-auth.mdx new
+17
@@ -0,0 +1,17 @@
1 +---
2 +title: Managed Auth
3 +description: Check which toolkits have Composio managed authentication
4 +---
5 +
6 +Toolkits with managed auth work out of the box with no OAuth setup. For toolkits without managed auth, you need to provide your own credentials.
7 +
8 +You can also check programmatically whether a toolkit has managed auth:
9 +
10 +```bash
11 +curl 'https://backend.composio.dev/api/v3/toolkits/posthog' \
12 + -H 'x-api-key: YOUR_API_KEY'
13 +```
14 +
15 +See [When to use your own developer credentials](/docs/custom-app-vs-managed-app) for help deciding which approach fits your use case.
16 +
17 +<ManagedAuthList />
docs/content/toolkits/premium-tools.mdx
-4
@@ -3,10 +3,6 @@ title: Premium Tools
3 description: Learn about premium tools, pricing, and limits in Composio
4 ---
5
6 -[← All Toolkits](/toolkits)
7 -
8 -# Premium Tools
9 -
6 This is a quick overview of premium tools, what they are, how they are priced, what limits they have and such.
7
8 ## What are premium tools?
docs/mdx-components.tsx
+2
@@ -20,6 +20,7 @@ import { Video } from '@/components/video';
20 import { CapabilityCard, CapabilityList } from '@/components/capability-card';
21 import { TemplateCard, TemplateGrid } from '@/components/template-card';
22 import { ToolkitsLanding } from '@/components/toolkits/toolkits-landing';
23 +import { ManagedAuthList } from '@/components/toolkits/managed-auth-list';
24 import { Mermaid } from '@/components/mermaid';
25 import { AIToolsBanner } from '@/components/ai-tools-banner';
26 import { Glossary, GlossaryTerm } from '@/components/glossary';
@@ -92,6 +93,7 @@ export function getMDXComponents(components?: MDXComponents): MDXComponents {
93 TemplateCard,
94 TemplateGrid,
95 ToolkitsLanding,
96 + ManagedAuthList,
97 Mermaid,
98 AIToolsBanner,
99 StepTitle,