Компоненты
- Accordion
- Alert
- Alert Dialog
- Autocomplete
- Avatar
- Badge
- Breadcrumb
- Button
- Calendar
- Card
- Checkbox
- Checkbox Group
- Collapsible
- Combobox
- Command
- Date Picker
- Dialog
- DrawerNew
- Empty
- Field
- Fieldset
- Form
- Frame
- Group
- Input
- Input Group
- Kbd
- Label
- Menu
- Meter
- Number Field
- OTP FieldNew
- Pagination
- Popover
- Preview Card
- Progress
- Radio Group
- Scroll Area
- Select
- Separator
- Sheet
- Skeleton
- Slider
- Spinner
- Switch
- Table
- Tabs
- Textarea
- Toast
- Toggle
- Toggle Group
- Toolbar
- Tooltip
AI Components
- AI Components
- Chat Conversation
- Chat Message
- Chat Response
- Chat Suggestion
- Chat Prompt Input
- Chat Attachments
- Chat Code Block
- Chat Image
- Chat Inline Citation
- Chat Reasoning
- Chat Sources
- Chat Actions
- Chat Context
- Chat Loader
- Chat Task
- Chat Tool
- Chat Web Preview
- Chat Snippet
- Chat Terminal
- Chat Stack Trace
- Chat Test Results
- Chat File Tree
- Chat Environment Variables
- Chat Audio Player
- Chat Transcription
- Chat Speech Input
- Chat Mic Selector
- Chat Voice Selector
- Chat Agent
- Chat Persona
- Chat Connection
- Chat Queue
- Chat Checkpoint
- Chat Confirmation
- Chat Artifact
- Chat JSX Preview
- Chat Schema Display
- Chat Package Info
- Chat Commit
- Chat Plan
- Chat Panel
- Chat Open In Chat
- Chat Sandbox
- Chat Model Selector
- Chat Canvas
- Chat Node
- Chat Edge
Resources
Chat Schema Display
Визуализатор API/функционального схемы — method, path, request/response параметры.
POST/api/sessions
Create a new chat session and return its identifier. Requires an authenticated user.
systemPromptstringrequired
Initial system prompt for the agent.
modelstringoptional
Model identifier — claude-opus-4-7 by default.
toolsstring[]optional
Optional tool list to enable.
idstringrequired
createdAtstringrequired
ISO-8601 timestamp of session creation.
import {
ChatSchemaDisplay,
ChatSchemaDisplayContent,
ChatSchemaDisplayDescription,
ChatSchemaDisplayHeader,
ChatSchemaDisplayMethod,
ChatSchemaDisplayPath,
ChatSchemaParameter,
ChatSchemaSection,
} from "@/components/ui/chat-schema-display";
export default function Particle() {
return (
<div className="w-full max-w-2xl p-4">
<ChatSchemaDisplay>
<ChatSchemaDisplayHeader>
<ChatSchemaDisplayMethod method="POST" />
<ChatSchemaDisplayPath>/api/sessions</ChatSchemaDisplayPath>
</ChatSchemaDisplayHeader>
<ChatSchemaDisplayDescription>
Create a new chat session and return its identifier. Requires an
authenticated user.
</ChatSchemaDisplayDescription>
<ChatSchemaDisplayContent>
<ChatSchemaSection label="Request body">
<ChatSchemaParameter
description="Initial system prompt for the agent."
name="systemPrompt"
required
type="string"
/>
<ChatSchemaParameter
description="Model identifier — claude-opus-4-7 by default."
name="model"
type="string"
/>
<ChatSchemaParameter
description="Optional tool list to enable."
name="tools"
type="string[]"
/>
</ChatSchemaSection>
<ChatSchemaSection label="Response">
<ChatSchemaParameter name="id" required type="string" />
<ChatSchemaParameter
description="ISO-8601 timestamp of session creation."
name="createdAt"
required
type="string"
/>
</ChatSchemaSection>
</ChatSchemaDisplayContent>
</ChatSchemaDisplay>
</div>
);
}
Installation
pnpm dlx shadcn@latest add @jenny/chat-schema-display
Usage
import {
ChatSchemaDisplay,
ChatSchemaDisplayContent,
ChatSchemaDisplayDescription,
ChatSchemaDisplayHeader,
ChatSchemaDisplayMethod,
ChatSchemaDisplayPath,
ChatSchemaParameter,
ChatSchemaSection,
} from "@/components/ui/chat-schema-display";
<ChatSchemaDisplay>
<ChatSchemaDisplayHeader>
<ChatSchemaDisplayMethod method="POST" />
<ChatSchemaDisplayPath>/api/sessions</ChatSchemaDisplayPath>
</ChatSchemaDisplayHeader>
<ChatSchemaDisplayDescription>
Create a new chat session and return its ID.
</ChatSchemaDisplayDescription>
<ChatSchemaDisplayContent>
<ChatSchemaSection label="Request body">
<ChatSchemaParameter
description="Initial system prompt for the agent."
name="systemPrompt"
required
type="string"
/>
<ChatSchemaParameter
description="Model identifier (claude-opus-4-7 by default)."
name="model"
type="string"
/>
</ChatSchemaSection>
<ChatSchemaSection label="Response">
<ChatSchemaParameter name="id" required type="string" />
<ChatSchemaParameter name="createdAt" required type="string (ISO)" />
</ChatSchemaSection>
</ChatSchemaDisplayContent>
</ChatSchemaDisplay>Methods
GET / POST / PUT / PATCH / DELETE / HEAD / OPTIONS — каждый со своим цветом badge.
<ChatSchemaParameter> рендерит name (mono), type (mono muted), и required/optional. description — серой строкой ниже.
On This Page