iiRecord
Agentic AI Atlas · UserPromptExpansion (Claude Code)
hook-surface:claude.user-prompt-expansiona5c.ai
II.
HookSurface JSON

hook-surface:claude.user-prompt-expansion

Structured · live

UserPromptExpansion (Claude Code) json

Inspect the normalized record payload exactly as the atlas UI reads it.

File · channels-hooks/hook-surfaces/native/claude-code-extended-hooks.yamlCluster · channels-hooks
Record JSON
{
  "id": "hook-surface:claude.user-prompt-expansion",
  "_kind": "HookSurface",
  "_file": "channels-hooks/hook-surfaces/native/claude-code-extended-hooks.yaml",
  "_cluster": "channels-hooks",
  "attributes": {
    "eventName": "UserPromptExpansion (Claude Code)",
    "displayName": "UserPromptExpansion (Claude Code)",
    "kind": "native",
    "originVendor": "Anthropic",
    "direction": "pre",
    "blocking": true,
    "family": "shell-hook",
    "payloadSchema": {
      "type": "object",
      "required": [
        "hook_event_name",
        "expansion_type",
        "command_name",
        "command_source",
        "prompt"
      ],
      "properties": {
        "hook_event_name": {
          "type": "string",
          "const": "UserPromptExpansion"
        },
        "expansion_type": {
          "type": "string",
          "enum": [
            "slash_command",
            "mcp_prompt"
          ]
        },
        "command_name": {
          "type": "string"
        },
        "command_args": {
          "type": "string"
        },
        "command_source": {
          "type": "string",
          "enum": [
            "plugin",
            "skill",
            "builtin",
            "mcp"
          ]
        },
        "prompt": {
          "type": "string"
        }
      }
    },
    "description": "Fires when a slash command (or MCP prompt) expands into a prompt — before\nthe expanded prompt enters the model context. Subscribers can inspect the\nexpansion, mutate it, or block it via decision: \"block\" / exit 2.\nMatchable by command name. Canonicalizes loosely to UserPromptSubmit.\n"
  },
  "outgoingEdges": [
    {
      "from": "hook-surface:claude.user-prompt-expansion",
      "to": "hook-surface:user-prompt-submit",
      "kind": "canonicalized_to",
      "attributes": {}
    }
  ],
  "incomingEdges": [
    {
      "from": "agent-runtime-impl:claude-code.runtime@1.x",
      "to": "hook-surface:claude.user-prompt-expansion",
      "kind": "exposes",
      "attributes": {}
    },
    {
      "from": "hook-mapping:claude-user-prompt-expansion",
      "to": "hook-surface:claude.user-prompt-expansion",
      "kind": "maps_hook",
      "attributes": {}
    }
  ]
}