Skip to content

components_v2_preview

Components v2 Read only

Render a Components V2 layout as ASCII so the agent can sanity-check structure without sending. Pairs with components_v2_validate for offline iteration.

{
"name": "components_v2_preview",
"arguments": {
"components": [
{
"type": 10,
"content": "Hello from discord-mcp"
}
]
}
}
FieldTypeRequiredConstraintsDescription
componentsarray<unknown>yesComponents array to render
Complete input JSON Schema
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"components": {
"type": "array",
"items": {},
"description": "Components array to render"
}
},
"required": [
"components"
]
}

{ascii} - multi-line string visualizing the layout.

{
"ascii": "example"
}
FieldTypeRequiredConstraintsDescription
asciistringyes
Complete output JSON Schema
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"ascii": {
"type": "string"
}
},
"required": [
"ascii"
],
"additionalProperties": false
}
PropertyValue
Read-onlyyes
Destructiveno
Idempotentyes
Open-worldno
Confirmation requiredno
  • The components_v2 category must be enabled by MCP_CATEGORIES when an allowlist is set.
  • This tool is local-only and does not call Discord. Schema or domain validation can still reject malformed input.

packages/mcp-core/src/tools/components-v2/preview-tool.ts