Module Hook Implement
module_hook_implementImplement a hook in an existing Drupal module by providing the module machine name and hook, with an optional file path.
Instructions
Implement a hook in an existing module.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"machine_name": "<machine_name>",
"hook": "<hook>"
},
"name": "module_hook_implement"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| hook | Yes | ||
| path | No | ||
| machine_name | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||