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, 10:45 UTC
docs: hide redundant error schemas and TypeScript definitions
- Skip rendering Error schema on error responses (all 290 use identical schema) - Disable TypeScript Definitions box on responses - Hide empty schema wrapper divs left by null renders - Error accordions still show status code + description Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Sushmithamallesh committed
Feb 3, 2026 at 16:30 UTC
3d5f7192f60465409f1cbed53ce7eaf16070bf0c
2 files changed
+11
docs/app/global.css
+5
@@ -488,6 +488,11 @@ div.flex.items-center:has(> span.font-mono.text-fd-primary > span.text-red-400)
488
color: #f87171;
489
}
490
491
+/* Hide empty schema wrapper divs (e.g. when Error schema is skipped) */
492
+div.border.rounded-lg:not(:has(*)) {
493
+ display: none;
494
+}
495
+
496
/* Hide redundant "application/json" content type labels */
497
p.text-fd-muted-foreground.not-prose:has(> code.text-xs) {
498
display: none;
docs/components/api-page.tsx
+6
@@ -6,8 +6,14 @@ import { CustomSchemaUI } from './custom-schema-ui';
6
7
export const APIPage = createAPIPage(openapi, {
8
client,
9
+ generateTypeScriptSchema: false,
10
schemaUI: {
11
render: (options, ctx) => {
12
+ // Skip rendering the shared Error schema on error responses -
13
+ // the status code and description are shown by the accordion already
14
+ const ref = ctx.schema.getRawRef(options.root);
15
+ if (ref === '#/components/schemas/Error') return null;
16
+
17
const generated = generateSchemaData(
18
{
19
root: options.root,