generate_php_function
Create WordPress PHP functions that follow coding standards, including parameters, return types, and hook registration for actions and filters.
Instructions
Generate WordPress PHP function following coding standards
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": {
"name": "<name>",
"body": "<body>"
},
"name": "generate_php_function"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | Function name | |
| description | No | Function description | |
| parameters | No | Function parameters | |
| returnType | No | Return type | |
| body | Yes | Function body code | |
| hooks | No | Hooks to register |