guild_blueprint_compile
Turn one natural-language server request into a complete, deterministic, read-only Discord guild blueprint. The tool selects one verified primary public template and up to three bounded inspirations internally, then converts their structural signals and capability modules into safe channels, roles, regenerated permissions, onboarding, AutoMod, and Components V2 content.
When to use
Section titled “When to use”Use this as the high-level entrypoint for requests such as “build a professional gaming server”. A small model needs only this one call; it does not need to call templates_recommend first or pass template output between tools.
Safety
Section titled “Safety”Templates are verified structural references, not literal layouts. Source template IDs, permissions, overwrites, names, and descriptions never enter the trusted blueprint. All references are symbolic, generated roles and overwrites reject dangerous permissions, onboarding and AutoMod limits are validated, Components V2 channel placeholders must be resolved and revalidated before send, and this tool never changes Discord.
MCP call example
Section titled “MCP call example”{ "name": "guild_blueprint_compile", "arguments": { "request": "example" }}| Field | Type | Required | Constraints | Description |
|---|---|---|---|---|
request |
string | yes | min length: 3; max length: 500 |
Natural-language description of the Discord server to design |
preferred_primary_code |
string | no | min length: 1; max length: 100; pattern: ^[a-zA-Z0-9_-]+$ |
Optional public template code to prefer only when relevant and live-verified safe |
Complete input JSON Schema
{ "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "properties": { "request": { "type": "string", "minLength": 3, "maxLength": 500, "description": "Natural-language description of the Discord server to design" }, "preferred_primary_code": { "description": "Optional public template code to prefer only when relevant and live-verified safe", "type": "string", "minLength": 1, "maxLength": 100, "pattern": "^[a-zA-Z0-9_-]+$" } }, "required": [ "request" ]}Returns
Section titled “Returns”Verified source evidence, a stable blueprint_id, the symbolic blueprint, bounded verification counters, and explicit prerequisites for a later target-guild dry-run/apply step.
Example structured result
Section titled “Example structured result”{ "status": "no_match", "request": "zzzz qqqq no such intent", "source": { "catalog_version": "example", "primary": null, "inspirations": [], "permission_policy": "discard_source_and_regenerate" }, "blueprint_id": null, "blueprint": null, "verification": { "catalog_records": 4970, "metadata_candidates": 0, "candidates_inspected": 0, "rest_requests": 0, "cache_hits": 0, "rest_verified": 0, "rest_failed": 0, "safety_rejected": 0, "blueprint_validation": "not_run", "blueprint_bytes": 0 }, "warnings": [ "A verified primary template is required before compiling a deployable blueprint." ]}Output schema
Section titled “Output schema”| Field | Type | Required | Constraints | Description |
|---|---|---|---|---|
status |
“ready” | “partial” | “no_match” | yes | one of ready, partial, no_match |
|
request |
string | yes | ||
source |
object | yes | ||
blueprint_id |
string | null | yes | ||
blueprint |
object | null | yes | ||
verification |
object | yes | ||
warnings |
array<string> | yes |
Complete output JSON Schema
{ "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "properties": { "status": { "type": "string", "enum": [ "ready", "partial", "no_match" ] }, "request": { "type": "string" }, "source": { "type": "object", "properties": { "catalog_version": { "type": "string" }, "primary": { "anyOf": [ { "type": "object", "properties": { "code": { "type": "string", "minLength": 1, "maxLength": 100, "pattern": "^[a-zA-Z0-9_-]+$" }, "use_url": { "type": "string", "format": "uri" }, "score": { "type": "number", "minimum": 0, "maximum": 100 }, "matched_capabilities": { "type": "array", "items": { "type": "string", "enum": [ "gaming", "community", "roleplay", "lfg", "platform", "staff", "support", "events", "technology", "learning", "art", "music", "voice", "forum" ] } }, "effective_capabilities": { "type": "array", "items": { "type": "string", "enum": [ "gaming", "community", "roleplay", "lfg", "platform", "staff", "support", "events", "technology", "learning", "art", "music", "voice", "forum" ] } }, "contributes": { "type": "array", "items": { "type": "string", "enum": [ "gaming", "community", "roleplay", "lfg", "platform", "staff", "support", "events", "technology", "learning", "art", "music", "voice", "forum" ] } }, "structural_contributions": { "type": "array", "items": { "type": "string", "enum": [ "categories", "text_channels", "voice_channels", "forums", "stages", "custom_roles" ] } }, "reasons": { "type": "array", "items": { "type": "string" } }, "blueprint": { "type": "object", "properties": { "channel_count": { "type": "integer", "minimum": 0 }, "category_count": { "type": "integer", "minimum": 0 }, "text_channel_count": { "type": "integer", "minimum": 0 }, "voice_channel_count": { "type": "integer", "minimum": 0 }, "forum_channel_count": { "type": "integer", "minimum": 0 }, "stage_channel_count": { "type": "integer", "minimum": 0 }, "other_channel_count": { "type": "integer", "minimum": 0 }, "nsfw_channel_count": { "type": "integer", "minimum": 0 }, "permission_overwrite_count": { "type": "integer", "minimum": 0 }, "role_count": { "type": "integer", "minimum": 0 }, "privileged_role_count": { "type": "integer", "minimum": 0 }, "risky_permission_signals": { "type": "array", "items": { "type": "object", "properties": { "permission": { "type": "string", "enum": [ "ADMINISTRATOR", "MANAGE_GUILD", "MANAGE_ROLES", "MANAGE_CHANNELS", "MANAGE_WEBHOOKS", "KICK_MEMBERS", "BAN_MEMBERS", "MENTION_EVERYONE" ] }, "role_count": { "type": "integer", "exclusiveMinimum": 0 } }, "required": [ "permission", "role_count" ], "additionalProperties": false } } }, "required": [ "channel_count", "category_count", "text_channel_count", "voice_channel_count", "forum_channel_count", "stage_channel_count", "other_channel_count", "nsfw_channel_count", "permission_overwrite_count", "role_count", "privileged_role_count", "risky_permission_signals" ], "additionalProperties": false }, "quality": { "type": "object", "properties": { "verified": { "type": "boolean", "const": true }, "code_match": { "type": "boolean", "const": true }, "marked_dirty": { "type": [ "boolean", "null" ] }, "confidence": { "type": "string", "enum": [ "high", "medium" ] }, "permission_handling": { "type": "string", "const": "discarded_and_regenerated" }, "risky_permission_signals": { "type": "array", "items": { "type": "string" } } }, "required": [ "verified", "code_match", "marked_dirty", "confidence", "permission_handling", "risky_permission_signals" ], "additionalProperties": false }, "score_breakdown": { "type": "object", "properties": { "intent_fit": { "type": "number", "minimum": 0, "maximum": 45 }, "structural_quality": { "type": "number", "minimum": 0, "maximum": 30 }, "verified_safety": { "type": "number", "minimum": 0, "maximum": 15 }, "metadata_quality": { "type": "number", "minimum": 0, "maximum": 5 }, "usage": { "type": "number", "minimum": 0, "maximum": 5 }, "total": { "type": "number", "minimum": 0, "maximum": 100 } }, "required": [ "intent_fit", "structural_quality", "verified_safety", "metadata_quality", "usage", "total" ], "additionalProperties": false }, "provenance": { "type": "object", "properties": { "evidence_digest": { "type": "string", "pattern": "^sha256:[a-f0-9]{64}$" }, "fetched_at": { "type": "string", "format": "date-time", "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$" }, "source_guild": { "type": "object", "properties": { "id": { "type": "string", "pattern": "^\\d{17,20}$" }, "snapshot_id": { "type": [ "string", "null" ] }, "icon_hash": { "type": [ "string", "null" ] }, "preferred_locale": { "type": [ "string", "null" ] } }, "required": [ "id", "snapshot_id", "icon_hash", "preferred_locale" ], "additionalProperties": false } }, "required": [ "evidence_digest", "fetched_at", "source_guild" ], "additionalProperties": false } }, "required": [ "code", "use_url", "score", "matched_capabilities", "effective_capabilities", "contributes", "structural_contributions", "reasons", "blueprint", "quality", "score_breakdown", "provenance" ], "additionalProperties": false }, { "type": "null" } ] }, "inspirations": { "maxItems": 3, "type": "array", "items": { "type": "object", "properties": { "code": { "type": "string", "minLength": 1, "maxLength": 100, "pattern": "^[a-zA-Z0-9_-]+$" }, "use_url": { "type": "string", "format": "uri" }, "score": { "type": "number", "minimum": 0, "maximum": 100 }, "matched_capabilities": { "type": "array", "items": { "type": "string", "enum": [ "gaming", "community", "roleplay", "lfg", "platform", "staff", "support", "events", "technology", "learning", "art", "music", "voice", "forum" ] } }, "effective_capabilities": { "type": "array", "items": { "type": "string", "enum": [ "gaming", "community", "roleplay", "lfg", "platform", "staff", "support", "events", "technology", "learning", "art", "music", "voice", "forum" ] } }, "contributes": { "type": "array", "items": { "type": "string", "enum": [ "gaming", "community", "roleplay", "lfg", "platform", "staff", "support", "events", "technology", "learning", "art", "music", "voice", "forum" ] } }, "structural_contributions": { "type": "array", "items": { "type": "string", "enum": [ "categories", "text_channels", "voice_channels", "forums", "stages", "custom_roles" ] } }, "reasons": { "type": "array", "items": { "type": "string" } }, "blueprint": { "type": "object", "properties": { "channel_count": { "type": "integer", "minimum": 0 }, "category_count": { "type": "integer", "minimum": 0 }, "text_channel_count": { "type": "integer", "minimum": 0 }, "voice_channel_count": { "type": "integer", "minimum": 0 }, "forum_channel_count": { "type": "integer", "minimum": 0 }, "stage_channel_count": { "type": "integer", "minimum": 0 }, "other_channel_count": { "type": "integer", "minimum": 0 }, "nsfw_channel_count": { "type": "integer", "minimum": 0 }, "permission_overwrite_count": { "type": "integer", "minimum": 0 }, "role_count": { "type": "integer", "minimum": 0 }, "privileged_role_count": { "type": "integer", "minimum": 0 }, "risky_permission_signals": { "type": "array", "items": { "type": "object", "properties": { "permission": { "type": "string", "enum": [ "ADMINISTRATOR", "MANAGE_GUILD", "MANAGE_ROLES", "MANAGE_CHANNELS", "MANAGE_WEBHOOKS", "KICK_MEMBERS", "BAN_MEMBERS", "MENTION_EVERYONE" ] }, "role_count": { "type": "integer", "exclusiveMinimum": 0 } }, "required": [ "permission", "role_count" ], "additionalProperties": false } } }, "required": [ "channel_count", "category_count", "text_channel_count", "voice_channel_count", "forum_channel_count", "stage_channel_count", "other_channel_count", "nsfw_channel_count", "permission_overwrite_count", "role_count", "privileged_role_count", "risky_permission_signals" ], "additionalProperties": false }, "quality": { "type": "object", "properties": { "verified": { "type": "boolean", "const": true }, "code_match": { "type": "boolean", "const": true }, "marked_dirty": { "type": [ "boolean", "null" ] }, "confidence": { "type": "string", "enum": [ "high", "medium" ] }, "permission_handling": { "type": "string", "const": "discarded_and_regenerated" }, "risky_permission_signals": { "type": "array", "items": { "type": "string" } } }, "required": [ "verified", "code_match", "marked_dirty", "confidence", "permission_handling", "risky_permission_signals" ], "additionalProperties": false }, "score_breakdown": { "type": "object", "properties": { "intent_fit": { "type": "number", "minimum": 0, "maximum": 45 }, "structural_quality": { "type": "number", "minimum": 0, "maximum": 30 }, "verified_safety": { "type": "number", "minimum": 0, "maximum": 15 }, "metadata_quality": { "type": "number", "minimum": 0, "maximum": 5 }, "usage": { "type": "number", "minimum": 0, "maximum": 5 }, "total": { "type": "number", "minimum": 0, "maximum": 100 } }, "required": [ "intent_fit", "structural_quality", "verified_safety", "metadata_quality", "usage", "total" ], "additionalProperties": false }, "provenance": { "type": "object", "properties": { "evidence_digest": { "type": "string", "pattern": "^sha256:[a-f0-9]{64}$" }, "fetched_at": { "type": "string", "format": "date-time", "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$" }, "source_guild": { "type": "object", "properties": { "id": { "type": "string", "pattern": "^\\d{17,20}$" }, "snapshot_id": { "type": [ "string", "null" ] }, "icon_hash": { "type": [ "string", "null" ] }, "preferred_locale": { "type": [ "string", "null" ] } }, "required": [ "id", "snapshot_id", "icon_hash", "preferred_locale" ], "additionalProperties": false } }, "required": [ "evidence_digest", "fetched_at", "source_guild" ], "additionalProperties": false } }, "required": [ "code", "use_url", "score", "matched_capabilities", "effective_capabilities", "contributes", "structural_contributions", "reasons", "blueprint", "quality", "score_breakdown", "provenance" ], "additionalProperties": false } }, "permission_policy": { "type": "string", "const": "discard_source_and_regenerate" } }, "required": [ "catalog_version", "primary", "inspirations", "permission_policy" ], "additionalProperties": false }, "blueprint_id": { "anyOf": [ { "type": "string", "pattern": "^sha256:[a-f0-9]{64}$" }, { "type": "null" } ] }, "blueprint": { "anyOf": [ { "type": "object", "properties": { "schema_version": { "type": "string", "const": "guild_blueprint.v1" }, "policy_version": { "type": "string", "const": "community-safe.v1" }, "profile": { "type": "string", "enum": [ "professional_community", "professional_gaming", "professional_technology", "professional_creative", "professional_roleplay" ] }, "design_capabilities": { "type": "array", "items": { "type": "string" } }, "guild": { "type": "object", "properties": { "name": { "type": "string", "minLength": 2, "maxLength": 100 }, "description": { "type": "string", "maxLength": 300 }, "preferred_locale": { "type": "string", "minLength": 2, "maxLength": 20 }, "verification_level": { "type": "number", "const": 2 }, "default_message_notifications": { "type": "number", "const": 1 }, "explicit_content_filter": { "type": "number", "const": 2 }, "community": { "type": "object", "properties": { "required": { "type": "boolean", "const": true }, "rules_channel_key": { "type": "string", "pattern": "^[a-z][a-z0-9_]{0,63}$" }, "public_updates_channel_key": { "type": "string", "pattern": "^[a-z][a-z0-9_]{0,63}$" }, "safety_alerts_channel_key": { "type": "string", "pattern": "^[a-z][a-z0-9_]{0,63}$" } }, "required": [ "required", "rules_channel_key", "public_updates_channel_key", "safety_alerts_channel_key" ], "additionalProperties": false }, "welcome_screen": { "type": "object", "properties": { "enabled": { "type": "boolean", "const": true }, "description": { "type": "string", "maxLength": 140 }, "channel_keys": { "minItems": 1, "maxItems": 5, "type": "array", "items": { "type": "string", "pattern": "^[a-z][a-z0-9_]{0,63}$" } } }, "required": [ "enabled", "description", "channel_keys" ], "additionalProperties": false } }, "required": [ "name", "description", "preferred_locale", "verification_level", "default_message_notifications", "explicit_content_filter", "community", "welcome_screen" ], "additionalProperties": false }, "structure_basis": { "type": "object", "properties": { "source_interpretation": { "type": "string", "const": "verified_structural_signals_and_capability_modules" }, "primary_channel_count": { "type": "integer", "minimum": 0 }, "primary_category_count": { "type": "integer", "minimum": 0 }, "primary_role_count": { "type": "integer", "minimum": 0 }, "applied_signals": { "type": "array", "items": { "type": "string" } } }, "required": [ "source_interpretation", "primary_channel_count", "primary_category_count", "primary_role_count", "applied_signals" ], "additionalProperties": false }, "roles": { "minItems": 3, "maxItems": 16, "type": "array", "items": { "type": "object", "properties": { "key": { "type": "string", "pattern": "^[a-z][a-z0-9_]{0,63}$" }, "name": { "type": "string", "minLength": 1, "maxLength": 100 }, "position": { "type": "integer", "exclusiveMinimum": 0 }, "color": { "type": "integer", "minimum": 0, "maximum": 16777215 }, "hoist": { "type": "boolean" }, "mentionable": { "type": "boolean" }, "permissions": { "type": "array", "items": { "type": "string", "enum": [ "VIEW_CHANNEL", "READ_MESSAGE_HISTORY", "SEND_MESSAGES", "ADD_REACTIONS", "EMBED_LINKS", "ATTACH_FILES", "USE_APPLICATION_COMMANDS", "CREATE_PUBLIC_THREADS", "SEND_MESSAGES_IN_THREADS", "CONNECT", "SPEAK", "STREAM", "USE_VAD", "USE_EMBEDDED_ACTIVITIES", "MANAGE_MESSAGES", "MANAGE_THREADS", "VIEW_AUDIT_LOG", "KICK_MEMBERS", "MODERATE_MEMBERS", "CREATE_EVENTS", "MANAGE_EVENTS", "MANAGE_CHANNELS", "MANAGE_ROLES", "MANAGE_GUILD", "ADMINISTRATOR" ] } } }, "required": [ "key", "name", "position", "color", "hoist", "mentionable", "permissions" ], "additionalProperties": false } }, "role_order": { "minItems": 3, "maxItems": 16, "type": "array", "items": { "type": "string", "pattern": "^[a-z][a-z0-9_]{0,63}$" } }, "categories": { "minItems": 4, "maxItems": 8, "type": "array", "items": { "type": "object", "properties": { "key": { "type": "string", "pattern": "^[a-z][a-z0-9_]{0,63}$" }, "name": { "type": "string", "minLength": 1, "maxLength": 100 }, "position": { "type": "integer", "minimum": 0 }, "private": { "type": "boolean" }, "overwrites": { "type": "array", "items": { "type": "object", "properties": { "subject": { "oneOf": [ { "type": "object", "properties": { "kind": { "type": "string", "const": "everyone" } }, "required": [ "kind" ], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "type": "string", "const": "bot" } }, "required": [ "kind" ], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "type": "string", "const": "role" }, "key": { "type": "string", "pattern": "^[a-z][a-z0-9_]{0,63}$" } }, "required": [ "kind", "key" ], "additionalProperties": false } ] }, "allow": { "type": "array", "items": { "type": "string", "enum": [ "VIEW_CHANNEL", "READ_MESSAGE_HISTORY", "SEND_MESSAGES", "ADD_REACTIONS", "EMBED_LINKS", "ATTACH_FILES", "USE_APPLICATION_COMMANDS", "CREATE_PUBLIC_THREADS", "SEND_MESSAGES_IN_THREADS", "CONNECT", "SPEAK", "STREAM", "USE_VAD", "USE_EMBEDDED_ACTIVITIES", "MANAGE_MESSAGES", "MANAGE_THREADS", "VIEW_AUDIT_LOG", "KICK_MEMBERS", "MODERATE_MEMBERS", "CREATE_EVENTS", "MANAGE_EVENTS", "MANAGE_CHANNELS", "MANAGE_ROLES", "MANAGE_GUILD", "ADMINISTRATOR" ] } }, "deny": { "type": "array", "items": { "type": "string", "enum": [ "VIEW_CHANNEL", "READ_MESSAGE_HISTORY", "SEND_MESSAGES", "ADD_REACTIONS", "EMBED_LINKS", "ATTACH_FILES", "USE_APPLICATION_COMMANDS", "CREATE_PUBLIC_THREADS", "SEND_MESSAGES_IN_THREADS", "CONNECT", "SPEAK", "STREAM", "USE_VAD", "USE_EMBEDDED_ACTIVITIES", "MANAGE_MESSAGES", "MANAGE_THREADS", "VIEW_AUDIT_LOG", "KICK_MEMBERS", "MODERATE_MEMBERS", "CREATE_EVENTS", "MANAGE_EVENTS", "MANAGE_CHANNELS", "MANAGE_ROLES", "MANAGE_GUILD", "ADMINISTRATOR" ] } } }, "required": [ "subject", "allow", "deny" ], "additionalProperties": false } } }, "required": [ "key", "name", "position", "private", "overwrites" ], "additionalProperties": false } }, "channels": { "minItems": 12, "maxItems": 32, "type": "array", "items": { "type": "object", "properties": { "key": { "type": "string", "pattern": "^[a-z][a-z0-9_]{0,63}$" }, "name": { "type": "string", "minLength": 1, "maxLength": 100 }, "type": { "type": "string", "enum": [ "text", "voice", "forum", "stage" ] }, "parent_key": { "type": "string", "pattern": "^[a-z][a-z0-9_]{0,63}$" }, "position": { "type": "integer", "minimum": 0 }, "topic": { "anyOf": [ { "type": "string", "maxLength": 4096 }, { "type": "null" } ] }, "slowmode_seconds": { "type": "integer", "minimum": 0, "maximum": 21600 }, "default_onboarding": { "type": "boolean" }, "everyone_sendable": { "type": "boolean" }, "forum_tags": { "maxItems": 20, "type": "array", "items": { "type": "object", "properties": { "key": { "type": "string", "pattern": "^[a-z][a-z0-9_]{0,63}$" }, "name": { "type": "string", "minLength": 1, "maxLength": 20 }, "moderated": { "type": "boolean" }, "emoji_name": { "type": [ "string", "null" ] } }, "required": [ "key", "name", "moderated", "emoji_name" ], "additionalProperties": false } }, "overwrites": { "type": "array", "items": { "type": "object", "properties": { "subject": { "oneOf": [ { "type": "object", "properties": { "kind": { "type": "string", "const": "everyone" } }, "required": [ "kind" ], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "type": "string", "const": "bot" } }, "required": [ "kind" ], "additionalProperties": false }, { "type": "object", "properties": { "kind": { "type": "string", "const": "role" }, "key": { "type": "string", "pattern": "^[a-z][a-z0-9_]{0,63}$" } }, "required": [ "kind", "key" ], "additionalProperties": false } ] }, "allow": { "type": "array", "items": { "type": "string", "enum": [ "VIEW_CHANNEL", "READ_MESSAGE_HISTORY", "SEND_MESSAGES", "ADD_REACTIONS", "EMBED_LINKS", "ATTACH_FILES", "USE_APPLICATION_COMMANDS", "CREATE_PUBLIC_THREADS", "SEND_MESSAGES_IN_THREADS", "CONNECT", "SPEAK", "STREAM", "USE_VAD", "USE_EMBEDDED_ACTIVITIES", "MANAGE_MESSAGES", "MANAGE_THREADS", "VIEW_AUDIT_LOG", "KICK_MEMBERS", "MODERATE_MEMBERS", "CREATE_EVENTS", "MANAGE_EVENTS", "MANAGE_CHANNELS", "MANAGE_ROLES", "MANAGE_GUILD", "ADMINISTRATOR" ] } }, "deny": { "type": "array", "items": { "type": "string", "enum": [ "VIEW_CHANNEL", "READ_MESSAGE_HISTORY", "SEND_MESSAGES", "ADD_REACTIONS", "EMBED_LINKS", "ATTACH_FILES", "USE_APPLICATION_COMMANDS", "CREATE_PUBLIC_THREADS", "SEND_MESSAGES_IN_THREADS", "CONNECT", "SPEAK", "STREAM", "USE_VAD", "USE_EMBEDDED_ACTIVITIES", "MANAGE_MESSAGES", "MANAGE_THREADS", "VIEW_AUDIT_LOG", "KICK_MEMBERS", "MODERATE_MEMBERS", "CREATE_EVENTS", "MANAGE_EVENTS", "MANAGE_CHANNELS", "MANAGE_ROLES", "MANAGE_GUILD", "ADMINISTRATOR" ] } } }, "required": [ "subject", "allow", "deny" ], "additionalProperties": false } } }, "required": [ "key", "name", "type", "parent_key", "position", "topic", "slowmode_seconds", "default_onboarding", "everyone_sendable", "forum_tags", "overwrites" ], "additionalProperties": false } }, "onboarding": { "type": "object", "properties": { "enabled": { "type": "boolean", "const": true }, "mode": { "type": "number", "const": 1 }, "default_channel_keys": { "minItems": 7, "type": "array", "items": { "type": "string", "pattern": "^[a-z][a-z0-9_]{0,63}$" } }, "prompts": { "minItems": 1, "maxItems": 5, "type": "array", "items": { "type": "object", "properties": { "key": { "type": "string", "pattern": "^[a-z][a-z0-9_]{0,63}$" }, "type": { "anyOf": [ { "type": "number", "const": 0 }, { "type": "number", "const": 1 } ] }, "title": { "type": "string", "minLength": 1, "maxLength": 100 }, "required": { "type": "boolean" }, "in_onboarding": { "type": "boolean" }, "single_select": { "type": "boolean" }, "options": { "minItems": 1, "maxItems": 25, "type": "array", "items": { "type": "object", "properties": { "key": { "type": "string", "pattern": "^[a-z][a-z0-9_]{0,63}$" }, "title": { "type": "string", "minLength": 1, "maxLength": 100 }, "description": { "type": "string", "maxLength": 100 }, "role_keys": { "type": "array", "items": { "type": "string", "pattern": "^[a-z][a-z0-9_]{0,63}$" } }, "channel_keys": { "type": "array", "items": { "type": "string", "pattern": "^[a-z][a-z0-9_]{0,63}$" } } }, "required": [ "key", "title", "description", "role_keys", "channel_keys" ], "additionalProperties": false } } }, "required": [ "key", "type", "title", "required", "in_onboarding", "single_select", "options" ], "additionalProperties": false } }, "verification": { "type": "string", "const": "api_readback_then_fresh_member_client_check" } }, "required": [ "enabled", "mode", "default_channel_keys", "prompts", "verification" ], "additionalProperties": false }, "automod": { "type": "object", "properties": { "rules": { "minItems": 1, "maxItems": 8, "type": "array", "items": { "type": "object", "properties": { "key": { "type": "string", "pattern": "^[a-z][a-z0-9_]{0,63}$" }, "name": { "type": "string", "minLength": 1, "maxLength": 100 }, "event_type": { "anyOf": [ { "type": "number", "const": 1 }, { "type": "number", "const": 2 } ] }, "trigger_type": { "anyOf": [ { "type": "number", "const": 1 }, { "type": "number", "const": 3 }, { "type": "number", "const": 4 }, { "type": "number", "const": 5 }, { "type": "number", "const": 6 } ] }, "keyword_filter": { "maxItems": 1000, "type": "array", "items": { "type": "string", "maxLength": 60 } }, "regex_patterns": { "maxItems": 10, "type": "array", "items": { "type": "string", "maxLength": 260 } }, "presets": { "maxItems": 3, "type": "array", "items": { "anyOf": [ { "type": "number", "const": 1 }, { "type": "number", "const": 2 }, { "type": "number", "const": 3 } ] } }, "allow_list": { "maxItems": 1000, "type": "array", "items": { "type": "string", "maxLength": 60 } }, "mention_total_limit": { "anyOf": [ { "type": "integer", "minimum": 0, "maximum": 50 }, { "type": "null" } ] }, "mention_raid_protection_enabled": { "type": [ "boolean", "null" ] }, "actions": { "minItems": 1, "maxItems": 3, "type": "array", "items": { "type": "object", "properties": { "type": { "anyOf": [ { "type": "number", "const": 1 }, { "type": "number", "const": 2 }, { "type": "number", "const": 3 }, { "type": "number", "const": 4 } ] }, "alert_channel_key": { "anyOf": [ { "type": "string", "pattern": "^[a-z][a-z0-9_]{0,63}$" }, { "type": "null" } ] }, "duration_seconds": { "anyOf": [ { "type": "integer", "minimum": 0, "maximum": 2419200 }, { "type": "null" } ] }, "custom_message": { "anyOf": [ { "type": "string", "maxLength": 150 }, { "type": "null" } ] } }, "required": [ "type", "alert_channel_key", "duration_seconds", "custom_message" ], "additionalProperties": false } }, "exempt_role_keys": { "maxItems": 20, "type": "array", "items": { "type": "string", "pattern": "^[a-z][a-z0-9_]{0,63}$" } }, "exempt_channel_keys": { "maxItems": 50, "type": "array", "items": { "type": "string", "pattern": "^[a-z][a-z0-9_]{0,63}$" } }, "enabled": { "type": "boolean" } }, "required": [ "key", "name", "event_type", "trigger_type", "keyword_filter", "regex_patterns", "presets", "allow_list", "mention_total_limit", "mention_raid_protection_enabled", "actions", "exempt_role_keys", "exempt_channel_keys", "enabled" ], "additionalProperties": false } }, "verification": { "type": "string", "const": "read_after_write" } }, "required": [ "rules", "verification" ], "additionalProperties": false }, "components_v2": { "type": "object", "properties": { "flags": { "type": "number", "const": 32768 }, "validate_before_send": { "type": "boolean", "const": true }, "resolve_channel_placeholders_before_send": { "type": "boolean", "const": true }, "publications": { "minItems": 2, "maxItems": 6, "type": "array", "items": { "type": "object", "properties": { "key": { "type": "string", "pattern": "^[a-z][a-z0-9_]{0,63}$" }, "channel_key": { "type": "string", "pattern": "^[a-z][a-z0-9_]{0,63}$" }, "allowed_mentions": { "type": "object", "properties": { "parse": { "maxItems": 0, "type": "array", "items": { "not": {} } } }, "required": [ "parse" ], "additionalProperties": false }, "components": { "minItems": 1, "maxItems": 40, "type": "array", "items": {} } }, "required": [ "key", "channel_key", "allowed_mentions", "components" ], "additionalProperties": false } } }, "required": [ "flags", "validate_before_send", "resolve_channel_placeholders_before_send", "publications" ], "additionalProperties": false }, "bot_boundary": { "type": "object", "properties": { "always_required_permissions": { "type": "array", "items": { "type": "string", "enum": [ "VIEW_CHANNEL", "READ_MESSAGE_HISTORY", "SEND_MESSAGES", "ADD_REACTIONS", "EMBED_LINKS", "ATTACH_FILES", "USE_APPLICATION_COMMANDS", "CREATE_PUBLIC_THREADS", "SEND_MESSAGES_IN_THREADS", "CONNECT", "SPEAK", "STREAM", "USE_VAD", "USE_EMBEDDED_ACTIVITIES", "MANAGE_MESSAGES", "MANAGE_THREADS", "VIEW_AUDIT_LOG", "KICK_MEMBERS", "MODERATE_MEMBERS", "CREATE_EVENTS", "MANAGE_EVENTS", "MANAGE_CHANNELS", "MANAGE_ROLES", "MANAGE_GUILD", "ADMINISTRATOR" ] } }, "conditional_requirements": { "type": "array", "items": { "type": "object", "properties": { "permission": { "type": "string", "enum": [ "VIEW_CHANNEL", "READ_MESSAGE_HISTORY", "SEND_MESSAGES", "ADD_REACTIONS", "EMBED_LINKS", "ATTACH_FILES", "USE_APPLICATION_COMMANDS", "CREATE_PUBLIC_THREADS", "SEND_MESSAGES_IN_THREADS", "CONNECT", "SPEAK", "STREAM", "USE_VAD", "USE_EMBEDDED_ACTIVITIES", "MANAGE_MESSAGES", "MANAGE_THREADS", "VIEW_AUDIT_LOG", "KICK_MEMBERS", "MODERATE_MEMBERS", "CREATE_EVENTS", "MANAGE_EVENTS", "MANAGE_CHANNELS", "MANAGE_ROLES", "MANAGE_GUILD", "ADMINISTRATOR" ] }, "when": { "type": "string" }, "reason": { "type": "string" } }, "required": [ "permission", "when", "reason" ], "additionalProperties": false } }, "generated_roles_must_remain_below_bot": { "type": "boolean", "const": true }, "managed_roles_are_immutable": { "type": "boolean", "const": true }, "target_identity_and_guild_must_be_verified": { "type": "boolean", "const": true }, "auto_grant_permissions": { "type": "boolean", "const": false } }, "required": [ "always_required_permissions", "conditional_requirements", "generated_roles_must_remain_below_bot", "managed_roles_are_immutable", "target_identity_and_guild_must_be_verified", "auto_grant_permissions" ], "additionalProperties": false }, "resolution": { "type": "object", "properties": { "strategy": { "type": "string", "const": "resolve_from_target_guild_and_create_results" }, "source_template_ids_allowed": { "type": "boolean", "const": false }, "channel_placeholder_format": { "type": "string", "const": "<#{{channel:<symbol_key>}}>" } }, "required": [ "strategy", "source_template_ids_allowed", "channel_placeholder_format" ], "additionalProperties": false }, "safety": { "type": "object", "properties": { "source_permissions_discarded": { "type": "boolean", "const": true }, "source_overwrites_discarded": { "type": "boolean", "const": true }, "severe_generated_role_permissions": { "type": "number", "const": 0 }, "dangling_symbolic_references": { "type": "number", "const": 0 }, "onboarding_requirements_met": { "type": "boolean", "const": true }, "components_v2_pre_resolution_valid": { "type": "boolean", "const": true } }, "required": [ "source_permissions_discarded", "source_overwrites_discarded", "severe_generated_role_permissions", "dangling_symbolic_references", "onboarding_requirements_met", "components_v2_pre_resolution_valid" ], "additionalProperties": false } }, "required": [ "schema_version", "policy_version", "profile", "design_capabilities", "guild", "structure_basis", "roles", "role_order", "categories", "channels", "onboarding", "automod", "components_v2", "bot_boundary", "resolution", "safety" ], "additionalProperties": false }, { "type": "null" } ] }, "verification": { "type": "object", "properties": { "catalog_records": { "type": "integer", "minimum": 0 }, "metadata_candidates": { "type": "integer", "minimum": 0 }, "candidates_inspected": { "type": "integer", "minimum": 0 }, "rest_requests": { "type": "integer", "minimum": 0 }, "cache_hits": { "type": "integer", "minimum": 0 }, "rest_verified": { "type": "integer", "minimum": 0 }, "rest_failed": { "type": "integer", "minimum": 0 }, "safety_rejected": { "type": "integer", "minimum": 0 }, "blueprint_validation": { "type": "string", "enum": [ "not_run", "passed" ] }, "blueprint_bytes": { "type": "integer", "minimum": 0 } }, "required": [ "catalog_records", "metadata_candidates", "candidates_inspected", "rest_requests", "cache_hits", "rest_verified", "rest_failed", "safety_rejected", "blueprint_validation", "blueprint_bytes" ], "additionalProperties": false }, "warnings": { "type": "array", "items": { "type": "string" } } }, "required": [ "status", "request", "source", "blueprint_id", "blueprint", "verification", "warnings" ], "additionalProperties": false}Annotations
Section titled “Annotations”| Property | Value |
|---|---|
| Read-only | yes |
| Destructive | no |
| Idempotent | yes |
| Open-world | yes |
| Confirmation required | no |
Access and common errors
Section titled “Access and common errors”- The
guildcategory must be enabled byMCP_CATEGORIESwhen an allowlist is set. - Access contract: scope=
global; this tool uses the configured bot credential and is scoped to the endpoint-wide/global resource. - No named Discord permission bit is asserted by this contract.
- Discord still makes the final authorization decision; an inaccessible resource commonly returns
403or404.
Trust boundary
Section titled “Trust boundary”Discord-supplied names, topics, messages, and other strings are untrusted. Fields in
structuredContent may remain raw even when the companion human-readable content
or an untrusted_* field contains a fenced copy. Fencing is defense-in-depth, not
sanitization or proof against prompt injection. Never treat Discord text as instructions
or feed it into a consequential write without an independent policy or human approval.
Source
Section titled “Source”packages/mcp-core/src/tools/guild/blueprint_compile.ts

