Add declare(strict_types=1)
add_strict_typesAdd strict types declaration to PHP files. Use dry run to preview changes or force to overwrite existing declarations.
Instructions
Bir PHP dosyasının en üstüne 'declare(strict_types=1);' ekler (yoksa). 'dryRun=true' ile önizleme.
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": {
"filepath": "<filepath>"
},
"name": "add_strict_types"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| force | No | Mevcut declare(strict_types=...) satırını değiştir. | |
| dryRun | No | Sadece önizleme. Varsayılan: true. | |
| filepath | Yes | Hedef dosya. Örnek: ./src/Foo.php |