Skip to content

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

fix(docs): fix redundant "array of X[]" type display

Sushmithamallesh3c47b938dce2
diff --git a/docs/components/schema-generator.tsx b/docs/components/schema-generator.tsx
index 14341024f..c5e472310 100644
--- a/docs/components/schema-generator.tsx
+++ b/docs/components/schema-generator.tsx
@@ -110,13 +110,19 @@ export function generateSchemaData(
const id = getSchemaId(schema);
if (id in refs) return id;
+ // For arrays, aliasName is the item type (used in "array of X" display)
+ const aliasName =
+ schema.type === 'array' && schema.items
+ ? getTypeName(schema.items)
+ : getTypeName(schema);
+
const base: FieldBase = {
description: schema.description
? ctx.renderMarkdown(schema.description)
: undefined,
infoTags: generateInfoTags(schema),
typeName: getTypeName(schema),
- aliasName: getTypeName(schema),
+ aliasName,
deprecated: schema.deprecated,
enumValues: schema.enum
? schema.enum.map((v: unknown) => String(v))